Extra pixels are being added to span element
问题 I can't figure out why but 2 extra pixels are added to the height of a span element. Here is an example: <!DOCTYPE html> <html> <head> </head> <body> <span style="font-size:20px;line-height: 20px"> test </span> </body> </html> In chrome debugger tools the span has a height of 22 pixels. If I change the test element to a div the extra pixels go away. <!DOCTYPE html> <html> <head> </head> <body> <div style="font-size:20px;line-height: 20px"> test </div> </body> </html> here is a fiddle with the