Author Topic: GUI project for aliaser ala autokey  (Read 1081 times)

Offline Archie

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 8821
  • Aurum nostrum non est aurum vulgi.
GUI project for aliaser ala autokey
« on: October 05, 2011, 09:43:46 PM »
I've got some free time and I would like to embark on a collaborative project with anyone who wishes to learn with me.

I've recently tested Autokey and it is sweet. Very pragmatic. Aliaser is unlike it but similar. Aliaser is CLI only and I would like to try and add a dress to it.

I am not a coder much less a programmer but I am willing to learn and to test and maybe eventually contribute something meaningful to PCLinuxOS.

I am planning on contacting the author of Aliaser for his permission to use his code but only when I am sure I (and anyone else volunteering) can make something out of it.

I am not sure how easy or difficult this would be ... and it will probably include a lot of reading and code samples ... and I really didn't plan on this. It's just a choice I made last night ... a whim.

Anyone?
Since 2006 | LiCo 401868 | Bare Metal | What is necessary is never unwise. --Sarek, 2258.42


Offline Just17

  • PCLinuxOS Tester
  • Super Villain
  • *******
  • Posts: 11064
  • MLUs Forever!
Re: GUI project for aliaser ala autokey
« Reply #1 on: October 06, 2011, 03:08:22 AM »
What style of dress do you plan to use?

I have oft begun to try my hand at dress-making but failed miserably ..... I might try again as a collaboration ....  have no idea what Autokey is, but that should not make a huge difference (I hope) :D
MLUs rule the roost!

Linux XPS 3.4.48-pclos1.bfs  64 bit
Intel Core2 Quad CPU Q9450 @ 2.66GHz
4 GB RAM
MCP51 High Def Audio
GeForce GTX 550 Ti
PHILIPS  ‎DVD+-RW DVD8701
‎Logitech ‎BT Mini-Receiver
Afatech DTT

Offline Archie

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 8821
  • Aurum nostrum non est aurum vulgi.
Re: GUI project for aliaser ala autokey
« Reply #2 on: October 06, 2011, 04:35:11 AM »
Thank you for replying, John. It's what can be agreed on - QT/GTK ... heck, even Java if that's where it can be taken. Zenity is much easier (I think). But Autokey is already suited up; it's Aliaser that I wanna try to tailor.

This is menotu's post of Aliaser and I have been using it since. I find it much more usual than adding to .bash_aliases. The core is a python script and it lets you add, remove, list, etc aliases on the fly. I run my simple scripts with a couple of keystrokes+Enter ... it is really handy. But Autokey is handier.

Anyway, back to your question ... a most likely answer would be to first try Zenity (the easiest) and if that doesn't work we could explore GTK or QT. So that's just me thinking out loud.

But more important I suppose is that you first try aliaser. I hope Leiche would also jump in.
Since 2006 | LiCo 401868 | Bare Metal | What is necessary is never unwise. --Sarek, 2258.42


Offline Just17

  • PCLinuxOS Tester
  • Super Villain
  • *******
  • Posts: 11064
  • MLUs Forever!
MLUs rule the roost!

Linux XPS 3.4.48-pclos1.bfs  64 bit
Intel Core2 Quad CPU Q9450 @ 2.66GHz
4 GB RAM
MCP51 High Def Audio
GeForce GTX 550 Ti
PHILIPS  ‎DVD+-RW DVD8701
‎Logitech ‎BT Mini-Receiver
Afatech DTT

Offline Archie

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 8821
  • Aurum nostrum non est aurum vulgi.
Re: GUI project for aliaser ala autokey
« Reply #4 on: October 06, 2011, 07:18:02 AM »
Yes, that's the one. And as you can see from the screenshots, it's all done on the terminal. Have you taken a look at Autokey? As I mentioned, it is very similar in function but quite different.
Since 2006 | LiCo 401868 | Bare Metal | What is necessary is never unwise. --Sarek, 2258.42


Offline Just17

  • PCLinuxOS Tester
  • Super Villain
  • *******
  • Posts: 11064
  • MLUs Forever!
Re: GUI project for aliaser ala autokey
« Reply #5 on: October 06, 2011, 07:18:59 AM »
Yes, that's the one. And as you can see from the screenshots, it's all done on the terminal. Have you taken a look at Autokey? As I mentioned, it is very similar in function but quite different.

No, no idea even where to find it  :D
MLUs rule the roost!

Linux XPS 3.4.48-pclos1.bfs  64 bit
Intel Core2 Quad CPU Q9450 @ 2.66GHz
4 GB RAM
MCP51 High Def Audio
GeForce GTX 550 Ti
PHILIPS  ‎DVD+-RW DVD8701
‎Logitech ‎BT Mini-Receiver
Afatech DTT

Offline Archie

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 8821
  • Aurum nostrum non est aurum vulgi.
Re: GUI project for aliaser ala autokey
« Reply #6 on: October 06, 2011, 08:43:06 AM »
You can try it by installing the 64-bit unofficial RPMS. The files you will need are:

  • autokey-0.71.3-5_archie_2011.x86_64.rpm
  • autokey-common-0.71.3-5_archie_2011.x86_64.rpm
  • autokey-qt-0.71.3-5_archie_2011.x86_64.rpm

Please refer to this post for current issues, which is only the QT version is working and not the GTK.

My screenshots:
Aliaser running on Konsole


