What I mean is,for example I have the 3 files called "x.png","y.png" and "z.png" and I have set that the default png viewer is something like showfoto,but I want that only "z.png" gets opened by gwenview by default. I know I can just click on "open with",but with this feature it would safe some time,cause I don't have to click on "open with" every time I want to open the specific file. So I want to be able to set a program that opens those specific files by default. It would also be handy If I can select that all files in a specific folder use a different default application than the systems default,so for example if the default image viewer of the system viewer is showfoto,but i want that all png files in folder "example name" get opened with gwenview. Btw this feature would have an actual usecase for me,cause many windows programs don't work with the newest wine version and with that feature I could just set different default wine version for a .exe that doesn't work with the newest wine version. I know there are wine managers,but I want to do everything in a file manager. And this feature would also be handy if that happens for another program,so that some files only work with an older version. It would just save much time.
I don't think that would be feasible, finding apps to open a file is mainly based on the mimetype, not by file name...
So is it impossible to implement a feature like that?
Not impossible, just somewhat incompatible with the way it's currently done. One way it could be implemented is to add an extended attribute on the file indicating that it wishes to always be opened with a particular application, if available. If that application is not available, or no such extended attribute is set, it would fall back to opening with the normal mimetype-based method. This is the kind of thing that would ideally be proposed as a FreeDesktop spec, as it would be kind of sucky for it to only work in a KDE-based environment.