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 8081709
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T16:49:31+00:00 2026-06-05T16:49:31+00:00

I am developing one app in python curses. I am using getch() method to

  • 0

I am developing one app in python curses. I am using getch() method to get pressed keys.
But I can see pressed keys on screen. I can move cursor whenever I want, but after cursor I can see what user typed.

Of course, I can erase and redraw the whole screen after every pressed key, but it’s blinking – that’s distrubing.

Any idea how to get rid of these pressed keys? Thank you

  • 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-06-05T16:49:33+00:00Added an answer on June 5, 2026 at 4:49 pm

    Initialize the curses class in the following way, it will solve the problem.

    class curses_screen:
        def __enter__(self):
            self.stdscr = curses.initscr()
            curses.cbreak()
            curses.noecho()
            self.stdscr.keypad(1)
            SCREEN_HEIGHT, SCREEN_WIDTH = self.stdscr.getmaxyx()
            return self.stdscr
        def __exit__(self,a,b,c):
            curses.nocbreak()
            self.stdscr.keypad(0)
            curses.echo()
            curses.endwin()
    
    with curses_screen() as stdscr:
        """
        Execution code plush getch code here
        """
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

i am developing one app using opengl surface view ,how can implemented please forward
I'm developing a web app using a cakephp. I've one function in which I
i am developing one app i am using upload image in sdcard getting from
Hi I am developing one app using the below link Custom ListView With Headers
I am developing a Python web app using sqlalchemy to communicate with mysql database.
We're developing a trading app where one can enter previous trades including date and
I'm developing a Cocoa app using XCode 4. One of the windows has a
I'm developing a ruby app with Vim in one screen, and in another I'm
I am developing one app.In that app I had created one main screen.On that
I am developing one Iphone application using jquery mobile + HTML5. I can check

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.