public inbox for insight@sourceware.org
 help / color / mirror / Atom feed
From: "Martin M. Hunt" <hunt@redhat.com>
To: Keith Seitz <keiths@cygnus.com>
Cc: Insight Maling List <insight@sources.redhat.com>
Subject: Re: [RFA] fix tab size spinner
Date: Tue, 16 Oct 2001 17:42:00 -0000	[thread overview]
Message-ID: <200110170042.RAA21720@cygnus.com> (raw)
In-Reply-To: <Pine.GSO.4.33.0110111216180.28476-100000@makita.cygnus.com>

On Thursday 11 October 2001 12:21 pm, Keith Seitz wrote:
> On Thu, 11 Oct 2001, Martin M. Hunt wrote:
> > More brain-damaged iwidgets.  The tab size spinner does not initialize
> > itself to the textvariable, instead it initializes the textvariable.
> >
> >    frame $f.x
> > +
> >    # Tab size
> > +  set tab_size [pref get gdb/src/tab_size]
> >    itk_component add size {
> >      iwidgets::spinint $f.x.size -labeltext "Tab Size" -range {1 16} \
> >        -step 1 -fixed 2 -width 2 -textvariable [pref varname
> > gdb/src/tab_size] \
> >        -wrap 0
> >    }
> > +  $f.x.size delete 0 end
> > +  $f.x.size insert end $tab_size
>
> Ugh, now I remember why I disliked the preference dialogs... We should not
> be using "pref varname gdb/src/tab_size" in the spinint. If we do, then
> the instant the spinint is changed, it is saved in the preference, no?
> Sounds a little backwards.
>
> We should be doing something like:
>
>   iwidgets::spinint ... -textvariable [scope _tab_size] ...
>   set _tab_size [pref get gdb/src/tab_size]
>
> Then in GlobalPref::_apply, we should be doing
> pref set gdb/src/tab_size $_tab_size
>
> Does this not make more sense? Of course, I could be hallucinating. :-)

Some prefs use "apply" and some don't.  We need to either fix the apply 
button or remove it.  We also need to fix closing the dialog so it does the 
same thing as hitting "OK".  

Anyone feel strongly about the need for "Apply"?  Is there a problem with 
having options apply themselves immediately?

Martin

       reply	other threads:[~2001-10-16 17:42 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <Pine.GSO.4.33.0110111216180.28476-100000@makita.cygnus.com>
2001-10-16 17:42 ` Martin M. Hunt [this message]
2001-10-16 18:25   ` Fernando Nasser
2001-10-17 10:32     ` Tom Tromey
2001-10-17 11:11       ` Keith Seitz

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200110170042.RAA21720@cygnus.com \
    --to=hunt@redhat.com \
    --cc=insight@sources.redhat.com \
    --cc=keiths@cygnus.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).