Jump to content

Szary

Member
  • Posts

    4
  • Joined

  • Last visited

Reputation

0 Neutral

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Thank you for your reply Hippocode, Could please explain step by step or give me some example files how to build/find resource file which will have the icon and then link it to the plugin? I know I ask for much time but I have spent so many hours digging through the documentation, examples and google that I am close to giving up and you are my only hope. Also I can see there two types of events, object events and tool events, I assume I need the second to built the mode bar? I changed the script file using binary editor to enable tool events but now the tool is not being selected in VW I only get one event with arguments (3,0,0) I try to respond with vs.vstSetEventInfo(3, 0, 0, 1) but this does not help:/ Kind Regards, Peter
  2. Thank you for your reply Hippocode, Could please explain step by step or give me some example files how to build/find resource file which will have the icon and then link it to the plugin? I know I ask for much time but I have spent so many hours digging through the documentation, examples and google that I am close to giving up and you are my only hope. Also I can see there two types of events, object events and tool events, I assume I need the second to built the mode bar? I changed the script file using binary editor to enable tool events but now the tool is not being selected in VW I only get one event with arguments (3,0,0) I try to respond with vs.vstSetEventInfo(3, 0, 0, 1) but this does not help:/ Kind Regards, Peter
  3. I have done further research and maybe my question might be more specific. Do I need to use vwr resource file? http://developer.vectorworks.net/index.php/Vectorworks_VWR_Resources#Compiling_with_BuildVWR_build_step Does anyone have any example with using it with the scripts? And maybe know how to build one?
  4. Hello, I am trying to add an button to the Mode Bar for my tool scripted in python, but I am having some difficulties as I am a newbie. The description here is not very helpful: http://developer.vectorworks.net/index.php/VS:vstAddButtonMode Can you tell me what should be passed in to this function? Or maybe even better, where should I find this info? I found some description for AddRadioMode: The string identifier for the image. It should be of the form "ResourceFileNameWithoutExtension/PathOfImageFile". But I don't know where to put the icon or is the path relative or not? Even without the proper icon specified the button appears on the mode bar with the red cross as an icon, but when I click it I am getting preferences window and the button disappears after the window is gone. Is this because of the icon problem? Or I am doing something else wrong? I am actually writing a python script but I think it should be easy enough to convert. Here is the main code: def PrepModeBar(): vs.vstAddButtonMode("button") def execute(): theEvent,buttonid = vs.vsoGetEventInfo() if theEvent == vs.kObjOnInitXProperties: PrepModeBar() Any help would be appreciated. Regards, Peter
×
×
  • Create New...