This forum has been archived. All content is frozen. Please use KDE Discuss instead.

How to preview on click instead of on hover?

Tags: None
(comma "," separated)
gpwr
Registered Member
Posts
17
Karma
2
OS
Enabling file previews in Dolphin results in the preview panel updating to the last-hovered file, and not the last-clicked file. The reason this annoys me is that I want to click on my audio samples to preview them when I produce music, before drag-and-dropping them into my DAW, similarly to FL Studio's sample browser previewer. Is this possible?

Thanks in advance, and God bless.


Our aim has to be the infinite and not the finite. The infinite is our homeland. We have always been expected in Heaven.
—Bl. Carlo Acutis
Clancularius
Registered Member
Posts
50
Karma
0
AFAIK, it's not possible. I think the reason it doesn't work like this is because there is the option to open files with a single click in the system settings (workspace behaviour>>general behaviour) and maybe this would cause some conflict. That said, you could set it to single click to open and have the default player preview your audio files but you would obviously be changing that behaviour for all types of files at the same time.
gpwr
Registered Member
Posts
17
Karma
2
OS
I see. That makes a lot of sense. Thanks for your answer!


Our aim has to be the infinite and not the finite. The infinite is our homeland. We have always been expected in Heaven.
—Bl. Carlo Acutis
dzon
Registered Member
Posts
493
Karma
3
Yeah, that doesn't work in Dolphin. But it made me think, if you want to hear or see a quick preview of a media file ( other than on hover that is), I guess you could create a service menu for that.At least, if it's a quick listen or something. Not sure if it'll do you any good but something like this does the trick with mpv. The 10 in the file are the seconds of the preview.

[Desktop Entry]
Type=Service
ServiceTypes=KonqPopupMenu/Plugin
MimeType=video/*;audio/*
Actions=Quicklisten
X-KDE-Submenu=
Icon=amarok_lyrics
X-KDE-Priority=TopLevel

[Desktop Action Quicklisten]
Exec=mpv %f -really-quiet -endpos 10
Name=Quicklisten
Icon=amarok_lyrics

You can add a --geometry option to the exec if you want. Looks like this: https://imgur.com/a/Mx5e14Q

ALTHOUGH...come to think of it, that isn't a good solution. Does pretty much the same as the hover in the end. And, unless you want to set it as default "open with" as an application, it's of no use.


This realm's name is Maya. And she speaks Hertz. But Ahamkara makes a fuzz about it.
dzon
Registered Member
Posts
493
Karma
3
As a desktop app it would look like ( not set as default here):https://imgur.com/a/HaJ9Vbo

File ( goes in ~/.local/share/applications):

[Desktop Entry]
Comment=
Exec=mpv --geometry=400x300 %f -really-quiet -endpos 10
GenericName=logout
Icon=amarok_lyrics
MimeType=x-content/video-vcd;x-content/video-svcd;x-content/video-dvd;x-content/audio-player;x-content/audio-cdda;video/x-theora+ogg;video/x-theora+ogg;video/x-ogm+ogg;video/x-nsv;video/x-msvideo;video/x-msvideo;video/x-msvideo;video/x-msvideo;video/x-msvideo;video/x-ms-wmv;video/x-matroska;video/x-flv;video/x-flv;video/x-flv;video/x-flic;video/x-flic;video/x-anim;video/webm;video/vnd.rn-realvideo;video/vnd.mpegurl;video/quicktime;video/ogg;video/mpeg;video/mpeg;video/mpeg;video/mpeg;video/mpeg;video/mp4;video/mp4;video/mp4;video/mp2t;video/dv;video/3gpp2;video/3gpp2;video/3gpp;video/3gpp;video/3gpp;text/x-google-video-pointer;text/x-google-video-pointer;image/vnd.rn-realpix;audio/x-xm;audio/x-wavpack;audio/x-wav;audio/x-wav;audio/x-vorbis+ogg;audio/x-vorbis+ogg;audio/x-tta;audio/x-speex;audio/x-scpls;audio/x-scpls;audio/x-s3m;audio/x-pn-realaudio-plugin;audio/x-musepack;audio/x-ms-wma;audio/x-ms-asx;audio/x-ms-asx;audio/x-ms-asx;audio/x-mpegurl;audio/x-mpegurl;audio/x-mod;audio/x-matroska;audio/x-it;audio/x-gsm;audio/x-ape;audio/x-aiff;audio/webm;audio/vnd.rn-realaudio;audio/vnd.rn-realaudio;audio/vnd.dts.hd;audio/vnd.dts;audio/ogg;audio/mpeg;audio/mpeg;audio/mpeg;audio/mpeg;audio/mpeg;audio/mp4;audio/mp4;audio/mp4;audio/mp2;audio/mp2;audio/midi;audio/flac;audio/flac;audio/basic;audio/AMR-WB;audio/AMR;audio/ac3;audio/aac;audio/aac;application/xspf+xml;application/x-shorten;application/x-quicktime-media-link;application/x-quicktime-media-link;application/x-matroska;application/vnd.rn-realmedia;application/vnd.rn-realmedia;application/vnd.ms-wpl;application/vnd.ms-asf;application/vnd.ms-asf;application/vnd.ms-asf;application/vnd.ms-asf;application/vnd.apple.mpegurl;application/vnd.adobe.flash.movie;application/sdp;application/ram;application/ogg;application/ogg;application/mxf;
Name=Quickie
NoDisplay=false
Path[$e]=
StartupNotify=true
Terminal=0
TerminalOptions=
Type=Application
X-KDE-SubstituteUID=false
X-KDE-Username=

It's the only way I can think of to immediately have a preview. As you can see, the selected file will show a preview, not the hovered one. https://imgur.com/a/59NIqka
So, in a way it's like opening it in your default player, but slicker and with a given time.


This realm's name is Maya. And she speaks Hertz. But Ahamkara makes a fuzz about it.


Bookmarks



Who is online

Registered users: Bing [Bot], Google [Bot], Sogou [Bot]