On Jun 19, 2011, at 5:30 AM, f...@libero.it wrote: >> My system throws an error for this: >> - ttk::bindMouseWheel $w.glist "glist.ybar_ $w.glist" >> -> invalid command name "ttk::bindMouseWheel" >> Instead i use >> + bindMouseWheel $w.glist "glist.ybar_ $w.glist" >> > Thanks, i forgot to catch the call. > Which tk version are you using? > I think that ttk:bindMouseWheel should work on Mac too. > It would be nice if someone with a Mac can confirm this.
It works on my Mac with Tcl/Tk 8.5.9, but the horizontal scrolling also scrolls vertically. Scrolling to the left also scrolls upward (much faster than the horizontal scrolling), the opposite happens with the right scrolling. Vertical scrolling works without any problem. I only have a Magic Trackpad to test, but it works fine with the demo widgets that come with Tk. >> There are other minor bugs too. >> >> But using C++ style procedure names (eg "glist.update") is not a good idea. >> Why not just use "::" ? In most everything tcl/tk (and certainly the whole > of >> Scid), the "." is pretty much reserved for the Tk widget hierarchy. You're >> really messing badly with the given conventions imho. >> > Well, i suppose it's a matter of taste. > Widget must start with . so i don't think glist.update can be confused with a > widget. > And if you download the ttk::treeview source code you will see that there are > heading.press heading.drag heading.release etc... > The fact is tcl has no encapsulation. > Especially in scid is difficult to figure out what a function do without > reading the code. > Writing glist.update makes clear that glist is an object and update one of > his > methods. > So one can assume that update will not change other glist objects or other > scid parts. > However, as i said, i suppose it's a matter of taste. I think the issue is not about taste, it's about consistency. I think that mixing coding styles makes the code harder to read and might be the source of confusion later on, if you check Scid's code you'll see that '::' is used everywhere. Israel ------------------------------------------------------------------------------ EditLive Enterprise is the world's most technically advanced content authoring tool. Experience the power of Track Changes, Inline Image Editing and ensure content is compliant with Accessibility Checking. http://p.sf.net/sfu/ephox-dev2dev _______________________________________________ Scid-users mailing list Scid-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/scid-users