Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 0e697c86e291709f8ca61f4ad3388be2f804c276
Ticket: cb62320163a541a573763f3c0fcaf6cb4ce561cb
two errors moving from itcl 4.0.3 to itcl 4.0.4
User & Date: bennron on 2016-04-11 15:08:03
Changes

  1. assignee changed to: "nobody"
  2. closer changed to: "nobody"
  3. cmimetype changed to: "text/plain"
  4. comment changed to:
    Apr 11, 2016
    Ronald Benn
    Q.W.Page Associates Inc.
    [email protected]
    
    Moving from tcl 8.6.4 and itcl 4.0.3 to tcl 8.6.5 and itcl 4.0.4
    
    Two errors occur and both are described here. Both prevent the creation of iWidgets which are in turn based on the itk library. My code failed creating a toplevel iWidget but probably creating any iWidget will expose the problems. The errors were (1) and (2) below:
    
    (1) invalid command name ".itk.dialog1.info.list"
    
    The workaround to (1) is in itk4.0/Archetype.tcl. Line (a) below has to be changed to line (b)
    
            (a) ::rename $itk_component(hull) $_path
    
            (b) ::uplevel #0 ::rename $itk_component(hull) $_path
     
    (2) "bad option "_option_add": should be one of ..."
    
    The workaround to (2) is also in itk4.0/Archetype.tcl. Line (c) below has to be changed to line (d)
    
            (c) private _option_add {list} {
    
            (d) protected method _option_add {list} {
    
    Both workarounds indicate the change from tcl 8.6.4 to tcl 8.6.5 and itcl 4.0.3 to itcl 4.0.4 involve implementation of namespaces and a subtle difference has occurred. For error (1) it is probable that the command is renamed to a command within the namespace of the itk widget instead of in the global namespace and the uplevel #0 workaround deals with this. The cause of error (2) is unknown but seems to be a problem with the implementation of private versus protected and may also be namespace-related.
    
    
    It would seem that iWidgets will not work in itcl 4.0.4 and this is pretty serious. It cost me a couple of days to isolate the problem. Also note that moving to itcl 4.0.4. is also critical as itcl 4.0.4 fixes a bug that made itcl 4.0 several orders of magnitude (depending on the test) slower than itcl 3.4. I am up and working with the workarounds but I think these issues should be addressed.
    
  5. foundin changed to: "tcl 8.6.5 itcl 4.0.4"
  6. is_private changed to: "0"
  7. login: "bennron"
  8. priority changed to: "5 Medium"
  9. private_contact changed to: "265d4f5d7c80223f93178459dda260259b0ea86f"
  10. resolution changed to: "None"
  11. severity changed to: "Critical"
  12. status changed to: "Open"
  13. submitter changed to: "bennron"
  14. subsystem changed to: "- New Builtin Object Types"
  15. title changed to: "two errors moving from itcl 4.0.3 to itcl 4.0.4"
  16. type changed to: "Bug"