======Geany====== **Geany** is a nice text editor that can do a fair chunk of things proper IDEs can. =====Features===== ====Terminal==== To add a terminal emulator to the messages pane you just need to install [[arch>extra/x86_64/vte3/|vte3]]. ====Split Window==== To split the window, so that you can view two separate files simultaneously, you have to install a plug-in: * [[github>geany/geany/blob/master/plugins/splitwindow.c]] This seems to live in the big plug-in pack you can download too. ====External Commands==== You can use the 'Send Selection to' function to send chunks of text to other programs for modification. * ''Right-mouse > Format > Send Selection to >'' or * ''Edit > Format > Send Selection to >'' or * ''Ctrl+[n]'' I have one setup that sends highlit text to ''sort'' when I press ''Ctrl+1'', which alphabetises it. Nice for CSS and lists. * https://wiki.geany.org/config/customcmds/sort-selection ====Context Actions==== Like external commands, you can use the single context action to send bits of text off to other places. There being only one is a bit limiting, but. I have mine set to send stuff to [[Firefox]], which I use for URLs. To set: - ''Edit > Preferences > Tools'' - Find the 'Context action:' field or - Edit ''~/.config/geany/geany.conf'' - Find ''context_action_cmd='' and add your command here. I have ''firefox %s''. If you want send stuff to [[duckduckgo|DDG]] use ''firefox %%"https://duckduckgo.com/?t=ffab&q=%s"%%'', etc. You can also have a different context action configured per file type. To do this: - Copy the files you want from ''/usr/share/geany/filedefs'' to ''~/.config/geany/filedefs'' - Add your command to ''context_action_cmd='' I have ''%%https://developer.mozilla.org/en-GB/search?q=%s%%'' for [[CSS]] and [[HTML]] files, for example. ====Keyboard Shortcuts==== Some ones I find useful: | ''Ctrl+Shift+X'' | Cut line | | ''Ctrl+Shift+C'' | Copy line | | ''Ctrl+K'' | Delete line | | ''Ctrl+D'' | Duplicate line | | ''Ctrl+E'' | Comment-out line (toggle) | | ''Ctrl+I'' | Indent line | | ''Ctrl+U'' | Outdent line | | ''Alt+PgUp'' | Shift line up | | ''Alt+PgDn'' | Shift line down | | ''Ctrl+H'' | Find and replace dialogue | | ''Ctrl+[n]'' | Custom commands. The number depends on the command's place in the list | ====editorconfig==== You can enable [[file_kinds#.editorconfig]] support with a plug-in: * [[github>editorconfig/editorconfig-geany]] * [[aur>?O=0&SeB=nd&K=editorconfig+geany&outdated=&SB=n&SO=a&PP=50&do_Search=Go|editorconfig geany]] search. ==== Syntax Highlighting ===== To add new filetypes to existing syntax highlighting styles:, you can add them to ''~/.config/geany/filetype_extensions.conf''. Currently mine looks like: # Adds to defaults /usr/share/geany/filetype_extensions.conf [Extensions] Conf=*.ssa;*.ass; [Groups] ===== See Also ===== * [[https://www.geany.org/|www.geany.org]] {{tag>guide open-source software text-editor}}