Questions tagged [user-interface]

User Interface (UI) is the system through which people interact with a computer. This tag can be used for UI-related programming questions. Note that there's a separate Stack Exchange site for User Interfaces, Interactions with the Computer and User Experience design: https://ux.stackexchange.com.

User Interface (UI) is the system through which people interact with a computer. This tag can be used for UI-related programming questions.

Note that there's a separate Stack Exchange site for User Interfaces, and Interaction- and User Experience design.

References

56892 questions
133
votes
2 answers

GUI not working after rewriting to MVC

I'm practicing MVC style programming. I have a Mastermind game in a single file, working fine (maybe apart of the fact that "Check" button is invisible at start). http://paste.pocoo.org/show/226726/ But when I've rewritten it to model, view,…
trevor_nise
  • 1,357
  • 2
  • 9
  • 3
131
votes
2 answers

How to best position Swing GUIs?

In another thread I stated that I liked to center my GUIs by doing something like this: JFrame frame = new JFrame("Foo"); frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); frame.getContentPane().add(new…
Hovercraft Full Of Eels
  • 283,665
  • 25
  • 256
  • 373
131
votes
1 answer

What GUI libraries are the JetBrains using?

Background I am somewhat new to Java and am enjoying using IntelliJ IDE developed by the JetBrains team. I have downloaded the source for the Community Edition, and I am trying to work out what GUI libraries they are using to get the…
Levi Putna
  • 2,863
  • 6
  • 30
  • 47
130
votes
14 answers

How can I add a hint text to WPF textbox?

For example, Facebook has a "Search" hint text in the Search text box when the textbox is empty. How to achieve this with WPF text boxes??
Louis Rhys
  • 34,517
  • 56
  • 153
  • 221
128
votes
13 answers

Vertical align with Tailwind CSS across full screen div

How can I vertically align a div with Tailwind? What I want: ----------------------------------- | | | | | | | item1 | | …
ajthinking
  • 3,386
  • 8
  • 45
  • 75
123
votes
2 answers

Difference between validate(), revalidate() and invalidate() in Swing GUI

Swing components have multiple methods related to updates of screen layout, in particular: validate() invalidate() revalidate() The Java documentation defines these somewhat from a technical perspective, but it's not particularly clear how they…
mikera
  • 105,238
  • 25
  • 256
  • 415
123
votes
6 answers

Newline in JLabel

How can I display a newline in JLabel? For example, if I wanted: Hello World! blahblahblah This is what I have right now: JLabel l = new JLabel("Hello World!\nblahblahblah", SwingConstants.CENTER); This is what is displayed: Hello…
mportiz08
  • 10,206
  • 12
  • 40
  • 42
121
votes
19 answers

How to crop circular area from bitmap in Android

I have a bitmap and I want to crop a circular region from this bitmap. All pixels outside the circle should be transparent. How can I do this?
Altaf
  • 5,150
  • 10
  • 39
  • 55
119
votes
5 answers

Padding doesn't affect in an XML Layout

I am trying to set padding in a declared within an XML file/layout. But whatever I set, nothing changes related to padding. If I modify any other properties, I see the effects on the UI. But it doesn't work with padding. Could you please…
Lyubomyr Dutko
  • 4,486
  • 7
  • 32
  • 39
117
votes
8 answers

What is the need of JSF, when UI can be achieved with JavaScript libraries such as jQuery and AngularJS

I was reading about JSF that it's a UI framework and provides some UI components. But how is it better or different from number of components that are available from jQueryUI, AngularJS, React, Vue.js, Svelte, ExtJS, or even plain HTML, CSS and…
sushil bharwani
  • 29,685
  • 30
  • 94
  • 128
116
votes
12 answers

Hand Coded GUI Versus Qt Designer GUI

I'm spending these holidays learning to write Qt applications. I was reading about Qt Designer just a few hours ago, which made me wonder : what do people writing real world applications in Qt use to design their GUIs? In fact, how do people design…
Ankur Sethi
  • 3,508
  • 5
  • 23
  • 17
115
votes
9 answers

What's dp (density independent pixels) units with CSS?

For Android, people recommend using dp (density independent pixels) measurements for UI elements, and there are conventions that exist such as using 48dp for a button height, etc. I'm working on a web application, and I'm getting a lot of criticism…
Brad
  • 10,015
  • 17
  • 54
  • 77
113
votes
24 answers

What's the best UI for entering date of birth?

What is the best method for date of birth selector? 3 text inputs (month / day / year) or one mask input. User MUST use keyboard 3 select boxes. User can use keyboard or mouse. One nice datepicker. I want to know what is the most usable and…
Ionuț Staicu
  • 21,360
  • 11
  • 51
  • 58
113
votes
12 answers

Is there a visual profiler for Python?

I use cProfile now but I find it tedious to write pstats code just to query the statistics data. I'm looking for a visual tool that shows me what my Python code is doing in terms of CPU time and memory allocation. Some examples from the Java world…
Frederik
  • 14,156
  • 10
  • 45
  • 53
112
votes
5 answers

How to make PHPStorm collapsing all methods/functions on file open?

How to make something like this? (all methods collapsed by default without any hotkeys)
Dmitry K.
  • 3,065
  • 2
  • 21
  • 32