PIXMAP(1)

πŸ“¦ version 2.6.6, in debian bookworm, ubuntu jammy

from the General Commands Manual 🫢

🌸 NAME 🌸

pixmap β€” Xpm pixmap editor for X ✨


πŸ¦‹ SYNOPSIS πŸ¦‹

pixmap [-options ...]

πŸ’– DESCRIPTION πŸ’–

okay so the pixmap program is a tool for creating or editing rectangular images made up of colored pixels, i.e., pixmaps. Pixmaps are intensively used in X to define window backgrounds, icon images, etc.

The pixmap program can have two different interfaces, a Athena widgets version and a Motif widgets version.


✨ USAGE ✨

Pixmap displays grid in which each square represents a single pixel in the picture being edited. Squares can be set, cleared, or inverted (this last operation will be detailed later) directly with the buttons on the pointer and a menu of higher level operations such as draw line and fill circle is provided to the side of the grid. Another menu on the top of the window allows files operations (Load, Save, ...), edit operations (Cut/Copy/Paste, attributes of pixmap editing, ...) and colors operations (drawing color, attributes of colors, ...). Pixmap uses a Pixmap widget to represent the pixmap image.

Pixmaps are stored as a C string array variable suitable for including in applications, using the format defined by Arnaud Le Hors in his Xpm library (refer to Xpm manual for format description). This format allows pixmaps to be used indistinctly on monochrome, grey scale or color displays.


πŸŽ€ OPTIONS πŸŽ€

Pixmap accepts the following options:

  • -display/-d display β€” This option specifies the name of the X server to use.
  • -geometry geometry β€” This option specifies the placement and size of the pixmap program window on the screen. See X for details.
  • -help/-h β€” This option asks for the usage description of pixmap.
  • -size WIDTHxHEIGHT β€” This option specifies the size (width and height) in pixels of the pixmap to be edited.
  • -squares SIZE β€” This option specifies the size in display points to use to represent each pixel (a square of SIZE points).
  • +grid/-grid β€” This option indicates that the grid lines in the Pixmap widget should be displayed or not.
  • -stippled β€” This option turns off stipple drawing of transparent pixels.
  • -stipple pixmap β€” This option specifies the depth 1 pixmap to use to draw transparent pixels.
  • +axes/-axes β€” This option indicates that the axes in the Pixmap widget should be displayed or not.
  • +proportional/-proportional β€” This option indicates that the pixels in the Pixmap widget should be drawn proportional, i.e. in squares, or not.
  • -hl color β€” This option specifies the color to use for highlighting purposes. color can be any name accepted by the XParseColor(3X11) function.
  • -fr color β€” This option specifies the color to use to draw grid and axes in Pixmap widget. color can be any name accepted by the XParseColor(3X11) function.
  • -tr color β€” This option specifies the color to use to represent transparent pixels. color can be any name accepted by the XParseColor(3X11) function.
  • -fn/-font fontname β€” This option specifies the font to be used in pixmap.
  • -filename/-f/-in filename β€” This option specifies the name of the file from which the pixmap to be edited should be loaded.
  • -colormap/-pc β€” This option specifies that pixmap should use its own private colormap instead of the default colormap.

πŸ–±οΈ PIXELS EDITING WITH MOUSE πŸ–±οΈ

Pixels may be set, cleared, or inverted by pointing to them and clicking one of the buttons indicated below. Multiple pixels can be changed at once by holding the button down and dragging the cursor across them. Set pixels are filled with the current color; cleared pixels are filled with white; and inverted pixels are either set if they were originally cleared or cleared otherwise.

  • Button 1 β€” This button (usually leftmost on the pointer) is used to set one or more pixels.
  • Button 2 β€” This button (usually in the middle) is used to invert one or more pixels.
  • Button 3 β€” This button (usually on the right) is used to clear one or more pixels.
  • Button 4 β€” This button is used to clear one or more pixels.
  • Button 5 β€” This button is used to clear one or more pixels.

Every button operation can be changed by means of resources in the .Xdefaults file or application defaults file (/usr/lib/X11/app-defaults/Pixmap).


To make defining shapes easier, pixmap provides several commands for drawing and manipulating the pixmap edited, and commands for file management.

Commands are layed in a vertical bar at the left of the Pixmap widget and in a menu bar at the top of the window. Most of the drawing commands are located in the left bar, where as file management and other general commands are located in the top menu bar.

In the left bar, some commands are represented by icons. They are, from left to right and up to down, Flip horizontally, Up, Flip vertically, Left, Fold, Right, Rotate right (counterclock), Down, Rotate left (clockwise).

