[xwiki-devs] Skip CSS for Print
Hi Devs, i want to print pages and can't use 100% Scale because they are to wide. I found with Firefox Inspector that the reason is #contentcolumn .main { margin: 0px !important; } Do you know how i can only disable this for print? I tried #contentcolumn .main { margin: auto; } but this not seems to work. When i disable this css-line in firefox inspector it seems ok. Regards, Matthias -- View this message in context: http://xwiki.475771.n2.nabble.com/Skip-CSS-for-Print-tp7588333.html Sent from the XWiki- Dev mailing list archive at Nabble.com.
On 12/09/2013 03:02 PM, Matthias Wegner wrote:
Hi Devs,
i want to print pages and can't use 100% Scale because they are to wide. I found with Firefox Inspector that the reason is
#contentcolumn .main { margin: 0px !important; }
Do you know how i can only disable this for print?
I tried
#contentcolumn .main { margin: auto; }
but this not seems to work. When i disable this css-line in firefox inspector it seems ok.
The !important marker at the end of the rule takes precedence over other non-important rules. If you want to override it, you must also use !important, as in: #contentcolumn .main { margin: auto !important; } -- Sergiu Dumitriu http://purl.org/net/sergiu
I tried every id-tag and class with #main, #body, #xwikimaincontainer, #menuview, #headerglobal, #contentcontainer, #footerglobal, #contentcontainerinner, #xwikicontent,#leftsidecolumns, #xwikimaincontainerinner, #xwikicontent, #mainContentArea, #contentcolumn, #contentcontainer, .main, .leftsidecolumn, .layoutsection, .contenthideleft, .wiki-xwiki, .space-Main , .viewbody , .hideleft { margin: 0px !important; } to skip the margin but nothing seems to work. Only * { margin: 0px !important; } seems to work. But when i use it there is nothing useful left for printing. Are you able to print a page which only contains (% style="float: right;"%)Text and the print shows the "Text" on the right (without scaling the print in browser-print-options)? Regards, Matthias -- View this message in context: http://xwiki.475771.n2.nabble.com/Skip-CSS-for-Print-tp7588333p7588345.html Sent from the XWiki- Dev mailing list archive at Nabble.com.
participants (2)
-
Matthias Wegner -
Sergiu Dumitriu