Project

General

Profile

Bug #1267

Inappropriate font choice in HTML-output from mod_dirlisting

Added by rasmus over 11 years ago. Updated over 11 years ago.

Status:
Fixed
Priority:
Normal
Assignee:
-
Category:
mod_dirlisting
Target version:
Start date:
Due date:
% Done:

0%

Estimated time:
Missing in 1.5.x:

Description


"Courier New", Courier, monospace

should be


monospace

Specifying monospace will cause the client browser to chose the most appropriate font for monospace (often chosen by the user). Explicitly specifying a certain typeface will override the users choice.

So, the HTML/CSS output should be adjusted not to override the users' settings.

My suggestion is to update mod_dirlisting.c to generate this css instead:


a, a:active {text-decoration: none; color: blue;}
a:visited {color: #48468F;}
a:hover, a:focus {text-decoration: underline; color: red;}
h2 {margin-bottom: .6em;}
table {margin-left: .7em;}
th, td { font-family: monospace; text-align: left;}
th { font-weight: bold; padding-right: 1.2em; padding-bottom: .4em;}
td {padding-right: 1.2em;}
td.s, th.s {text-align: right;}
div.list { border-top: 1px solid #999; border-bottom: 1px solid #999; padding-top: .6em; padding-bottom: 1em;}
div.foot { font-family: monospace; font-size: 90%; color: #777; padding-top: .5em;}

That would allow for respecting user configuration, be easily printable and zoom as expected in web browsers that support it.[

lighttpd_index_font_size.patch (679 Bytes) lighttpd_index_font_size.patch font size / font face directory index patch xxv, 2007-08-11 14:47

Associated revisions

Revision 1897 (diff)
Added by jan over 11 years ago

replaced hard-coded fonts and font-size by relative sizes (fixes #1267)

History

#1

Updated by xxv over 11 years ago

I added a patch that applies this change and also uses the user's default font sizes. "pt" sizes are inappropriate for text intended to be read on a screen, as points are a physical units of measure akin to inches.

#2

Updated by rasmus over 11 years ago

Great!

#3

Updated by jan over 11 years ago

  • Status changed from New to Fixed
  • Resolution set to fixed

applied in r1897 for 1.5.0.

Also available in: Atom