One more and maybe impossible now: Back page

Having trouble installing Oxygen PDF Chemistry? Got a bug to report? Post it all here.
Timber
Posts: 25
Joined: Mon Dec 11, 2017 4:00 pm

One more and maybe impossible now: Back page

Post by Timber »

Hi and thank you again for helping me out,

The template that I am working on also needs a back page. Everything right-aligned and at the lower half of the page. The same logo as before and a lot of paragraphs and line breaks. See the attachment that I sent you.

Seems like @page:last is not even implemented yet. Any help from using back-matter in bookmap? The easier way would be to paste the whole thing as an image, but the problem of how to put it at the bottom (not margin box) of the last page still remains.

Any suggestions?

Cheers,

Timo
Radu
Posts: 9018
Joined: Fri Jul 09, 2004 5:18 pm

Re: One more and maybe impossible now: Back page

Post by Radu »

Hi Timo,

"@page:last" is implemented and it can be used to style the layout of the last page. But it does not automatically create a blank page.
Maybe you can try something like this:

Code: Select all

:root:after{
page:lp;
display:block;
content: " ";
margin-top:50%;
text-align:right;
}

@page lp{
background-image:url("Takakansi.svg");
background-position:top left;
background-repeat:no-repeat;
}
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
Timber
Posts: 25
Joined: Mon Dec 11, 2017 4:00 pm

Re: One more and maybe impossible now: Back page

Post by Timber »

Good. Thanks.

The only thing is that it should be right-aligned. I tried moving it around, but the it shrank. Background-position: 50% 50% puts it at the centr, but background-size is not accepted for some reason.


Happy holidays,


Timo
Timber
Posts: 25
Joined: Mon Dec 11, 2017 4:00 pm

Re: One more and maybe impossible now: Back page

Post by Timber »

Great!

SInce I couldn't adjust the svg, I cropped al the white space out and modified the code a bit:

Code: Select all


   :root:after{
page:lp;
display:block;
content: " ";
margin-top:50%;
text-align:right;
}

@page lp{
background-image:url("Takakansi.svg");
background-position:80% 80%;
background-repeat:no-repeat;
}
Now it's still a bit small, but good enough.

But if I try to empty the margin boxes with code like...

Code: Select all


@page : lp{
@bottom-right {
content: " ";
}}
...it is not accepted.

Any solution?

Happy holidays!


Timo
Timber
Posts: 25
Joined: Mon Dec 11, 2017 4:00 pm

Re: One more and maybe impossible now: Back page

Post by Timber »

Woops. Had to remove ':*. Sorry.

I guess it will be ok now.
Post Reply