Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

ToolFltkMenu Class Reference

VMDFltkMenu subclass that implements a GUI for configuring Tool, Sensor, Button, Feedback, and VMDTracker objects. More...

#include <ToolFltkMenu.h>

Inheritance diagram for ToolFltkMenu:

VMDFltkMenu VMDMenu UIObject List of all members.

Public Methods

 ToolFltkMenu (VMDApp *)
void reset_device_menus ()
 Put tracker, force, and button device names into choosers. More...

void reset_tool_list ()
 Re-create list of of active tools. More...

void create_tool ()
 Create a new tool, using the current tool type from the tooltypechooser. More...

void delete_tool ()
 Delete the currently selected tool. More...

void select_tool_type ()
 Change the currently selected tool to the currently selected type. Does nothing if no tool is selected. More...

void select_tool ()
 A tool has been selected in the toolchooser; update the values for the devices, offset, force, etc. More...

void choose_tracker (const char *)
 A device of the given type has been chosen in the GUI. More...

void choose_feedback (const char *)
void choose_buttons (const char *)
void set_offset ()
 set the tool offset based on current values. More...

void set_springscale ()
 set the spring constant for the tool based on the current value. More...

void set_forcescale ()
 set the force scale for the tool based on current values. More...

void set_positionscale ()
 set the position scaling for the tool based on the current value. More...

void set_toolrep ()
 Set the rep, if any, assigned to the current tool. More...

void update_toolrep_choosers ()
 Make the tool rep reflect reality, based on currently existing molecules and reps and the currently selected tool, if any. More...

void update_replist ()
 Update the rep list to reflect the currently selected molecule. More...


Protected Methods

int act_on_command (int, Command *)
 update the display due to a command being executed. Return whether any action was taken on this command. Arguments are the command type, command object, and the success of the command (T or F). More...


Detailed Description

VMDFltkMenu subclass that implements a GUI for configuring Tool, Sensor, Button, Feedback, and VMDTracker objects.

Definition at line 37 of file ToolFltkMenu.h.


Constructor & Destructor Documentation

ToolFltkMenu::ToolFltkMenu VMDApp  
 

Definition at line 503 of file ToolFltkMenu.C.

References UIObject::app, cmdList, UIObject::command_wanted, UIVR::num_tool_types, reset_device_menus, UIVR::tool_name, Command::TOOL_SCALE, Command::TOOL_SCALE_FORCE, Command::TOOL_SCALE_SPRING, toolrepCmdList, and VMDApp::uivr.


Member Function Documentation

int ToolFltkMenu::act_on_command int    type,
Command  
[protected, virtual]
 

update the display due to a command being executed. Return whether any action was taken on this command. Arguments are the command type, command object, and the success of the command (T or F).

Reimplemented from UIObject.

Definition at line 525 of file ToolFltkMenu.C.

References cmdList, reset_tool_list, select_tool, Command::TOOL_SCALE, Command::TOOL_SCALE_FORCE, Command::TOOL_SCALE_SPRING, toolrepCmdList, and update_toolrep_choosers.

void ToolFltkMenu::choose_buttons const char *   
 

Definition at line 375 of file ToolFltkMenu.C.

References UIObject::app, select_tool, UIVR::set_buttons, and VMDApp::uivr.

Referenced by button_cb.

void ToolFltkMenu::choose_feedback const char *   
 

Definition at line 371 of file ToolFltkMenu.C.

References UIObject::app, select_tool, UIVR::set_feedback, and VMDApp::uivr.

Referenced by force_cb.

void ToolFltkMenu::choose_tracker const char *   
 

A device of the given type has been chosen in the GUI.

Definition at line 367 of file ToolFltkMenu.C.

References UIObject::app, select_tool, UIVR::set_tracker, and VMDApp::uivr.

Referenced by position_cb.

void ToolFltkMenu::create_tool  
 

Create a new tool, using the current tool type from the tooltypechooser.

Definition at line 285 of file ToolFltkMenu.C.

References UIObject::app, NULL, and VMDApp::tool_create.

Referenced by createtool_cb.

