The part of the application that users directly interact with. Use this tag for reviews of code that defines how an application's user interface works and looks.

learn more… | top users | synonyms

4
votes
3answers
172 views

Swing GUI in Java

I'm learning Java at the moment and I'm currently trying to make a GUI using Swing. I've done some reading and people usually prefer and advice to use composition instead of inheritance of e.g. ...
3
votes
0answers
41 views

Kivy language code of my Vehicle Details app

So I've written my first android app in kivy. This app takes a Vehicle License Number as input from the user and submits it to a sites and shows the results from the site. The complete Source Code ...
1
vote
1answer
74 views

Web Page Inspector

I wrote a small JavaFX Application to inspect Javascript within HTML pages. It loads and browses sites, shows the HTML source, shows an overview of the text of a page, provides a simple Javascript ...
6
votes
1answer
74 views

UserForm to handle Date Inputs (Day,Month,Year)

Some fraction of a follow-up to The half-finished version. What's changed: Added year as well as Day/Month. Added input Validation. Implemented a poor man's ...
6
votes
1answer
117 views

Populating Day/Month Selections in UserForm Controls

So I have a simple userform where I require the User to input the target month, and the day to analyse data up to. This is just a small section of code to govern populating the month selection and ...
3
votes
2answers
25 views

OOP, FP and IMP condensed in Rock, Paper and Scissors

Rock Paper and Scissors is a pretty basic program. The reason I wrote this program is because I wanted to see what a small script that used all of the main programming paradigms looked like. My code ...
0
votes
0answers
151 views

Showing/Hiding multiple HTML elements with AngularJS

I'm new to AngularJS and I'd like a review on my approach to handle prizes being reclaim. The process is as following: User enters prize list page; Click on a Reclaim Button; Provide me with ...
4
votes
1answer
103 views

Giveth me thy easier user input in C++ - follow up

I've decided to take some of the many suggestions for improvement on my previous question, Easier user input in C++, and actually get it to work as expected. This time around, a few things are ...
30
votes
5answers
2k views

Easier user input in C++

A more proper version of this utility can be found at the following link here: Giveth me thy easier user input in C++ - follow up. I've always been a little bothered by the fact, that in order to ...
2
votes
1answer
48 views

Should a style sheet object know about its target?

Here are three classes in my project. They work as expected. What I'm not sure of is the passing of the target into style sheet. What is going on is that I want the matrix as a whole to be ...
2
votes
1answer
576 views

Monoalphabetic Cipher in Java With GUI

An easy, terribly written but working, Caeasar (Monoalphabetic) cipher implementation, with a GUI (Graphical User Interface). Cipher.java ...
1
vote
1answer
21 views

Java Loops and UIs

I've always found coding UIs in Java very inefficient, and hopefully this is because of my misunderstanding. Here's a great example. I have a UI class which is returning the String "Hours", which is ...
3
votes
1answer
337 views

Set a font for a UITextView if the font is nil or not equal to desired font

Main question I am setting a font for a UITextView that is a subview in a custom view. I only set it if the user didn't specify the font size in the Interface Builder. I have the following working ...
4
votes
2answers
1k views

Removing a subview with a subview from a UIView without memory leaks

I made a custom UITextView for vertical Mongolian writing. It is made by subclassing UIView, which has a subview called ...
6
votes
2answers
135 views

CommandBars, Buttons and Commands: Take 2

Following-up on CommandBars, Buttons and Commands: Cleanup is on the menu, I decided to try a more ambitious approach, as suggested in Nikita's answer. It works, but there are a number of "gotchas" ...
14
votes
2answers
138 views

CommandBars, Buttons and Commands: Cleanup is on the menu

One of the biggest pain point in the entire rubberduck code base, is the way commandbar menus and menu items are created and wired up - something needs to be done to straighten that up, and while I ...
3
votes
0answers
37 views

Multiple select widget in CoffeeScript

I created a widget to handle multiple selections in CoffeeScript. There's a working attached snippet that uses the compiled JavaScript (Stack Snippets don't support CoffeeScript), which is available ...
3
votes
1answer
31 views

user_interface module

As writing code to handle error-checked input or to present functions to execute to the user is boring and error-prone, I wrote a module to automate these tasks: ...
6
votes
2answers
243 views

Heavily nested anonymous classes for Swing UIs

Oftentimes, I write small little dialogs or forms without a UI builder. I usually find myself having a lot of "container" panel variables that just float around. I found this leads to time-wasting ...
0
votes
0answers
80 views

Inline editing for modifying field that requires supplementary inputs (such as password)

I've been using x-editable, but recently needed to perform in-line editing, but required the user to enter one or more additional fields. For instance, to change ...
6
votes
1answer
174 views

Button presses counter

I'm moving on to graphics, picking Pyglet and Cocos2D. This is my first program in Python with GUI. Introducing: Two distinct high definition button sprites Satisfying high quality button pressing ...
4
votes
0answers
586 views

Reducing complexity in NSView event handling code in Swift

My Cocoa event code always tends to descend into madness, I need to advice on how to reduce complexity. I've spend a few hours putting this example together. CanvasView is a layer hosting subclass of ...
4
votes
2answers
220 views

TextField Validation for Teleport Feature in Game

I've implemented a teleport feature for my game and I would like some feedback on the way that I validate the user input. I am using the libGDX library. When the player clicks the Teleport Menu ...
1
vote
1answer
100 views

Constructing a UI to ask a list of questions

This code fragment from 2009: ...
7
votes
1answer
142 views

Implementation of Hangman in Java

Here's an implementation of Hangman that I've written that uses a basic GUI. As I am new to Java, please let me know of any improvements I can make to my coding style. Thanks for your help. ...
5
votes
1answer
403 views

Class-based user input validation

Having contributed to this Community Wiki on StackOverflow regarding validating user input, I thought I'd finally sit down and write something more robust to do these kinds of tasks. I wanted ...
2
votes
0answers
241 views

Graphical Flowchart Programming

This is an incomplete implementation of something similar to scratch. It's incomplete because right now, I'm working purely on the user interface. I used Swing to make the basics of it, but then ...
3
votes
1answer
247 views

HMSegmentedControl react to tapping on currently selected segment

I'm using HMSegmentedControl, an open-source UISegmentedControl subclass. I'm trying to react to the user tapping on the currently selected segment. HMSegmentedControl only supports reacting to a ...
4
votes
1answer
194 views

C++ line-editing micro-library

Working on a project, I've taken to adapting the linenoise line editing library for my own use, among other things, rewriting it using C++. The idea is to separate my changes and updates into a new ...
1
vote
1answer
819 views

Backbone/Marionette form with list of inputs

Using Backbone/Marionette, I'm building a simple widget that looks like: I'm hoping to get some feedback on my approach because I think I may be doing it wrong. jsfiddle ...
2
votes
1answer
411 views

Super simple way of generating dynamic interfaces in Python both CLI and Web GUI

I want to know if this is a good idea. It is definitely only a proof of concept at this point, but if it's a good idea I would pursue the development into a more mature product. There are three ...
15
votes
1answer
3k views

IBDesignable UICheckbox

A more up-to-date version of this control can be found on GitHub. One UI control that has always been mysteriously missing from Xcode's interface builder is some sort of checkbox. ...
0
votes
1answer
3k views

Correct Implementation of Custom UIView into ViewController Programatically

I am familiar with using scoreboards to construct UI elements in Xcode, but I am only beginning to learn how to make UI programmatically (with out storyboard). I wanted to know if this is the correct ...
2
votes
1answer
34 views

Isolating testable portions in rendered html, without imposing on content or formatting

I'm unit testing some webpages and I'm trying to figure out how to best isolate the portions that need to be tested. There are two goals: Don't impose on the webpage's content or format, and be as ...
2
votes
1answer
8k views

Toggle-item inside a Bootstrap dropdown-menu

I have this working code for a toggle-item inside a Bootstrap dropdown-menu. See demo here. I suspect that it should be possible to improve it : in order to have a shorter code and avoid all the ...
4
votes
1answer
237 views

Checkbox multiselect user interface

I wrote a small multiple select interface in jQuery, and I'm looking for any feedback on code quality/usability. It has to do the following: When check all is checked, all boxes must become checked ...
1
vote
1answer
6k views

Populate dropdown B on selection in dropdown A

On selection from drop-down A (HTML select) I need to populate another "sub"-dropdown with a different list of values. For instance, on selection of country in ...
6
votes
3answers
1k views

Lemonade stand menu program

This is an assignment given in my C++ programming class. I have one main menu with four other menus branching out from it. I would like to make my code as clutter-free as I can, so please review ...
3
votes
2answers
3k views

Making sure user inputs correct type

I have two functions that are used to prompt and recieve input from the user. One is for int and the other is for boolean. They ...
11
votes
3answers
634 views

Efficiency of this constantly running time processor for an HTML5 video control bar

I built a custom HTML5 video control bar, and for each second, it updates two readings: Time Elapsed Time Remaining in hh:mm:ss notation, like so: Because of how often this function runs, I ...
6
votes
2answers
488 views

Testing quicksort user input

I am testing a quicksort implementation. Arrays of random size with random data are passed to quicksort and the return time is averaged out. The user is prompted to enter values for minimum length ...
6
votes
2answers
393 views

User Interface for Strategy Game

I've been working a strategy game for iOS for a little while, and each time I add functionality to the game model I'm finding myself building a lot of UI code to sync up with it. I believe that my ...
6
votes
1answer
499 views

Interactive slider

Task: Create an interactive slider that allows the user to view a given image gallery. Slider controls: See previous slide See next slide Quick navigation through the images / Paging - ...
5
votes
3answers
7k views

Custom iOS chat interface design & functionality

Preamble So, as most of you have likely also noticed, chat components, at least at a basic level, are becoming very common with lots of apps. I found myself tweaking and redesigning the interface ...
7
votes
1answer
131 views

DRY multiple if statements used to show/hide elements based on slider value

I'm showing and hiding 4 svg paths based on the value of a slider, all is working as expected, but it still feels a little cumbersome. Does anyone know a way to "DRY" it out a little more? jsFiddle ...
3
votes
2answers
2k views

Custom UI - Seeing which control has focus

I'm trying to make a simple UI to better understand how interfaces and the System.Windows.Forms Controls behave. Like the above namespace, I will be able to get ...
5
votes
2answers
4k views

Splitting the GUI into smaller classes

I am currently working on a course project and have been assigned to write a GUI. I've written it and it's about 2000 lines of code. It will be bigger when I add the SQL codes and new panels. So, ...
1
vote
1answer
120 views

Extracting Javascript functions

I have this jQuery click handler function that has three jobs: Set the time interval for the refresh rate Change the color on the clicked refresh rate selection Callback the tablesort functions to ...
4
votes
1answer
290 views

GUI layout for a security camera app

I'm designing a security camera program. Right now, I am just trying to set up the GUI before receiving. I am using Kivy since, in the future, I plan on designing some programs for Android. I really ...
3
votes
0answers
2k views

File input control with rounded buttons and styled textbox

We have orange rounded buttons as a standard on our site. For our purposes, we switched everything over to use an anchor tag, instead of input type=button. The exception to this was the File Upload ...