Callback function on window focus?

4 visualizzazioni (ultimi 30 giorni)
Giuseppe Antonio
Giuseppe Antonio il 19 Nov 2019
Commentato: Ajay Kumar il 19 Nov 2019
I created a figure with
f = figure
Is it possible to make something happen (callback) when the window containing my figure is selected ("on Focus")?

Risposte (1)

Ajay Kumar
Ajay Kumar il 19 Nov 2019
f = figure;
drawnow
figure(f);
  2 Commenti
Giuseppe Antonio
Giuseppe Antonio il 19 Nov 2019
I'm not asking how to give focus to the window but how to recognize that the user selected the window (i.e. detect window focus) and set a callback.
Ajay Kumar
Ajay Kumar il 19 Nov 2019
what do you want to write in the callback? if the figure is selected?

Accedi per commentare.

Categorie

Scopri di più su Interactive Control and Callbacks in Help Center e File Exchange

Prodotti


Release

R2016a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by