Re: Fremantle: HildonCheckButton with two labels
Aniello, thanks for the input. I'll give it a try, but I like to use the second label as description label, as it has a smaller font. Not sure how it will look when I put that much text on a normal check button. But I'll try :) Conny On Mon, 2009-09-21 at 12:02 +0100, Aniello Del Sorbo wrote: May be you don't like it, but why don't actually use the explanation label as the main checkbox label? What's the point of having the first label Xml backend if you then need to explain it a row below? Either you change the one row text to make it clear what you're clicking or put the explanation in the already existing Info button. The latter would make sense so me. Would it for you as well? Aniello 2009/9/21 Alberto Garcia agar...@igalia.com: On Sat, Sep 19, 2009 at 11:55:03AM +0200, Cornelius Hald wrote: I'm trying to create a Hildon check button with two labels. The problem is that HildonCheckButton only supports one label. Why? As Mox explained, that check button was designed to have only one label. If we supported two we wouldn't be able to use some of GtkButton's functions, notably gtk_button_set_label() I can't think of any obvious workaround other than writing a new widget based on the HildonButton code... It looks like the inheritance tree of the Hildon*Buttons is quite messy! Are there any plans to fix that or will it be fixed with Qt? Hopefully we'll be able to make this simpler in the future: https://bugzilla.gnome.org/show_bug.cgi?id=557720 Berto ___ maemo-developers mailing list maemo-developers@maemo.org https://lists.maemo.org/mailman/listinfo/maemo-developers ___ maemo-developers mailing list maemo-developers@maemo.org https://lists.maemo.org/mailman/listinfo/maemo-developers
RE: Fremantle: HildonCheckButton with two labels
On Sun, 2009-09-20 at 21:39 +0200, ext-mox.so...@nokia.com wrote: To me it seems you are trying to cram a bit too much functionality into a single dialog. It's of course feasible, as you show, but it's a bit too Maemo 4 to my taste. Just for completeness, here is a screenshot of the (unfinished) Diablo version: http://talk.maemo.org/attachment.php?attachmentid=3925stc=1d=1250602896 What you could do instead is to replace the checkbuttons with a GtkTreeview (inside pannable), i.e. a list: * you can keep the checkbox graphics within the list, but that will require custom cellrenderer * remove the info and settings buttons for each plugin for this dialog * pressing the list item on top of checkbox, would obviously turn it on/off * pressing the list item elsewhere would open a sub-dialog, which would contain the info/settings stuff for the plugin. Could be pannable if needed. * list supports the two-row text approach, if you want to use that, via custom cellrenderer There are two things that I don't really like about this: 1) Putting the settings and about buttons on level deeper will add one more level of dialogs and I don't like dialogs that open dialogs. I think it's cluttered. I'm already unhappy to have two levels of dialogs. 2) Tapping on the check box of the row will perform a different action than tapping on the text of the row. I think this is confusing to the user as the text is basically the caption of the check box. Therefore text/caption and check box really belong together. But of course I could recreate the same layout as I have now, but instead of buttons using a TreeView. It probably will work, but don't think it will look as clean as the buttons. I might give it a try, though. How is the cell renderer called that is used for the two-row text? Sorry, that I can't completely agree with your idea, but thank you for taking the time :) Hopefully we'll find something that looks nice and is functional. Cheers! Conny ___ maemo-developers mailing list maemo-developers@maemo.org https://lists.maemo.org/mailman/listinfo/maemo-developers
RE: Fremantle: HildonCheckButton with two labels
-Original Message- From: ext Cornelius Hald [mailto:h...@icandy.de] But of course I could recreate the same layout as I have now, but instead of buttons using a TreeView. [...] I might give it a try, though. How is the cell renderer called that is used for the two-row text? Talk to the coders and/or hildon maintainers about that... Mox ___ maemo-developers mailing list maemo-developers@maemo.org https://lists.maemo.org/mailman/listinfo/maemo-developers
RE: Fremantle: HildonCheckButton with two labels
On Mon, 2009-09-21 at 10:35 +0200, ext-mox.so...@nokia.com wrote: -Original Message- From: ext Cornelius Hald [mailto:h...@icandy.de] There are two things that I don't really like about this: 1) Putting the settings and about buttons on level deeper will add one more level of dialogs and I don't like dialogs that open dialogs. I think it's cluttered. I'm already unhappy to have two levels of dialogs. Umm, I didn't actually suggest to add more levels of dialogs. What you could do is to merge the info sub-dialog and settings-subdialog into one subdialog. That single subdialog would open when pressing the list item. Since I haven't seen those subdialogs, hard to say if it makes sense. Fair enough :) As you don't know the dialogs it's of course impossible to tell. The info dialog is like a GtkAboutDialog - name, description, authors, license, etc.. The other dialog is provided by the plugin. I think that's to much info for one dialog and the things are too unrelated, therefore I think it doesn't make sense to merge them. Cheers! Conny ___ maemo-developers mailing list maemo-developers@maemo.org https://lists.maemo.org/mailman/listinfo/maemo-developers
Re: Fremantle: HildonCheckButton with two labels
On Sat, Sep 19, 2009 at 12:00:50PM +0200, Cornelius Hald wrote: In my HildonButton subclass. Instead of setting the GtkCellView using hildon_button_set_image(), I also tried gtk_button_set_image(). The problem with the latter is, that it's just never shown. Probably HildonButton is somehow overriding the image part of GtkButton. Yes, because GtkButton's _set_image() is not a virtual method. GtkButton supports an image and a label. If you change that default layout (which is what HildonButton does) there's no way to reuse some of its methods. Berto ___ maemo-developers mailing list maemo-developers@maemo.org https://lists.maemo.org/mailman/listinfo/maemo-developers
Re: Fremantle: HildonCheckButton with two labels
On Sat, Sep 19, 2009 at 11:55:03AM +0200, Cornelius Hald wrote: I'm trying to create a Hildon check button with two labels. The problem is that HildonCheckButton only supports one label. Why? As Mox explained, that check button was designed to have only one label. If we supported two we wouldn't be able to use some of GtkButton's functions, notably gtk_button_set_label() I can't think of any obvious workaround other than writing a new widget based on the HildonButton code... It looks like the inheritance tree of the Hildon*Buttons is quite messy! Are there any plans to fix that or will it be fixed with Qt? Hopefully we'll be able to make this simpler in the future: https://bugzilla.gnome.org/show_bug.cgi?id=557720 Berto ___ maemo-developers mailing list maemo-developers@maemo.org https://lists.maemo.org/mailman/listinfo/maemo-developers
Re: Fremantle: HildonCheckButton with two labels
May be you don't like it, but why don't actually use the explanation label as the main checkbox label? What's the point of having the first label Xml backend if you then need to explain it a row below? Either you change the one row text to make it clear what you're clicking or put the explanation in the already existing Info button. The latter would make sense so me. Would it for you as well? Aniello 2009/9/21 Alberto Garcia agar...@igalia.com: On Sat, Sep 19, 2009 at 11:55:03AM +0200, Cornelius Hald wrote: I'm trying to create a Hildon check button with two labels. The problem is that HildonCheckButton only supports one label. Why? As Mox explained, that check button was designed to have only one label. If we supported two we wouldn't be able to use some of GtkButton's functions, notably gtk_button_set_label() I can't think of any obvious workaround other than writing a new widget based on the HildonButton code... It looks like the inheritance tree of the Hildon*Buttons is quite messy! Are there any plans to fix that or will it be fixed with Qt? Hopefully we'll be able to make this simpler in the future: https://bugzilla.gnome.org/show_bug.cgi?id=557720 Berto ___ maemo-developers mailing list maemo-developers@maemo.org https://lists.maemo.org/mailman/listinfo/maemo-developers -- -- anidel Sent from London, Eng, United Kingdom ___ maemo-developers mailing list maemo-developers@maemo.org https://lists.maemo.org/mailman/listinfo/maemo-developers
RE: Fremantle: HildonCheckButton with two labels
Hi, The purpose of the two labels in HildonButton, is to have different semantics for the labels. The first one is title, the second one is value (HildonPickerButton) or description (Hildonbutton) The checkbutton doesn't really fit so well with this kind of semantics. So you're not really supposed to have two labels there. So I guess you have something weird in your UI design. If you put the checkbutton widget on a row of it's own, there should be enough width for any sane text for the single label. If you have lack of space, then the first thing to do is to reduce the length of the string. BR, Mox From: maemo-developers-boun...@maemo.org [maemo-developers-boun...@maemo.org] On Behalf Of ext Cornelius Hald [h...@icandy.de] Sent: Saturday, September 19, 2009 13:00 To: maemo-developers@maemo.org Subject: Re: Fremantle: HildonCheckButton with two labels Ah, I forgot another thing I tried: In my HildonButton subclass. Instead of setting the GtkCellView using hildon_button_set_image(), I also tried gtk_button_set_image(). The problem with the latter is, that it's just never shown. Probably HildonButton is somehow overriding the image part of GtkButton. Cheers! Conny On Sat, 2009-09-19 at 11:55 +0200, Cornelius Hald wrote: Hi, I'm trying to create a Hildon check button with two labels. The problem is that HildonCheckButton only supports one label. Why? I don't know, but I'm looking for a work around. What I tried so far: * Creating a HildonButton with two labels and an image that looks like a check box. Does work somehow, but looks slightly different is not themable. * Creating a subclass of HildonButton and adding as an image a GtkCellView with a GtkCellRendererToggle. Does work somehow. The problem is that HildonButton calls gtk_misc_set_alignment() on the image and a GtkCellView is not a GtkMisc, but only a GtkWidget. Therefore this results in many warnings and errors. * Implementing my own subclass of GtkMisc which proxies a GtkCellView, so that I could use this widget as 'image' on HildonButton. No success at all. Way to complicated :( It looks like the inheritance tree of the Hildon*Buttons is quite messy! Are there any plans to fix that or will it be fixed with Qt? Anyways, points to a cleaner work around would be highly appreciated! Thanks! Conny ___ maemo-developers mailing list maemo-developers@maemo.org https://lists.maemo.org/mailman/listinfo/maemo-developers ___ maemo-developers mailing list maemo-developers@maemo.org https://lists.maemo.org/mailman/listinfo/maemo-developers ___ maemo-developers mailing list maemo-developers@maemo.org https://lists.maemo.org/mailman/listinfo/maemo-developers
RE: Fremantle: HildonCheckButton with two labels
Hi, The purpose of the two labels in HildonButton, is to have different semantics for the labels. The first one is title, the second one is value (HildonPickerButton) or description (Hildonbutton) that's fine with me. The first row is Name of Plugin the second is Description of plugin. Now it should be possible to enable and disable those plugins. The checkbutton doesn't really fit so well with this kind of semantics. So you're not really supposed to have two labels there. So I guess you have something weird in your UI design. Why does a checkbox does not fit to the title/description semantics? You can have a something named with title with an additional description and this thing you want to turn on/off. That's what checkboxes are used for, no? Anyways, here is my weird UI :)[1]. It's a list of plugins. For each plugin you can open a config dialog and an about box. The list might get long, so it's pannable with the rest of the settings. Suggestions on how to solve this without writing my own button implementation are welcome. But suggestions on how to add a checkbox to a HildonButton or how to add a second label to a HildonCheckButton are even better - because I like how it looks :) Thanks! Conny [1] http://zwong.de/wp-content/uploads/2009/09/settings_plugins.png ___ maemo-developers mailing list maemo-developers@maemo.org https://lists.maemo.org/mailman/listinfo/maemo-developers
RE: Fremantle: HildonCheckButton with two labels
The purpose of the two labels in HildonButton, is to have different semantics for the labels. The first one is title, the second one is value (HildonPickerButton) or description (Hildonbutton) that's fine with me. The first row is Name of Plugin the second is Description of plugin. Now it should be possible to enable and disable those plugins. The checkbutton doesn't really fit so well with this kind of semantics. So you're not really supposed to have two labels there. So I guess you have something weird in your UI design. Why does a checkbox does not fit to the title/description semantics? You can have a something named with title with an additional description and this thing you want to turn on/off. That's what checkboxes are used for, no? With Maemo 5, there's now very optimized, small set of widgets, which support only certain types of behaviour. Of course, many of those widgets are customizable, but the idea is that those that try to avoid customization will get UI which is very familiar to Maemo 5 users. Because that way the UI is very consistent in all apps. Anyways, here is my weird UI :)[1]. It's a list of plugins. For each plugin you can open a config dialog and an about box. The list might get long, so it's pannable with the rest of the settings. Suggestions on how to solve this without writing my own button implementation are welcome. But suggestions on how to add a checkbox to a HildonButton or how to add a second label to a HildonCheckButton are even better - because I like how it looks :) [1] http://zwong.de/wp-content/uploads/2009/09/settings_plugins.png Thanks a lot for the screenshot, it helped to understand the situation much more than the words alone. To me it seems you are trying to cram a bit too much functionality into a single dialog. It's of course feasible, as you show, but it's a bit too Maemo 4 to my taste. What you could do instead is to replace the checkbuttons with a GtkTreeview (inside pannable), i.e. a list: * you can keep the checkbox graphics within the list, but that will require custom cellrenderer * remove the info and settings buttons for each plugin for this dialog * pressing the list item on top of checkbox, would obviously turn it on/off * pressing the list item elsewhere would open a sub-dialog, which would contain the info/settings stuff for the plugin. Could be pannable if needed. * list supports the two-row text approach, if you want to use that, via custom cellrenderer This way, the dialog becomes a bit more calm, only the most important stuff to look at. BR, Mox ___ maemo-developers mailing list maemo-developers@maemo.org https://lists.maemo.org/mailman/listinfo/maemo-developers
Re: Fremantle: HildonCheckButton with two labels
Ah, I forgot another thing I tried: In my HildonButton subclass. Instead of setting the GtkCellView using hildon_button_set_image(), I also tried gtk_button_set_image(). The problem with the latter is, that it's just never shown. Probably HildonButton is somehow overriding the image part of GtkButton. Cheers! Conny On Sat, 2009-09-19 at 11:55 +0200, Cornelius Hald wrote: Hi, I'm trying to create a Hildon check button with two labels. The problem is that HildonCheckButton only supports one label. Why? I don't know, but I'm looking for a work around. What I tried so far: * Creating a HildonButton with two labels and an image that looks like a check box. Does work somehow, but looks slightly different is not themable. * Creating a subclass of HildonButton and adding as an image a GtkCellView with a GtkCellRendererToggle. Does work somehow. The problem is that HildonButton calls gtk_misc_set_alignment() on the image and a GtkCellView is not a GtkMisc, but only a GtkWidget. Therefore this results in many warnings and errors. * Implementing my own subclass of GtkMisc which proxies a GtkCellView, so that I could use this widget as 'image' on HildonButton. No success at all. Way to complicated :( It looks like the inheritance tree of the Hildon*Buttons is quite messy! Are there any plans to fix that or will it be fixed with Qt? Anyways, points to a cleaner work around would be highly appreciated! Thanks! Conny ___ maemo-developers mailing list maemo-developers@maemo.org https://lists.maemo.org/mailman/listinfo/maemo-developers ___ maemo-developers mailing list maemo-developers@maemo.org https://lists.maemo.org/mailman/listinfo/maemo-developers