[dpdk-web] [PATCH] fix navigation bar with fallback font

Thomas Monjalon thomas.monjalon at 6wind.com
Tue May 24 21:49:04 CEST 2016


When the font exo2 is not available (because of disabled download),
the fallback font can be too big and make the menu oversized on
two lines.
The fallback font size is adjusted thanks to font-size-adjust
property. It is supported only on Firefox.

Signed-off-by: Thomas Monjalon <thomas.monjalon at 6wind.com>
---
 layout.css | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/layout.css b/layout.css
index df9e220..9b06455 100644
--- a/layout.css
+++ b/layout.css
@@ -14,7 +14,7 @@ header h1 {
 	margin: 0 auto 0.75em;
 	padding-top: 0.25em;
 	text-align: center;
-	font: italic bold 2em 'exo2',sans-serif;
+	font: italic bold 2em 'exo2', sans-serif;
 }
 header h1 a {
 	color: #333;
@@ -38,7 +38,8 @@ header nav li {
 header nav li a {
 	display: inline-block;
 	padding: 0.8em 1.5em;
-	font: normal 1em/1 'exo2',sans-serif;
+	font: normal 1em/1 'exo2', sans-serif;
+	font-size-adjust: 0.51;
 	color: #ccc;
 	-webkit-transition: background-color .1s linear;
 	-moz-transition: background-color .1s linear;
-- 
2.7.0



More information about the web mailing list