Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place! |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
|
07-22-2017, 04:58 AM
|
#1
|
Member
Registered: May 2017
Posts: 46
Rep:
|
Replacement for Hotkeys
Hi,
I am switching my wife to Linux, I have been using it for the last 3 months. Reasons are very simply we are both fed up with Windows updates!!
She uses hotkeys, that I have programed for her.
The sequence is ctrl Y gives [youtube][/youtube] she uses this very often, as you can see, it is a pain to type every time.
Is there a way to set this up in Linux? It is not important what the key sequence is to do it. It can be an F number or any other command.
Thanks all for your help
Simon
|
|
|
07-22-2017, 12:33 PM
|
#2
|
LQ Veteran
Registered: Jul 2006
Location: London
Distribution: PCLinuxOS, Salix
Posts: 6,191
|
Yes indeed! You use the Super key: the one with the Windows logo. It depends on the desktop you're using, but there may be something in the menu for "keyboard shortcuts". If you have KDE, use the menu editor, select the program you want, right-click, and select "properties". If you have Gnome, Mate, or Cinnamon, then you need to run the configuration editor and define both a keybinding and a command. There's a lot of documentation about, or you can ask for more help.
For example, I have
Super-w for gnome-terminal -e "units"
Super-q for wine "/home/david/.wine/drive_c/Program Files/QemuLator/QemuLator.exe"
|
|
|
07-22-2017, 01:11 PM
|
#3
|
LQ Guru
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342
|
xfce4 and perhaps others as well but I am in xfce4 right now and am downloading so I cannot log out and into a different WM/DT to affirm this.
Code:
firefox www.youtube.com
in the keyboard shortcuts app they got then assign it to whatever keys one wants. the format should be similar for other means to apply KB short cuts.
Last edited by BW-userx; 07-22-2017 at 01:13 PM.
|
|
|
07-22-2017, 04:10 PM
|
#4
|
LQ Guru
Registered: Jan 2005
Location: USA and Italy
Distribution: Debian testing/sid; OpenSuSE; Fedora; Mint
Posts: 5,524
|
gnome-control-center allows to assign global keyboard shortcuts.
|
|
|
07-22-2017, 09:46 PM
|
#5
|
Member
Registered: Jun 2016
Distribution: any&all, in VBox; Ol'UnixCLI; NO GUI resources
Posts: 999
|
For CLI (maybe GUI too, Idk): bind (Readline & inputrc: learning FUN for me Thanks! )
|
|
|
07-23-2017, 03:11 AM
|
#6
|
Member
Registered: May 2017
Posts: 46
Original Poster
Rep:
|
Hi,
Thanks for those replies.
I am using Cinammon 18.1, I am not sure I fully understood exactly what I should do, but I will look for some documentation
Thanks again
Simon
|
|
|
07-23-2017, 07:31 AM
|
#7
|
Member
Registered: May 2017
Posts: 46
Original Poster
Rep:
|
Hello Again,
I feel I have not fully explained what I am trying to do.
I am not looking to launch a program by the hotkey, I want some text to be applied when I click the hotkey.
It will be used within Mozilla
Thanks once again
Simon
|
|
|
07-23-2017, 11:48 AM
|
#8
|
LQ Veteran
Registered: Jul 2006
Location: London
Distribution: PCLinuxOS, Salix
Posts: 6,191
|
|
|
|
07-23-2017, 01:09 PM
|
#9
|
Member
Registered: May 2017
Posts: 46
Original Poster
Rep:
|
Sorry,
She repeatedly has to type type the following command [youtube][/youtube] when posting, as you can see it is a bit difficult to type, so in Windows I just created a hotkey that when she pressed ctrl y it typed out the you tube thing.
I should have explained in more detail.
Thanks for your help
Simon
|
|
|
07-23-2017, 02:13 PM
|
#10
|
LQ Guru
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342
|
that little special web key is a hardware thing I do not think it will be useful anymore in Linux just like the "fn" on keyboards. They do not register in the system as a keyboard key because they are not.
you can google about the fn key and you will see all kinds of people asking why there fn key does not work. that special web key for windows I would bet is the same way. it is a 'hardware' key therefore, to set it up to get youtube with only one push of a key you can use a Function key which is do-able . if she does not want to use two keys or more to fire up a web browser and have it go straight to youtube.
How To Change The Linux Mint Cinnamon Keyboard Shortcuts
https://www.lifewire.com/how-to-chan...rtcuts-4064754
if it has an area to type the command just add what I showed in my other post. assign a key or two or three to it then save it. then test it.
Last edited by BW-userx; 07-23-2017 at 02:19 PM.
|
|
|
07-24-2017, 03:36 AM
|
#11
|
Member
Registered: Jun 2016
Distribution: any&all, in VBox; Ol'UnixCLI; NO GUI resources
Posts: 999
|
Make Ubuntu Great Again
More positive toward Linux usability 'UI/UX', (very sorry that I don't 'do' GUI),
both/all are just 'machine code', so IF Win can, Linux can! (I think/HOPE!)
I tried searches like this: linux define hotkey browser "insert text"
&found autokey: https://www.howtogeek.com/howto/2691...x-application/ and https://askubuntu.com/questions/2806...redefined-text
I think I now understand that, in Firebox (like I click on LQ's quote/code/link etc.)
OP wants something like Ctrl+y (or other key, like F9 or ' Win'+y or most anything)
to insert: [youtube][/youtube] into the browser text window, in which they're typing.
Best wishes, for getting Linux to 'work for users'! (Let us know the solution!)
Last edited by Jjanel; 07-24-2017 at 03:41 AM.
|
|
|
07-24-2017, 06:05 AM
|
#12
|
Senior Member
Registered: Apr 2010
Posts: 2,278
|
This needs to open a terminal:
alias you='firefox http://www.youtube.com/'
So just type: you to open youtube (not tested not sure if it will work)
Or try xbindkeys
https://linux.die.net/man/1/xbindkeys
Last edited by JJJCR; 07-24-2017 at 05:55 PM.
Reason: edit
|
|
|
07-24-2017, 09:25 AM
|
#13
|
LQ Guru
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342
|
Quote:
Originally Posted by Jjanel
More positive toward Linux usability 'UI/UX', (very sorry that I don't 'do' GUI),
both/all are just 'machine code', so IF Win can, Linux can! (I think/HOPE!)
I tried searches like this: linux define hotkey browser "insert text"
&found autokey: https://www.howtogeek.com/howto/2691...x-application/ and https://askubuntu.com/questions/2806...redefined-text
I think I now understand that, in Firebox (like I click on LQ's quote/code/link etc.)
OP wants something like Ctrl+y (or other key, like F9 or ' Win'+y or most anything)
to insert: [youtube][/youtube] into the browser text window, in which they're typing.
Best wishes, for getting Linux to 'work for users'! (Let us know the solution!)
|
I gave up looking -- maybe someone should e mail Linus Torvalds about it.
|
|
|
07-24-2017, 02:02 PM
|
#14
|
Member
Registered: Jun 2016
Distribution: any&all, in VBox; Ol'UnixCLI; NO GUI resources
Posts: 999
|
more clarification
To see what OP (apparently) means, do this:
in LQ's 'Reply' msg box, click on the icon for Quote
( [QUOTE][/QUOTE] gets inserted).
The question is: how to setup some 'keystroke' to do like this,
on other websites, like mail/blog/etc.
[youtube][/youtube] would be inserted, and user can then type/paste in between the tags
(like Ab1x99Z or whatever).
|
|
|
07-25-2017, 12:07 PM
|
#15
|
LQ Veteran
Registered: Jul 2006
Location: London
Distribution: PCLinuxOS, Salix
Posts: 6,191
|
This seems to be the answer!
http://code.google.com/archive/p/autokey/
It is odd that this feature is not built-in. Thirty years ago with my Sinclair QL I could just enter the shell command altkey 'a','whatever'.
|
|
1 members found this post helpful.
|
All times are GMT -5. The time now is 08:11 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|