Autokey QT
Since 2006 | LiCo 401868 | Bare Metal | What is necessary is never unwise. --Sarek, 2258.42


Online muungwana

  • Hero Member
  • *****
  • Posts: 6269
Re: GUI project for aliaser ala autokey
« Reply #7 on: October 06, 2011, 09:16:55 AM »

You dont need their permission to create a GUI front end and they will probably be happy to know somebody is creating a GUI front end for it to make it more usable.

You dont need their permission because your program will be just another user as far as their program is concerned. They may complain if you take extra steps to hide the fact that you are using their program while hiding their. Display the back end prominently and they wont complain.

I have my own project i started to help me learn qt and qt is very easy to use toolkit. It shouldnt be hard doing it in qt and will help if you decide to go with this toolkit.

my project is at: http://code.google.com/p/zulucrypt/

.. 3 things are certain in life : death, taxes and software bloat ..
.. tell me something i don't know, something i can use as i struggle to reason with the world around me ..

Online muungwana

  • Hero Member
  • *****
  • Posts: 6269
Re: GUI project for aliaser ala autokey
« Reply #8 on: October 06, 2011, 09:22:57 AM »

I am not sure how easy or difficult this would be ... and it will probably include a lot of reading and code samples ... and I really didn't plan on this. It's just a choice I made last night ... a whim.


No, not really, you are creating a front end to a cli too. All you will do is run the tool on the terminal with the option you want, look at the output to know what your GUI will expect and then from your GUI program, you run the program with the options you want and then read the cli program output and then work with it.

You do not need to know or look at the project source code. The only thing you will need to know is what option the cli tool expect and what output it gives when it run with given options.
.. 3 things are certain in life : death, taxes and software bloat ..
.. tell me something i don't know, something i can use as i struggle to reason with the world around me ..

Offline Neal ManBear

  • Administrator
  • Super Villain
  • *****
  • Posts: 15829
  • LXDE! Coffee, Bacon and Cheesecake!
Re: GUI project for aliaser ala autokey
« Reply #9 on: October 06, 2011, 09:46:30 AM »
Archie,
For examples in using zenity to create a GUI, look at pinoc's addlocale and lomanager scripts. He adds comments throughout, so you can understand what is being coded. Check out Leiche's scripts. I believe you'll learn a lot from his work, too.     

You may want to consider using yad as an alternative to zenity.     

Offline Archie

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 8821
  • Aurum nostrum non est aurum vulgi.
Re: GUI project for aliaser ala autokey
« Reply #10 on: October 06, 2011, 10:15:32 AM »
Thank you so much for your input, muungwana, Neal. Truly appreciate it. Frankly, I am bent on QT4 as I have already QT4 Designer installed on my KDE system. However, as much as I know very little about its advantages, I don't know much of its disadvantages. Hence, soliciting your inputs. To many of you seasoned coders, this project may look plain and simple. It will be my first so you must pardon my ignorance.

@muungwana, what you pointed out makes good sense. When the time is right, I do want to let them know about this endeavor. I just feel it is the right thing to do. I really do not need their permission since the license state that I only need retain/reproduce their copyright but giving them notice might even make me another friend. :)

@Neal, I've played a bit with Zenity and it is easy enough to understand much of it. Thank you for pointing pinoc's addlocale and lomanager as examples.

As for what the python script actually does, I've been using it long enough to list and understand the options included, which are not really that hard to follow. And I do have an idea in my mind of what the window might look like. I'll post an image of this idea as soon as I get around to it.

Thank you to both of you.
Since 2006 | LiCo 401868 | Bare Metal | What is necessary is never unwise. --Sarek, 2258.42


Offline Neal ManBear

  • Administrator
  • Super Villain
  • *****
  • Posts: 15829
  • LXDE! Coffee, Bacon and Cheesecake!
Re: GUI project for aliaser ala autokey
« Reply #11 on: October 06, 2011, 10:21:18 AM »
Hmm...... a while back, I played a bit with QT Creator. I remember liking it much more than QT Designer.     

Online muungwana

  • Hero Member
  • *****
  • Posts: 6269
Re: GUI project for aliaser ala autokey
« Reply #12 on: October 06, 2011, 10:29:03 AM »

Qt designer just creates the GUI. If you use it, you will have to take its output and manually incorporated it in your Qt code.

You are better off using kdevelop or qt creator for both code and UI creating. They both have Qt designer build into them and will auto integrate the GUI elements with your code and you will be able to go back and forth btw UI design and code within the same program
.. 3 things are certain in life : death, taxes and software bloat ..
.. tell me something i don't know, something i can use as i struggle to reason with the world around me ..

Offline Archie

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 8821
  • Aurum nostrum non est aurum vulgi.
Re: GUI project for aliaser ala autokey
« Reply #13 on: October 06, 2011, 10:36:35 AM »
Great! Very useful info. I do hope some GTK fans can pitch in their 2 cents.
Since 2006 | LiCo 401868 | Bare Metal | What is necessary is never unwise. --Sarek, 2258.42


Offline Neal ManBear

  • Administrator
  • Super Villain
  • *****
  • Posts: 15829
  • LXDE! Coffee, Bacon and Cheesecake!
Re: GUI project for aliaser ala autokey
« Reply #14 on: October 06, 2011, 10:43:28 AM »
GTK has Glade3. It is a GUI creator. Its big drawback is that it creates your GUI in XML. ::) Then there's Anjuta. http://www.anjuta.org/