Questions tagged [user-interface]

18131 questions
-1

votes
1

answer
21

Views

JavaFX update progress bar and wait for threads to complete

I'm trying to update a progress bar in Java FX. My first problem was that the window said 'not responding' instead of actually updating. It just froze and then after the tasks were done, the progress bar became full. So I found out that I had to use multithreading and implemented it like this. overa...
Karan Bijani
0

votes
0

answer
5

Views

Better Kivy Click Drag and Draw line

This is a a small component of a bigger app that draws a line when clicked, dragged and released : from kivy.app import App from kivy.uix.boxlayout import BoxLayout from kivy.core.window import Window from kivy.graphics import Color, Line, Rectangle Window.set_system_cursor('crosshair') DRAG_START =...
Keno
1

votes
2

answer
201

Views

Setting background color of a tkinter ttk frame

I want to simply set a background color to the frame within the tkinter window. The background color for the window was successful set, but the not for the frame inside. Simply entering bg='color_name or color_code' is not working. How can one set the background color of a ttk frame? In addition t...
Pratyush Karna
0

votes
2

answer
12

Views

Do not understand behavior of wpf updating dynamically created image control visibility changing every seconds

I have a Grid with 8 rows and 8 columns in wpf: the code behind is: public partial class MainWindow : Window { private const int MaxRow = 8; private const int MaxCol = 8; public MainWindow() { InitializeComponent(); DataContext = this; } private void Start() { for (int i = 0; i < MaxRow ; i++) { for...
Edgar
0

votes
0

answer
9

Views

App/Homepage displaying as blank window while using class structures with tkinter in Python 3.7

I'm brand new to python/programming (2-3 weeks experience) and I'm trying to make a GUI app with tkinter for a Battleship game that I wrote originally as a cmd line game for my first project. I would like this GUI to have a few different screens/frames that walk the user through setting up and playi...
BurtMacklinFBI
1

votes
1

answer
252

Views

Resources for learning tk/tile

Besides Ruby-Doc, what sources are best to take some examples and tutorials from, especially about Tk/Tile in Ruby? I found myself more normal with http://www.tutorialspoint.com/ruby/ruby_tk_guide.htm http://www.perfectxml.com/syngress/ruby/Page1.asp but the information is pretty vague, and there is...
Denees
0

votes
0

answer
6

Views

Update Gtk+2 text view widget from another thread

I am writing a chat client in GTK. The client has the main GTK loop, plus a spawned thread that sits and blocks at the read() function waiting for input from a file descriptor connected to a socket. Once the read function gets past the blocking, it has a char buffer of text that I would like to appe...
Matthew
1

votes
1

answer
5.4k

Views

How can wrap input value text [duplicate]

This question already has an answer here: How to wrap text of html button with fixed width 8 answers I have this piece of code but I am unable to wrap word.
Shube
1

votes
1

answer
895

Views

Using markup with Gtk.TextView

I have been trying to find a way to use Pango markup with Gtk.TextView and Gtk.TextBuffer in Python GObject, but it seems like this functionality is only available for tooltips and labels. Gtk.TextBuffer has the insert_markup method, but requires Gtk.TextIter as input, and must be of specified lengt...
Holsterbau
1

votes
2

answer
1.9k

Views

Android, add view with height in percentage

i wanna add a view with a 100% width and X%(e.g: lets make it 40%) to the parent view i have this: private RelativeLayout getParentView(){ return (RelativeLayout) MyActivity.this.getWindow().getDecorView().getRootView(); } i should cast parent view to LinearLayout or RelativeLayout can achieve this...
Mars
1

votes
2

answer
1.6k

Views

Centering images horizontally in a shiny fluidRow

Is it possible to centre three images in one row within the shiny ui fluidPage AND have the width of each image fixed at 300px? To get: One idea I had was to use splitLayout and somehow insert an image as a function of window width but I am not sure how to acheive this. I understand you can use spli...
KGee
1

votes
1

answer
356

Views

Distribute remaining space in GridPane or how to do it

We need a solution for a 3 column layout with the following requirements: The middle column has a fixed size The middle column is centered in the parent The other two columns both share the remaining space The other two columns both have the same size Let's say we have an amount of horizontal space...
Guardian667
2

votes
1

answer
25

Views

Payment calculator does not reset properly

So after you hit the reset button or have an error message all the values turn blank but keep getting added onto when you continue to use the program but they are supposed to start over. public GroceryCalc() { initComponents(); purchase = 0; numitems = 0; } public void recordPurchase(double item_pri...
J. Sack
1

votes
1

answer
88

Views

Swift Threading: When to use DispatchQueue.main.async?

I believe I understand what the dispatch queue is doing when I call it, but I'm not sure when exactly I should use it and what it's advantages are when I do use it. If my understanding is correct, DispatchQueue.main.async { // code } will schedule the code contained within the closure to run on the...
YungGun
1

votes
1

answer
67

Views

How to create a JavaFX TableView without warnings?

I'm following a tutorial by Oracle to create a TableView in JavaFX. In this screenshot, I've copied and pasted the code and I get several errors, which aren't mentioned in the tutorial anywhere. The warning on the TableView says: TableView is a raw type. References to generic type TableView should...
JolonB
1

votes
5

answer
136

Views

How to set elevation color below the view in Android?

I am creating below design in Android Studio. But I stuck in how I can add color in elevation as seen in the picture below. A greenish color is shown below each button. I don't know how I can achieve this. I have even set the android:outlineSpotShadowColor and also this android:outlineAmbientShado...
1

votes
2

answer
2.2k

Views

Qt - How to open a website in a particular browser

I am coding one project, which needs to launch some webbrowsers with the given url. I saw some QT examples, but they explained how to launch the default browser, not a particular browser. Any helping suggestions will be appreciated. Edit1: Below is the code I use currently QString temp='C:/Program F...
prabhakaran
-1

votes
0

answer
18

Views

GUI java reading shapes from a text file and displaying in another window

I need have 2 modules one for painting shapes and the secon for displaying. The painting Program has to save information about generated shapes to a file.The displaying modules should read from a text file and display.Resizing a window is followed by rescaling all drawn elements Additional descri...
gukahhh
1

votes
3

answer
2.4k

Views

How does one use SWT without eclipse?

I want to use swt to make GUIs but I do not want to use eclipse to program. Is there anyway to do this. Also,are there any GUI designers for swt that are not eclipse plugins.
user1659754
1

votes
0

answer
42

Views

SwiftCharts- display one data point for Custom Units Scrollable graph

I would like to display one data point for Custom Units Scrollable graph (Custom Units Example). Is it possible to do it with this library? I have looked into issues and the library to check and I only see [ChartAxisValue] array to create ChartAxisModel (i.e. xModel an yModel), no function to only a...
mir
1

votes
1

answer
80

Views

Kivy: Making a persistent notification with buttons

I'd like to make an Android app, and I prefer to not have to step out of my comfort zone which is Python. I heard that the Kivy package can make Android apps, but I heard that it likely doesn't have the full Android UI functionality that you could access using Java. My desired app should have a pers...
Ram Rachum
1

votes
1

answer
344

Views

Python - Creating a Cancel Button for a Countdown Timer

This code is the start of a program simulating a smart toaster. I am trying to make a cancel button for my countdown timer. The timer works fine except for the fact that when the cancel button is pressed, the message 'Timer done' is displayed, but the timer continues. Is there a way I can do this? f...
cellodude1998
1

votes
0

answer
366

Views

Getting NullPointerException when button is clicked (JavaFX and FXML) [duplicate]

This question already has an answer here: What is a NullPointerException, and how do I fix it? 12 answers What's the difference between fx:id and id: in JavaFX? 4 answers After finally getting the gui to run without problems whenever i click on a designated button the IDE (Eclipse) putting out a l...
Arad Zekler
1

votes
0

answer
32

Views

Android Activity - Design on Server / Render on Client

We have a Windows Mobile application which is being migrated to Android. It has a large-ish number of forms (around 150). Given the complexity of the rewrite ahead of us, I am looking for as many shortcuts as I can find :) One of the options we are considering is as follows: Move all the .NET code...
Timothy Muir
1

votes
1

answer
138

Views

python Tkinter buttons are freezing while waiting

I wrote a gui class using Tkinter: def start_gui(): def do_some_task(): dosometask def do_some_task2(): dosometask2 ttk.Button(mainframe, text='task1', command=do_some_task).grid(column=1, row=3, sticky=W) ttk.Button(mainframe, text='task2', command=do_some_task2).grid(column=2, row=3, sticky=W) if...
kabe
1

votes
1

answer
283

Views

Delay rendering UI until store loads in ExtJs

The store I want to load takes significant time in authentication and fetching the data (huge), and I need to select one field from store as default as per the condition. Since the store takes a lot of time (8-10s) and UI is rendered already, so setting the value appears out of nowhere, which is an...
Virag Swami
1

votes
1

answer
29

Views

add Line_Edit while program is running

I am using Pyqt5 and Qt Designer to build GUIs. i want to know if there is any way to make a Gui that it can build a new line edit with a push button while running by clicking on another push button (add button for example) a picture of what i mean new line
Ahmad
1

votes
1

answer
36

Views

JTextArea Output

Good Evening, What can I do to have the output from jTExtArea like in the console? You can see the image how it is, I use .append to show the output in jTextArea Image Code: public void actionPerformed(ActionEvent e) { if (e.getSource() == b1) { for (int i = 0; i < a.pattern_cnt; i++) { for (int j =...
John Coffey
1

votes
1

answer
143

Views

Returning an output from a listbox, TKinter

I'm trying to create a clock that reacts to time zone inputs from the user, using TKinter. I'm having trouble with the selectTZ function in the code. It prints the selected timezone, but when I try to return it and use it in the clock function, it gives an error. Can you help me figure out what the...
Yuval Schlosser
1

votes
1

answer
169

Views

How to add a custom menu to an actionBar

I am working in an app with this kind of structure: The app has no initial ActionBar so I add it on the OnCreate on each Activity this way: android.support.v7.widget.Toolbar barra =(android.support.v7.widget.Toolbar) getLayoutInflater().inflate(local.quick_stuff.R.layout.barra_herramientas,null); Li...
Albert
1

votes
1

answer
36

Views

Labels not displaying - why? - Using wxPython-Phoenix

I'm trying to create a simple graphical interface with wxPython-Phoenix but the widgets are not displaying and I'm not sure why. I have choose to use wx.FlexGridSizer() as the sizer to handle the widgets positioning. Attached is my code: class App_Frame(wx.Frame): def __init__(self,title=''): #Conta...
Andy
1

votes
1

answer
64

Views

Why does my SDL app have an abnormal window border on Mac?

I've noticed my simple SDL application has an abnormal window border on Mac. There's no gradient and the color is dark gray instead of light gray. It just looks wrong. I've noticed that LÖVE also has this on mac, and it uses SDL as well, leading me to believe this is indeed SDL-related... Meanwhile...
Accumulator
1

votes
0

answer
63

Views

JSplitPane in JLayeredPane

I want the right content of an JSplitPane to fill the entire available space and the left content (panel) to be on top of the other panel. I was thinking about using a JLayeredPane to solve that problem but I couldn't get it to work. My class currently looks like this: public class LayeredPane exte...
Ubuntix
1

votes
0

answer
32

Views

Faster UI response for mouse position

I am making a UI to display the mouse's position on the user's screen. However I have a very large amount of lag. Anyone have an idea on how I can increasse the speed of my UI's response ? import sys from PySide import QtGui, QtCore import lsl_threads class mouse_position_viewer(QtGui.QWidget): def...
LearningAssembly
1

votes
1

answer
30

Views

Save data from multiple classes

I have looked around a lot and I have looked into many comparable questions and types of guis but unfortunately I am still not able to solve my problem. Currently I am working on an Tkinter gui with multiple pages. People have to insert certain properties and eventually i would like to print those p...
Carmen
1

votes
1

answer
30

Views

iOS, leftButtonItem 'are you sure?' approach to confirming exit from screen approach?

I'm trying to figure out the standard approach or the best approach. I don't want my users (children) to accidentally tap the back button and lose what they have entered into a view. 1) In a very old implementation, there's a leftBarButtonItem with an action which shows an alert asking are you sure....
Jules
1

votes
1

answer
53

Views

Fixed element when using TileView in Android Studio

I am building an activity within Android Studio which uses the TileView library by moagrius to build a layout that can be panned and zoomed, which is all working just fine. I am trying to add an element to the activity which stays fixed at the bottom of the screen and not be affected by the scrollin...
Timothy Bomer
1

votes
0

answer
57

Views

JavaFX - Sorting Algorithms - BarChart not updating

Here is a hope that someone might be able to help me. I have to work on a project for sorting algorithms and have had to develop an application which uses an interface, so that a sorted list is updated on the Console, a ListView and this 'Bargraph' (a subclass of BarChart). The project has the foll...
Cameron
1

votes
1

answer
222

Views

Add label on drawing in Java

My experience in Java is very little but I like programming and everything I make I want it to be as good as possible. Having studied Java for a total time of at most 2 days, it is not so easy. I've been asked to make a Logic Gate Simulator. I've done everything besides the GUI. It is not necessary...
John Katsantas
1

votes
0

answer
144

Views

Tkinter changing the height of a button

Hi I am trying to create a button with the following features: B_home = ttk.Button(self, width=17, height=20, text='Home', command=lambda: controller.show_frame(main_menu)) When I run my code, I get an error saying: _tkinter.TclError: unknown option '-height'. I have read through tkinter documentat...
Momo 6aye3

View additional questions