-
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
additional margin to code
, kbd:[] and menu:[]
#1264
Comments
Nope, this is not possible. Prawn doesn't provide any way to do it. That's why we have border-offset. Because the best we can do is extend the background/border. You could hack it by inserting a thin space, but that's pretty brute force and not very precise. I've filed an issue in Prawn for this to be considered. See prawnpdf/prawn#1128 If it gets implemented there, then we can add left-to-right padding to inline elements. |
Although your hack is very clever, it doesn't work because it modifies the fragment too late. We need to be able to control the width of the fragment that Prawn uses when arranging the text fragments. And as far as I can see (and best remember), that's not possible. |
Ok, I see. Thx! |
It appears this might now be possible (after recent updates to the converter). I'll look into it. |
Btw, you were actually on the right path. It just requires changes in a few more places. |
I think I got it. It's a little patchy, but it works very well. |
Thx a lot! Can't test it yet (on vacation) but will definitely do it in a week or so. |
Just tested it -- works flawlessly! Awesome, thank you! |
I'm so happy to hear that. Thanks for testing! |
Hi @mojavelinux, could you tell me if it is possible to extend fragment of the inline code in a way that it doesn't eat next characters?
My first silly attempt was to change
But as expected (by me :) ) it didn't work.
So is it even possible? To extend the inline code fragment on X?
Now you have to kind of tune the border offset and border width otherwise it highlights before and after characters.
The text was updated successfully, but these errors were encountered: