Rank: 567 based on 226 downloads (last 30 days) and 1 file submitted
photo

David Sampson

E-mail
Company/University
MathWorks
Lat/Long
52.22889, 0.151883

Personal Profile:

Principal Consultant at MathWorks in Cambridge, UK. Ph.D. from Cambridge in vehicle dynamics and control.


 

Watch this Author's files

 

Files Posted by David Sampson
Updated   File Tags Downloads
(last 30 days)
Comments Rating
06 Oct 2014 Screenshot GUI Layout Toolbox Layout management objects for MATLAB GUIs, for the new graphics system introduced in R2014b Author: David Sampson gui, layout, layout manager, toolbox, r2014b graphics ready 226 35
  • 5.0
5.0 | 12 ratings
Comments and Ratings by David Sampson View all
Updated File Comments Rating
15 Dec 2014 GUI Layout Toolbox Layout management objects for MATLAB GUIs, for the new graphics system introduced in R2014b Author: David Sampson

Carsten, there are issues with handling illustrations (legend, colorbar) and rotate3d with the new graphics system. The challenge is identifying graphics objects that should be ignored for layout purposes. We are making progress but there are some small changes that are also required in MATLAB itself. Until then, the workaround is to place axes with illustrations and 3D-rotating axes in a uicontainer (or uipanel with decorations turned off), as described in the GUI Layout Toolbox documentation.

08 Dec 2014 GUI Layout Toolbox Layout management objects for MATLAB GUIs, for the new graphics system introduced in R2014b Author: David Sampson

Jamie, you shouldn't be setting the Position of GLT container contents directly. Any changes that you make will be clobbered by the toolbox code. If you feel that there are differences in layout behavior between v1 and v2 then please contact us directly and we will investigate.

08 Dec 2014 GUI Layout Toolbox Layout management objects for MATLAB GUIs, for the new graphics system introduced in R2014b Author: David Sampson

Thanks to Gary and Jamie for spotting some minor bugs. The fixes have been implemented and will be included in the next release.

29 Oct 2014 GUI Layout Toolbox Layout management objects for MATLAB GUIs, for the new graphics system introduced in R2014b Author: David Sampson

Jonathan, good catch, I will implement support for negative (relative) TabWidth as soon as possible.

23 Oct 2014 GUI Layout Toolbox Layout management objects for MATLAB GUIs, for the new graphics system introduced in R2014b Author: David Sampson

Tom, we have removed the enable/disable functionality at this stage due to challenges with the implementation, although we are open to working on it some more. Property 'Enable' is included in the uiextras package to support legacy code, although it no longer has any effect. The demo 'enableexample' should have been removed and will be from the next release.

I encourage anyone with enable/disable use cases to get in touch. Specifically, I am interested in cases where more than set( findall( c, 'Type', 'uicontrol' ), 'Enable', v ) is needed.

Comments and Ratings on David Sampson's Files View all
Updated File Comment by Comments Rating
22 Dec 2014 GUI Layout Toolbox Layout management objects for MATLAB GUIs, for the new graphics system introduced in R2014b Author: David Sampson Romain

First, thank you for this excellent toolbox

I just want to submit a bug using +uix.VButtonBox and +uix.HButtonBox:
It is documented that there is an "Enable" property, but setting this property I have the following issue : "There is no Enable property on the VButtonBox class".
Any idea about this issue ?
Thanks in advanced !

22 Dec 2014 GUI Layout Toolbox Layout management objects for MATLAB GUIs, for the new graphics system introduced in R2014b Author: David Sampson Stephane

There are a few issues for backward compatibility when still using +uiextras. For instance 'set' commands for 'ColumnSizes/RowSizes' are no longer recognized and one must use 'Widths/Heights' from +uix. Same for 'BorderType', one must use 'none' as 'None' is no longer working. Else from that this is an excellent toolbox.

21 Dec 2014 GUI Layout Toolbox Layout management objects for MATLAB GUIs, for the new graphics system introduced in R2014b Author: David Sampson Amro

This is seriously one of the best submissions on File Exchange!

I've been browsing the code, and I can see that it's finally possible in R2014b to subclass MATLAB uicontrols (uix.Container in v2 inherits from matlab.ui.container.internal.UIContainer, instead of being a wrapper as in v1)!

However whenever I try this with my own classes, I get an error that "Class 'MyControl' is not an allowed subclass of class 'matlab.ui.container.internal.UIContainer'."... Are your classes hardcoded in MATLAB as allowed subclasses, but no one else??

21 Dec 2014 GUI Layout Toolbox Layout management objects for MATLAB GUIs, for the new graphics system introduced in R2014b Author: David Sampson zxc

17 Dec 2014 GUI Layout Toolbox Layout management objects for MATLAB GUIs, for the new graphics system introduced in R2014b Author: David Sampson Jamie

Thank you for the feedback, I think this may help folks in understanding the distinction between uipanel and uiextras.Panel, in particular not setting the position of GLT containers. In cases where manual positioning is desired, use a regular uipanel. Below is an example, related to the difficulty I was having and demonstrating the position clobbering that David is referring to:

w = figure(75);
g1 = uiextras.GridFlex('Parent', w);

c11 = uiextras.Panel('Parent', g1, 'BackgroundColor', [0.95, 0.95, 0.95]);
c12 = uiextras.Panel('Parent', g1, 'BackgroundColor', [0.95, 0.95, 0.95]);
c21 = uiextras.Panel('Parent', g1, 'BackgroundColor', [0.95, 0.95, 0.95]);
c22 = uipanel('Parent', g1, 'BackgroundColor', [0.95, 0.95, 0.95]);

set(g1,'RowSizes',[-1 -1],'ColumnSizes',[-1 -1]);

x = 0:pi/100:2*pi;
y = sin(x);

a1 = axes('Parent', c11, 'Units', 'Normalized', 'Position', [.25, .25, .5, .5]);
plot(x, y);

a2 = axes('Parent', c22, 'Units', 'Normalized', 'Position', [.25, .25, .5, .5]);
plot(x, y);

Contact us