Igor 7.08 - Position of controls in recreation macro?

rwashenfelder
Posts: 10
Joined: 2016-03-28
Location: United States

If I create a Control Panel in Igor 7.08 and save the recreation macro, the controls are saved in slightly incorrect positions. Here's a simple example:

NewPanel; Button button0,pos={10,10},size={40,20}

//Recreation macro created by Igor 7.06:
Window MyPanel() : Panel
PauseUpdate; Silent 1 // building window...
NewPanel /W=(150,77,450,277) as "MyPanel"
Button button0,pos={10.00,10.00},size={40.00,20.00}
EndMacro

// Recreation macro created by Igor 7.08:
Window MyPanel() : Panel
PauseUpdate; Silent 1 // building window...
NewPanel /W=(90,49.8,270,169.8) as "MyPanel"
Button botton0,pos={9.60,9.60},size={39.60,19.80}
EndMacro

This is a very small example, but I'm working with a large panel in Igor 7.08 and when I save the recreation macro, all the controls are misaligned.

Is there any explanation / work-around?

Thanks,
Rebecca


Posts: 1966
Joined: 2007-06-29
Location: United States

Are you running on a Windows system? Is your display set to 125% scaling (or 120 DPI)? That 125% setting for displays on Windows has given us a lot of grief. I think there may be some integer arithmetic involved somewhere...

John Weeks
WaveMetrics, Inc.
support@wavemetrics.com


rwashenfelder
Posts: 10
Joined: 2016-03-28
Location: United States

John,

Thanks for the reply. I have a new laptop with Igor 7.08, Windows 7, and 125% scaling (like you guessed). I tried changing the display to 100% scaling, and that solved the problem with the control panel positions. I can use 100% scaling when I'm laying out panels.

- Rebecca


Posts: 1966
Joined: 2007-06-29
Location: United States

Thanks for the follow-up. The whole business of laying out control panels got a lot more complicated with high-resolution displays. You may benefit from reading DisplayHelpTopic "Control Panel Resolution on Windows".

John Weeks
WaveMetrics, Inc.
support@wavemetrics.com


Back to top