Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
821d8b73
Commit
821d8b73
authored
Apr 26, 1999
by
Barry Warsaw
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Describe the Color database files
parent
6e7f6ea7
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
58 additions
and
31 deletions
+58
-31
Tools/pynche/README
Tools/pynche/README
+58
-31
No files found.
Tools/pynche/README
View file @
821d8b73
...
@@ -2,7 +2,7 @@ Pynche - The PYthonically Natural Color and Hue Editor
...
@@ -2,7 +2,7 @@ Pynche - The PYthonically Natural Color and Hue Editor
Contact: Barry A. Warsaw
Contact: Barry A. Warsaw
Email: bwarsaw@python.org
Email: bwarsaw@python.org
Version:
0.1
Version:
1.0
Introduction
Introduction
...
@@ -16,19 +16,21 @@ Introduction
...
@@ -16,19 +16,21 @@ Introduction
changed the name because these days, too many other systems have
changed the name because these days, too many other systems have
the acronym `ICE'.
the acronym `ICE'.
Pynche has been tested with Python 1.5.
1 using Tk 8.0
. It
Pynche has been tested with Python 1.5.
x using Tk 8.0.x
. It
probably works with Python 1.5. I've tested it on both Solaris
probably works with Python 1.5. I've tested it on both Solaris
2.6 and Windows NT. There are some funky things that happen on
2.6 and Windows NT. There are some funky things that happen on
Windows but I think they are primarily Tk problems. You'll want
Windows but I think they are primarily Tk problems. You'll want
to be sure to have Tk 8.0.3 for Windows. Also, Pynche is very
to be sure to have at least Tk 8.0.3 for Windows. Also, Pynche is
colormap intensive, so it doesn't work very well on 8-bit graphics
very colormap intensive, so it doesn't work very well on 8-bit
cards. I'll probably fix that in the future.
graphics cards. I'll probably fix that in the future.
Pynche must find a text database of colors, in the X11 format.
Pynche must find a text database of colors names in order to
Pynche is distributed with an rgb.txt file from the X11R6.4
provide `nearest' color matching. Pynche is distributed with an
distribution for this reason, but you can use a different file
rgb.txt file from the X11R6.4 distribution for this reason, along
with the -d option. The file xlicense.txt contains the license
with other "Web related" database (see below). You can use a
only for rgb.txt and both files are in the X/ subdirectory.
different file with the -d option. The file xlicense.txt contains
the license only for rgb.txt and both files are in the X/
subdirectory.
Pynche is pronounced `Pinch-ee'.
Pynche is pronounced `Pinch-ee'.
...
@@ -41,8 +43,7 @@ Running Standalone
...
@@ -41,8 +43,7 @@ Running Standalone
--database file
--database file
-d file
-d file
Alternate location of the color database file. Without this
Alternate location of the color database file. Without this
option, the first of /usr/openwin/lib/rgb.txt or X/rgb.txt
option, the first valid file found will be used (see below).
will be used.
--initfile file
--initfile file
-i file
-i file
...
@@ -68,10 +69,12 @@ Running Standalone
...
@@ -68,10 +69,12 @@ Running Standalone
Running as a Modal Dialog
Running as a Modal Dialog
Pynche can be run as a modal dialog, inside another application.
Pynche can be run as a modal dialog, inside another application,
It supports the API implemented by the Tkinter standard
say as a general color chooser. In fact, Grail 0.6 already uses
tkColorChooser module, with a few changes. By importing
Pynche and a future version of IDLE may as well. Pynche supports
pyColorChooser from the Pynche package, you can run
the API implemented by the Tkinter standard tkColorChooser module,
with a few changes as described below. By importing pyColorChooser
from the Pynche package, you can run
pyColorChooser.askcolor()
pyColorChooser.askcolor()
...
@@ -79,8 +82,9 @@ Running as a Modal Dialog
...
@@ -79,8 +82,9 @@ Running as a Modal Dialog
color.
color.
There are some UI differences when running as a modal
There are some UI differences when running as a modal
vs. standalone. When running as a modal, there is no "File" menu,
vs. standalone. When running as a modal, there is no "Quit" menu
but instead there are "Okay" and "Cancel" buttons.
item under the "File" menu. Instead there are "Okay" and "Cancel"
buttons.
When "Okay" is hit, askcolor() returns the tuple
When "Okay" is hit, askcolor() returns the tuple
...
@@ -148,6 +152,9 @@ The Colorstrip Window
...
@@ -148,6 +152,9 @@ The Colorstrip Window
be slower). Click on "Hexadecimal" to display the arrow numbers
be slower). Click on "Hexadecimal" to display the arrow numbers
in hex.
in hex.
There are also two shortcut buttons in this window, which
auto-select Black (0/0/0) and White (255/255/255).
The Proof Window
The Proof Window
In the lower left corner of the main window you see two larger
In the lower left corner of the main window you see two larger
...
@@ -164,7 +171,7 @@ The Proof Window
...
@@ -164,7 +171,7 @@ The Proof Window
RGB value. In that case, the first one found in the text database
RGB value. In that case, the first one found in the text database
is designated the "primary" name, and this is shown under the
is designated the "primary" name, and this is shown under the
Nearest chip. The other names are "aliases" and they are visible
Nearest chip. The other names are "aliases" and they are visible
in
other Pynche windows
.
in
the Color List Window (see below)
.
The Type-in Window
The Type-in Window
...
@@ -210,15 +217,15 @@ The Text Window
...
@@ -210,15 +217,15 @@ The Text Window
The Color List Window
The Color List Window
The "Color List" window shows every
color in the text databas
e
The "Color List" window shows every
named color in the color nam
e
(this window may take a while to come up). In the upper part of
database (this window may take a while to come up). In the upper
the window you see a scrolling list of all the color names in the
part of the window you see a scrolling list of all the color names
database, in alphabetical order. Click on any color to select it.
in the database, in alphabetical order. Click on any color to
In the bottom part of the window is displayed any aliases for the
select it. In the bottom part of the window is displayed any
selected color (those color names that have the same RGB value,
aliases for the selected color (those color names that have the
but were found later in the text database). For example, find the
same RGB value, but were found later in the text database). For
color "Black" and you'll see that its aliases are "gray0" and
example, find the color "Black" and you'll see that its aliases
"grey0".
are "gray0" and
"grey0".
If the color has no aliases you'll see "<no aliases>" here. If you
If the color has no aliases you'll see "<no aliases>" here. If you
just want to see if a color has an alias, and do not want to select a
just want to see if a color has an alias, and do not want to select a
...
@@ -258,7 +265,7 @@ The Details Window
...
@@ -258,7 +265,7 @@ The Details Window
around to the other side. Thus if red were at 238 and +25
around to the other side. Thus if red were at 238 and +25
were clicked, red would have the value 7.
were clicked, red would have the value 7.
Preseve Distance
Prese
r
ve Distance
When the increment or decrement would send any of the tied
When the increment or decrement would send any of the tied
variations out of bounds, all tied variations are wrapped as
variations out of bounds, all tied variations are wrapped as
one, so as to preserve the distance between them. Thus if
one, so as to preserve the distance between them. Thus if
...
@@ -299,7 +306,7 @@ Persistency
...
@@ -299,7 +306,7 @@ Persistency
When Pynche exits, it saves these values in the init file, and
When Pynche exits, it saves these values in the init file, and
re-reads them when it starts up. There is no locking on this
re-reads them when it starts up. There is no locking on this
file, so if you run multiple instances of Pynche at a time, you
file, so if you run multiple instances of Pynche at a time, you
will override
the init file.
may clobber
the init file.
The actual options stored include
The actual options stored include
...
@@ -311,12 +318,32 @@ Persistency
...
@@ -311,12 +318,32 @@ Persistency
insertion point, and all current text widget element color
insertion point, and all current text widget element color
settings.
settings.
- the name of the color database file (but not its contents)
You can inhibit Pynche from reading the init file by supplying the
You can inhibit Pynche from reading the init file by supplying the
--ignore option on the command line. However, you cannot suppress
--ignore option on the command line. However, you cannot suppress
the storing of the settings in the init file on Pynche exit. If
the storing of the settings in the init file on Pynche exit. If
you really want to do this, use /dev/null as the init file, using
you really want to do this, use /dev/null as the init file, using
--initfile.
--initfile.
Color Name Database Files
Pynche uses a color name database file to calculate the nearest
color to the selected color, and to display in the Color List
view. Several files are distributed with Pynche, described
below. By default, the X11 color name database file is selected.
Other files:
html40colors.txt -- the HTML 4.0 guaranteed color names
websafe.txt -- the 216 "Web-safe" colors that Netscape and MSIE
guarantee will not be dithered. These are specified in #rrggbb
format for both values and names
webcolors.txt -- The 140 color names that Tim Peters and his
sister say NS and MSIE both understand (with some controversy over
AliceBlue).
To Do
To Do
Here's a brief list of things I want to do:
Here's a brief list of things I want to do:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment