RTF font overrides code box font

Home Forums cherrytree RTF font overrides code box font

This topic contains 4 replies, has 2 voices, and was last updated by  giuspen 1 month ago.

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #124423

    CT_user
    Member

    Hello!

    Code box font settings in RTF node could not be set properly due to them been overriden by RTF font settings. Whenever I open an existing .ctb file or switch nodes, font of code boxes switches to the font set for RTF nodes. Going to font settings dialog and pressing ok temporary fixes this, but once node is switched or document is closed the problem persists.

    This issue has already been brought to your attention here:

    https://github.com/giuspen/cherrytree/issues/258

    You mentioned that this might be a file permission issue, but I think you are wrong for the following reasons:

    1) This problem occured to me both in windows and linux builds;
    2) RTF font settings are always applied properly, it’s just the code boxes that cause problems. I suppose if it was a file permission issue I would not be able to change RTF font as well;
    3) When I go to code box settings for a temporary fix I see that a proper code box font is already selected, it is just always overriden by RTF font unless each time I switch nodes I go to font settings and press ok.

    I realize you’re busy with porting your application to a new platform, but it would be great to have a little update just to fix this issue. It makes it very uncomfortable to work with notes related to code because RTF font really messes up the code.

    #124429

    giuspen
    Moderator

    Hi, I’ll try to reproduce and propose a development version for you to test

    #124434

    giuspen
    Moderator

    What is the syntax highlighting type you are using for the codeboxes? Could you send me a document where I can see the problem at document load and when returning to a node?
    If you change the properties of the node with right click, is that also temporarily fixing the font?

    #124436

    CT_user
    Member

    I had never tried code boxes with syntax highliting before you mentioned that, only had used the simple ones without it. It turns out that the syntax highliting version of code boxes works properly, both when changing nodes and opening documents.

    So it is just the code boxes without syntax highliting that show this odd behaviour. Changing node properties with right click does not change font in these code boxes.

    I’ve created an example file in a portable Windows version of CherryTree.

    <br /><div style=font-size:9px;font-family:Arial, Helvetica, sans-serif;width:127px;font-color:#44a854;> upload files free</div>

    • This reply was modified 1 month ago by  CT_user.
    • This reply was modified 1 month ago by  CT_user.
    • This reply was modified 1 month ago by  CT_user.
    #124441

    giuspen
    Moderator

    At the moment the font of the plain text is the same of the font of the rich text while only the code font is different (automatic syntax highlighting, all but plain and rich text).
    So this is not a bug but a feature request.
    If you are interested I can give you a development version where you can configure the plain text font but only via editing the config.cfg, not with a user interface that will be available in the new version after the porting

Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.