Tk Source Code

View Ticket
Login
2003-11-13
06:37 Ticket [220931ffff] option get command responding to invalid input status still Open with 1 other change artifact: afd7828bfa user: dgp
2001-03-23
09:18 Ticket [220931ffff]: 1 change artifact: daa53aeb64 user: dgp
2000-11-20
17:37 Ticket [220931ffff]: 6 changes artifact: 975e9ecd0d user: dkf
2000-11-01
01:31 New ticket [220931ffff]. artifact: e6be1d79b6 user: welch

Ticket UUID: 220931
Title: option get command responding to invalid input
Type: Bug Version: obsolete: 8.3
Submitter: welch Created on: 2000-11-01 01:31:27
Subsystem: 57. [option] Assigned To: hobbs
Priority: 3 Low Severity:
Status: Open Last Modified: 2003-11-13 06:37:47
Resolution: None Closed By:
    Closed on:
Description:
OriginalBugID: 5957 Bug
Version: 8.3
SubmitDate: '2000-06-27'
LastModified: 
Severity: MED
Status: UnAssn
Submitter: techsupp
OS: Windows NT
Machine: Dell OptiPlex GX1


Name:
Allen Flick

ReproducibleScript:
Within ~/.Xdefaults.....                      *Button.background: cyan
then within Wish Console

% pack [button .b -text Button]
% option get .b background Button
cyan
% option get .b background Width
cyan
% option get .b background Relief
cyan
% pack [button .b -text Button]
% option get .b background Button
cyan
% option get .b background Label
cyan
% option get .b background Text
cyan

ObservedBehavior:
No matter what is put in for "class" of option database value, the response is only for the "name"
of the option database value.

DesiredBehavior:
If the "name" option with the given "class" does not exist, I'd expect to get an
empty string as the response.  Or some error code & message.
User Comments: dkf added on 2000-11-20 17:37:55:
It is part of the defined behaviour of options under X that option names are always preferred to option classes.  Tk implements exactly this, so the behaviour you describe is correct, if surprising.  Perhaps a documentation change would be useful, but certainly not a code change.