One of the many tedious tasks when setting up a new system, or if you've just installed new software to replace something you used previously, is to change the default software used when opening up different types of files.
For example, I may have GIMP open when I click on a .png file, but Gwenview open for .jpg files, if I find myself editing .png files often but hardly doing more with .jpg's than viewing them. Or perhaps you want to set all python files to automatically open in Atom when you double click them?
Whatever your logic is, in KDE5 there are two main wats you could go about this using built-in graphical tools.
The first way, and in my opinion, the easiest, is to simply change the file association, each time you come across a file in your day-to-day happenings, where you encounter a change that is needed, by using the 'open with' right-click menu option.
For example, if you wanted to ensure that all .txt files are opened via KWrite according to this method, simply right click on the file, and select "Open with" and then "Other."
From here, you'll need to select the program that in the future, you wish to use as default for that specific filetype (.txt in our example.)
Important: Don't forget to click the little box at the bottom, signifying to remember this change for the future, or you'll have to redo this again!
Done! You can do this each time you come across a different file type in your day, until everything is done, without going out of your way too far.
This method is to manually search for, and change the file associations, one by one, from within the KDE settings application.
By clicking your applications menu in the (default) bottom left corner of your screen, followed by "Settings" and "System Settings" you'll be taken to the main settings application. We won't cover the other options here in this tutorial, so head down to "Applications" and you'll find our next step.
Next, you'll want to click "File associations" on the left side, as seen in the image below. From here, you can either browse or search for the file extension you want to change, select it, and on the right side of your screen select the application you wish to use.
I personally find this option less appealing, but some may want to get a bunch out of the way all at once, and I find this method might be more suiting to such end.
No matter how you do it, it's a good idea to change your file associations as soon as you can, to avoid headache and annoyance when accidentally opening the wrong application for the job at hand.
Now you: Which method do you prefer, and why? Let us know in the comments!
Advertising revenue is falling fast across the Internet, and independently-run sites like Ghacks are hit hardest by it. The advertising model in its current form is coming to an end, and we have to find other ways to continue operating this site.
We are committed to keeping our content free and independent, which means no paywalls, no sponsored posts, no annoying ad formats (video ads) or subscription fees.
If you like our content, and would like to help, please consider making a contribution:
Ghacks is a technology news blog that was founded in 2005 by Martin Brinkmann. It has since then become one of the most popular tech news sites on the Internet with five authors and regular contributions from freelance writers.