Mercurial > hg-stable
changeset 31630:c208bc65318a
gitweb: use monospace font for commit messages
Commit messages often contain vertically aligned text. The default
paper style already uses monospace fonts for rendering commit messages.
And, AFAICT, a number of Git servers also render commit messages
with monospace. It seems like the reasonable thing to do.
This commit converts all instances of the full commit message
in the gitweb style to render with monospace.
author | Gregory Szorc <gregory.szorc@gmail.com> |
---|---|
date | Fri, 24 Mar 2017 19:52:43 -0700 |
parents | c60091fa1426 |
children | 0febf8e4e2ce |
files | mercurial/templates/gitweb/changelogentry.tmpl mercurial/templates/gitweb/changeset.tmpl mercurial/templates/gitweb/fileannotate.tmpl mercurial/templates/gitweb/filerevision.tmpl mercurial/templates/static/style-gitweb.css tests/test-hgweb.t |
diffstat | 6 files changed, 13 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/templates/gitweb/changelogentry.tmpl Fri Mar 24 22:40:08 2017 -0400 +++ b/mercurial/templates/gitweb/changelogentry.tmpl Fri Mar 24 19:52:43 2017 -0700 @@ -7,7 +7,7 @@ </div> <i>{author|obfuscate} [{date|rfc822date}] rev {rev}</i><br/> </div> -<div class="log_body"> +<div class="log_body description"> {desc|strip|escape|websub|addbreaks|nonempty} <br/> <br/>
--- a/mercurial/templates/gitweb/changeset.tmpl Fri Mar 24 22:40:08 2017 -0400 +++ b/mercurial/templates/gitweb/changeset.tmpl Fri Mar 24 19:52:43 2017 -0700 @@ -43,7 +43,7 @@ {child%changesetchild} </table></div> -<div class="page_body"> +<div class="page_body description"> {desc|strip|escape|websub|addbreaks|nonempty} </div> <div class="list_head"></div>
--- a/mercurial/templates/gitweb/fileannotate.tmpl Fri Mar 24 22:40:08 2017 -0400 +++ b/mercurial/templates/gitweb/fileannotate.tmpl Fri Mar 24 19:52:43 2017 -0700 @@ -59,7 +59,7 @@ </table> </div> -<div class="page_path"> +<div class="page_path description"> {desc|strip|escape|websub|addbreaks|nonempty} </div> <div class="page_body">
--- a/mercurial/templates/gitweb/filerevision.tmpl Fri Mar 24 22:40:08 2017 -0400 +++ b/mercurial/templates/gitweb/filerevision.tmpl Fri Mar 24 19:52:43 2017 -0700 @@ -59,7 +59,7 @@ </table> </div> -<div class="page_path"> +<div class="page_path description"> {desc|strip|escape|websub|addbreaks|nonempty} </div>
--- a/mercurial/templates/static/style-gitweb.css Fri Mar 24 22:40:08 2017 -0400 +++ b/mercurial/templates/static/style-gitweb.css Fri Mar 24 19:52:43 2017 -0700 @@ -145,6 +145,10 @@ background-color: #bfdfff; } +.description { + font-family: monospace; +} + /* Graph */ div#wrapper { position: relative;
--- a/tests/test-hgweb.t Fri Mar 24 22:40:08 2017 -0400 +++ b/tests/test-hgweb.t Fri Mar 24 19:52:43 2017 -0700 @@ -337,7 +337,7 @@ $ get-with-headers.py --twice localhost:$HGPORT 'static/style-gitweb.css' - date etag server 200 Script output follows - content-length: 6986 + content-length: 7032 content-type: text/css body { font-family: sans-serif; font-size: 12px; border:solid #d9d8d1; border-width:1px; margin:10px; background: white; color: black; } @@ -487,6 +487,10 @@ background-color: #bfdfff; } + .description { + font-family: monospace; + } + /* Graph */ div#wrapper { position: relative;