Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 598691
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T16:24:59+00:00 2026-05-13T16:24:59+00:00

I am writing a timer program in Python using PyGTK. It is precise to

  • 0

I am writing a timer program in Python using PyGTK. It is precise to the hundredths place. Right now, I am using a constantly updated label. This is a problem, because if I resize the window while the timer is running, Pango more often than not throws some crazy error and my program terminates. It’s not always the same error, but different ones that I assume are some form of failed draw. Also, the label updates slower and slower as I increase the font size.

So, I am wondering if there is a more correct way to display the timer. Is there a more stable method than constantly updating a label?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T16:24:59+00:00Added an answer on May 13, 2026 at 4:24 pm

    I figured out the problem. It was indeed a problem with the threads. I never would’ve guessed that myself. The trick is to use gobject.timeout_add() to create a timer instead of a threaded loop. Here is some information about gobject.timeout_add():

    http://faq.pygtk.org/index.py?req=show&file=faq01.021.htp

    Don’t forget to have your function return True, or the timer will stop.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 532k
  • Answers 532k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer If you don't want to put in code to explicitly… May 17, 2026 at 12:13 am
  • Editorial Team
    Editorial Team added an answer You can't scroll from another thread, but you don't have… May 17, 2026 at 12:13 am
  • Editorial Team
    Editorial Team added an answer I have had this problem before. There was a valid… May 17, 2026 at 12:13 am

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Related Questions

In a Python program I'm writing I've compared using a for loop and increment
I'm writing python program to build mac-address cache using pcap. But pcap module for
I am writing a python program that lauches a subprocess (using Popen). I am
I'm writing a program in python that uses genetic techniques to optimize expressions. Constructing
I'm writing a silly program in python for a friend that prints We are
I'm writing a python program that deals with a fair amount of strings/files. My
I am writing a simple Python program. My program seems to suffer from linear
I'm writing a program in python which should be able to pass callables which
I am constantly trying to optimize my time. Writing a C code takes a
I am writing a program to leak memory( main memory ) to test how

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.