Some commands are also available directly through the keyboard when the mouse cursor is located on the Pixmap widget. They will be mentioned as an accelerator in the following description.

πŸ’… LEFT BAR COMMANDS πŸ’…

  • Undo β€” This command is used to undo the last operation. Only one operation can be undone. The accelerator of this command is Any<Key>u.
  • Clear β€” This command is used to clear all of the pixels in the pixmap as if Button 3 had been dragged through every pixel in the pixmap. The accelerator of this command is [Shift]<Key>c.
  • Set β€” This command is used to set all of the pixels in the pixmap to the current color, as if Button 1 had been dragged through every pixel in the pixmap. The accelerator of this command is [Shift]<Key>s.
  • Redraw β€” This command is used to redisplay the pixmap. The accelerator of this command is Ctrl<Key>l.
  • Copy β€” This command is used to copy a region of the pixmap from one location to another. When this command is invoked, the region to copy should be specified by pressing Button 1, dragging the mouse and releasing Button 1. The region can now be copied by pressing Button 1 with the cursor located on the region selected, dragging the mouse and releasing it where the upper left corner of the region should be copied. If a region was already selected with a Mark command, only the second phase of the copy is necessary. The accelerator of this command is available when a region has already been selected and is Ctrl<Btn2Down> to drag the region and Ctrl<Btn2Up> to draw it to point. This accelerated command is identical to the Paste command available through the Edit menu of the top menu bar.
  • Move β€” This command is used to move a region of the pixmap from one location to another. When this command is invoked, the region to move should be specified by pressing Button 1, dragging the mouse and releasing Button 1. The region can now be moved by pressing Button 1 with the cursor located on the region selected, dragging the mouse and releasing it where the upper left corner of the region should be moved. The initial region is cleared. If a region was already selected with a Mark command, only the second phase of the move is necessary.
  • Mark β€” This command is used to mark a region to move or copy it later (commands Move and Copy above), or to put it in the Cut&Paste buffer (commands Cut and Copy of the Edit menu of the top menu bar). When this command is invoked, the region should be specified by pressing Button 1, dragging the mouse and releasing Button 1. Once marked, the region is highlighted. The accelerator of this command is Ctrl<Btn1Down> to initiate the selection and Ctrl<Btn1Up> to finish it.
  • Unmark β€” This command is used to unmark a region previously marked. It will unhighlight the region. The accelerator of this command is Ctrl<Btn3Down>.
  • Flip horizontally β€” This command is used to flip horizontally the whole pixmap or the marked region. This means mirroring horizontally the pixmap image. The mirror is placed at the middle of the pixmap height. The accelerator of this command is [Shift|Ctrl]<Key>h.
  • Up β€” This command is used to move the whole pixmap or the marked region up. Pixels at the top of the pixmap are pushed back at the bottom of the new pixmap. The accelerator of this command is Any<Key>Up (not available in Motif version).
  • Flip vertically β€” This command is used to flip vertically the whole pixmap or the marked region. This means mirroring vertically the pixmap image. The mirror is placed at the middle of the pixmap width. The accelerator of this command is Any<Key>v.
  • Left β€” This command is used to move the whole pixmap or the marked region left. Pixels at the left of the pixmap are pushed back at the right of the new pixmap. The accelerator of this command is Any<Key>Left (not available in Motif version).
  • Fold β€” This command is used to "Fold" the pixmap. This means splitting the pixmap image in four squares (top left, top right, bottom left and bottom right) and inverting them (top becomes bottom, left becomes right, and so on). "Folding" twice a pixmap does no change. The accelerator of this command is [Shift|Ctrl]<Key>f.
  • Right β€” This command is used to move the whole pixmap or the marked region right. Pixels at the right of the pixmap are pushed back at the left of the new pixmap. The accelerator of this command is Any<Key>Right (not available in Motif version).
  • Rotate right β€” This command is used to rotate the pixmap image or the marked region right (clockwise) of 90 degrees. Four Rotate right operations does no change. The accelerator of this command is [Shift|Ctrl]<Key>r.

Down

