The Origin Forum
File Exchange
Try Origin for Free
The Origin Forum
Home | Profile | Register | Active Topics | Members | Search | FAQ | Send File to Tech support
 All Forums
 Origin Forum for Programming
 LabTalk Forum
 Custom Buttons for graphs

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

Screensize:
UserName:
Password:
Anti-Spam Code:
Format Mode:
Format: BoldItalicizedUnderlineStrikethrough Align LeftCenteredAlign Right Horizontal Rule Insert HyperlinkUpload FileInsert Image Insert CodeInsert QuoteInsert List
   
Message:

* HTML is OFF
* Forum Code is ON
Smilies
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Clown [:o)]
Black Eye [B)] Eight Ball [8] Frown [:(] Shy [8)]
Shocked [:0] Angry [:(!] Dead [xx(] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
drmetal Posted - 09/24/2002 : 04:11:47 AM
Hi,

I am looking for custom buttons that do the same as the line-graphbutton but one has the axis-titles "time/intensity" and the other "energy/counts" (for instance) as default axis-titles.
Is something like that possible with LabTalk ?

thanks
Heiko
1   L A T E S T    R E P L I E S    (Newest First)
Mike Buess Posted - 09/24/2002 : 8:38:30 PM
Are you referring to the New Graph button that opens an empty plot window? If so, it runs the command

win -t Plot Origin; // Open a new plot window using the template Origin.otp

To create a button that does that and also changes the axis titles first open a new text file in Notepad. (If you are using Origin 7 you can do this in CodeBuilder instead.) Add the following section to the text file:

[Main]
win -t Plot Origin;
label -xb "time/intensity"; // set bottom axis title
label -yl "energy/counts"; // set left axis title

Save the file as NewPlot.ogs in your Origin program folder. (Of course you can name the file and the section header [Main] anything you want.)

Now that your script is ready you can assign it to a button. Select Toolbars on Origin's View menu and go to the Button Groups tab. Find User Defined on the Groups list, select the button labelled Plot and click the Settings button below. Enter the following Button Settings...

File: NewPlot
Section: Main
Arguments: (leave blank)
Tool Tip Text: (Enter the tool tip message you want to see when the mouse cursor is over the button.)
Status Bar: (Enter the status bar message)
Context: (Leave this alone for now.)

Click OK and drag the Plot button to any existing toolbar. Finally, close the Customize Toolbar dialog and try out your new button.

Mike Buess
Origin WebRing Member

The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000