You are not logged in.
Pages: 1
Hello,
I am on Debian 10 with xfce 4.12 and mousepad 0.4.1. I observe that Python scripts opened with mousepad get the filetype detected as Document > Filetype > Script > Python, but I don't get any actual highlighting: All text stays the default black on white.
What could be wrong?
Best regards,
Robert
Last edited by jondo (2020-08-17 16:02:36)
Offline
Hello and welcome.
There is an old bug in that version of mousepad. You need to set the Color Scheme to anything but "None". Classic is the default one.
Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki | Community | Contribute ---
Offline
That worked, thank you!
Offline
I have a slightly different problem with recognizing shell scripts without the extension appended. I don't append the .sh extension to my shell scripts (most POSIX shell scripts on my system do not have it), which makes them unrecognizable to GtkSourceView. I have these properties set in language-specs (even commented out the globs property):
<language id="sh" name="sh" version="2.0" _section="Script">
<metadata>
<property name="mimetypes">text/x-shellscript;application/x-shellscript;text/x-sh</property>
<!-- <property name="globs">*.sh;*bashrc;.profile;.bash_profile</property> -->
<property name="line-comment-start">#</property>
</metadata>
Is my only option here to start appending the extension?
Remember to edit the subject of your topic to include the [SOLVED] tag once you're satisfied with the answers or have found a solution (in which case, don't forget to share it as well), so that other members of the community can quickly refer to it and save their time. Pretty please!
Offline
Which version of mousepad are you using? 0.4.90 added the ability to infer filetype from the shebang line. Do your scripts have shebang lines?
Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki | Community | Contribute ---
Offline
Which version of mousepad are you using?
Its version is 0.4.2 on Xubuntu 20.04.
0.4.90 added the ability to infer filetype from the shebang line.
Thanks. I see that now. Perhaps I can request a backport.
Do your scripts have shebang lines?
Of course I do, though POSIX leaves it unspecified.
Remember to edit the subject of your topic to include the [SOLVED] tag once you're satisfied with the answers or have found a solution (in which case, don't forget to share it as well), so that other members of the community can quickly refer to it and save their time. Pretty please!
Offline
Pages: 1
[ Generated in 0.008 seconds, 8 queries executed - Memory usage: 548.12 KiB (Peak: 548.96 KiB) ]