user-interface

Using .config in tkinter

余生长醉 提交于 2021-01-29 07:11:02
问题 Beginner here Having trouble getting a label to update on a simple countdown app, Can anyone explain why the label does not update in the loop? import time import tkinter as tk root = tk.Tk() root.geometry('150x100') seconds_inp = tk.Entry(root) global time_label time_label = tk.Label(root, text = '00', font = 20) start_button = tk.Button(root, text = 'start', command = lambda: countdown_clock(int(seconds_inp.get()))) def countdown_clock(seconds): while True: seconds = seconds - 1 time.sleep

Is there a development platform for Graphical Interface in Python using 'click and drag'?

旧街凉风 提交于 2021-01-29 07:06:20
问题 Is there a platform for developing GUIs in Python using the 'click and drag' technique? without having to develop each component manually. Making a comparison, it is something like JavaFx from Java. 来源: https://stackoverflow.com/questions/64707548/is-there-a-development-platform-for-graphical-interface-in-python-using-click-a

Hangman cannot update image one by one

主宰稳场 提交于 2021-01-29 07:04:54
问题 from tkinter import * from tkinter import messagebox import random class homewindow(object): def __init__(self,win): self.words = ['rainbow','geography','testimonial','science','effort','amusing'] self.hidden_wd = random.choice(self.words) self.words.remove(self.hidden_wd) self.photo_list = [PhotoImage(file='1.gif'), PhotoImage(file='2.gif'),PhotoImage(file='3.gif'), PhotoImage(file='4.gif'),PhotoImage(file='5.gif'), PhotoImage(file='6.gif'),PhotoImage(file='7.gif'), PhotoImage(file='8.gif')

Is it possible to use Java methods from *.jar files in angular 5 services?

三世轮回 提交于 2021-01-29 06:22:58
问题 I am new to Angular, I am wondering if there is any possibility of importing *.jar files inside Angular 5 components or Services. Thanks in advance!! 来源: https://stackoverflow.com/questions/52412891/is-it-possible-to-use-java-methods-from-jar-files-in-angular-5-services

Flutter Switching FAB on PageView Pages with animation in Scaffold

二次信任 提交于 2021-01-29 06:06:57
问题 So I've looked several places for how this is supposed to be implemented and I'm sure I'm missing something trivial, but I have a flutter app with a Scaffold who's body is a PageView. I need to have a different FAB for some pages and the way it's currently set up is the floatingActionButton attribute of the scaffold is set to access an array of FloatingActionButtons with the index being the _currentPageIndex (private variable shared by bottomNavBar and _pageController. This changes the FAB

Complex layout of multiple components

隐身守侯 提交于 2021-01-29 05:29:28
问题 I am designing a GUI where I have the components shown below. But in the second row, I would like to manage spaces between the components. For example, in the second row, I would like to fit both the JLabel "Move to time" and the JTextField without so much spacing. As I can see, right now MigLayout places the JTextField in line with the second component in the first row. Then, the JButton "Move" in the 2nd row should be aligned to the 2nd component in the first row. How do I achieve this?

Illegal static declaration in inner class while using ActionListener

混江龙づ霸主 提交于 2021-01-29 03:08:12
问题 I'm trying to write a basic calculator GUI program for homework. I'm trying to define a variable for each button pressed on the calculator, and make a calculation when all the variables are declared. Right now, it's only able to add/subtract/divide/multiply two numbers 0-9, but I want to make sure I can get that working before expanding it. My problem is that I get the error code, "Illegal static declaration in inner class Calculator.sign". I'm wondering how I can get past this error. Thanks

Python - Tkinter Label Output?

时光怂恿深爱的人放手 提交于 2021-01-29 02:00:36
问题 How would I take my entries from Tkinter, concatenate them, and display them in the Label below (next to 'Input Excepted: ')? I have only been able to display them input in the python console running behind the GUI. Is there a way my InputExcept variable can be shown in the Label widget? from Tkinter import * master = Tk() master.geometry('200x90') master.title('Input Test') def UserName(): usrE1 = usrE.get() usrN2 = usrN.get() InputExcept = usrE1 + " " + usrN2 print InputExcept usrE = Entry

Python - Tkinter Label Output?

会有一股神秘感。 提交于 2021-01-29 01:57:31
问题 How would I take my entries from Tkinter, concatenate them, and display them in the Label below (next to 'Input Excepted: ')? I have only been able to display them input in the python console running behind the GUI. Is there a way my InputExcept variable can be shown in the Label widget? from Tkinter import * master = Tk() master.geometry('200x90') master.title('Input Test') def UserName(): usrE1 = usrE.get() usrN2 = usrN.get() InputExcept = usrE1 + " " + usrN2 print InputExcept usrE = Entry