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

Syntax Highlighting is broken, color themes not displayed. #2493

Closed
keyboard-penman opened this issue Apr 26, 2024 · 13 comments
Closed

Syntax Highlighting is broken, color themes not displayed. #2493

keyboard-penman opened this issue Apr 26, 2024 · 13 comments

Comments

@keyboard-penman
Copy link

Versions : 1.1.0 and 1.1.2 (using AppImage) on Ubuntu 22.04.4 LTS

  1. When inserting code nodes or code blocks within rich text nodes, the dialog to choose (syntax highlighting) language shows no language options. It's blank.
  2. The default syntax highlighting language option sh itself produces no syntax highlighting whatsoever, even with genuine bash commands.
  3. Code blocks as well as nodes do not show the color themes specified in preferences.
@giuspen
Copy link
Owner

giuspen commented Apr 27, 2024

I can see that on 24.04 the AppImage doesn't even start, while runs correctly on 20.04.
I will investigate.

@giuspen
Copy link
Owner

giuspen commented Apr 27, 2024

On 24.04 the appimage doesn't start because libfuse.so.2 is not found.
Running it from the terminal gave me that info so it was fixed after installing libfuse2t64.
I then tried on a 22.04 and it worked normally.
Can you try to run it from the command line and report if any error is printed?

@keyboard-penman
Copy link
Author

keyboard-penman commented Apr 28, 2024

Can you try to run it from the command line and report if any error is printed?

Thanks, I shall try that.

Edit:

I tried it, the application behaviour is same (expectedly). The following is printed in the terminal:

Gtk-Message: 12:20:09.722: Failed to load module "colorreload-gtk-module"
Gtk-Message: 12:20:09.723: Failed to load module "window-decorations-gtk-module"
[2024-04-28 12:20:09.723] [   ] [debug] /home/username/.config/cherrytree/config.cfg parsed
[2024-04-28 12:20:09.723] [   ] [warning] Unexp missing /usr/share/cherrytree/data/user-style.xml
[2024-04-28 12:20:09.723] [   ] [warning] Unexp missing /usr/share/cherrytree/data/user-style.xml

(AppRun.wrapped:9698): Gtk-WARNING **: 12:20:09.762: Theme directory places/128 of theme ubuntustudio has no size field


(AppRun.wrapped:9698): Gtk-WARNING **: 12:20:09.762: Theme directory places/scalable of theme ubuntustudio has no size field

[2024-04-28 12:20:10.064] [   ] [debug] Node 2 > secondnode
[2024-04-28 12:20:14.515] [   ] [debug] Node 1 > firstnode
[2024-04-28 12:20:18.416] [gtk] [critical] gtk_tree_view_scroll_to_cell: assertion 'tree_view->priv->tree != NULL' failed
[2024-04-28 12:20:25.917] [gtk] [critical] gtk_tree_view_scroll_to_cell: assertion 'tree_view->priv->tree != NULL' failed
[2024-04-28 12:20:33.067] [gtk] [critical] gtk_tree_view_scroll_to_cell: assertion 'tree_view->priv->tree != NULL' failed
[2024-04-28 12:20:39.747] [   ] [debug] Node 2 > secondnode

Note: Personal directory and cherrytree node names changed for privacy.

@giuspen
Copy link
Owner

giuspen commented Apr 28, 2024

I see you are using Ubuntu studio and a KDE desktop, that may be the reason I'm not seeing the issue, as I'm on a GTK desktop.
I suspect some GTK needed stuff is not in the AppImage bundle, in fact I see errors loading a couple of GTK modules.
I will try to reproduce myself on a KDE desktop.

@giuspen
Copy link
Owner

giuspen commented Apr 30, 2024

Turns out the issue is visible also on a GTK desktop. I wasn't seeing it because I had the cherrytree dependencies already installed. It's visible for example also on a clean Ubuntu (Gnome, GTK) 24.04 installation. I'll see if I can find out which library files are not copied over from the AppImage GTK script

@keyboard-penman
Copy link
Author

Thank you very much.

@keyboard-penman
Copy link
Author

I wasn't seeing it because I had the cherrytree dependencies already installed

What are the package names of these dependencies?

Of course, a self-contained Appimage coming with these is the ideal solution, but as a temporary fix, could the problem be solved with sudo apt install <packagename>?

@giuspen
Copy link
Owner

giuspen commented May 2, 2024

Correct @keyboard-penman installing the dependencies will fix the issue, if your distribution is too old though you may find an old package with incorrect dependencies.
I can paste here later the current dependencies on Ubuntu 22.04

@giuspen
Copy link
Owner

giuspen commented May 2, 2024

I believe installing this will do for you, please confirm:

sudo apt install libgtksourceviewmm-3.0-0v5

@keyboard-penman
Copy link
Author

sudo apt install libgtksourceviewmm-3.0-0v5

Yes, it did indeed work. Thank you, again.

@giuspen
Copy link
Owner

giuspen commented May 4, 2024

I believe the issue is now fixed.
It would be very useful if you could confirm it:

  1. sudo apt purge libgtksourceviewmm-3.0-0v5
  2. sudo apt autoremove --purge
  3. check that you do see the issue again with the AppImage v1.1.2
  4. download
    https://www.giuspen.net/software/CherryTree-1.1.2+7-x86_64.AppImage and verify that there is no issue there

@keyboard-penman
Copy link
Author

keyboard-penman commented May 5, 2024

I believe the issue is now fixed. It would be very useful if you could confirm it:

  1. sudo apt purge libgtksourceviewmm-3.0-0v5
  2. sudo apt autoremove --purge
  3. check that you do see the issue again with the AppImage v1.1.2
  4. download
    https://www.giuspen.net/software/CherryTree-1.1.2+7-x86_64.AppImage and verify that there is no issue there

Just did this.

Purging ibgtksourceviewmm-3.0-0v5 did cause the error again.

And it was fixed with the new Appimage.

Problem solved, it appears :)

Thank you so much for addressing this.

@giuspen
Copy link
Owner

giuspen commented May 5, 2024

Excellent, many thanks @keyboard-penman for reporting and verifying the fix

@giuspen giuspen closed this as completed May 5, 2024
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

No branches or pull requests

2 participants