atom feed13 messages in org.xwiki.usersRe: [xwiki-users] Printing pages as d...
FromSent OnAttachments
Mahomed HusseinMay 5, 2015 9:53 am 
Mahomed HusseinMay 5, 2015 9:58 am 
Mahomed HusseinMay 7, 2015 3:46 am 
Ecaterina Moraru (Valica)May 7, 2015 4:24 am 
Mahomed HusseinMay 7, 2015 4:57 am 
Ecaterina Moraru (Valica)May 7, 2015 5:29 am 
Mahomed HusseinMay 8, 2015 2:30 am 
vinc...@massol.netMay 10, 2015 3:29 am 
Mahomed HusseinMay 14, 2015 8:29 am 
Clemens Klein-RobbenhaarMay 15, 2015 4:17 am 
Mahomed HusseinMay 15, 2015 4:52 am 
Clemens Klein-RobbenhaarMay 15, 2015 6:12 am 
Mahomed HusseinMay 15, 2015 7:01 am 
Subject:Re: [xwiki-users] Printing pages as displayed
From:Mahomed Hussein (Maho@CustodianDC.com)
Date:May 14, 2015 8:29:27 am
List:org.xwiki.users

That’s cool. Thanks Vincent ☺

I finally got some time (and was forced to) look at implementing changes to the
print formatting. I had some mixed results. I’ll document what I’ve done below
and the bits I am having some trouble with and hopefully someone can provide me
with further tips.

1. I managed to format the PDF Export output by attaching a pdf.css file
to my custom skin application (as per
http://extensions.xwiki.org/xwiki/bin/view/Extension/Skin+Application). This has
mostly worked for straightforward items like headers and font. But I am having
trouble with some of my tables and it would help if I could reduce the margins
of the page. QUESTION: Is there a simple way to modify the margins (I need narrower margins)

2. I tried to format the printed output but found that attaching a
print.css to my skin application did very little/nothing to format the output. I
tested by creating an article in the Sandbox, Clicking “More Actions” > “Print
Preview” > Press Ctrl+P. This was testing in Chrome and Firefox with the same
effect/results.

3. I then found that there were several @Media=”Print” sections in the
Style.css file. So I downloaded this, removed the @Media sections and
re-attached my new style.css to my skin application. This now allowed my
formatting in the attached print.css to take effect. So this now works and looks
as I would expect. But I don’t really like the idea of having my own style.css
as it’ll make it more difficult to take advantage of any new formatting changes
that may be added later (unless I’ve missed the point here)

4. I have locked down the xwiki so that only registered and logged in
users can view any of the documents. Unfortunately this now means that style.css
is not accessible on the login page. I have modified the access rights on the
skin application and given view permissions to XWikiAllGroup but I suspect I
need to somehow give access to guests but I can’t see how to do that.

Sorry for the long email and I hope I’ve explained clearly. Any help greatly
appreciated (as always).

Kind regards,

Mahomed

From: Vincent Massol [mailto:vmas@gmail.com] On Behalf Of vinc@massol.net Sent: 10 May 2015 11:29 To: XWiki Users Cc: Mahomed Hussein Subject: Re: [xwiki-users] Printing pages as displayed

Thanks for the kind words! You’re now on
http://www.xwiki.org/xwiki/bin/view/References/Testimonials

:)

Thanks -Vincent

On 8 May 2015 at 11:30:18, Mahomed Hussein
(maho@custodiandc.com<mailto:maho@custodiandc.com>) wrote: Thanks for this. The power of xwiki and the great job the
developers/contributors have done never ceases to amaze me! I love it :)

Kind regards,

Mahomed

-----Original Message----- From: users [mailto:user@xwiki.org] On Behalf Of Ecaterina Moraru
(Valica) Sent: 07 May 2015 13:29 To: XWiki Users Subject: Re: [xwiki-users] Printing pages as displayed

Except print.css another way of 'printing' XWiki pages would be to customize the PDF export, but this step is more complicated (you need to do modifications to pdf templates, XHTML2FO XSL and FOP XSL transformations, etc.), see http://platform.xwiki.org/xwiki/bin/view/AdminGuide/Configuration#HCustomizingthePDFexportLook26Feel

Depends on what you need to do. Have fun, Caty

On Thu, May 7, 2015 at 2:57 PM, Mahomed Hussein
<Maho@custodiandc.com<mailto:Maho@custodiandc.com>> wrote:

Great! Thanks. Good to know I was on the right path :)

Kind regards,

Mahomed

-----Original Message----- From: users [mailto:user@xwiki.org] On Behalf Of Ecaterina Moraru (Valica) Sent: 07 May 2015 12:25 To: XWiki Users Subject: Re: [xwiki-users] Printing pages as displayed

On Thu, May 7, 2015 at 1:46 PM, Mahomed Hussein
<Maho@custodiandc.com<mailto:Maho@custodiandc.com>> wrote:

Hi

Can anyone help please with some information on how to modify/control the print layout please? Thanks.

Each skin has a print.css

Kind regards,

Mahomed

-----Original Message----- From: users [mailto:user@xwiki.org] On Behalf Of Mahomed Hussein Sent: 05 May 2015 17:59 To: XWiki Users Subject: Re: [xwiki-users] Printing pages as displayed

Oh! I forgot to mention we are running 7.0.1 and a custom skin/theme based on the flamingo skin.

Kind regards,

Mahomed

-----Original Message----- From: users [mailto:user@xwiki.org] On Behalf Of Mahomed Hussein Sent: 05 May 2015 17:53 To: XWiki Users Subject: [xwiki-users] Printing pages as displayed

Hi

Is there a way of printing the pages as they are displayed? Ideally printing without the side panel, but with all the different colours/formatting as it appears on the screen would be ideal. At the moment all colours and formatting is stripped if you try to print directly from the page, using the print preview option or by exporting to PDF.

I have tried an export to HTML and then using the local html file to see if that works but it seems that whatever script/css is forcing the print formatting still takes effect on the exported html. I have tried saving the page only directly but it still does the same thing. I have tried Chrome. Firefox and IE.

I have also tried a google search and I have searched for print and printing on the FAQ but there are so many results it may take a few hours to go through them all. I suspect there’s a CSS file I need to modify somewhere (possibly print.css?) that will format the export with the header colours etc. If so, please could someone kindly point me at the correct documentation or provide any tips/hints?

Thanks in advance.

Kind regards,

Mahomed