Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230
Way to copy syntax highlighting in gedit?
Way to copy syntax highlighting in gedit?
Is there a way to save the syntax highlighting of a gedit document so that it can be backed up with the highlighting?
Is there a way to apply syntax highlighting to groups of files instead of one at a time?
Is there a way to apply syntax highlighting to groups of files instead of one at a time?
Re: Way to copy syntax highlighting in gedit?
no.kcbagr wrote:Is there a way to save the syntax highlighting of a gedit document so that it can be backed up with the highlighting?
why would you need that.
usually happens automatically when you open the file anyhow, but i know of no editor that can explicitely apply the same syntax highlighting to a group of files.Is there a way to apply syntax highlighting to groups of files instead of one at a time?
again, why do you think you need that? are your files not recognized automatically?
Re: Way to copy syntax highlighting in gedit?
I "need" it because I have gone to a lot of trouble to mark certain files with the syntax highlighting that I want. Yet when I copy said files over to an external hard drive (for backing up purposes), the highlighting is lost. So in the future, when I pull that backup (e.g., after upgrading to a new version of Debian), I will once again have to go through and manually mark all those files with the highlighting I want. It's a major PITA to have to do this every couple years.debiman wrote:no.kcbagr wrote:Is there a way to save the syntax highlighting of a gedit document so that it can be backed up with the highlighting?
why would you need that.
usually happens automatically when you open the file anyhow, but i know of no editor that can explicitely apply the same syntax highlighting to a group of files.Is there a way to apply syntax highlighting to groups of files instead of one at a time?
again, why do you think you need that? are your files not recognized automatically?
Re: Way to copy syntax highlighting in gedit?
sorry, but i don't understand this statement.kcbagr wrote:I have gone to a lot of trouble to mark certain files with the syntax highlighting that I want.
can you describe the process?
in my understanding, syntax highlighting is something that the editor (nano, geany, vim, gedit ...) does automatically when i open the file. in a very few cases it does not recognize the correct syntax, and i have to go to
Menu => Filetype => [Language]
or something like that.
are you saying you somehow applied the colors manually to your code?
Re: Way to copy syntax highlighting in gedit?
I'm not opening "code" more as notes that are organized via code highlighting.
So if I open a .txt file, it has no highlighting. To help organize the appearance, I go to Gedit Hamburger Menu > View > Highlight Mode = .desktop.
I have found no other way to "activate" .desktop syntax highlighting. So it's a rather clunky process of applying this syntax to each and every file that I want it to appear on.
So if I open a .txt file, it has no highlighting. To help organize the appearance, I go to Gedit Hamburger Menu > View > Highlight Mode = .desktop.
I have found no other way to "activate" .desktop syntax highlighting. So it's a rather clunky process of applying this syntax to each and every file that I want it to appear on.
Re: Way to copy syntax highlighting in gedit?
Gedit applies the highlighting according to the file suffix.
I don't understand what you want, however it is possible to save syntax highlighted text to pdf or similar and then it will be 'permanent'
I don't understand what you want, however it is possible to save syntax highlighted text to pdf or similar and then it will be 'permanent'
Re: Way to copy syntax highlighting in gedit?
it will work when all your notes are renamed something.desktop.kcbagr wrote:I'm not opening "code" more as notes that are organized via code highlighting.
So if I open a .txt file, it has no highlighting. To help organize the appearance, I go to Gedit Hamburger Menu > View > Highlight Mode = .desktop.
I have found no other way to "activate" .desktop syntax highlighting. So it's a rather clunky process of applying this syntax to each and every file that I want it to appear on.
Re: Way to copy syntax highlighting in gedit?
When I rename the file, for example "something.desktop", gedit reports "There was an error launching the application."debiman wrote:it will work when all your notes are renamed something.desktop.kcbagr wrote:I'm not opening "code" more as notes that are organized via code highlighting.
So if I open a .txt file, it has no highlighting. To help organize the appearance, I go to Gedit Hamburger Menu > View > Highlight Mode = .desktop.
I have found no other way to "activate" .desktop syntax highlighting. So it's a rather clunky process of applying this syntax to each and every file that I want it to appear on.
Is there a particular way in naming it so it works?
Re: Way to copy syntax highlighting in gedit?
pylkko,pylkko wrote:Gedit applies the highlighting according to the file suffix.
I don't understand what you want, however it is possible to save syntax highlighted text to pdf or similar and then it will be 'permanent'
1) open gedt
2) type some text
3) save the document
4) go to the hamburger menu and select: View > Highlight Mode = .desktop
What "file suffix" is causing this .desktop highlighting? (as you are saying it is according to file suffix).
Re: Way to copy syntax highlighting in gedit?
are you sure gedit issues this message, and not your filemanager?kcbagr wrote:When I rename the file, for example "something.desktop", gedit reports "There was an error launching the application."
you have to right-click on the file and Open With... => gedit.
if it is indeed gedit issueing that message, then gedit is broken.
you made an unlucky choice of highlighting format for your notes, because .desktop files are somewhat reserved on freedesktop systems.
- static-catsit
- Posts: 34
- Joined: 2011-04-12 23:36
Re: Way to copy syntax highlighting in gedit?
To view .desktop files you can open up Gedit and then drop the file in.When I rename the file, for example "something.desktop", gedit reports "There was an error launching the application."
Is there a particular way in naming it so it works?
Re: Way to copy syntax highlighting in gedit?
kcbagr wrote:pylkko,pylkko wrote:Gedit applies the highlighting according to the file suffix.
I don't understand what you want, however it is possible to save syntax highlighted text to pdf or similar and then it will be 'permanent'
1) open gedt
2) type some text
3) save the document
4) go to the hamburger menu and select: View > Highlight Mode = .desktop
What "file suffix" is causing this .desktop highlighting? (as you are saying it is according to file suffix).
yes, if you use .c you get c syntax highlighting, and guess what? if you use .py you get Python syntax highlighting. if you, however right a python script and name it whatever.txt you will not get it automatically, but you need to do the procedure of clicking the "hamburger menu" etc that you want to avoid.
Re: Way to copy syntax highlighting in gedit?
Thanks for all your help guys! I really appreciate all the info posted.