In the app there are some buttons that do nothing useful for a current state of the project or inevitable lead to an error after clicking them. Disabling and hiding them will improve the app usability and declutter the interface a little bit. Below is the list of such buttons I found:
Mesh Visualization tool
[ ] Visualize volume
Problem: This button is always active, even though the project might not have a FEM mesh, thus no volume to display. Clicking this button in such case will lead to an error:
Error
Index in position 2 exceeds array bounds.
Error in zef_plot_volume (line 319)
tetra_c = (1/4)*(nodes(tetra(:,1),:) + nodes(tetra(:,2),:) + nodes(tetra(:,3),:) + nodes(tetra(:,4),:));
Error in zef_visualize_volume (line 4)
zef_plot_volume;
Error using matlab.ui.control.internal.controller.ComponentController/executeUserCallback (line 427)
Error while evaluating Button PrivateButtonPushedFcn.
Solution: Disable this button whenever the FEM mesh does not exist. Also, It would be awesome to add an explanation for disabled button in a tooltip.
Solution example
zef.h_pushbutton31.Enable = 'off'
zef.h_pushbutton31.TooltipString = 'You should create FEM Mesh first'
[ ] Frame / Movie
Problem: presumably, this button only makes sense in case if the model has more than one frame.
Solution: Disable this button when there is no more than 1 frame in current model
[ ] Cutting plane mode
Problems:
It looks like it relates to clipping planes, but it uses another term "cutting plane" which is a little bit confusing
It stays active even though the clipping planes are deactivated
Solution: Disable when all clipping planes are deactivated. Rename to "clipping plane mode"
[ ] Plot graph button
Problem: This button seems to work only after the FEM mesh is generated. Otherwise it causes the following error
Error
Error using matlab.ui.control.UIAxes/set
Value must be a 1x2 vector of numeric type in which the second element is greater than the first element or is Inf.
Error in zef_histogram (line 15)
set(gca,'ylim',[min(hist_y) max(hist_y)]);
Error in zef_plot_graph (line 9)
eval([g_list{2}{g_ind} '(' v_name ');']);
Error using matlab.ui.control.internal.controller.ComponentController/executeUserCallback (line 427)
Error while evaluating Button PrivateButtonPushedFcn.
Solution: Disable this button whenever the FEM mesh does not exist. Also, It would be awesome to add an explanation for disabled button in a tooltip.
Figure tool
[ ] Reset/Play/Stop/Pause buttons and "Loop on count" checkbox
Problem: these controls do nothing for a single frame project
[ ] Many sliders are not having any effect in certain context. They might be hidden or disabled
Time is only used when there is more than 1 frame
Transp. rec, Transp. surf, Transp. sens, Transp. cones, Transp. add are always shown and active even though the Figure Tool might not even show surfaces, cones or sensors at a given moment. This often leads to confusion when the wrong slider is used mistakenly.
Mesh tool
[ ] Meshing accuracy control
In practice this value should always be 1. Changing this parameter leads to degrading accuracy.
Solution: Remove this input field
[ ] Downsample surfaces
Solution: Rename this checkbox to Resample surfaces
Description
In the app there are some buttons that do nothing useful for a current state of the project or inevitable lead to an error after clicking them. Disabling and hiding them will improve the app usability and declutter the interface a little bit. Below is the list of such buttons I found:
Mesh Visualization tool
[ ] Visualize volume
Problem: This button is always active, even though the project might not have a FEM mesh, thus no volume to display. Clicking this button in such case will lead to an error:
Error
Index in position 2 exceeds array bounds. Error in zef_plot_volume (line 319) tetra_c = (1/4)*(nodes(tetra(:,1),:) + nodes(tetra(:,2),:) + nodes(tetra(:,3),:) + nodes(tetra(:,4),:)); Error in zef_visualize_volume (line 4) zef_plot_volume; Error using matlab.ui.control.internal.controller.ComponentController/executeUserCallback (line 427) Error while evaluating Button PrivateButtonPushedFcn.Solution: Disable this button whenever the FEM mesh does not exist. Also, It would be awesome to add an explanation for disabled button in a tooltip.
Solution example
zef.h_pushbutton31.Enable = 'off' zef.h_pushbutton31.TooltipString = 'You should create FEM Mesh first'[ ] Frame / Movie
Problem: presumably, this button only makes sense in case if the model has more than one frame. Solution: Disable this button when there is no more than 1 frame in current model
[ ] Cutting plane mode
Problems:
Solution: Disable when all clipping planes are deactivated. Rename to "clipping plane mode"
[ ] Plot graph button
Problem: This button seems to work only after the FEM mesh is generated. Otherwise it causes the following error
Error
Error using matlab.ui.control.UIAxes/set Value must be a 1x2 vector of numeric type in which the second element is greater than the first element or is Inf. Error in zef_histogram (line 15) set(gca,'ylim',[min(hist_y) max(hist_y)]); Error in zef_plot_graph (line 9) eval([g_list{2}{g_ind} '(' v_name ');']); Error using matlab.ui.control.internal.controller.ComponentController/executeUserCallback (line 427) Error while evaluating Button PrivateButtonPushedFcn.Solution: Disable this button whenever the FEM mesh does not exist. Also, It would be awesome to add an explanation for disabled button in a tooltip.
Figure tool
[ ] Reset/Play/Stop/Pause buttons and "Loop on count" checkbox Problem: these controls do nothing for a single frame project
[ ] Many sliders are not having any effect in certain context. They might be hidden or disabled
Mesh tool