Moves the whole pixmap or the marked region down. Pixels that fall off the bottom get pushed back in at the top of the new pixmap β€” like a lil conveyor belt 🎒. Accelerator: Any<Key>Down (heads up bestie, this one's not available in the Motif version).

Rotate left

Rotates the pixmap image or the marked region left (counterclock) by 90 degrees. Do it four times and literally nothing changed, it's giving full circle ✨. Accelerator: [Shift]<Key>l.

Point

Sets, inverts or clears a pixel to the current color. Think of it as a mode β€” once you pick it, pixels get set, inverted or cleared depending on which button you use (peep Pixels Editing with the Mouse for the deets). If you keep the mouse button pressed while dragging, you can hit more than one pixel πŸ–±οΈ. This command has no accelerator.

Curve

Draws curved lines (set, cleared or inverted). The curve gets drawn live while you drag the mouse. Also a mode. You can honestly get pretty much the same effect by dragging the mouse in point mode β€” the main difference is that here the pixels get drawn contiguously πŸŒ€. No accelerator.

Line

Draws lines between two points (set, cleared or inverted). The lines show up highlighted first while the mouse button stays pressed. Yep, a mode too. No accelerator.

Rectangle

Draws rectangles between two points that define the two opposite corners (set, cleared or inverted). Again, first drawn highlighted while the mouse button remains pressed. A mode. No accelerator.

Filled Rectangle

Draws filled rectangles between two points defining the two opposite corners of the rectangle (set, cleared or inverted). The rectangle outlines are drawn highlighted first while the mouse button stays pressed. A mode. No accelerator.

Circle

Sets, inverts or clears the pixels on a circle specified by a center and a point on the curve. Small circles might not look super round β€” that's just the pixmap size and the whole "discrete pixels" situation, no cap 😭. A mode. No accelerator.

Filled Circle

Sets, inverts or clears all of the pixels in a circle specified by a center and a point on the curve. All pixels side and including the circle are set. A mode. No accelerator.

Flood Fill

Sets all clear pixels in an enclosed shape. That enclosed shape is determined by all the pixels whose color is different from the color of the pixel you clicked. If the shape isn't closed, the entire pixmap gets filled 🌊 β€” so like, be aware. A mode. No accelerator.

Set Hot Spot

Lets you specify a Hot Spot. You select it by clicking the Set mouse button. Clicking Invert will invert the Hot Spot β€” set or reset it depending on its previous state. Hot spots are useful for cursor pixmaps, and they're used to reference the sensible part of the pixmap πŸ‘‘. No accelerator.

Clear Hot Spot

Clears the current Hot Spot. That's it, that's the whole job πŸ’…. No accelerator.

Set Port

Lets you create a Port extension line graphically. This is part of the customized Port extension editor developed by Tim Wise (SES Inc.). The Port gets set on the pixmap image by clicking any of the mouse button. No acelerator.

Clear Port

Lets you remove a Port extension line graphically. Also part of the customized Port extension editor developed by Tim Wise (SES Inc.). The Port onto which any mouse button was clicked is cancelled. No accelerator.

Move Port

Lets you move a Port, i.e. change the coordinates specified in the Port extension line. Part of the customized Port extension editor developed by Tim Wise (SES Inc.). The Port onto which any mouse button was pressed moves along with the mouse cursor until you release the mouse button. No accelerator.

Port Info...

Lets you edit the information associated to a Port, the stuff contained in a Port extension line. Part of the customized Port extension editor developed by Tim Wise (SES Inc.). The info associated with the Port onto which any mouse button was clicked shows up in a dialog window, and you can edit it right there and save it by clicking the "Okay" button of the dialog. No accelerator.


🌈 TOP MENU COMMANDS 🌈

Info

Pops up an info window β„ΉοΈβœ¨.


πŸŽ€ File MENU πŸŽ€

Load...

Loads a pixmap file into the pixmap editor. A dialog window pops up and you gotta hand over a filename. You can bail on the whole thing with the Cancel button of the dialog window. Accelerator: Alt<Key>l.

Insert...

Loads a pixmap into the Cut&Paste buffer of the pixmap editor. Then you can paste the contents of that pixmap file onto the current pixmap 🫢. A dialog window pops up where you provide a filename. Interruptible with the Cancel button. Accelerator: Alt<Key>i.

Save

Saves the current pixmap into the current file being edited. By default β€” and this stays true until something else changes it via a Filename..., Load... or Save As... operation, or by specifying the filename on the command line β€” the filename is scratch. The Filename... command is how you change that default filename. Accelerator: Alt<Key>s.

Save As...

Saves the current pixmap into a particular file, whose name you provide in the dialog window that pops up. Interruptible with the Cancel button. Accelerator: Alt<Key>a.

Resize...

Resizes the current pixmap to the width and height specified in the dialog window that pops up. The syntax is WIDTHxHEIGHT. This is different from Rescale... β€” it just adds or removes pixels to the current pixmap without trying to fit the space correctly with the pixmap image. Interruptible with the Cancel button. Accelerator: Alt<Key>r.

Rescale...

Rescales the current pixmap image so it fits a larger or smaller space. You specify the new width and height in the dialog window that pops up, with the syntax WIDTHxHEIGHT. Interruptible with the Cancel button. Accelerator: Alt<Key>e.

Filename...

Changes the current filename β€” that is, the name of the file the pixmap gets saved into with a Save operation. Provide the new filename in the dialog window that pops up. Interruptible with the Cancel button. Accelerator: Alt<Key>f.

Hints comment...

Pops up a dialog window where you can specify the hints section comment of the pixmap file. Interruptible with the Cancel button. Accelerator: Alt<Key>h.

Colors comment...

Pops up a dialog window where you can specify the colors section comment of the pixmap file. Interruptible with the Cancel button. Accelerator: Alt<Key>c.

Pixels comment...

Pops up a dialog window where you can specify the pixels section comment of the pixmap file. Interruptible with the Cancel button. Accelerator: Alt<Key>p.

Quit

Makes pixmap display a dialog box asking whether or not it should save the pixmap (if it has changed) and then exit. Answering yes is the same as invoking Save; no causes pixmap to simply exit; and cancel aborts the Quit command so you can keep making more changes πŸ’–. Accelerator: Alt<Key>q.


πŸ’œ Edit MENU πŸ’œ

Image

Pops up a window showing the real size pixmap. Close that window by clicking the mouse inside it, or by invoking Image once again. When the window is popped up, an X mark is displayed in the menu at the left of the Image label. Accelerator: <Key>i.

Grid

Toggles the display of the grid πŸ¦‹. When the grid is displayed, an X mark is added at the left of the Grid label. Accelerator: <Key>g.

Axes

Toggles the display of axes. When axes are displayed, an X mark is added at the left of the Axes label. Accelerator: <Key>a.

  • Proportional β€” okay so this one toggles the display into proportional mode for the pixmap. What does that even mean, bestie? It means the Pixmap widget stops trying to stretch itself to fill all the available space in the interface and instead shows each pixel as a square, which probably leaves some empty space chilling around the widget. When proportional mode is on, an X mark pops up at the left of the Proportional label. The accelerator of this command is <Key>p.
  • Zoom β€” this one zooms some pixels of the current pixmap, and the zooming region has to be selected by the user as a rectangle region, literally just like marking a region (peep the Mark command πŸ‘€). You can interrupt the operation by invoking any other command. When a region is zoomed, an X mark shows up at the left of the Zoom label. Invoke the Zoom command one more time and it zooms back out. The accelerator of this command is <Key>z.
  • Zoom In β€” incrementally zooms into the current pixmap πŸŽ€. The side effect? The square used to represent a single pixel gets bigger. The accelerator of this command is <Key>x.
  • Zoom Out β€” incrementally zooms out of the current pixmap. The side effect here is that the square representing a single pixel shrinks. The accelerator of this command is <Key>y.
  • Zooming Factor β€” this command pops up a dialog window where you get to edit the current zooming factor. And what is the zooming factor? It's literally the size of the square used to represent a single pixel. Bump it up and you zoom into the current pixmap; shrink it and you zoom out. The accelerator of this command is <Key>f.
  • Cut β€” when a region is marked, this operation becomes active. It cuts the contents of the region and drops them into the Cut&Paste buffer. The Paste command now becomes active, the marked region gets unmarked, and the pixels in that marked region are cleared. Heads up: this command acts as the Move one when a region is already marked. The accelerator of this command is Ctrl<Key>c.
  • Copy β€” when a region is marked, this operation is active. It copies the contents of the region into the Cut&Paste buffer. The Paste command now becomes active and the marked region is unmarked. This command acts as the Copy command of the left border when a region is already marked. The accelerator of this command is Ctrl<Key>x.
  • Paste β€” once a region has been cut or copied into the Cut&Paste buffer, this command is active and you can use it to paste the buffer contents wherever the mouse button is clicked 🫢. The paste operation actually pays attention to which button you used to specify the point to paste the buffer at. The button can stay pressed so you can move the buffer around, then release it to paste the buffer at the current location. A Copy and Paste operation can be accelerated with Ctrl<Btn2Down> to initiate the operation and Ctrl<Btn2Up> to finish it, i.e. paste the buffer. The accelerator of this command is Ctrl<Key>p.
  • Crop β€” when a region is marked, or when a file has been inserted into the Cut&Paste buffer, this command swaps the current pixmap with the marked region, or with the Cut&Paste buffer. Cropping twice does nothing, fr fr. The accelerator of this command is Ctrl<Key>o.

🎨 Foreground Color MENU 🎨

  • Add color... β€” this command adds a new color to the Color Panel (scroll down for that one πŸ’–). The color name gets specified in the dialog window that pops up, and it can be either a real color name found in the rgb.txt file or a string like #rrggbb, where rr, gg and bb represent the red, green and blue components of the color in hexadecimal format. You can interrupt the operation with the Cancel button of the dialog window. The accelerator of this command is Ctrl<Key>a.
  • Symbolic name... β€” sets the symbolic name of the current color. You type the symbolic name into the dialog window that pops up. The operation can be interrupted with the Cancel button of the dialog window. The accelerator of this command is Ctrl<Key>s.
  • Monochrome name... β€” sets the monochrome name of the current color, i.e. the name of the color to use on monochrome displays. You enter the monochrome name in the dialog window that pops up. The operation can be interrupted with the Cancel button of the dialog window. The accelerator of this command is Ctrl<Key>m.
  • Grey scale 4 name... β€” sets the grey scale 4 name of the current color, i.e. the name of the color to use on grey scale 4 displays. The grey scale 4 name is entered in the dialog window that pops up. The operation can be interrupted with the Cancel button of the dialog window. The accelerator of this command is Ctrl<Key>4.
  • Grey scale name... β€” sets the grey scale name of the current color, i.e. the name of the color to use on grey scale displays (the ones with more then 4 levels). You enter the grey scale name in the dialog window that pops up. The operation can be interrupted with the Cancel button of the dialog window. The accelerator of this command is Ctrl<Key>g.
  • Color name... β€” sets the color name of the current color. This change gets considered when saving the pixmap, but to remain visible it affects the label of the menu item of the color. This is useful to directly change a specific color for another one, or to let multiple symbols represent the same color (the color can be the same on a color display but change on grey scale or monochrome ones). The color name is entered in the dialog window that pops up. The operation can be interrupted with the Cancel button of the dialog window. The None name (not case sensitive) is used to change the pixel representing the transparent color. The accelerator of this command is Ctrl<Key>n.

πŸ¦‹ Xpm Extensions MENU πŸ¦‹

  • Add Extension... β€” this command pops up a dialog window where you provide a name for an extension to be added to the current pixmap extensions list. The operation can be interrupted with the Cancel button of the dialog window. If you confirm with the Okay button, another dialog window pops up where you can edit the extension contents. When you click the Cancel button in that extension editing window, the edit operation is interrupted but the extension is still added to the extensions list of the current pixmap. So if you actually want to abort the Add Extension... operation, you need to click on the Remove button. Otherwise the edition can be confirmed by clicking on the Okay button.
  • Any extension name β€” when an extension is added to the extensions list of the current pixmap, its name appears in the Xpm Extensions menu. When selected in the menu, the extension edition window pops up. See above for its description πŸ‘†.

In addition the Motif version defines the status label as two active buttons which operate as Filename... and Resize... commands.


🌈 COLOR PANEL 🌈

Colors in the pixmap are presented in the Color Panel, and every loaded color is associated with a square button filled with the color pixel. Scrollbars around the panel let you scan the whole panel, so nothing is hiding from you πŸ’….

To choose a color for drawing, you have to click on a color button. At this time, the current name of the color is displayed as the title of the Foreground Color menu. A color can also be selected by using Shift<BtnDown> on a pixel of the current pixmap whose color should be used. This accelerator is genuinely so useful when you're modifying small parts of a pixmap locally ✨.

πŸ’Ύ FILE FORMAT πŸ’Ύ

ok so bestie, when you hit Save or Save As..., the pixmaps get stored using the format that Arnaud Le Hors defined in his Xpm library (version 3.x). Every single pixmap is a C string array variable β€” which means you can literally #include it and use it inside your programs, or point at it with X Toolkit pixmap resources (that works as long as a String to Pixmap converter has been registered on the server). πŸ’…

Here's what a pixmap file actually looks like, no cap:

/* XPM */
static char * plaid[] = {
/* plaid pixmap
 * width height ncolors chars_per_pixel */
"22 22 4 2 ",
/* colors */
"   c red         m white  s light_color ",
"Y  c yellow      m black  s lines_in_mix ",
"+  c yellow      m white  s lines_in_dark ",
"x                m black  s dark_color ",
/* pixels */
"x   x   x x x   x   x x x x x x + x x x x x ",
"  x   x   x   x   x   x x x x x x x x x x x ",
"x   x   x x x   x   x x x x x x + x x x x x ",
"  x   x   x   x   x   x x x x x x x x x x x ",
"x   x   x x x   x   x x x x x x + x x x x x ",
"Y Y Y Y Y x Y Y Y Y Y + x + x + x + x + x + ",
"x   x   x x x   x   x x x x x x + x x x x x ",
"  x   x   x   x   x   x x x x x x x x x x x ",
"x   x   x x x   x   x x x x x x + x x x x x ",
"  x   x   x   x   x   x x x x x x x x x x x ",
"x   x   x x x   x   x x x x x x + x x x x x ",
"          x           x   x   x Y x   x   x ",
"          x             x   x   Y   x   x   ",
"          x           x   x   x Y x   x   x ",
"          x             x   x   Y   x   x   ",
"          x           x   x   x Y x   x   x ",
"x x x x x x x x x x x x x x x x x x x x x x ",
"          x           x   x   x Y x   x   x ",
"          x             x   x   Y   x   x   ",
"          x           x   x   x Y x   x   x ",
"          x             x   x   Y   x   x   ",
"          x           x   x   x Y x   x   x "
} ;

The plaid name that gets used to reference the pixmap variable is built straight off the name of the file the pixmap was saved in. 🌸 Any directories get stripped off the front of that name, and any suffix that starts with a period gets stripped off the end.

So the pixmap variable is a string array, and the very first string in it holds the width, height, number of colors and number of characters per pixel. That's your whole header, right there. πŸ‘‘

After that first string come the color descriptions β€” one string per color. A color description can be made up of one or more characters that represent a pixel, plus a color display name preceded by the c character, and/or a symbolic name preceded by the s character, and/or a monochrome display name preceded by the m character, and/or a grey scale 4 levels display name preceded by the string g4, and/or a grey scale display name preceded by the character g β€” and you can put them in any order you want. Mix and match, it's giving flexible. ✨

Once all the color description strings are done, every string after that represents one line of the pixmap, made up of symbolic characters that are assigned to colors. πŸŽ€


🌈 USING PIXMAPS IN PROGRAMS 🌈

ngl the whole reason the pixmap file format is shaped like this is so pixmaps are stupidly easy to use inside X programs, whatever your display happens to be. πŸ¦‹

Check it β€” this code creates a pixmap you can use as a window background, using the enhanced Xpm library (version 3.3) from Groupe Bull, and it assumes the pixmap was stored in a file named plaid.xpm:

#include "plaid.xpm"

Pixmap pixmap;

XpmCreatePixmapFromData (display, drawable, plaid, &pixmap,
             &pixmap_mask, &attributes);

And there's more where that came from β€” additional routines are available for reading in pixmap files and returning the data in the file in Pixmaps. 🫢

🌳 WIDGET HIERARCHY 🌳

okay bestie, this is the whole family tree of the pixmap editor πŸ’– we're laying it out so you can configure the editor with X resources in a .Xdefaults file. The first widget class is the Athena version one, and the second one β€” separated by a | character β€” is the Motif version. iykyk 🫢

Pixmap                                            pixmap
     Paned|RowColumn                              parent
          Form|RowColumn                          formy
               MenuButton|CascadeButtonGadget     fileButton
               SimpleMenu|RowColumn               fileMenu
                    SmeBSB|PushButtonGadget       load
                    SmeBSB|PushButtonGadget       insert
                    SmeBSB|PushButtonGadget       save
                    SmeBSB|PushButtonGadget       saveAs
                    SmeLine|SeparatorGadget       line
                    SmeBSB|PushButtonGadget       resize
                    SmeBSB|PushButtonGadget       rescale
                    SmeBSB|PushButtonGadget       filename
                    SmeBSB|PushButtonGadget       hintsCmt
                    SmeBSB|PushButtonGadget       colorsCmt
                    SmeBSB|PushButtonGadget       pixelsCmt
                    SmeLine|SeparatorGadget       line
                    SmeBSB|PushButtonGadget       quit
               MenuButton|CascadeButtonGadget     editButton
               SimpleMenu|RowColumn               editMenu
                    SmeBSB|ToggleButtonGadget     image
                    SmeLine|SeparatorGadget       line
                    SmeBSB|ToggleButtonGadget     grid
                    SmeBSB|ToggleButtonGadget     axes
                    SmeBSB|ToggleButtonGadget     proportional
                    SmeBSB|ToggleButtonGadget     zoom
                    SmeBSB|PushButtonGadget       zoomIn
                    SmeBSB|PushButtonGadget       zoomOut
                    SmeBSB|PushButtonGadget       zoomFactor
                    SmeLine|SeparatorGadget       line
                    SmeBSB|PushButtonGadget       cut
                    SmeBSB|PushButtonGadget       copy
                    SmeBSB|PushButtonGadget       paste
                    SmeBSB|PushButtonGadget       crop
               MenuButton|CascadeButtonGadget     fgButton
               SimpleMenu|RowColumn               fgMenu
                    SmeBSB|PushButtonGadget       addColor
                    SmeBSB|PushButtonGadget       symbolicName
                    SmeBSB|PushButtonGadget       monochromeName
                    SmeBSB|PushButtonGadget       g4Name
                    SmeBSB|PushButtonGadget       gName
               MenuButton|CascadeButtonGadget     extensionButton
               SimpleMenu|RowColumn               extensionMenu
                    SmeBSB|PushButtonGadget       addExtension
                    SmeBSB|PushButtonGadget       <extension_name>
                    .
                    .
                    .
               Label|CascadeButtonGadget          status
               |CascadeButtonGadget               statusb
               Command|CascadeButtonGadget        infoButton
          Paned|Form                              pane
               Form|RowColumn                     form
                    Command|PushButtonGadget      undo
                    Command|PushButtonGadget      clear
                    Command|PushButtonGadget      set
                    Command|PushButtonGadget      redraw
                    Toggle|ToggleButtonGadget     copy
                    Toggle|ToggleButtonGadget     move
                    Toggle|ToggleButtonGadget     mark
                    Command|PushButtonGadget      unmark
                    |RowColumn                    formh
                         Command|PushButtonGadget flipHoriz
                         Command|PushButtonGadget up
                         Command|PushButtonGadget flipVert
                    |RowColumn                    formh
                         Command|PushButtonGadget left
                         Command|PushButtonGadget fold
                         Command|PushButtonGadget right
                    |RowColumn                    formh
                         Command|PushButtonGadget rotateLeft
                         Command|PushButtonGadget down
                         Command|PushButtonGadget rotateRight
                    Toggle|ToggleButtonGadget     point
                    Toggle|ToggleButtonGadget     line
                    Toggle|ToggleButtonGadget     rectangle
                    Toggle|ToggleButtonGadget     filledRectangle
                    Toggle|ToggleButtonGadget     circle
                    Toggle|ToggleButtonGadget     filledCircle
                    Toggle|ToggleButtonGadget     floodFill
                    Toggle|ToggleButtonGadget     setHotSpot
                    Command|PushButtonGadget      clearHotSpot
                    Toggle|ToggleButtonGadget     setPort
                    Toggle|ToggleButtonGadget     clearPort
                    Toggle|ToggleButtonGadget     movePort
                    Toggle|ToggleButtonGadget     portInfo
               Paned|PanedWindow                  vPane
                    ViewPort|ScrolledWindow       colorView
                         Box|RowColumn            colorPane
                              Command|PushButton  <color_name>
                              .
                              .
                              .
                    ViewPort|ScrolledWindow       pixmapView
                         Pixmap|Pixmap            pixmap
     TransientShell|TransientShell                image
          Label|Label                             label
     PopupShell|SelectionBox                      info
          Dialog|                                 dialog
               Label|                             label
               Text|                              value
               Command|                           Okay
     PopupShell|SelectionBox                      input
          Dialog|                                 dialog
               Label|                             label
               Text|                              value
               Command|                           Okay
               Command|                           Cancel
     PopupShell|SelectionBox                      file
          Dialog|                                 dialog
               Label|                             label
               Text|                              value
               Command|                           Okay
               Command|                           Cancel
     PopupShell|SelectionBox                      error
          Dialog|                                 dialog
               Label|                             label
               Command|                           Abort
               Command|                           Retry
     PopupShell|SelectionBox                      qsave
          Dialog|                                 dialog
               Label|                             label
               Text|                              value
               Command|                           Yes
               Command|                           No
               Command|                           Cancel
     PopupShell|PopupShell                        extEditorShell|extEditor_popup
          Form|Form                               extEditor
               Label|Label                        name
               AsciiText|ScrolledText             text
               Command|PushButtonGadget           ok
               Command|PushButtonGadget           cancel
               Command|PushButtonGadget           remove

ngl this next bit matters πŸ‘€ Lines where only one or the other type of a widget shows up (like Dialog| or |CascadeButtonGadget) mean that the widget doesn't exist in one or the other version. Like, it's just not there. Fr fr. 🌸

And in the case of dialogs in the Motif version, the widgets are created by means of convenient routines which assign the name of the widget depending on the name of the dialog. By the way, we can't provide with a list of types and names for the substructure of dialog widgets in the Motif version. However, these shouldn't be often modified. πŸ’…


✨ X DEFAULTS ✨

On top of the standard Athena or Motif widgets resources, pixmap uses the following resources for the Pixmap widget (named pixmap):

  • Cursor β€” the cursor to use within the Pixmap widget. πŸ’–
  • Foreground β€” the initial foreground color for drawing.
  • Highlight β€” the highlighting color.
  • Framing β€” the framing color, used to draw grid and axes. πŸŽ€
  • Transparent β€” the color representing transparent pixels. (iconic, honestly)
  • Proportional β€” toggles initial proportional display mode.
  • Grid β€” toggles initial grid display.
  • GridTolerance β€” determines when to display grid according to SquareSize.
  • Stippled β€” suppress stipple drawing of transparent pixels.
  • Stipple β€” Depth 1 pixmap to use to draw transparent pixels stippled.
  • Axes β€” toggles axes display.
  • Resize β€” toggles Pixmap widget resize when requesting by window manager.
  • Distance β€” the margin around Pixmap widget.
  • SquareSize β€” the size in screen points used to display each pixmap pixels.
  • PixmapWidth β€” the initial width of the pixmap.
  • PixmapHeight β€” the initial height of the pixmap.
  • Button1Action β€” the action associated to mouse button 1 (between Set, Invert and Clear).
  • Button2Action β€” the action associated to mouse button 2 (between Set, Invert and Clear).
  • Button3Action β€” the action associated to mouse button 3 (between Set, Invert and Clear).
  • Button4Action β€” the action associated to mouse button 4 (between Set, Invert and Clear).
  • Button5Action β€” the action associated to mouse button 5 (between Set, Invert and Clear).
  • Filename β€” the initial file to load. πŸ¦‹
  • AddColorNtfyProc β€” the procedure to call when reading a pixmap file to notify color loading. It is strongly advised not to change this resource. 🚨
  • ExtensionNtfyProc β€” the procedure to call when reading a pixmap file to notify extension loading. It is strongly advised not to change this resource. 🚨
bestie do NOT touch AddColorNtfyProc or ExtensionNtfyProc. the manpage literally says it's strongly advised not to change them. leave them alone, they're doing their job 😭

πŸ‘‘ SEE ALSO πŸ‘‘

  • X(1)
  • Xpm library manual
  • Xlib - C Language X Interface (particularly the section on Manipulating Pixmaps) πŸ’œ

πŸ’€ BUGS πŸ’€

okay bestie, we gotta be real for a sec β€” nothing's perfect, and this icon deserves the truth. here's the tea:

  • the zoomies problem πŸƒβ€β™€οΈπŸ’¨ β€” if you move the pointer too fast while holding a pointer button down, some pixels may be missed. lowkey tragic, but it's not pixmap's fault: this is caused by limitations in how frequently the X server can sample the pointer location. the server just can't keep up with your main character speed, and honestly? relatable.
  • the color clone situation 🎨😭 β€” if you load a pixmap file where the same color is used more than once with different symbols and descriptions, and then write it, you'll lose information concerning the color used more than once. that's a real data-loss moment, so heads up. and like, even the pixmap file plaid given as an example in this man won't be saved that way by pixmap. iconic example, slightly cursed behaviour, we move.
  • athena said no πŸ™…β€β™€οΈβœ¨ β€” accelerators to menu operations don't seem to work with the Athena version. periodt. that's just how it is.
  • the motif focus drama πŸ’…πŸ«  β€” in the Motif version, the Filename... and Resize... commands open their respective dialog window in a strange mode. the user has to voluntary (;-) give the focus to the text widget inside to be able to change its content. yes the (;-) is in the original, yes it's a wink, yes you're gonna have to manually click into that text box like it's 1994. slay i guess.

Copyright 1991,1992,1993,1994 - Lionel Mallet.

that's the whole thing, bestie. intellectual property, protected, iconic.


🌸 AUTHOR 🌸

pixmap by Lionel Mallet - Simulog.

Extension edition and customized Port editor by Tim Wise - SES Inc.

two legends, one absolutely unhinged pixel editor. we stan. πŸ’–


and that's the whole page, bestie!! πŸŽ€ this little manual is from X11, dated February 1994, and it's literally titled PIXMAP(1) β€” a genuine vintage artifact from the era of big hair and bigger monitors. thank you for reading all six parts, you're a real one fr fr. now go make some pixel art and remember: move the mouse slowly while drawing. mwah πŸ’…βœ¨πŸ¦‹

πŸ“¦ where this page comes from