home *** CD-ROM | disk | FTP | other *** search
/ PC World 1997 November / PCWorld_1997-11_cd.bin / software / programy / komix / DATA.Z / menuced.mnu < prev    next >
Text File  |  1997-04-07  |  12KB  |  631 lines

  1. registerObject {
  2.     type        CustMenuBarButton
  3.     name        .file
  4.     readOnly    1
  5.     objSpec {
  6.         label        File
  7.         mnemonic    F
  8.         }
  9. }
  10.  
  11. registerObject {
  12.     type        CustMenu
  13.     name        .file.menu
  14.     readOnly    1
  15. }
  16.  
  17. registerObject {
  18.     type        CustMenuPushButton
  19.     name        .file.menu.reload
  20.     readOnly    1
  21.     objSpec {
  22.         hintText    "Reloads the edited customization file."
  23.         label        "Reload"
  24.         mnemonic    l
  25.         accelerator    Ctrl+r
  26.         activated    {.main edit [.main object]}
  27.     }
  28. }
  29.  
  30. registerObject {
  31.     type        CustMenuPushButton
  32.     name        .file.menu.save
  33.     readOnly    1
  34.     inToolBar    1
  35.     objSpec {
  36.         hintText    "Saves the edited customization file."
  37.         label        Save
  38.         mnemonic    S
  39.         accelerator    Ctrl+S
  40.         toolBarPixmap    save_16
  41.         checkOn        levelChange
  42.         enableScript    {
  43.             if [.main currentlyReadOnly] {
  44.                 %this sensitive 0
  45.             } else {
  46.                 %this sensitive 1
  47.             }
  48.         }
  49.         activated    {.main save}
  50.     }
  51. }
  52.  
  53. registerObject {
  54.     type        CustMenuSeparator
  55.     name        .file.menu.separator2
  56.     readOnly    1
  57. }
  58.  
  59. registerObject {
  60.     type        CustMenuPushButton
  61.     name        .file.menu.exit
  62.     readOnly    1
  63.     objSpec {
  64.         hintText    "Exits the editor."
  65.         label        "Exit"
  66.         mnemonic    x
  67.         activated    {.main exit}
  68.     }
  69. }
  70.  
  71. registerObject {
  72.     type        CustMenuBarButton
  73.     name        .edit
  74.     readOnly    1
  75.     objSpec {
  76.         label        Edit
  77.         mnemonic    E
  78.     }
  79. }
  80.  
  81. registerObject {
  82.     type        CustMenu
  83.     name        .edit.menu
  84.     readOnly    1
  85.     objSpec {
  86.     }
  87. }
  88.  
  89. registerObject {
  90.     type        CustCascadeButton
  91.     name        .edit.menu.new
  92.     readOnly    1
  93.     objSpec {
  94.         hintText    "Contains commands for defining menu objects. "
  95.         label        New
  96.         mnemonic    N
  97.     }
  98. }
  99.  
  100. registerObject {
  101.     type        CustMenu
  102.     name        .edit.menu.new.menu
  103.     readOnly    1
  104.     objSpec {
  105.     }
  106. }
  107.  
  108. registerObject {
  109.     type        CustMenuPushButton
  110.     name        .edit.menu.new.menu.menubarbutton
  111.     readOnly    1
  112.     objSpec {
  113.         hintText    "Creates a new menu bar button."
  114.         label        "MenuBarButton..."
  115.         mnemonic    M
  116.         checkOn        levelChange
  117.         enableScript    {
  118.             if [.main currentlyReadOnly] {
  119.                 %this sensitive 0
  120.             } else {
  121.                 %this sensitive 1
  122.             }
  123.         }
  124.         activated    { 
  125.             if {[catch {.main.newMBButton popUp}]} {
  126.                 require "newmenubar.tcl"
  127.                 NewMenuBarButtonDialog new .main.newMBButton
  128.                 .main.newMBButton popUp
  129.             }
  130.         }
  131.     }
  132. }
  133.  
  134. registerObject {
  135.     type        CustMenuPushButton
  136.     name        .edit.menu.new.menu.cascadebutton
  137.     readOnly    1
  138.     objSpec {
  139.         hintText    "Creates a new cascade button."
  140.         label        "CascadeButton..."
  141.         mnemonic    C
  142.         checkOn        levelChange
  143.         enableScript    {
  144.             if [.main currentlyReadOnly] {
  145.                 %this sensitive 0
  146.             } else {
  147.                 %this sensitive 1
  148.             }
  149.         }
  150.         activated    { 
  151.             if {[catch {.main.newMenuEntry popUp CustCascadeButton}]} {
  152.                 require "newmenuent.tcl"
  153.                 NewMenuEntryDialog new .main.newMenuEntry
  154.                 .main.newMenuEntry popUp CustCascadeButton
  155.             }
  156.         }
  157.     }
  158. }
  159.  
  160. registerObject {
  161.     type        CustMenuSeparator
  162.     name        .edit.menu.new.menu.separator1
  163.     readOnly    1
  164. }
  165.  
  166. registerObject {
  167.     type        CustMenuPushButton
  168.     name        .edit.menu.new.menu.pushbutton
  169.     readOnly    1
  170.     objSpec {
  171.         hintText    "Creates a new push button."
  172.         label        "PushButton..."
  173.         mnemonic    P
  174.         checkOn        levelChange
  175.         enableScript    {
  176.             if [.main currentlyReadOnly] {
  177.                 %this sensitive 0
  178.             } else {
  179.                 %this sensitive 1
  180.             }
  181.         }
  182.         activated    { 
  183.             if {[catch {.main.newMenuEntry popUp CustMenuPushButton}]} {
  184.                 require "newmenuent.tcl"
  185.                 NewMenuEntryDialog new .main.newMenuEntry
  186.                 .main.newMenuEntry popUp CustMenuPushButton
  187.             }
  188.         }
  189.     }
  190. }
  191.  
  192. registerObject {
  193.     type        CustMenuPushButton
  194.     name        .edit.menu.new.menu.checkbutton
  195.     readOnly    1
  196.     objSpec {
  197.         hintText    "Creates a new check button."
  198.         label        "CheckButton..."
  199.         mnemonic    h
  200.         checkOn        levelChange
  201.         enableScript    {
  202.             if [.main currentlyReadOnly] {
  203.                 %this sensitive 0
  204.             } else {
  205.                 %this sensitive 1
  206.             }
  207.         }
  208.         activated    { 
  209.             if {[catch {.main.newMenuEntry popUp CustMenuCheckButton}]} {
  210.                 require "newmenuent.tcl"
  211.                 NewMenuEntryDialog new .main.newMenuEntry
  212.                 .main.newMenuEntry popUp CustMenuCheckButton
  213.             }
  214.         }
  215.     }
  216. }
  217.  
  218. registerObject {
  219.     type        CustMenuPushButton
  220.     name        .edit.menu.new.menu.radiobutton
  221.     readOnly    1
  222.     objSpec {
  223.         hintText    "Creates a new radio button."
  224.         label        "RadioButton..."
  225.         mnemonic    R
  226.         checkOn        levelChange
  227.         enableScript    {
  228.             if [.main currentlyReadOnly] {
  229.                 %this sensitive 0
  230.             } else {
  231.                 %this sensitive 1
  232.             }
  233.         }
  234.         activated    { 
  235.             if {[catch {.main.newMenuEntry popUp CustMenuRadioButton}]} {
  236.                 require "newmenuent.tcl"
  237.                 NewMenuEntryDialog new .main.newMenuEntry
  238.                 .main.newMenuEntry popUp CustMenuRadioButton
  239.             }
  240.         }
  241.     }
  242. }
  243.  
  244. registerObject {
  245.     type        CustMenuSeparator
  246.     name        .edit.menu.new.menu.separator2
  247.     readOnly    1
  248. }
  249.  
  250. registerObject {
  251.     type        CustMenuPushButton
  252.     name        .edit.menu.new.menu.separator
  253.     readOnly    1
  254.     objSpec {
  255.         hintText    "Creates a new separator."
  256.         label        "Separator..."
  257.         mnemonic    S
  258.         checkOn        levelChange
  259.         enableScript    {
  260.             if [.main currentlyReadOnly] {
  261.                 %this sensitive 0
  262.             } else {
  263.                 %this sensitive 1
  264.             }
  265.         }
  266.         activated    { 
  267.             if {[catch {.main.newSeparator popUp}]} {
  268.                 require "newmenusep.tcl"
  269.                 NewMenuSeparatorDialog new .main.newSeparator
  270.                 .main.newSeparator popUp 
  271.             }
  272.         }
  273.     }
  274. }
  275.  
  276. registerObject {
  277.     type        CustMenuPushButton
  278.     name        .edit.menu.editproperties
  279.     inPopUpMenu    1
  280.     readOnly    1
  281.     objSpec {
  282.         hintText    "Edits the properties of the selected object."
  283.         label        "Edit Properties"
  284.         mnemonic    E
  285.         selCount    1
  286.         checkOn         selectionChange
  287.         enableScript    {
  288.             if {![[[.main editorArea] selectedSet] editable]} {
  289.                 %this sensitive 0
  290.             } else {
  291.                 if [.main currentlyReadOnly] {
  292.                     %this sensitive 0
  293.                 } else {
  294.                     %this sensitive 1
  295.                 }
  296.             }
  297.         }
  298.         activated    { 
  299.             [[.main editorArea] selectedSet] open
  300.         }
  301.     }
  302. }
  303.  
  304. registerObject {
  305.     type        CustMenuPushButton
  306.     name        .edit.menu.redefine
  307.     readOnly    1
  308.     inToolBar    1
  309.     inPopUpMenu    1
  310.     objSpec {
  311.         hintText    "Create a new object with the properties of the selected one."
  312.         label        "Redefine"
  313.         mnemonic    R
  314.         selCount    1
  315.         checkOn         selectionChange
  316.         toolBarPixmap    copy_16
  317.         enableScript    {
  318.             if [.main currentlyReadOnly] {
  319.                 %this sensitive 0
  320.             } else {
  321.                 %this sensitive 1
  322.             }
  323.         }
  324.         activated    { 
  325.             set obj [[.main editorArea] selectedSet]
  326.             set newObj [[.main editorArea] redefineObject $obj]
  327.             if [isCommand $newObj] {
  328.                 wmtkmessage "'[$obj name]' redefined, starting edit..."
  329.                 $newObj redefined 1
  330.                 $newObj open    
  331.                 wmtkmessage ""
  332.             } else {
  333.                 wmtkwarning $newObj
  334.             }
  335.         }
  336.     }
  337. }
  338.  
  339. registerObject {
  340.     type        CustMenuSeparator
  341.     name        .edit.menu.separator1
  342.     readOnly    1
  343. }
  344.  
  345. registerObject {
  346.     type        CustMenuPushButton
  347.     name        .edit.menu.info
  348.     readOnly    1
  349.     inToolBar    1
  350.     inPopUpMenu    1
  351.     objSpec {
  352.         hintText    "Gives info on the selected object."
  353.         label        "Info"
  354.         mnemonic    I
  355.         selCount    1
  356.         checkOn         selectionChange
  357.         activated    { 
  358.             set obj [[.main editorArea] selectedSet]
  359.             .main showObjectInfo $obj
  360.         }
  361.         toolBarPixmap    info_16
  362.        }
  363. }
  364.  
  365. registerObject {
  366.     type        CustMenuSeparator
  367.     name        .edit.menu.separator3
  368.     readOnly    1
  369. }
  370.  
  371. registerObject {
  372.     type        CustMenuPushButton
  373.     name        .edit.menu.delete
  374.     readOnly    1
  375.     inToolBar    1
  376.     inPopUpMenu    1
  377.     objSpec {
  378.         hintText    "Deletes the selected object."
  379.         label        "Delete"
  380.         mnemonic    D
  381.         accelerator     Del
  382.         selCount    many
  383.         checkOn         selectionChange
  384.         enableScript    {
  385.             if [.main currentlyReadOnly] {
  386.                 %this sensitive 0
  387.             } else {
  388.                 %this sensitive 1
  389.                 foreach obj [[.main editorArea] selectedSet] {
  390.                     if {![$obj editable]} {
  391.                         %this sensitive 0
  392.                     }
  393.                 }
  394.             }
  395.         }
  396.         activated    { 
  397.             [.main editorArea] deleteObjects [[.main editorArea] selectedSet]
  398.         }
  399.         toolBarPixmap    delete_16
  400.     }
  401. }
  402.  
  403. registerObject {
  404.     type    CustMenuBarButton
  405.     name    .view
  406.     objSpec {
  407.         label        View
  408.         mnemonic    V
  409.     }
  410. }
  411.  
  412. registerObject {
  413.     type    CustMenu
  414.     name    .view.menu
  415.     objSpec {
  416.     }
  417. }
  418.  
  419. registerObject {
  420.     type    CustMenuCheckButton
  421.     name    .view.menu.toolbar
  422.     objSpec {
  423.         hintText    "Shows or hides the toolbar."
  424.         label        ToolBar
  425.         mnemonic    T
  426.         state        1
  427.         stateChanged    {
  428.             .main toolBarPresent [[.main menuBar].view.menu.toolbar state]
  429.         }
  430.     }
  431. }
  432.  
  433. registerObject {
  434.     type    CustMenuCheckButton
  435.     name    .view.menu.contextarea
  436.     objSpec {
  437.         hintText    "Shows or hides the context area."
  438.         label        "Context Area"
  439.         mnemonic    C
  440.         state        1
  441.         stateChanged    {
  442.             .main contextAreaPresent [[.main menuBar].view.menu.contextarea state]
  443.         }
  444.     }
  445. }
  446.  
  447. registerObject {
  448.     type    CustMenuCheckButton
  449.     name    .view.menu.messagearea
  450.     objSpec {
  451.         hintText    "Shows or hides the message area."
  452.         label        "Message Area"
  453.         mnemonic    M
  454.         state        1
  455.         stateChanged    {
  456.             .main messageAreaPresent [[.main menuBar].view.menu.messagearea state]
  457.         }
  458.     }
  459. }
  460.  
  461. registerObject {
  462.     type    CustMenuBarButton
  463.     name    .options
  464.     objSpec {
  465.         label        Options
  466.         mnemonic    O
  467.     }
  468. }
  469.  
  470. registerObject {
  471.     type    CustMenu
  472.     name    .options.menu
  473.     objSpec {
  474.         pinnable    1
  475.     }
  476. }
  477.  
  478. registerObject {
  479.     type    CustMenuPushButton
  480.     name    .options.menu.font
  481.     objSpec {
  482.         hintText    "Changes the view font."
  483.         label        "Font..."
  484.         mnemonic    F
  485.         activated    {[.main options] font}
  486.     }
  487. }
  488.  
  489. registerObject {
  490.     type        CustMenuBarButton
  491.     name        .filter
  492.     objSpec
  493.     {
  494.         label        "Filter"
  495.         mnemonic    i
  496.     }
  497. }
  498.  
  499. registerObject {
  500.     type        CustMenu
  501.     name        .filter.menu
  502.     objSpec
  503.     {
  504.         pinnable    1
  505.     }
  506. }
  507.  
  508. registerObject {
  509.     type        CustMenuCheckButton
  510.     name        .filter.menu.filteronactiveentries
  511.     objSpec
  512.     {
  513.         hintText    "Filters out the not active entries"
  514.         label        "Filter On Active Entries"
  515.         mnemonic    A
  516.         stateChanged    { set filter [[.main editorArea] filter]
  517.                   $filter activeFilter [%this state]
  518.                   if {[isCommand [.main wmtArea]]} {
  519.                       if [$filter isFilterActive] {
  520.                         [.main wmtArea] filter "On"    
  521.                       } else {
  522.                         [.main wmtArea] filter "Off"    
  523.                       }
  524.                   }
  525.         }
  526.     }
  527. }
  528.  
  529. registerObject {
  530.     type        CustMenuCheckButton
  531.     name        .filter.menu.filteroutseparators
  532.     objSpec
  533.     {
  534.         hintText    "Filters out the separators."
  535.         label        "Filter Out Separators"
  536.         mnemonic    S
  537.         stateChanged    { set filter [[.main editorArea] filter]
  538.                   $filter separatorFilter [%this state]
  539.                   if {[isCommand [.main wmtArea]]} {
  540.                       if [$filter isFilterActive] {
  541.                         [.main wmtArea] filter "On"    
  542.                       } else {
  543.                         [.main wmtArea] filter "Off"    
  544.                       }
  545.                   }
  546.         }
  547.     }
  548. }
  549.  
  550. registerObject {
  551.     type        CustMenuBarButton
  552.     name        .help
  553.     readOnly    1
  554.     objSpec {
  555.         label        Help
  556.         mnemonic    H
  557.         helpButton    1
  558.     }
  559. }
  560.  
  561. registerObject {
  562.     type        CustMenu
  563.     name        .help.menu
  564.     readOnly    1
  565.     objSpec {
  566.         pinnable    1
  567.     }
  568. }
  569.  
  570. registerObject {
  571.     type        CustMenuPushButton
  572.     name        .help.menu.whatsthis
  573.     readOnly    1
  574.     objSpec {
  575.         hintText    "Shows context sensitive help."
  576.         label        "What's This?"
  577.         mnemonic    W
  578.         activated    {.main helpOnContext}
  579.     }
  580. }
  581.  
  582.  
  583. registerObject {
  584.     type    CustMenuPushButton
  585.     name    .help.menu.helptopics
  586.     readOnly    1
  587.     objSpec {
  588.     hintText    "Shows help topics."
  589.     label        "Help Topics"
  590.     mnemonic    T
  591.     activated    {showHelpTopics}
  592.     }
  593. }
  594.  
  595. registerObject  {
  596.     name        .help.menu.productdocumentation
  597.     type        CustMenuPushButton
  598.     objSpec        {
  599.         label        {Product Documentation}
  600.         hintText    {Starts online documentation.}
  601.         activated    {
  602.             #CTGENMessage
  603.             wmtkmessage {Start online documentation ...}
  604.             #CTGENBusyCursorOn
  605.             .main busy TRUE
  606.             #CTGENCommandScript
  607.             startOnlineDoc 
  608.             #CTGENEndCommandScript    
  609.             #CTGENRemoveMessage
  610.             wmtkmessage ""
  611.             #CTGENBusyCursorOff
  612.             .main busy FALSE
  613.         }
  614.     }
  615. }
  616.  
  617. registerObject {
  618.     type    CustMenuPushButton
  619.     name    .help.menu.aboutmenucustomizationeditor
  620.     readOnly    1
  621.     objSpec {
  622.         hintText    "Shows version information."
  623.         label        "About Menu Customization Editor"
  624.         mnemonic    A
  625.         activated    {
  626.             showVersionDialog [%this label]
  627.         }
  628.     }
  629. }
  630.  
  631.