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
Username:
Password:
Save Password
Forgot your Password? | Admin Options

 All Forums
 Origin Forum for Programming
 LabTalk Forum
 Layout page editing
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

alex_eagle

Austria
36 Posts

Posted - 10/15/2002 :  11:47:38 AM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
I want to add a graph and a worksheet window to the layout page
with the DoToolbox-command. How can I define automatically
size and position of the windows in the layout page without clicking and dragging ?

Alex


Laurie

USA
404 Posts

Posted - 10/15/2002 :  2:40:42 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
You have to size and position manually. Once the window has been added to the layout page, it is now an object that you can manipulate. Alt+double-click on the image and you'll see the object name from the Label Control dialog. In the Script Window, type the objectname.= and press Return and you'll see a list of all object properties. For example, type:

BMP.=



OriginLab Technical Support
Go to Top of Page

Mike Buess

USA
3037 Posts

Posted - 10/16/2002 :  11:18:50 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi Alex,

The draw.last$ property gets the name of the last object that was created, so you don't have to open the Label Control to find the object name. One way to use this is to define a macro something like this...

def SetWin {
%O=draw.last$;
%O.left=%1; // position of left edge in pixels
%O.top=%2; // position of top edge in pixels
%O.width=%3; // height in pixels
%O.height=%4; // width in pixels
};

and use it like this...

#First, add graph to layout page
dotool -pg Graph1;
-- click on layout page to create the graph image --

#Next (immediately) enter following command
SetWin 0 0 150 150;

This will position the graph window in the upper left hand corner of the layout page and set its width and height to 150 pixels. As Laurie said you can use

%O.=

(after you run the SetWin macro) to find other properties you might want to control.

Mike Buess
Origin WebRing Member
Go to Top of Page
  Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000