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
 Ajusting label positions - varying behaviour
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

peter.cook

UK
356 Posts

Posted - 03/23/2005 :  06:59:23 AM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Origin Version (Select Help-->About Origin): 7.5SR5
Operating System: Win2000

Hi,

I have observed different behaviour on different PCs when trying to adjust label positions via code. Can anyone please shed any light. What I really want is to ensure the same behaviour for all users. The graph templates is of course the same for all. the code is :

 def ChangeLabelFormat {

Switch(NGpP)
{
Case 1 2:
Top1=260; DTop=80; Nfsize=16; NumLines=1; break;
Case 3 4 5 6:
Top1=190; Top2=1240; DTop=50; Nfsize=12; NumLines=2; break;
Case 7 8 9:
Top1=170; Top2=880; Top3=1580; DTop=40; Nfsize=10; NumLines=3; break;
Default:
Break;
};
loop(ng,1,NGpP) {
page.active=ng;
if(NumLines==3) {
layer.top+=2;
layer.height-=2;
}
NumLine=int(NumLines*(ng-1)/NGpP)+1;
Compound$(ng).top=Top$(NumLine);
Compound$(ng)a.top=Top$(NumLine)+DTop;
Compound$(ng).fsize=Nfsize;
Compound$(ng)a.fsize=Nfsize;
};
if(NGpP==1) {
antagonistlabel1.show=0; agonistlabel1.show=0;
};
};


For some users the label positions have to be set to different values. I think this is something to do with page/layer units but changing the unit values has no effect on the code behaviour.
Any help would be greatly appreciated.

Cheers,

pete

Leo_Li

China
Posts

Posted - 03/31/2005 :  02:08:48 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi Peter,
Your problem is mostly due to different resolutions of pages on different computers. Please check:

page.resx=
page.resy=

If so, your positions of labels should be scaled. Please let us know whether it works.

Leo
Originlab
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