-
Notifications
You must be signed in to change notification settings - Fork 500
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Watermark (foreground image) is always left-aligned on landscape pages #2528
Comments
The size, fit, and position of the foreground (watermark) image is controlled using the
By default, a foreground image is automatically scaled to fit the bounds of the page (i.e., fit=contain) and centered (i.e., position=center). You can learn more about how these attributes work on the following page: https://docs.asciidoctor.org/pdf-converter/latest/background-images/ I'll update that page to clarify that the size, fit, and position apply to foreground images as well. |
In the future, please direct questions about usage to the project chat first at https://chat.asciidoctor.org. |
Ok, Sorry for my request here and Thank you for your answer! |
No worries.
I'm confident the image is centered by default. This is supported by tests.
It's possible that the image is not aligned to the center in the image
itself. But if you can prove otherwise, please provide a reproducible
example and I will study it.
|
maybe I am doing something wrong. Here is an example == Possible issues Here is an example of a landscape image. [page-layout=portrait] |
The fact that the layout is being changed back and forth in the document is very important context that was missing from your original report. Your terse report could be interpreted that the watermark was not being centered when the whole document was in landscape. It's always helpful be clear how you are using the feature, and that means providing a reproducible example up front. You're correct that when you switch the layout, the foreground image is not positioned correctly on pages with a layout which is different from the layout on the first page. That's because the foreground image is being added using a single stamp and that stamp is static. In order to correct this behavior, there needs to be a foreground image stamp per layout. That's not too difficult, so I will implement it. |
…ge layout changes
Hello,
it seems like Watermark (foreground image) is always left-aligned on landscape pages.
The text was updated successfully, but these errors were encountered: