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

  • Home
  • SEARCH
  • 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 7047427
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T02:46:12+00:00 2026-05-28T02:46:12+00:00

I need to call several QWidget.update(rectangle) on the same widget, each time in a

  • 0

I need to call several QWidget.update(rectangle) on the same widget, each time in a different or same rectangle. But the paint method needs more information, i.e. what to do in that rectangle. Highlight? Cursor? Fill? etc. So how do I pass the paintEvent() this extra information? [I am using PyQt, but an answer in Qt is fine also.]

  • 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-28T02:46:13+00:00Added an answer on May 28, 2026 at 2:46 am

    Here is a solution I’ve worked out for python:

    Create several ‘paint’ methods, for example paintAction1(self, event), paintAction2(self, event).
    Then, whenever you need a specific one, reassign the default paintEvent method to the correct one, for example self.paintEvent = self.paintAction1, etc. You can event create a default ‘paint’ method, and have each unusual one reassign ‘self.paintEvent’ back to the default one upon completion.

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

Sidebar

Related Questions

I'm working on project that need do call the same method several times, but
i need to call method from several classes, but i don't know how to
I need to call a method that accepts a stream argument. The method loads
I need to call a number of different procedures within an Oracle package successively
I have several api's that I am integrating with and need to call in
Reading this article I found several ways to call a method. Method to call:
I need to call to SEVERAL functions that are inside the EXE from a
Please i need to call the main function of a java file several times
Need to call a filter function on some options based on a radio selected
I need to call into a Win32 API to get a series of strings,

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.