KandZ – Tuts

We like to help…!

CSS 8 ๐Ÿ’ป text-align, letter-spacing, word-spacing and text-transform

text-align โ†’ specifies how the text will be aligned within its parent element
it can take start, end, left, right, center, justify, match-parent
it sets the alignment to left
it sets the alignment to center
it sets the alignment to right
letter-spacing โ†’ sets the space between the letters in a word
it can take normal keyword and length values like em, px etc
it sets the space to normal
it sets the space to 2px

word-spacing โ†’ sets the space between words
it can take the keyword normal, and length values like px, em etc;
example 1 with normal value
example 2 with 2px value
text-transform โ†’ changes the appearance of the text by capitalizing or the opposite
it can take capitalize, uppercase, lowercase and none keywords
example 1 with uppercase value
example 2 with capitalize value

8 – text-align, letter spacing, word-spacing and text-transform

<div class="left-aligned">This text is left-aligned within the first div.</div>
<div class="center-aligned">This text is centered within the Second div.</div>
<div class="right-aligned">This text is right-aligned within the Third div.</div>
<p class="normal-spacing">This text has normal letter spacing.</p>
<p class="expanded-spacing">This text has expanded letter spacing.</p>
<p class="normal-spacing">This text has normal word spacing.</p>
<p class="expanded-spacing">This text has expanded word spacing.</p>
<p class="uppercase">This text is in uppercase.</p>
<p class="capitalize">this text is capitalized.</p>
div.left-aligned {
    text-align: left; /* Aligns the text to the left */
    width: 50%;
    border: 1px solid #ddd;
    padding: 10px;
}

div.center-aligned {
    text-align: center; /* Centers the text within the div */
    width: 50%;
    border: 1px solid #ddd;
    padding: 10px;
}

div.right-aligned {
    text-align: right; /* Aligns the text to the right */
    width: 50%;
    border: 1px solid #ddd;
    padding: 10px;
}

p.normal-spacing {
    letter-spacing: normal; /* Default spacing between letters */
    font-size: 18px;
}

p.expanded-spacing {
    letter-spacing: 2px; /* Increases the space between letters */
    font-size: 18px;
}

p.normal-spacing {
    word-spacing: normal; /* Default spacing between words */
    font-size: 18px;
}

p.expanded-spacing {
    word-spacing: 2px; /* Increases the space between words */
    font-size: 18px;
 }   

p.uppercase {
    text-transform: uppercase; /* Converts all letters to uppercase */
    font-size: 18px;
}

p.capitalize {
    text-transform: capitalize; /* Capitalizes the first letter of each word */
    font-size: 18px;
    }     

Stop using slow, ad-bloated tool sites! ๐Ÿคฎ

๐Ÿ”Ž Search “KandZ Tools” on Google to use many professional utilities for free.

KandZ.me is the ultimate minimalist hub for:
โœ… Finance (Mortgage, Interest, Inflation)
โœ… Tech (Base64, JSON, Dev Suite, IP)
โœ… Health (BMI, BMR, TDEE)
โœ… Productivity (Timer, Workspace, QR)

โšก๏ธ Fast & Private
๐Ÿ”’ No data leaves your device
๐Ÿ’Ž 100% Free

๐Ÿ”— Use it now: https://tools.kandz.me
๐Ÿ”– Bookmark itโ€”youโ€™ll need it later!

Leave a Reply

Ads Blocker Image Powered by Code Help Pro

Ads Blocker Detected!!!

We have detected that you are using extensions to block ads. Please support us by disabling these ads blocker.

Powered By
100% Free SEO Tools - Tool Kits PRO