void ToolFltkMenu::delete_tool  
 

Delete the currently selected tool.

Definition at line 290 of file ToolFltkMenu.C.

References UIObject::app, and VMDApp::tool_delete.

Referenced by deletetool_cb.

void ToolFltkMenu::reset_device_menus  
 

Put tracker, force, and button device names into choosers.

Definition at line 243 of file ToolFltkMenu.C.

References UIObject::app, UIVR::get_button_names, UIVR::get_feedback_names, UIVR::get_tracker_names, ResizeArray::num, and VMDApp::uivr.

Referenced by ToolFltkMenu.

void ToolFltkMenu::reset_tool_list  
 

Re-create list of of active tools.

Definition at line 275 of file ToolFltkMenu.C.

References Tool::alive, UIObject::app, UIVR::gettool, UIVR::num_tools, Tool::type_name, and VMDApp::uivr.

Referenced by act_on_command.

void ToolFltkMenu::select_tool  
 

A tool has been selected in the toolchooser; update the values for the devices, offset, force, etc.

Definition at line 300 of file ToolFltkMenu.C.

References Tool::alive, UIObject::app, Tool::get_buttons, Tool::get_feedback, Tool::get_tracker, Tool::getforcescale, Tool::getoffset, Tool::getscale, Tool::getspringscale, UIVR::gettool, n, Tool::type_name, VMDApp::uivr, and update_toolrep_choosers.

Referenced by act_on_command, choose_buttons, choose_feedback, choose_tracker, and select_tool_cb.

void ToolFltkMenu::select_tool_type  
 

Change the currently selected tool to the currently selected type. Does nothing if no tool is selected.

Definition at line 294 of file ToolFltkMenu.C.

References UIObject::app, n, and VMDApp::tool_change_type.

Referenced by select_tool_type_cb.

void ToolFltkMenu::set_forcescale  
 

set the force scale for the tool based on current values.

Definition at line 390 of file ToolFltkMenu.C.

References UIObject::app, n, and VMDApp::tool_set_force_scale.

Referenced by forcescale_cb.

void ToolFltkMenu::set_offset  
 

set the tool offset based on current values.

Definition at line 380 of file ToolFltkMenu.C.

References n, and UIObject::runcommand.

Referenced by offset_cb.

void ToolFltkMenu::set_positionscale  
 

set the position scaling for the tool based on the current value.

Definition at line 406 of file ToolFltkMenu.C.

References UIObject::app, n, and VMDApp::tool_set_position_scale.

Referenced by positionscale_cb.

void ToolFltkMenu::set_springscale  
 

set the spring constant for the tool based on the current value.

Definition at line 398 of file ToolFltkMenu.C.

References UIObject::app, n, and VMDApp::tool_set_spring_scale.

Referenced by forceconstant_cb.

void ToolFltkMenu::set_toolrep  
 

Set the rep, if any, assigned to the current tool.

Definition at line 415 of file ToolFltkMenu.C.

References UIObject::app, VMDApp::molecule_id, n, and UIObject::runcommand.

Referenced by moleculerep_cb, and toolrep_cb.

void ToolFltkMenu::update_replist  
 

Update the rep list to reflect the currently selected molecule.

Definition at line 474 of file ToolFltkMenu.C.

References UIObject::app, VMDApp::molecule_id, VMDApp::molrep_get_selection, and VMDApp::num_molreps.

Referenced by moleculerep_cb, and update_toolrep_choosers.

void ToolFltkMenu::update_toolrep_choosers  
 

Make the tool rep reflect reality, based on currently existing molecules and reps and the currently selected tool, if any.

Definition at line 428 of file ToolFltkMenu.C.

References UIObject::app, fill_fltk_molchooser, Tool::get_rep_molid, Tool::get_rep_name, UIVR::gettool, VMDApp::molecule_id, VMDApp::molrep_get_by_name, n, VMDApp::num_molecules, VMDApp::uivr, and update_replist.

Referenced by act_on_command, and select_tool.


The documentation for this class was generated from the following files:
Generated on Fri Nov 8 02:47:24 2024 for VMD (current) by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002