Slight rendering of strings in MS Outlook

After doing a little research, I found that MS Outlook will not display the line height in the HTML message by anything less than 16 pixels.

This is a bit of a problem since I really need less.

Does anyone know of a fix for this?

+4
source share
3 answers

What code are you using? It will be below 16 pixels, but only if the font size is 14 pixels or less. Also, make sure that you set the row height on the parent TD โ€” that is, at the nearest block level, and not at the inline element.

+1
source

make sure you have 0 padding and โ€œdisplay: blockโ€ fields on all inline (especially images!) and set the line height to the expected height.

Outlook <2007 uses IE as a rendering engine, 2010 uses WORD.

Yes, this is very weak.

+1
source

This CSS can fix this problem, but it will only work with block elements (p, div, .. etc):

mso-line-height-rule:exactly; line-height:10px; 

If you are trying to create a vertical distance, use line-height and font-size to provide the height:

 line-height:5px;font-size:5px;height:5px; 

Outlook.com (Hotmail) will override your CSS line-height with their help, so you will need to use it to "reset" your CSS after changing it:

 .ExternalClass, .ExternalClass p, .ExternalClass span, .ExternalClass font, .ExternalClass td, .ExternalClass div {line-height: 100% !important;} 

Outlook.com continued: then if you have any elements with line-height:0 , you will need to specify the id attribute for them, and then specifically reset those:

 .ExternalClass #elementWithNoLineHeight { line-height:0 !important; } 
0
source

All Articles