fabounet, Tuesday 07 September 2010 à 10:17
|
|
Subscription date : 30 November 2007
Messages : 17118
|
I have a request for the applet
I've noticed that I often have to switch between 2 languages (basicaly en->fr and fr->en)
but the menu doesn't let me do that easily (or maybe I've missed something)
it seems that you have to select the "from" and te "to" languages from the long list, and it's not very convenient.
since the user will most probably always use the same languages, it would be nice to have a list of predefined couples.
this list could be placed directly in the main menu to be quickly accessible
the problem is to find a way to add/remove a predefined couple (maybe with an entry to add/remove the current one). |
SQP, Tuesday 07 September 2010 à 14:39
|
|
Subscription date : 03 July 2010
Messages : 1081
|
seeing your problem, I'd also suggest a "swap languages" option in right menu
or two modes : as your main language shouldn't change often.
- Get a list of preferred language in config
- menu checkbox (and shortcut) to allow easily swapping between something that could be described as reading (other language to your main) and writing (your language to the other one) mode
- 2 select list for translate and main language
|
Subscription date : 05 August 2009
Messages : 285
|
Right button over the icon -> "Switch languages" does not fit your needs ? Because it swap between the current pair of languages. That was already a Matttbe's suggestion that I've coded. I will think about the preferred languages list. Nice suggestion. |
SQP, Tuesday 07 September 2010 à 17:46
|
|
Subscription date : 03 July 2010
Messages : 1081
|
since I didn't installed it yet, I was just suggesting that option. Seem that fabounet didn't saw it |
fabounet, Tuesday 07 September 2010 à 17:58
|
|
Subscription date : 30 November 2007
Messages : 17118
|
oh, sorry if I missed it
how does it work ? does it swap the 2 languages "from"/"to" ? (this is actually what I need, but I could want to switch between 3 languages often, and then a user-defined list would be convenient too). |
Subscription date : 05 August 2009
Messages : 285
|
@Fabounet: Yes, swap between from/to. In cases where there is more than a pair, only the "preferred pairs" would save us. |
Subscription date : 05 August 2009
Messages : 285
|
Anyway, in cases where you have 3 or more, the selection would be manual, through menu, for example. At least the way I think it now. |
SQP, Wednesday 08 September 2010 à 02:28
|
|
Subscription date : 03 July 2010
Messages : 1081
|
may I complete my explaination to see if that would be usable :
First in the config :
- the preferred languages list (full checkbox maybe)
- main language : choice between a fixed one (select) and list (same choice, or maybe with only those in preffered)
then in the right menu :
- Writing mode (checkbox) : enable mode your language -> other language. So we could have shortcuts for toggle, read and write. I guess the common case is when you want to read other languages text so it would be the default unchecked.
- Translated : select list of preferred languages. Selected one with a checked mark.
- My language : if list enabled only, select list of preferred languages. Selected one with a checked mark.
so we don't have to manage pairs of languages list, and it should suit all needs easily without too much config. |
fabounet, Wednesday 08 September 2010 à 17:28
|
|
Subscription date : 30 November 2007
Messages : 17118
|
with your idea we could have a menu like that :
preferred languages --> 2n entries "main language -> language i" and "language i -> main language"
write mode <--.
read mode <---- these 2 entries are mutually exclusive (checkbox)
all languages --> N entries
the scroll could be used to quickly switch between read and write (or between the preferred languages) |
Subscription date : 05 August 2009
Messages : 285
|
@Fabounet: I have one doubt. Where can I read about the widgets that can be generated with the applet .conf file ? I mean, all those widgets in the of an applet's Configuration screen are generated when the .conf file is parsed. So, for example, a generates a checkbox with label "Lock position", and generates a select list filled with "item1" "item2", and so on. Since I've writing applets for CD I saw it but never found the doc. |
SQP, Thursday 09 September 2010 à 21:57
|
|
Subscription date : 03 July 2010
Messages : 1081
|
half of the src/gldit/cairo-dock-gui-factory.h file
edit : easy, I had the same last week |
fabounet, Friday 10 September 2010 à 10:38
|
|
Subscription date : 30 November 2007
Messages : 17118
|
yep, or you can just look into the config file of a plug-in that has the same widget you want |
SQP, Friday 10 September 2010 à 10:58
|
|
Subscription date : 03 July 2010
Messages : 1081
|
I was sure I saw a double select list widget somewhere (the one where you can switch items between list), but can't find it anymore.
Am I confusing with the clipboard one ? |
fabounet, Friday 10 September 2010 à 11:54
|
|
Subscription date : 30 November 2007
Messages : 17118
|
you can have a list with a checkbox on each line (cf Animated Icons)
it could be used to select the preferred languages |
Subscription date : 05 August 2009
Messages : 285
|
Yes, I was looking for that, and found in that source pointed by SQP the #E[item;item;item] (checkbox list). |
Subscription date : 05 August 2009
Messages : 285
|
The Translator is listed as Extra for 2.2.0 only, but it works for 2.1.3 >= CD Version < 2.2.0 also. Actually, the CD version I'm using, and also testing it is 2.1.4-0beta1. This separation was done because the new options for categories ? |
matttbe, Wednesday 22 September 2010 à 19:46
|
|
fabounet, Thursday 23 September 2010 à 11:05
|
|
Subscription date : 30 November 2007
Messages : 17118
|
I think this applet should not bother to work with the 2.1.3, since the official version is now 2.2.0.
so it's better to remove any test on the version, and assume that you are using the latest DBus API, it makes the code much easier to read and maintain (and saves you some work )
the applet will only be available if it matches the dock's version, so no need to worry about that. |
Subscription date : 05 August 2009
Messages : 285
|
@Fabounet: I agree about the maintainment aspect. No worries, I'm one of those that still use CD in its older versions, so, if the code does not have a back-compatibility, automatically I can not use it. My question was just to understand, there is no problem to list it just in 2.2.0 extras. Cheers. |
Subscription date : 05 August 2009
Messages : 285
|
Added the dictionary capability. If you provide only one word to the translator, it returns the dictionary with nouns, verbs, adjectives, and interjections that Google would. |
|