OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

docbook-apps message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: RE: [docbook-apps] WebHelp and print


It looks like adding {margins: 0 0 0 0;} to #content is all I was missing. Thank you for your help.

 

Regards,

Paul Bort

Systems Engineer

TMW Systems, Inc.

pbort@tmwsystems.com

440 721 2233 (voice)

440 290 2662 (fax)

 

From: Kasun Gajasinghe [mailto:kasunbg@gmail.com]
Sent: Tuesday, March 20, 2012 10:23 PM
To: Bort, Paul
Cc: docbook-apps@lists.oasis-open.org
Subject: Re: [docbook-apps] WebHelp and print

 

 

On Wed, Mar 21, 2012 at 3:13 AM, Bort, Paul <pbort@tmwsystems.com> wrote:

All,

 

I'm quite happy with the WebHelp option in 1.76.1, but I'd like to be able to print from it without having to turn off the TOC/Search each time. I've got this chunk of CSS that gets close:

 

@media print {

    body * {

        visibility:hidden;

    }

    #content, #content * {

        visibility: visible;

    }

   #content {

        position:absolute;

        left: 0;

        top: 0;

    }

}

 

(Based on http://stackoverflow.com/a/2618980.) But it still leaves blank space for the TOC along the left side. I tried "margin-left: 0px;" to counter the style set on the "content" div, but it didn't work, probably due to my lack of CSS knowledge.

 

You may just call showHideToc() _javascript_ function to hide the TOC. It's available in main.js file. If you still want to do this via CSS, understand how it hides the TOC, and  implement the same via CSS.

 

I tested it a little, and setting following CSS styles hides the TOC/Search. Mind that this is without your CSS styles. #sidebar stands for leftnavigation.

If you look closely, webhelp mainly has three div s inside <body>, ie #header, #content, and #sidebar. So, as you can see it's easier to deal with these separately rather than working appending CSS to body.

 

#content {

    margin: 0 0 0 0;

}

#sidebar {

    display: none;

}

 

Does this work for you? I tested this in latest snapshot, but showHideToc haven't changed logic-wise after the 1.76.1 release.

 

Regards,

--Kasun

 

 

Any suggestions?

 

Regards,

Paul Bort

Systems Engineer

TMW Systems, Inc.

pbort@tmwsystems.com

 



 

--
~~~*******'''''''''''''*******~~~
Kasun Gajasinghe
Software Engineer; WSO2 Inc.; http://wso2.com,

 



[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]