Add another sub-level to KDE-Submenu in Dolphin actions/services?

Is it possible to create lower levels of sub-menus in Dolphin context menu than the one created by the line X-KDE-Submenu= under [Desktop Entry]?


I have created an action called “Subtitles” (X-KDE-Submenu=Subtitles) which contains 4 options for downloading different languages with the filebot tool. I know I can make that appear in the top level or under Actions. I have set it for toplevel with the line X-KDE-Priority=TopLevel.

[Desktop Entry]
Name=Download subtitles (filebot)

[Desktop Action en]
Exec=filebot -get-subtitles -rename -non-strict %f
Name=English (filebot)

[Desktop Action fr]
Exec=terminator -e "filebot -get-subtitles --lang fr -rename -non-strict %f" -p ttt
Name=Français (filebot)

[Desktop Action ro]
Exec=terminator -e "filebot -get-subtitles --lang ro -rename -non-strict %f" -p ttt
Name=Româneşte (filebot)

[Desktop Action it]
Exec=terminator -e "filebot -get-subtitles --lang it -rename -non-strict %f" -p ttt
Name=Italiano (filebot)

enter image description here

After that I have created a second such file which is almost identical, only it uses the subliminal tool. Also, the two files have different names in Name= under [Desktop Entry]: one is Name=Download subtitles (filebot), the other Name=Download subtitles (subliminal).

Nevertheless, all the eight actions of these two files appear grouped together under ‘Subtitles’.

enter image description here

I was expecting that the names in Name=Download subtitles (filebot) and Name=Download subtitles (subliminal) to count for something, but they seem to do nothing.

I have created two desktop files with 4 actions each but it looks as if I had created a single desktop file with 8 actions, because the two files have in common the line X-KDE-Submenu=Subtitles.

I know I can separate the actions of the two files by setting different X-KDE-Submenu names, but then I will have two different toplevel entries (or two separate entries in Actions if I remove X-KDE-Priority=TopLevel).

But what I want is to have one toplevel entry called Subtitles with two sub-menus, one for filebot, the other for subliminal, and in each of these the four language options – similar to what I can add in a different OS in Nautilus. There, I have made this setting in Nautilus config tool:

enter image description here

Which gives this:

enter image description here

Is something similar possible in Dolphin?

Here is Solutions:

We have many solutions to this problem, But we recommend you to use the first solution because it is tested & true solution that will 100% work for you.

Solution 1

After investigating a bit more I dare say the answer is probably NO.

The Nautilus sub-menus created through settings in nautilus action configuration tool are based on .desktop files created in /.local/share/file-manager/actions. But while the lowest levels (the actions themselves) are normal desktop actions, the intermediary sub-menus (that can go on numerous levels and can be multiplied many times through the nautilus action configuration tool) are not such normal desktop files, but contain Gconf settings.

A Nautilus normal action is a desktop file that contains the line Type=Action; the multipliable menus are desktop files that contain the line Type=Menu, but also a line like ItemsList=495e5ac1-e34b-4570-b7e2-fb2188410dff;034e7ec6-32f8-4538-956b-624e421593ac;c2ee726a-bda0-4e36-96db-e8cfaa7c83d6;f519ea3d-6937-457e-baf9-4a9dcd586062;, which is the Gconf setting.

I guess that is not doable in KDE and Dolphin.

Note: Use and implement solution 1 because this method fully tested our system.
Thank you 🙂

All methods was sourced from or, is licensed under cc by-sa 2.5, cc by-sa 3.0 and cc by-sa 4.0

Leave a Reply