html - Weird sizing issues with h1 and span elements -


i have code:

<h1><a href="">windows store<br /><span class="smallsubtext">apps</span></a></h1> 

and:

#windowsstoreapplications {     float: right;     width: 50%;      font-size: 16pt;     text-align: center;     height: 182px;      background-color: #9dca87;     border-top: 6px solid #aedf66; }   .smallsubtext {     font-size: 16pt; } 

as can see, both h1 , span set same font-size - not how want it's how made because noticed font-sizes not matching how should be.

i made them both same size demonstrate both same size in code, when run site , @ - they're different sizes.

is due size weirdness h1 element?

well first, if havn't declared font-size h1's (and rest) browser defaults implemented vary in size.

second, should not using pt size, should using px, em or %.

#windowsstoreapplications h1 { font-size:16pt; /* or preffered unit */ } 

Comments

Popular posts from this blog

css - Which browser returns the correct result for getBoundingClientRect of an SVG element? -

gcc - Calling fftR4() in c from assembly -

Function that returns a formatted array in VBA -