Skip to content

Preserve text rendering order to maintain z-index - #91

Open
sugoidesune wants to merge 1 commit into
ray-pH:mainfrom
sugoidesune:preserve_text_zindex
Open

Preserve text rendering order to maintain z-index#91
sugoidesune wants to merge 1 commit into
ray-pH:mainfrom
sugoidesune:preserve_text_zindex

Conversation

@sugoidesune

Copy link
Copy Markdown

Z-Index in SVG's is decided by the order of the elements inside the SVG.
Currently text is added last for scaling reasons and so text is always rendered on top of everything else.

Changes:
To maintain the z-index of text we create and add the text element in the original order.
We later use that element inside the existing draw_texts and draw_multiline_texts to update it with content and settings.

This allows adding text in the background of other elements.
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant