Difference between revisions of "GIMP"
m (→Script-Fu GIMP Script) |
m (→Script-Fu GIMP Script) |
||
Line 73: | Line 73: | ||
*Copy either arrow.scm or arrow_V3.scm into /usr/share/gimp/2.0/scripts | *Copy either arrow.scm or arrow_V3.scm into /usr/share/gimp/2.0/scripts | ||
The scm file you use depends on your version of Gimp. The arrow_V3.scm should check that you are running V2.99.14 or later. If you are using GIMP V2.10.x you need to use file arrow.scm. | The scm file you use depends on your version of Gimp. The arrow_V3.scm should check that you are running V2.99.14 or later. If you are using GIMP V2.10.x you need to use file arrow.scm. | ||
− | |||
− | |||
To use the arrow script you have to "create paths." If you are not familiar with creating paths start by making sure you select the "Paths Tool" which is different from the Paintbrush tool. | To use the arrow script you have to "create paths." If you are not familiar with creating paths start by making sure you select the "Paths Tool" which is different from the Paintbrush tool. | ||
Line 82: | Line 80: | ||
# On Gimp menu click Tools -> Arrow -> Arrow | # On Gimp menu click Tools -> Arrow -> Arrow | ||
* The arrow head will appear on the first click point you made in your path! | * The arrow head will appear on the first click point you made in your path! | ||
+ | * It is recommended you take some time to get familiar with the Paths Tool. | ||
+ | |||
+ | Script '''arrow.scm''' by ''Berengar W. Lehr'' last revision '''13/10/2022''' is verified to work on '''Gimp version 2.10.30''' and is pretty slick to boot! | ||
==Annoyances== | ==Annoyances== |
Revision as of 19:45, 27 October 2023
GIMP is a full featured graphic / image / photo editing software set of programs and tools similar in use or functionality to Adobe Photoshop. GIMP (GNU Image Manipulation Program) is extensive enough that its own wiki page can be devoted to the software tools.
Gimp / GIMP (technically all upper case) will provide for you nearly all of the features and tools available in the expensive commercial software package Adobe Photoshop with the exception that GIMP is absolutely free. Also, unlike Adobe Photoshop, GIMP is cross-platform and open source. You can run GIMP under Linux, Windows, and MacOS. Many Linux distributions include GIMP as a part of their desktop operating systems, including Fedora and Debian.
Tools used to perform image editing can be accessed via the toolbox, through menus and dialogue windows. They include filters and brushes, as well as transformation, selection, layer and masking tools.
GIMP uses an interface made up of multiple independent windows, which can be confusing for some users. You can toggle between the default multi-window mode and the new single-window mode in GIMP 2.8 and newer through the Single-window mode checkbox in the Windows menu. In single-window mode, GIMP will put dockable dialogs and images in a single, tabbed image window. The default windows were: Toolbox (left), Main Image (middle), Layers and Brushes (right). In single window mode all three are contained within the Main Image window, which is more consistent with the user experience of Microsoft Windows software.
Contents
Customize
- CLICK Windows -> Single Window Mode (you will see a check symbol next to the label once selected)
GIMP 2.10.0 and newer have an updated interface. Most annoying is that the GIMP devs are trying to be more like Adobe Photoshop. This is a sad problem with the entire FOSS community trying to be more like the stuff the rest of us want to get away from....
You can restore the old interface colors and theme to some extent:
- CLICK Edit -> Preferences -> and under the Interface heading choose "Theme" -> Select the System theme.
- CLICK Edit -> Preferences -> and under the Interface heading choose "Icon Theme" -> Select the Legacy theme.
To remove a dialogue, select the same arrow symbol and choose Close Tab.
To move a dialog to a different dock, simply click and drag the dialog tab and release it in the heading area of any dock you choose.
Usage Help
Gimp works differently than other popular image manipulation software. This is because linux developers can be snobs rather than accommodating. Yes, it hurts linux, but because they think their way is best, we have to learn their way, even if it takes more time and mouse clicks.
- HOWTO: STRAIGHT LINE --- You can use pencil, paintbrush, eraser, airbrush, etc: Click and create a single dot -> hold down and maintain shift -> move to direct line -> click to complete line.
- HOWTO: ROTATE LAYER DEGREES --- Arbitrary Rotation: You can access this command from the image menubar through Layer → Transform → Arbitrary Rotation, or by using the keyboard shortcut Shift+R. THEN you might have to: Layer -> Transparency -> Remove Alpha Channel (if you're working with a simple 1 layer image and you want to restore the background.)
- HOWTO: CHANGE COLOR DEPTH --- Color Depth to 1-bit BW: Image -> Mode -> Indexed -> choose "Use black and white 1-bit palette)
- HOWTO: MOVE ACTIVE LAYER IMAGE ONLY --- Moving TEXT or an IMAGE layer: when I attempt to move text or an image in the active layer, gimp either moves the wrong layer or background layer, very stupid and annoying. SOLUTION: Hold SHIFT KEY while using the MOVE TOOL which forces Gimp to work with the current selected layer.
- HOWTO: MOVE SELECTION ONLY --- I select part of an image and when I use the move tool, it moves all of the layer. #$%! SOLUTION: Right click your selection and in the menu, select "Select -> Float." Ctrl+Shift+L Also, this makes it a temporary floating layer, so when you place it, you have to use the layers interface and "Anchor Layer" when done.
- HOWTO: REPLACE COLOR WITH ANOTHER --- In Paint Shop Pro you could select a color with the dropper and exchange it with another. With Gimp it is called the Color Exchange Function. Goto the Menu Colors -> Map -> Color Exchange and then either select the color from the preview picture using the color picker tool or just define the color to replace and the new color manually. Bug: If you have an alpha transparency you will see two tone gray squares to represent the transparency. Gimp color exchange lets you select them as if they were actual RGB colors in the image, which can be confusing, and is a programming oversight by the gimp developers as it should treat the squares as no color.
- HOWTO: COPY SELECT, PAST INTO IMAGE AND MOVE TO POSITION --- Use selection tool and create a selection. Press CTRL-C to copy then CTRL-V to paste. Choose the MOVE tool and make sure the MOVE tool is set to MOVE LAYER with Pick a Layer or Guide. Those are under the Tool Options which you should see in an area of the interface on the left center of the screen. Using the move tool you should not be able to move and place the pasted selection. After it is placed you can click anywhere outside of the selection to anchor it down, or CTRL-V again to get another copy of the selection to move and place. Basically, the extra step that PSP users aren't accustomed to involves switching to the MOVE TOOL after pasting.
- HOWTO: EDIT PALETTE IN AN INDEXED IMAGE --- use the Colormap dialog. Upper right of the interface is the dockable dialogs where you will see small tabs each to a dockable dialog. One of the dockable dialogs is Colormap, the tab symbol being four squares of colors. If the dockable dialog is not present goto WINDOWS -> DOCKABLE DIALOGS -> colormap. In the colormap dockable dialog click the color square to edit the color in the palette of the indexed image.
Anti-Aliasing
Anti-aliasing is a feature used to render smoother textures to otherwise jagged edges of an object by sampling pixels and overlapping colors from adjacent pixels, thereby rendering a smoother texture to the object. This is commonly the default for tools such as the Text Tool in The Gimp. In the Text Tool the common user typically wants this feature enabled. That's fine, and expected. However, when selecting an area of the image to crop, it is not typical to have anti-aliasing enabled.
Anti-Aliasing on the Selection Tools: The surge of Gimp, why the hell do the devs enable this PITA feature by default? For example, when you make a selection with the Ellipse Select Tool, anti aliasing is enabled by default. You won't notice it until later when you see a scum around the part of the image you cropped away and tried to fill with another color. Good grief! This is something most people would NOT want by default. You can tell devs are not application users.
Selection Tools
The four selection tools each have their own checkbox for anti-aliasing. You have to manually uncheck it for each tool prior to making the selection. If you noticed it too late, and try to use the UNDO tool then recrop with the same selection the software will not disable anti-aliasing even if you have it unchecked, another blunder by the Gimp devs.
Image Scaling
To be able to rotate, deform or scale a floating selection with the corresponding tools we have to set Interpolation to None in the Tool Options to avoid anti-aliasing.
Brush Tools
The Paintbrush Tool "P" will have anti-aliasing enabled and only the brush hardness can have any impact on this. When using the Pencil Tool "N" you can use a brush with no alpha channel.
Adding Brushes
You can add additional brushes, which is to say that using the brush tool allows you different shaped brushes. One useful example is the shape of an arrow. The web site https://www.gimphelp.org/ has been around over 20 years and the creator has many free brushes you can download and use.
Example: Brushes BW 2
After downloading the arrow brushes and extracting them into a directory, you can move them into the place where Gimp will detect them on launch. Make sure you exit Gimp before doing this.
mkdir /usr/share/gimp/2.0/brushes/arrows cp ~/arrow_brushes_BW_2/*.gbr /usr/share/gimp/2.0/brushes/arrows
Replace ~/arrow_brushes_BW_2/ with the location of the extracted gbr files.
Script-Fu GIMP Script
Another way to create arrows is using the Gimp scripting capabilities. drawing arrow lines is just one example of using script capabilities. In this example we will use arrow.scm Script-Fu GIMP Script originally written by B-Ranger.
- Exit Gimp.
- Copy either arrow.scm or arrow_V3.scm into /usr/share/gimp/2.0/scripts
The scm file you use depends on your version of Gimp. The arrow_V3.scm should check that you are running V2.99.14 or later. If you are using GIMP V2.10.x you need to use file arrow.scm.
To use the arrow script you have to "create paths." If you are not familiar with creating paths start by making sure you select the "Paths Tool" which is different from the Paintbrush tool.
- click on the Paths Tool
- make sure the Paths Tool is set to "Design" for the paths edit mode
- on canvas using Paths Tool you will have to make 3 total clicks! First is where the head of the arrow will appear. Second and Third define the tail direction. For the second and third click if you do them in the same spot then you will have a straight arrow.
- On Gimp menu click Tools -> Arrow -> Arrow
- The arrow head will appear on the first click point you made in your path!
- It is recommended you take some time to get familiar with the Paths Tool.
Script arrow.scm by Berengar W. Lehr last revision 13/10/2022 is verified to work on Gimp version 2.10.30 and is pretty slick to boot!
Annoyances
Pick a layer or guide
"Pick a layer or guide" is the default option under the "Move Tool Options" and should actually be changed to "Move the active layer." This makes more sense when you are trying to position something within the layer you've selected.
Assumed Antialiasing Everywhere
Antialiasing always selected by default - This is so annoying. There are a number of tools that show this by default. Some are: Ellipse Select Tool, Free Select Tool, Scissors Select Tool, Fuzzy Select Tool, Select by Color Tool, Bucket Fill Tool, and Text Tool. Im sure there are more. The default status needs to be configurable. On newer versions I have success in retaining the preference of having Anti Aliasing unchecked for most of these by going to:
- Edit -> Preferences -> Tool Options and saving the tool options or having it do so on exit.
- Edit -> Preferences -> Dialog Defaults -> (1) Fill Selection and (2) Stroke Selection - uncheck antialiasing
BUG: (2.10.30) In the Dialog Defaults, when "antialiasing" is unchecked under Stroke Selection and Stroke Path Dialogs, the changes will not be retained. Next time you go into the dialog it will be checked again!
Now Necessary to Manually Add Alpha Channel to Layers
- No alpha channel in subsequent layers as a default - Sometimes cutting from layers fills with white - When you cut from a layer above another, the current layer should contain a transparency where content was removed revealing image from underlying layer given that layer visually enabled. Sometimes Gimp does not do this and instead FILLS the cut area with a color or white. This is a change that we first noticed in version 2.10.30. In older versions, when you select and cut a section from a layer that is on top of another, what is in the layer behind it will become visible, which is the expected reasonable behavior. Now, when you cut from the top layer you will see a filled selection of (foreground) color (typically white) which is stupid. You have to manually add an alpha layer before you cut the selection in order to reveal what is underneath.
to resolve:
- Layer -> Transparency -> Add alpha channel
New Text on New Image is Vertical or Rotated
An annoying nasty little feature of Gimp now is that it will retain any rotation setting you applied to the text tool on last use, even on a new document. So, if three months ago you added rotated text to an image, from now on and on all new images the text tool will default to that rotation unless you change it back and Gimp saves the new setting before it crashes.
to Rotate or remove any rotation setting:
- Right click within the text box on your image (where your text appears rotated)
- select "left-to-right" from the drop down context menu
Error: Couldn't simply reduce colors further. Exporting as opaque.
Even though you have reduced the color depth to 256 prior to trying to save your image as a GIF with a transparent background, it will not succeed.
The error indicates Gimp cannot find a a free color slot to create a transparency, which it sees as another color.
Resolution: Even though Gif is a 256 color pallet, you must use an index of 255 colors.
- Image -> Mode -> Indexed (Maximum number of colors: 255)
Support
Paint Shop Pro import plugin
This plugin is crap. It fails to import traditional Jasc PSP files. It might be fine for doing a specific PSP format from the Corel days.
Gimp will not open Paint Shop Pro PSP files and with the plugin it still probably won't open your PSP file.
Workaround: For Linux perhaps the most dynamic and best available tool for this is called XnView and seems to be able to open practically any graphic file format out there with very few exceptions.