From: Alex T. <al...@tw...> - 2006-05-26 13:45:39
|
The Mac OS X guidelines, indeed the OS provided controls, have some restrictions on what they allow. Since wxWidgets uses these controls, wxPython and PythonCard have the same restrictions. Currently those restrictions are not reflected in the layoutEditor, which can lead users to think there is a bug in the layoutEditor (and therefore PythonCard in general). (btw - I wouldn't be at all surprised if there were indeed bugs in PythonCard and/or the layoutEditor that exacerbate these problems - but so far I haven't seen any confirmed cases). There probably are lots of such restrictions, but the ones I have come across are - textfields (i.e. single line TextCtrl) does not support setting the backgroundColour - textarea (i.e. multi-line TextCtrl) does not support alignment (other than left) - button does not support setting foregroundColour - button does not (adequately) support setting backgroundColour (the rectangle "behind" the button is set, but not within the button itself - ugly !!) It would be good to not only document this somewhere, but (since it will be an easily overlooked footnote in the docs) also make it more obvious to a user when they try to set properties that will not be reasonably honoured cross-platform. This would be especially helpful if they are setting a property while on a system that doesn't really support it - but I think should be done anyway to help people design cross-platform apps if they so desire. Would a dialog / preference be too intrusive ? Something like You have set a property that is not supported on your current platform. [ ] Don't give this warning again. ( OK ) and also same thing but "... supported on some other platforms." If that was a preference - should it be per-user, or per project ? Or would it be better to simply document it as prominently as we can ? -- Alex Tweedly http://www.tweedly.net -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.394 / Virus Database: 268.7.1/348 - Release Date: 25/05/2006 |
From: Brad A. <bra...@ma...> - 2006-05-26 15:03:12
|
Alex Tweedly wrote: >The Mac OS X guidelines, indeed the OS provided controls, have some >restrictions on what they allow. Since wxWidgets uses these >controls, wxPython and PythonCard have the same restrictions. >Currently those restrictions are not reflected in the layoutEditor, >which can lead users to think there is a bug in the layoutEditor >(and therefore PythonCard in general). (btw - I wouldn't be at all >surprised if there were indeed bugs in PythonCard and/or the >layoutEditor that exacerbate these problems - but so far I haven't >seen any confirmed cases). > >There probably are lots of such restrictions, but the ones I have >come across are >- textfields (i.e. single line TextCtrl) does not support setting >the backgroundColour >- textarea (i.e. multi-line TextCtrl) does not support alignment >(other than left) >- button does not support setting foregroundColour >- button does not (adequately) support setting backgroundColour > (the rectangle "behind" the button is set, but not within >the button itself - ugly !!) Thanks for bringing this up, Alex. I hadn't tried any of those settings on the Mac. The only limitation I was aware of was on button height; apparently there is UI standard for button height on Mac OS X, and wx keeps you from violating it while running on the Mac. If you create a tall button on another platform, and then run it on a Mac, the button smashes down to the standard size, leaving your button label hanging outside the button (usually above). I like the idea of a popping up warning dialog when using LayoutEditor to change a widget in a way that causes problems with other platforms. It should explain in each case which platform doesn't support the change, and offer to either cancel the change or apply anyway. There could also be a checkbox in the dialog saying "Don't warn me about this again." For those who are targeting only a single platform, and find the warnings annoying, create a preference setting for multiresource editor: checkbox: "Disable All Cross-Platform Warnings" > If that was a preference - should it be per-user, or per project ? I didn't know that PythonCard had a concept of "project". I had assumed the preference would be per user, but if you can tie it to a project that would be great. Some projects target cross-platform, while others do not. |
From: Alex T. <al...@tw...> - 2006-05-26 16:24:54
|
Brad Allen wrote: > Thanks for bringing this up, Alex. I hadn't tried any of those > settings on the > Mac. The only limitation I was aware of was on button height; apparently > there is UI standard for button height on Mac OS X, and wx keeps you > from violating it while running on the Mac. If you create a tall > button on another platform, and then run it on a Mac, the button > smashes down to the standard size, leaving your button label hanging > outside the button (usually above). > Thanks Brad - I had seen that one, but had forgotten it again > I like the idea of a popping up warning dialog when using LayoutEditor > to change a widget in a way that causes problems with other platforms. > It should explain in each case which platform doesn't support the change, > and offer to either cancel the change or apply anyway. I think it would more likely be generic "feature not evenly supported on all platforms, see http://wiki.wxpython.org/index.cgi/PythonCardPlatformRestrictions for list of known restrictions" > There could also be a checkbox in the dialog saying "Don't warn me > about this again." > > For those who are targeting only a single platform, and find the warnings > annoying, create a preference setting for multiresource editor: > > checkbox: "Disable All Cross-Platform Warnings" > >> If that was a preference - should it be per-user, or per project ? > > > I didn't know that PythonCard had a concept of "project". I had > assumed the preference would be per user, but if you can tie it to > a project that would be great. Some projects target cross-platform, > while others do not. > It doesn't have a 'project' concept - I should have said "per resource file" -- Alex Tweedly http://www.tweedly.net -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.394 / Virus Database: 268.7.1/348 - Release Date: 25/05/2006 |
From: XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX - 2006-05-26 15:12:43
|
On 26/5/06 14:45, Alex Tweedly wrote: > > It would be good to not only document this somewhere, but (since it will > be an easily overlooked footnote in the docs) also make it more obvious > to a user when they try to set properties that will not be reasonably > honoured cross-platform. This would be especially helpful if they are > setting a property while on a system that doesn't really support it - > but I think should be done anyway to help people design cross-platform > apps if they so desire. > > Would a dialog / preference be too intrusive ? Something like > > You have set a property that is not supported on your current platform. > [ ] Don't give this warning again. ( OK ) > > and also same thing but "... supported on some other platforms." > > If that was a preference - should it be per-user, or per project ? > > Or would it be better to simply document it as prominently as we can ? > IMHO I would just create a page in the documentation and on the site (or wiki) that lists what does or doesn't work on each platform, and try to keep that up-to-date. If you do add it, I would vote for per-user, so I can switch it off once and not see it again. My PythonCard projects currently just target Windows, but I do some early design and coding on my Mac, so the warning doesn't help me. Of course, if at some point I target OSX as a release platform and forget about the limitations it's my own fault. I would have thought that adding the dialog could end up being an ongoing chore you'd rather not have to deal with. Who knows what might happen in the future, e.g. 1) Microsoft suddenly starts following Apple's ideas and starts restricting what properties can be changed in a late Vista beta; 2) Apple continues it's "do as I say, not as I do" approach when it comes to its HI guidelines, and suddenly 10.5 comes out with some of the properties now available for amending; 3) The wxWidgets team replaces some of the Apple components with their own versions in which you can start setting the properties. OK, none of the above could happen, but who knows - you might end up having to implement a dialog that needs to test platform, OS version and wxPython version. And having to release a new version of PythonCard whenever one of the above possible scenarios happens, unless you implement a list of affected components that are held in a config. file. Of course, it's at this point that you tell me you've already added it, it does all the above and it only took a few minutes.....;-) -- XXXXXXXXXXX |