Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #69043

Re: How to clear all content in a Tk()

Path csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!news.mixmin.net!feeds.phibee-telecom.net!newsfeed.xs4all.nl!newsfeed3a.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail
Return-Path <marcelgmr@gmail.com>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.006
X-Spam-Evidence '*H*': 0.99; '*S*': 0.00; 'root': 0.05; 'skip:` 10': 0.07; 'root,': 0.09; 'so?': 0.09; 'subject:()': 0.09; 'subject:How': 0.10; 'cc:addr:python-list': 0.11; '17:30': 0.16; 'frame,': 0.16; 'root:': 0.16; 'cc:addr:python.org': 0.22; 'cc:2**0': 0.24; 'this:': 0.26; 'header:In-Reply-To:1': 0.27; 'message-id:@mail.gmail.com': 0.30; 'url:mailman': 0.30; 'program,': 0.31; 'stuff': 0.32; 'subject:all': 0.32; 'url:python': 0.33; 'but': 0.35; 'received:google.com': 0.35; 'there': 0.35; 'url:listinfo': 0.36; 'url:org': 0.36; 'clear': 0.37; 'url:mail': 0.40; 'deleting': 0.60; 'to:addr:gmail.com': 0.65; 'children.': 0.93
DKIM-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=GT8oiP94EMiBAfbMT3Zt3OMxGixMvIEiXTnFrgrpP0U=; b=je5aOOK5o+ocJvpfQfQ+Es2cf8LPXH32XxT7K9WJdZTtif+MGYieH8jLMTBJr+F7di kUv7koyo3hjOhlc0Mx5NbhHxrK4TI0HH/i8vyu97avjLnhlLUQ8t1gIMWsVlAhieP5mr rNlw/RGBJK3OmTYtue4QnzmjaHtI+q4LE4iDSs5gWp3AB07uO+sguPozCFWlYhq/eDTS iU3WQiRrULSF/2pkFfX4h3lseg5maKVmFMvYQIu9x8eCUxxpGm4U/UmWaloSubDhThon WQSZP9QTglMRBLFd868TJ7W7119BgG1ZdxzoRLo+2I0FoHNtvQAHmFLcgpMtatG4BLZ0 xXQg==
MIME-Version 1.0
X-Received by 10.182.55.65 with SMTP id q1mr1852850obp.70.1395767004084; Tue, 25 Mar 2014 10:03:24 -0700 (PDT)
In-Reply-To <0ed94669-6c1e-4e2f-b79d-33bed8cdde15@googlegroups.com>
References <0ed94669-6c1e-4e2f-b79d-33bed8cdde15@googlegroups.com>
Date Tue, 25 Mar 2014 14:03:24 -0300
Subject Re: How to clear all content in a Tk()
From Marcel Rodrigues <marcelgmr@gmail.com>
To eneskristo@gmail.com
Content-Type multipart/alternative; boundary=089e0153884877c0c904f57154a6
Cc python-list <python-list@python.org>
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.15
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <https://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.8527.1395767012.18130.python-list@python.org> (permalink)
Lines 44
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1395767012 news.xs4all.nl 2914 [2001:888:2000:d::a6]:34654
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:69043

Show key headers only | View raw


[Multipart message — attachments visible in raw view] - view raw

What about this:

Put a Frame() inside the root: `frame = Frame(root)`. This frame will be
the only immediate child of root. Everything else will be put inside the
frame. When you need to clear the root, call `frame.destroy()`. This will
destroy `frame` and all its children. You will need to recreate the frame,
but not the root.


2014-03-24 17:30 GMT-03:00 <eneskristo@gmail.com>:

> I have this program, and since I want to change stuff dynamically, I want
> to fully clear the root = Tk(), without deleting it. Is there a way to do
> so?
> --
> https://mail.python.org/mailman/listinfo/python-list
>

Back to comp.lang.python | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

How to clear all content in a Tk() eneskristo@gmail.com - 2014-03-24 13:30 -0700
  Re: How to clear all content in a Tk() Marcel Rodrigues <marcelgmr@gmail.com> - 2014-03-25 14:03 -0300

csiph-web