Tool Bar Question
-
To start I have not used the toolbar to access my wood working joint tools so I don't know how toolbars are created. My K2WS_Joint tools contains an Tools-menu/menu/sub-menu/sub-menu to operate and in using the program I find it seems to be a drag to always need 4 mouse clicks to get the tool back again. Typically after using a tool you need a different tool for the next operation. For instance after making a M&T Joint at one end of a table apron you would need to change to the Tenon Only tool to make the tenon at the other end because the copied/flipped leg component would already have the mortise.
Now this is my question: Could I make a generic tool bar with 4 buttons that would respond to the current Type of Joint Tool??
When the M&T tool loads could it define the button operations as Joint Tool, Tenon Only, Mortise Only. Then if the user changed to the Dowel Joint tool the buttons redefined to Dowel Joint, Holes, Add Holes & Dowels, Dowels in Existing Holes?
Basically I am asking could the toolbar be context sensitive to the current Joint Tool selected? You can see by the code below how many options are available but the User will usually only need 1 or 2 of the Joint Tools in a given session.if( not file_loaded?("K2_ToolsLoader.rb")) # Access the main Tools menu tools_menu = UI.menu "Tools" # Add a separator and a submenu tools_menu.add_separator sub_menu = tools_menu.add_submenu("KK_Tools") # Add two menu items to the submenu sub_menu1 = sub_menu.add_submenu("Biscuits") it1 = sub_menu1.add_item("Complete Biscuit Joint") {biscuitJointTool} it2 = sub_menu1.add_item("Add Biscuit Slots & Biscuits 1 Comp") {biscuitSlotTool} #it3 = sub_menu1.add_item("Add Biscuits") {biscuitTool} it4 = sub_menu.add_item("BoxJoint_Fingers") {boxJointFingers} sub_menu2 = sub_menu.add_submenu("Dominos") it5 = sub_menu2.add_item("Complete Domino Joint") {dominoJoint} it6 = sub_menu2.add_item("Add Holes & Dominos 1 Comp") {dominoHoles} #it7 = sub_menu2.add_item("Add Dominos") {dominos} sub_menu3 = sub_menu.add_submenu("Dovetails") it8 = sub_menu3.add_item("Blind Dovetail Pins") {blind_dovetailPintool} it9 = sub_menu3.add_item("Blind Dovetail Tails") {blind_dovetailTailtool} it10 = sub_menu3.add_item("Thru Dovetail Pins") {dovetailPintool} it11 = sub_menu3.add_item("Thru Dovetail Tails") {dovetailTailtool} sub_menu4 = sub_menu.add_submenu("Dowels") it12 = sub_menu4.add_item("Complete Dowel Joint") {dowelJoint} it13 = sub_menu4.add_item("Add Holes & Dowels 1 Comp") {dowelHoles} it14 = sub_menu4.add_item("Add Dowels") {dowels} sub_menu5 = sub_menu.add_submenu("Mortise & Tenon") it15 = sub_menu5.add_item("Loose-Tenon Joint") {looseTenonJointtool} it16 = sub_menu5.add_item("Add Mortise 1 Comp") {mortiseC1tool} #it17 = sub_menu5.add_item("Add Loose Tenons") {mortiseC1tool} it18 = sub_menu5.add_item("Mortise & Tenon Joint") {mortise_TenonJoint} it19 = sub_menu5.add_item("Add Tenon 1 Comp") {tenonC1} it20 = sub_menu.add_item("Pocket Scw Holes") {pocketscw_holes} it21 = sub_menu.add_item("Screw Holes") {screw_holes} end
Currently the menu loads all the time but these tools are individual plug-in files and only load after the menu button is selected. One other option would be to make each tool a extension so the user would only load the extensions he/she would need for that session. This still could be toolbar overload if several tools were added for that session.
Any suggestions will be appreciated
Keith
This is the file that makes the menu items and loads the individual tool files as needed
-
Instead of yet another toolbar... why not set a shortcut-key to the menu item[s] that you are frequently using ?
-
do you read your PM's or check for answers? john
Advertisement