Loading Please Wait...

Logo Lynxsia IT Solutions

CSS Text Alignment

CSS Text Align

CSS text-align properties is used to set horizontal alignment of the inline element.

Text Align Values

Keyword value: left, right, center, justify, start, end, match-parent.

Global value: inherit, initial, revert, revert-layer, unset.

					 
        
          /* Keyword values */
          text-align: left;
          text-align: right;
          text-align: center;
          text-align: justify;
          text-align: start;
          text-align: end;
          text-align: match-parent;

          /* Global values */
          text-align: inherit;
          text-align: initial;
          text-align: revert;
          text-align: revert-layer;
          text-align: unset;
        
      

left: align to left edge of the box

right: align to right edge of the box

center: align to center within the box

justify: text is spaced to lined up the left and right edge of the box

start: same as left if direction is left-to-right and right if direction is right-to-left

end: same as right if direction is left-to-right and left if direction is right-to-left

match-parent: same as inherit but the start and end is calculated by the direction of the parent.

CSS Text Align Last

CSS text-align-last properties is used to set horizontal alignment of the last line of the inline element.

Text Align Last Values

Keyword value: auto, left, right, center, justify, start, end.

Global value: inherit, initial, revert, revert-layer, unset.

					 
        
          /* Keyword values */
          text-align-last: auto;
          text-align-last: start;
          text-align-last: end;
          text-align-last: left;
          text-align-last: right;
          text-align-last: center;
          text-align-last: justify;

          /* Global values */
          text-align-last: inherit;
          text-align-last: initial;
          text-align-last: revert;
          text-align-last: revert-layer;
          text-align-last: unset;
        
      
CSS Vertical Align

CSS vertical-align properties is used to set vertical alignment of the inline element.

Vertical Align Values

Keyword value: baseline, sub, super, text-top, text-bottom, middle, top, bottom.

Length value: 5px, 1em, etc.

Percentage value: 5%, 10%, etc.

Global value: inherit, initial, revert, revert-layer, unset.

					 
        
          /* Keyword values */
          vertical-align: baseline;
          vertical-align: sub;
          vertical-align: super;
          vertical-align: text-top;
          vertical-align: text-bottom;
          vertical-align: middle;
          vertical-align: top;
          vertical-align: bottom;

          /* length values */
          vertical-align: 10em;
          vertical-align: 4px;

          /* percentage values */
          vertical-align: 20%;

          /* Global values */
          vertical-align: inherit;
          vertical-align: initial;
          vertical-align: revert;
          vertical-align: revert-layer;
          vertical-align: unset;
        
      

How you feel about this blog:

Share this blog on:

Report Us

If you find any error in the turtorials, or want to share your suggestion/feedback, feel free to send us email at: info@lynxsia.com

Contact Us
Ads
Logo
Lynxsia IT Solutions

We are concern with various development process like website design & development, E-commerce development, Software development, Application development, SMS & Bulk SMS Provider, PWA Development, and many more..

Kotwali Road, Chhiptehri, Banda, 210001, UP, India

Copyright © 2022, Lynxsia IT Solutions, All rights reserved