Skip to content
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

Is inline colouring possible? #154

Open
ghost opened this issue Oct 20, 2024 · 2 comments
Open

Is inline colouring possible? #154

ghost opened this issue Oct 20, 2024 · 2 comments

Comments

@ghost
Copy link

ghost commented Oct 20, 2024

Lets say I wanted to emphasis or colourize mid part of the sentence.

[default black]This is an example[now red]of inline colouring[now black]within the same sentence in a PDF document.

I'm asking since you're supposed to position manually just like how it is with postscript (and in turn, PDF) creation, I feel it would be a pain to manually place multiple strings on the same line.

@AndreRenaud
Copy link
Owner

Hey. Yes, that would be a good feature. The absolute positioning makes that pretty tricky at the moment, so it would be better to be done automatically under the hood. It would require some kind of markdown-like parser, which might be a bit involved. Is there a simple syntax that already exists that might suit (to cover things like underline, strike through, colour etc...)?

Right now there isn't a trivial answer - you'd have to break it up yourself externally and then build each element separately with absolute positioning. Possible, but awkward.

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

No branches or pull requests

2 participants
@AndreRenaud and others