You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jspwiki.apache.org by "brushed (JIRA)" <ji...@apache.org> on 2015/08/09 17:28:45 UTC

[jira] [Commented] (JSPWIKI-905) HADDOCK – headings have insufficient padding

    [ https://issues.apache.org/jira/browse/JSPWIKI-905?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14679174#comment-14679174 ] 

brushed commented on JSPWIKI-905:
---------------------------------

Hi Dave,

The Haddock template adopts as much as possible the styling of Bootstrap. (see //http://getbootstrap.com)  

In general bootstrap pages look more "spacious" then the current default jspwiki pages. However, for header styles, the margins are slightly smaller.

Comparison table showing : top-margin, line-height, bottom-margin: 

||level    ||JSPWiki             || HADDOCK/Bootstrap||
|   h2 !!! | 30px 45px 15px |   20px 33px 10px   |
|   h3 !!  | 24px 36px 12px |   20px 27px 10px   |
|   h4 !   | 18px 27px 9px   |  10px 23.25px 10px   |     

So, Bootstrap uses the same top & bottom margins for all header styles irrespective of the font-size.  (i.e. 20px for top and 10px for bottom margin) Except for h4, which uses a slightly smaller margin-top.

The current default jspwiki template uses slightly bigger font-sizes for the headers, and the respective margins are proportional to the font-size.  (so bigger on larger headers)

(BTW, the current jspwiki default template also uses .25 padding on the headers, causing a slightly indented header.)

****
Personally, I have no particular preference for either of both styles.  IMO, also the spacing on your example page looks pretty ok.
The intention of the HADDOCK template was to adopt as much as possible unchanged the bootstrap styles, so that also upgrading to future versions would remain easy. 

If you do want to adopt the previous header spacing,  you could consider to add the following to your page  (rather then inserting line-breaks) or to your LeftMenu if you want to to be generally applied :
{noformat}
%%add-css
h2,h3,h4 {
    margin:1em 0 0.5em 0;
    line-height:1.5;
}
/%
{noformat}


> HADDOCK – headings have insufficient padding
> --------------------------------------------
>
>                 Key: JSPWIKI-905
>                 URL: https://issues.apache.org/jira/browse/JSPWIKI-905
>             Project: JSPWiki
>          Issue Type: Improvement
>          Components: Templates and UI
>    Affects Versions: 2.10.2
>         Environment: Client is: 
> - Firefox 39 (Ubuntu 14.04). 
> Server is:
> - JSPWiki v2.10.2-svn-25 running in GlassFish v4
> - Container managed authentication is enabled using a file-based realm
> - HTTPS is enabled
> - JSPWiki policy is locked down such that only authenticated users have access (both read and write)
>            Reporter: Dave Koelmeyer
>         Attachments: HADDOCK-HeadingPadding-1.png, HADDOCK-HeadingPadding-2.png, HADDOCK-HeadingPadding-3.png, HADDOCK-HeadingPadding-4.png, pagesource.txt
>
>
> I've noticed that when applying the HADDOCK template to an existing wiki which has hitherto been using PlainVanilla, main section headings appear to be bunched up to the point where legibility is impacted negatively.
> I've been compensating for this by manually inserting line breaks, but it occurs to me this should really be handled by HADDOCK, rather than manually reformatting. If one ever has to switch back to PlainVanilla for example, then there is a whole lot of associated manual reformatting to do as well.
> After doing some digging around with Firefox inspector, it appears HADDOCK heading elements  (h1, h2, h3) are missing padding values compared to their equivalents in PlainVanilla. This should be amended such that users can apply the HADDOCK template to an existing wiki without readability taking a step back. 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)