"Open With..." File Type Association???
:newbie: question!
How would i associate a particular type of file (say .pdf or .mov) with a particular application, both in GNOME and in KDE (or is there some Config file i can edit? if so how?)? In windows you can right click, select "Open With..." (you can also do this in KDE and GNOME) but in KDE and GNOME, there is no option to set the default application for that file type, like there is in windows. How do i set this please? I have been reading the man pages and the red hat 7.0 (the version i have) getting started book , and cannot find any answer whatsoever! Please help i am stumped! thanks! |
in gnomecc there is a file types section in the Document Handlers section.
|
where is that exactly?
somebody gave me a similar answer in another forum regarding KDE, but i have looked through the control centers of both GNOME and KDE and i can't find anything that resembles that option! i know i am missing something obvious so maybe you could walk me step by step towards where i might find that particular thing there please? and if anybody can explain in idiot language the same thing for KDE i would be most grateful! ta a lot, folks! |
in gnome, you open the control center - go to Document Handlers. under Document Handlers, there's a "File Types and Programs" section. there's a list of file extensions and associated actions that go with the file type. it's called mime types - you can edit them in that section.
|
oh yes, those mime types...
well, i have been in there a few times, but to no avail. What i do is i open up the mime types thing, and select the file type i want to fiddle with, let's say it's "application/pdf", then i click the edit button, which takes me to a little thing where i can specify the read, write, and execute command string for that type of file. Okay, so far so good. I note that i am given "emacs %f" as an example and reason that the " %f" must be the part of the string that gets substituted for the filename... Right, so i have got all three boxes (read, write and execute) set to "xpdf %f", i have also tried just "xpdf". Of course i only want to read pdfs right now so the other two boxes are irrelevant. Now, looks okay, i click okay to save the settings, then exit the control center. doubleclick on a pdf file (it still doesn't come up with a pdf logo, bad sign) and i get asked which app i want to use. No good, i just specified it in the control center, so why's it still asking? I reason that perhaps i have to log out of X for the changes to take effect (why i wouldn't know...) so i reboot to be on the safe side. Try doubleclicking the file again, no joy, i still get asked. I look in the control center to check the settings, and yes they still say "xpdf %f" just like before, so my settings *have* been saved, they just *don't work*! Oh please, if you know the answer, please help! thanks to the two guys who answered me already btw! maybe my syntax is wrong...? Also, what about KDE? thanks... |
I have done a bit of searching regarding mime types, it seems that a few people have had this problem, so i thought i'd post my results in case they are of any help to anybody else. Of course, if you are a person who can add more to this topic, please do, i will be happy to read what you say! myself, i am just guddling in the dark with this subject!
Firstly, here's this stuff that i found on mail.gnome.org Quote:
also, in KDE, from the KDE User Manual: Quote:
If it doesn't work, i'll be back, screaming and shouting about it, no doubt... |
This is pretty simple under KDE... just go to the control center, expand "File Browsing", and click on "File Associations".
|
i can't find it there, maybe it's moving around because it knows i;m looking for it...
I have had 3 or 4 people tell me how to do the file type thing in KDE, and no two have been the same, not only that, none work on my computer! i may be missing something because the one thing everybody says is that it's really easy! Right, as far as the GNOME file types problem was concerned, i went and did all that stuff from my last post and *no change*! well, it turns out that what i had to do was this: right click on the GNOME/Sawfish desktop, and DEselect the "detect file types by their mime types rather than their extension" box, and it all works fine now! Just thought i'd post this, as i say, for posterity... :) :Pengy: |
...and in KDE?
Does anyone know how to do the above (i.e. turn off mime and enable recognition by extension) in KDE?
I can't find any solution to this seemingly easy problem anywhere. Thanks. |
Nobody does it better, but Katy does it backwards!
Changing file associations in KDE is broken, period. If you attempt to use the properties of a file and edit the file type, you will not edit the file type for that singular file, but for all files with that type embedded in their properties! This is a fubar. Why? Because if you delete, for example, the file associations and types or change the name of the file type, kde will change all files associated as that type. For example, should you wish to change a file that shows up as cpp {C++ Sourec File} meaning only to change that particular file, say newproggie.c.my kde will go and change every cpp files association on your system, and delete all of the associations, types, and description. So now all of your previous cpp files will show up as the new type and will no longer look pretty and open in kwrite with multicolors as they did before. .h files, headers files, are similarly associated so you might think if kde fubar'ed cpp you can fix it quickly by making cpp similar to .h Not so. kde conventions and developers need to add both a warning about changing the file associations, and, more importantly, make changing the file association work on only the particular file you want to change. What all of this means is that you can't create a new file association. I hate to say that a little could be learned from Windows, but in this case it's true. If you create a file with Kwrite, it remains a Kwrite file no matter what you think you've changed it to. Adding a new extension and trying to edit the file association will only change all of the Kwrite file associations on your system. Maybe kde needs a "create file type" set. :Pengy: |
No answers yet because no one knows how KDE is broke, along with all programs that depend on file type associations in Linux.
KDE and KWrite, or any attempt to associate a file with an extension, takes the file descriptor and not the association and changes all files of that genre on the entire Linux Operating System. Neither KDE nor KWrite, not any program should have permission to do this. For example, when you do get to File Associations and select the tree for Text, then select a file type, such as one I've created called x-zone, based on plain text, create the endings and the application preference orderand then click on the icon button, if you dare change the icon, all files of the previous icon button, i.e., plain text, will be changed for every file on the system! The file type is selected by the Description, and all files of that description will be changed! This is totally backwards. You only wanted to change the association so that a new ending would be affected, but that is not how KDE works. Rather, it works on the Description and changes all files of that Description! It is really a bad attempt at file association on the developers' part, in that it associates the Description and the changes you apply, and not the file ending. It can royally screw up a file system. Creating a new type is difficult as well because if you don't have a file to associate [created already], you can't associate it. So the Description comes from a file whose association you want to change, however, this causes KDE to change all files and apparently totally disregard the ending you have supplied. The Howto on mime types, and creating one, leave out one crucial element: how to make KDE or KWrite install and use the new mime type and show it in the drop down menus. All in all, it's developing too fast without paying attention to what is going on. And widgets, like File Association, are consequently broke because of this approach. |
All times are GMT -5. The time now is 11:21 PM. |