Ctrl+A Autoscale Graph as subwindow in a Panel

Hello!

I have a question about the Ctrl+A (Windows) shortcut for autoscaling a Graph subwindow. In my application I have a panel with a Graph subwindow embedded and when I try to use Ctrl+A to autoscale its axes it does not work. Even if I first click in the graph (it gets a yellow outline, so it is selected) it does not work. I think that I read somewhere that Ctrl+A should work also with a Graph subwindow. Can anybody help? Autoscaling still works by right-clicking in the graph and selecting the appropriate menu item in the popup menu, but Ctrl+A is obviously faster and more convenient to use ...

Thank You in advance for any help/hints regarding this issue.

Cheers,
Gregor K
If you can find where you read it, I would like to know about it :)

Ctrl-A does two different things in Igor- it does "Select All" and "Autorange". On a Macintosh (where Igor started) you can attach the Cmd-A shortcut to both menu items, and whichever item is enabled gets called when you do Ctrl-A. On Windows, you can't attach a shortcut to two different menu items. We have some surprisingly complicated code that re-writes Igor's accelerator tables depending on whether a Graph is the top window or not. If you have a graph embedded in a panel, when that window is the frontmost window the Panel menu is shown, not the Graph menu. Consequently, the Ctrl-A accelerator is not available. Unfortunate, but true.

John Weeks
WaveMetrics, Inc.
support@wavemetrics.com
Thank you for your explanation. I already thought that this might be the catch (the Graph menu not showing when a graph embedded in a panel is selected). OK, at least now I know that I cannot use this shortcut for embedded graphs.

Cheers,
Gregor
johnweeks wrote:
Consequently, the Ctrl-A accelerator is not available. Unfortunate, but true.

Well here (on windows) this CTRL+A (as in SetAxis/A) works somehow.
I have a graph1 which has a exterior subwindow which embeds a graph2 and graph3.
And if I expand the axes in graph2/graph3 using the context menu I can happily use CTRL+A to get the complete graph shown again.
Actually, if I remember correctly, I choose exterior subwindows over panels because of the CTRL+A-working-feature.

bye,
thomas
thomas_braun wrote:
Well here (on windows) this CTRL+A (as in SetAxis/A) works somehow.

On Windows we did not implement the type-in-a-graph-switches-to-the-command-line feature. But on Windows you will run into the complicated procedure necessary to make Ctrl-A do the right thing depending on what is the top window. The OP was trying to use a Macintosh OS feature to reassign Cmd-A (Ctrl-A on Windows) to a different menu command. On Windows I think you would run into the code that re-assigns Ctrl-A; it would probably un-do your assignment if the top window were not a graph at some point (as is very likely).
Quote:
I have a graph1 which has a exterior subwindow which embeds a graph2 and graph3.

Exterior subwindows are a bit different in that they are actual windows (an embedded graph behaves a bit like a window inside a window, but it is just something Igor draws, it's not a real window). Still, we track the type of the main window. If the main window is a graph, you will see a Graph menu.

John Weeks
WaveMetrics, Inc.
support@wavemetrics.com