GUI-construction involves everything that is used to programmatically construct a custom graphical user interface under Mathematica.

learn more… | top users | synonyms

77
votes
2answers
6k views

How to manipulate 2D plots?

When it comes to visual analysis, large datasets or data with intricate internal details often makes plotting in 2D useless, as the outcome is either just a fraction of the full dataset, or no details ...
27
votes
4answers
1k views

Question about collections of custom GUI controls for Mathematica

Background: I have only recently begun programming GUIs in Mathematica, so I have a continuous need for custom controls. I needed a scrollable list control and with the help of Google I found a ...
23
votes
3answers
1k views

Generating graphs interactively (GUI)

I want to create graphs interactively using a GUI. I thought of using a ClickPane[] environment. The code I have (in part borrowed from the Documentation) works ...
19
votes
1answer
552 views

How can I effectively performance-profile Dynamics?

How to optimize performance-wise a complex dynamic expression (like a GUI) with lots of dynamically updated components, which require different update-frequencies? I was hesitant to ask this question ...
13
votes
2answers
691 views

How to set focus of a dialog window?

I have a dialog, which, when pops up, requests input from the user. How can I set the window up that the focus is on the InputField of the new window (i.e. the ...
13
votes
1answer
266 views

How to make an unremovable modal window?

Is there any way to securely stick a notebook window (e.g. a dialog) on screen that it cannot be closed/removed/hidden by any of the standard OS shortcuts, like AltF4 or AltTab under Windows? The ...
12
votes
3answers
294 views

In InputField, how to prevent Shift-Return from generating a new cell?

When running the following in a notebook (not a deployed CDF file), it can sometimes be annoying that accidentally pressing Shift-Return breaks out of the user ...
12
votes
1answer
277 views

How to create a notebook element that can replace itself?

I would like to create a notebook element that can replace itself. Here's an example to illustrate: ...
11
votes
2answers
291 views
11
votes
1answer
207 views

How to suppress Tooltip in built-in templates?

...or maybe switch the message. But I will be happy with no Tooltip at all. I've naively tried with ...
10
votes
2answers
226 views

Can one affect the appearance of components of a control?

I'd like to control the appearance of the components of a TabView[] control. Such a control appears constructed of Buttons, ...
9
votes
2answers
1k views

Basic questions about GUI

I have created the following simple GUI: ...
9
votes
1answer
144 views

How to customize the MathematicaClosingDialog.nb?

With Mathematica 10 came the closing dialog notebook, which probably most of you deactivated. (You can bring it back by dechecking "Always exit after closing last window" in ...
9
votes
1answer
257 views

Possible bug with second argument of Dynamic

According to the documentation, Dynamic Details & Options section, especially: For interactive mouse operations Dynamic[expr,{f_start, f, f_end}] typically ...
8
votes
2answers
157 views

Make the selection become the button you click

Let's assume I want a button that, when you click it, get the cell that contains it selected. This approach won't work, it selects the cell containg the selection previous to the click. ...
8
votes
1answer
94 views

How can I defer the loading of a PopupView control until it is used?

Background: I have several PopupViews of which the loadtime adds to the startup time of a program. To improve the perceived performance I want to defer the loading ...
8
votes
2answers
321 views

Strange behavior of CreateDialog's WindowSize option

Compare the two dialog windows, created by the same code except in the first WindowSize has a value while I omit it in the second one. Note, that ...
7
votes
4answers
197 views

Make which controls are visible in a Manipulate depend on a control value

I want to make a simple demonstration using Manipulate in which I have one or two input fields show depending on whether or not another control is True or False. How can I achieve such functionality? ...
7
votes
2answers
310 views

How to efficiently get the value from form UI built with dynamic InputField

Here is the code that I used to make a tabular UI. ...
7
votes
2answers
240 views

Moving controls from Manipulate to a Palette ( or similar GUI object )

Consider the following snippet as a reference. ...
7
votes
2answers
425 views

Detecting double click events

Is there a way to detect double click events? I did not find anything on the doc page of EventHandler. Use case: I want to re-implement the ...
7
votes
1answer
194 views

Why do images in a PopupMenu sometimes make a program load sluggishly?

In a demonstration, I would like to display a PopupMenu with a list of small PDF images, each weighing in at approximately 50k. The code of interest is below: ...
7
votes
1answer
164 views

Momentary Checkbox

I'm trying to create a demonstration in Mathematica where a checkbox will show an answer, but I only want the answer to be shown while the mouse button is pressed. There seems to be a ...
7
votes
1answer
234 views

LocatorPane, selecting multiple Locators

Consider the following snippet ...
7
votes
2answers
130 views

Appearance in Checkbox does not work

I'm experiencing strange behavior in Checkbox with Appearance: ...
7
votes
1answer
394 views

How to create a multi-selectable setterbar with colored buttons

Background: consider the following code-snippet. ...
7
votes
1answer
139 views

When are EvaluationNotebook[] and ButtonNotebook[] different?

I am looking for a concrete code example where EvaluationNotebook[] and ButtonNotebook[] will return different results. The ...
6
votes
1answer
226 views

Problems with visual update in GUI

Consider the following. When clicking in "Browse" and then choosing a file, the path will remain the original one and won't change to the one of the file I chose: ...
6
votes
1answer
944 views

How to make a dynamic stopwatch?

For some experiments I need some basic timer function. I tried various methods, and neither of them are fully satisfactory. What I need is a button, that starts/stops a timer, resets timer with each ...
6
votes
1answer
387 views

Dialog crashes Mathematica

I have some dialog windows in a GUI of which one regularly crashes the kernel. I managed to focus on this particular piece of code, though I don't really know what causes the crash: ...
6
votes
2answers
613 views

How can I set the background color to the Popupmenu?

I want to set the Background color of a PopupMenu to blue. I already searched in the documentation center, but I didn't find any ...
6
votes
1answer
390 views

Interactive Graph Editing with Animation

I want to make a simple interactive user interface like this: Such that when the user clicks on the "Add Edge" button, the edge specified by from and to fiels is added to the graph. The new graph ...
6
votes
0answers
131 views

How to create a floating image with no window background [duplicate]

Possible Duplicate: What is the most effective way to setup a Notebook with transparent background but solid contents? When MMA 8 starts, a floating image of spikey is shown. As you can see ...
5
votes
3answers
246 views

Self-referential list or table of buttons

How could one create a table or list of buttons, such that clicking on a button removes the button itself from the list?
5
votes
3answers
350 views

How to make a control array of buttons or togglers?

An array of buttons From time to time I wish I had a control array of the sort native to Visual Basic. A control array of buttons would be a table of buttons in which each button "knows" its ...
5
votes
2answers
696 views

How to create a simple interface to get file path and execute some code on it?

I need to create a simple user interface to choose one file in the notebook directory, import it and execute some functions on the imported data. For the first version I created this code: ...
5
votes
3answers
280 views

Switching among view points in a Manipulate expression

Edit: Some additional viewpoints were included to make it easier to test. Here's code for an alternative function, the graph of which is a bit less symmetric. Feel free to use either code set: ...
5
votes
2answers
430 views

Interactively select a row/column of a Grid

I need a simple way to display tabular data (preferably with Grid) and also be able to select a row or column of the table. I've tried different approaches, but I ...
5
votes
1answer
98 views

ListPicker with conditional selection

I am reading data from a SQL Database and want to manually sellect multiple rows. ListPicker works very nicely, the only added complication is that I need to not only select the records, but also ...
5
votes
1answer
170 views

Is it possible to embed a notebook as a panel in a java GUI?

I'd like to create a GUI that displays a tree, some text boxes, buttons, and then as a panel, a fully-functional notebook. Is that possible?
5
votes
2answers
426 views

How to save data to a variable by clicking a button, using Widget Panel

In Mathematica I am trying to implement algorithm, for which I would like to have user friendly interface, I have managed to create Panel using Widgets, but when I am trying to provide the value of ...
5
votes
1answer
179 views

Dynamic panel crashes Mathematica 10.0.0.0

This answer by @paw have revealed a bug that causes Mathematica v 10.0.0.0 to crash the GUI and kernel. So far the offending code is this: ...
5
votes
1answer
103 views

FlipView can't handle CurrentValue[“MouseOver”]. Kernel crash

Is this code crashing your Mathematica session? (it can so look out :P) ...
5
votes
0answers
102 views

Simple Choice-Dialog like the auto-completion popup

What I want is pretty simple, nevertheless, after half an hour I have only unsatisfying solutions here. Let me ask you who might work more often with Mathematica's GUI elements: Is there a way to ...
5
votes
0answers
86 views

Is there something like MaxProcessorUsed?

For standard procedures it is easy to test if the implementation is better or worse than other by using Timing etc. It does not help us with creating ...
5
votes
0answers
316 views

How can I change cursor style in InputField?

I want to make an InputField with a horizontal cursor, like this: Note that the blinking cursor should be horizontal and not the mouse pointer! Nevertheless, ...
4
votes
2answers
294 views

How can I change a Slider's appearance?

I am using Mathematica 9.0 and Windows 7. I want to create a Slider that looks like the following: I tried the following: ...
4
votes
2answers
179 views

How to execute a function each time the slider is dragged?

I've created a function f and a slider: Slider[Dynamic[y],{1,4}] How to execute/call f ...
4
votes
2answers
422 views

How can one popup menu be used to add another?

I'm trying to construct a GUI that changes depending on what's chosen in certain popup menu's. For example: The default state of the menu is condition one, but when the first PopupMenu is selected ...
4
votes
2answers
92 views

Write GUI to select spheres in a grid

I'd like to generate a code that: 1) starts with a grid of circles (in general, it won't be a square grid) 2) allows the user to choose some of those circles 3) allows the user to choose the type of ...