mirror of https://github.com/GNOME/gimp.git
Reordered the Script-Fu menus a bit. Feel free to come up with a
better menu structure! Also made sure that all scripts do reset the fg/bg colors and the active brush, pattern and gradient when they are done. --Sven
This commit is contained in:
parent
65e424f36b
commit
0254ae930e
25
ChangeLog
25
ChangeLog
|
@ -1,3 +1,28 @@
|
|||
Sun Dec 19 17:42:32 CET 1999 Sven Neumann <sven@gimp.org>
|
||||
|
||||
* app/menus.c
|
||||
* plug-ins/script-fu/scripts/3dTruchet.scm
|
||||
* plug-ins/script-fu/scripts/addborder.scm
|
||||
* plug-ins/script-fu/scripts/chip-away.scm
|
||||
* plug-ins/script-fu/scripts/circuit.scm
|
||||
* plug-ins/script-fu/scripts/coffee.scm
|
||||
* plug-ins/script-fu/scripts/comic-logo.scm
|
||||
* plug-ins/script-fu/scripts/lava.scm
|
||||
* plug-ins/script-fu/scripts/predator.scm
|
||||
* plug-ins/script-fu/scripts/rendermap.scm
|
||||
* plug-ins/script-fu/scripts/ripply-anim.scm
|
||||
* plug-ins/script-fu/scripts/select_to_image.scm
|
||||
* plug-ins/script-fu/scripts/test-sphere.scm
|
||||
* plug-ins/script-fu/scripts/textured-logo.scm
|
||||
* plug-ins/script-fu/scripts/trochoid.scm
|
||||
* plug-ins/script-fu/scripts/truchet.scm
|
||||
* plug-ins/script-fu/scripts/xach-effect.scm
|
||||
|
||||
Reordered the Script-Fu menus a bit. Feel free to come up with a
|
||||
better menu structure! Also made sure that all scripts do reset the
|
||||
fg/bg colors and the active brush, pattern and gradient when they are
|
||||
done.
|
||||
|
||||
1999-12-19 Michael Natterer <mitch@gimp.org>
|
||||
|
||||
* gimprc.in
|
||||
|
|
|
@ -105,7 +105,6 @@ static gchar G_GNUC_UNUSED *dummy_entries[] =
|
|||
N_("/Filters/Render/Pattern"),
|
||||
N_("/Filters/Misc"),
|
||||
N_("/Script-Fu/Decor"),
|
||||
N_("/Script-Fu/Modify"),
|
||||
N_("/Script-Fu/Utils"),
|
||||
N_("/Script-Fu/Animators"),
|
||||
N_("/Script-Fu/Stencil Ops"),
|
||||
|
|
|
@ -105,7 +105,6 @@ static gchar G_GNUC_UNUSED *dummy_entries[] =
|
|||
N_("/Filters/Render/Pattern"),
|
||||
N_("/Filters/Misc"),
|
||||
N_("/Script-Fu/Decor"),
|
||||
N_("/Script-Fu/Modify"),
|
||||
N_("/Script-Fu/Utils"),
|
||||
N_("/Script-Fu/Animators"),
|
||||
N_("/Script-Fu/Stencil Ops"),
|
||||
|
|
|
@ -105,7 +105,6 @@ static gchar G_GNUC_UNUSED *dummy_entries[] =
|
|||
N_("/Filters/Render/Pattern"),
|
||||
N_("/Filters/Misc"),
|
||||
N_("/Script-Fu/Decor"),
|
||||
N_("/Script-Fu/Modify"),
|
||||
N_("/Script-Fu/Utils"),
|
||||
N_("/Script-Fu/Animators"),
|
||||
N_("/Script-Fu/Stencil Ops"),
|
||||
|
|
|
@ -105,7 +105,6 @@ static gchar G_GNUC_UNUSED *dummy_entries[] =
|
|||
N_("/Filters/Render/Pattern"),
|
||||
N_("/Filters/Misc"),
|
||||
N_("/Script-Fu/Decor"),
|
||||
N_("/Script-Fu/Modify"),
|
||||
N_("/Script-Fu/Utils"),
|
||||
N_("/Script-Fu/Animators"),
|
||||
N_("/Script-Fu/Stencil Ops"),
|
||||
|
|
|
@ -116,6 +116,7 @@
|
|||
(tiledraw2 (car (gimp-layer-new tile size size RGB "Cooper" 100 NORMAL)))
|
||||
(Xindex 0)
|
||||
(Yindex 0)
|
||||
(old-bg (car (gimp-palette-get-background)))
|
||||
)
|
||||
|
||||
(gimp-image-undo-disable img)
|
||||
|
@ -149,6 +150,7 @@
|
|||
|
||||
|
||||
(gimp-image-delete tile)
|
||||
(gimp-palette-set-background old-bg)
|
||||
(gimp-image-undo-enable img)
|
||||
(gimp-display-new img)
|
||||
)
|
||||
|
|
|
@ -162,7 +162,7 @@
|
|||
|
||||
|
||||
(script-fu-register "script-fu-addborder"
|
||||
"<Image>/Script-Fu/Modify/Add Border..."
|
||||
"<Image>/Script-Fu/Decor/Add Border..."
|
||||
"Add a border around an image"
|
||||
"Andy Thomas <alt@picnic.demon.co.uk>"
|
||||
"Andy Thomas"
|
||||
|
|
|
@ -45,8 +45,8 @@
|
|||
(bg-layer (car (gimp-layer-new img width height RGB_IMAGE "Background" 100 NORMAL)))
|
||||
(bump-layer (car (gimp-layer-new img width height RGBA_IMAGE "Bump Layer" 100 NORMAL)))
|
||||
(old-fg (car (gimp-palette-get-foreground)))
|
||||
(old-bg (car (gimp-palette-get-background))))
|
||||
|
||||
(old-bg (car (gimp-palette-get-background)))
|
||||
(old-pattern (car (gimp-patterns-get-pattern))))
|
||||
(gimp-image-undo-disable img)
|
||||
(gimp-image-resize img width height 0 0)
|
||||
(gimp-image-add-layer img bg-layer 1)
|
||||
|
@ -103,6 +103,7 @@
|
|||
(if (= keep-back FALSE)
|
||||
(gimp-image-remove-layer img bg-layer))
|
||||
|
||||
(gimp-patterns-set-pattern old-pattern)
|
||||
(gimp-palette-set-foreground old-fg)
|
||||
(gimp-palette-set-background old-bg)
|
||||
(gimp-image-undo-enable img)
|
||||
|
|
|
@ -40,9 +40,7 @@
|
|||
(type (car (gimp-drawable-type-with-alpha drawable)))
|
||||
(image-width (car (gimp-image-width image)))
|
||||
(image-height (car (gimp-image-height image)))
|
||||
(old-gradient (car (gimp-gradients-get-active)))
|
||||
(old-fg (car (gimp-palette-get-foreground)))
|
||||
(old-bg (car (gimp-palette-get-background))))
|
||||
|
||||
(gimp-image-undo-disable image)
|
||||
(gimp-layer-add-alpha drawable)
|
||||
|
@ -112,8 +110,6 @@
|
|||
FALSE)
|
||||
(gimp-edit-clear active-layer))))
|
||||
|
||||
(gimp-gradients-set-active old-gradient)
|
||||
(gimp-palette-set-background old-bg)
|
||||
(gimp-palette-set-foreground old-fg)
|
||||
|
||||
(if (= keep-selection FALSE)
|
||||
|
@ -125,7 +121,7 @@
|
|||
(gimp-displays-flush)))
|
||||
|
||||
(script-fu-register "script-fu-circuit"
|
||||
"<Image>/Script-Fu/Decor/Circuit..."
|
||||
"<Image>/Script-Fu/Render/Circuit..."
|
||||
"Fills the current selection with something that looks
|
||||
vaguely like a circuit board."
|
||||
"Adrian Likins <adrian@gimp.org>"
|
||||
|
|
|
@ -21,6 +21,7 @@
|
|||
|
||||
(define (script-fu-coffee-stain inImage inLayer inNumber inDark)
|
||||
|
||||
(set! old-gradient (car (gimp-gradients-get-active)))
|
||||
(set! theImage inImage)
|
||||
(set! theHeight (car (gimp-image-height theImage)))
|
||||
(set! theWidth (car (gimp-image-width theImage)))
|
||||
|
@ -49,6 +50,7 @@
|
|||
(gimp-layer-set-offsets theStain (- (rand theWidth) (/ theSize 2)) (- (rand theHeight) (/ theSize 2)) theSize)
|
||||
)
|
||||
(gimp-selection-none theImage)
|
||||
(gimp-gradients-set-active old-gradient)
|
||||
(gimp-displays-flush)
|
||||
)
|
||||
|
||||
|
|
|
@ -28,6 +28,7 @@
|
|||
(bg-layer (car (gimp-layer-new img width height RGBA_IMAGE "Background" 100 NORMAL)))
|
||||
(white-layer (car (gimp-layer-copy text-layer 1)))
|
||||
(black-layer (car (gimp-layer-copy text-layer 1)))
|
||||
(old-gradient (car (gimp-gradients-get-active)))
|
||||
(old-fg (car (gimp-palette-get-foreground)))
|
||||
(old-bg (car (gimp-palette-get-background))))
|
||||
(gimp-image-undo-disable img)
|
||||
|
@ -72,6 +73,7 @@
|
|||
(plug-in-threshold-alpha 1 img text-layer 60)
|
||||
(gimp-layer-set-name text-layer text)
|
||||
(gimp-image-set-active-layer img text-layer)
|
||||
(gimp-gradients-set-active old-gradient)
|
||||
(gimp-palette-set-background old-bg)
|
||||
(gimp-palette-set-foreground old-fg)
|
||||
(gimp-image-undo-enable img)
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
; aklikins@eos.ncsu.edu
|
||||
;
|
||||
; based on a idea by Sven Riedel <lynx@heim8.tu-clausthal.de>
|
||||
; tweaked a little by Sven Neumann <neumanns@uni-duesseldorf.de>
|
||||
; tweaked a bit by Sven Neumann <neumanns@uni-duesseldorf.de>
|
||||
;
|
||||
; This program is free software; you can redistribute it and/or modify
|
||||
; it under the terms of the GNU General Public License as published by
|
||||
|
@ -99,7 +99,7 @@
|
|||
(gimp-displays-flush)))
|
||||
|
||||
(script-fu-register "script-fu-lava"
|
||||
"<Image>/Script-Fu/Decor/Lava..."
|
||||
"<Image>/Script-Fu/Render/Lava..."
|
||||
"Fills the current selection with lava."
|
||||
"Adrian Likins <adrian@gimp.org>"
|
||||
"Adrian Likins"
|
||||
|
|
|
@ -25,18 +25,16 @@
|
|||
|
||||
|
||||
(define (script-fu-predator image
|
||||
drawable
|
||||
edge-amount
|
||||
pixelize
|
||||
pixel-size
|
||||
keep-selection
|
||||
seperate-layer)
|
||||
drawable
|
||||
edge-amount
|
||||
pixelize
|
||||
pixel-size
|
||||
keep-selection
|
||||
seperate-layer)
|
||||
(let* (
|
||||
(type (car (gimp-drawable-type-with-alpha drawable)))
|
||||
(image-width (car (gimp-image-width image)))
|
||||
(image-height (car (gimp-image-height image)))
|
||||
(old-gradient (car (gimp-gradients-get-active)))
|
||||
(old-bg (car (gimp-palette-get-background))))
|
||||
(image-height (car (gimp-image-height image))))
|
||||
|
||||
(gimp-image-undo-disable image)
|
||||
(gimp-layer-add-alpha drawable)
|
||||
|
@ -88,8 +86,6 @@
|
|||
|
||||
; clean up the selection copy
|
||||
(gimp-selection-load active-selection)
|
||||
(gimp-gradients-set-active old-gradient)
|
||||
(gimp-palette-set-background old-bg)
|
||||
|
||||
(if (= keep-selection FALSE)
|
||||
(gimp-selection-none image))
|
||||
|
@ -100,7 +96,7 @@
|
|||
(gimp-displays-flush)))
|
||||
|
||||
(script-fu-register "script-fu-predator"
|
||||
"<Image>/Script-Fu/Decor/Predator..."
|
||||
"<Image>/Script-Fu/Alchemy/Predator..."
|
||||
"Fills the current selection with test"
|
||||
"Adrian Likins <adrian@gimp.org>"
|
||||
"Adrian Likins"
|
||||
|
|
|
@ -21,6 +21,9 @@
|
|||
|
||||
(define (script-fu-render-map inSize inGrain inGrad inWiden)
|
||||
|
||||
(set! old-gradient (car (gimp-gradients-get-active)))
|
||||
(set! old-fg (car (gimp-palette-get-foreground)))
|
||||
(set! old-bg (car (gimp-palette-get-background)))
|
||||
|
||||
(set! theWidth inSize)
|
||||
(set! theHeight inSize)
|
||||
|
@ -51,6 +54,9 @@
|
|||
(gimp-selection-none theImage)
|
||||
(gimp-gradients-set-active inGrad)
|
||||
(plug-in-gradmap TRUE theImage theLayer)
|
||||
(gimp-gradients-set-active old-gradient)
|
||||
(gimp-palette-set-background old-bg)
|
||||
(gimp-palette-set-foreground old-fg)
|
||||
(gimp-display-new theImage)
|
||||
)
|
||||
|
||||
|
|
|
@ -17,7 +17,8 @@
|
|||
(gimp-floating-sel-anchor floating-sel)))
|
||||
|
||||
(define (script-fu-ripply-anim img drawable displacement num-frames)
|
||||
(let* ((width (car (gimp-drawable-width drawable)))
|
||||
(let* ((old-bg (car (gimp-palette-get-background)))
|
||||
(width (car (gimp-drawable-width drawable)))
|
||||
(height (car (gimp-drawable-height drawable)))
|
||||
(ripple-image (car (gimp-image-new width height GRAY)))
|
||||
(ripple-layer (car (gimp-layer-new ripple-image width height GRAY_IMAGE "Ripple Texture" 100 NORMAL))))
|
||||
|
@ -86,6 +87,7 @@
|
|||
|
||||
(gimp-image-undo-enable rippletiled-image)
|
||||
(gimp-image-delete rippletiled-image)
|
||||
(gimp-palette-set-background old-bg)
|
||||
(gimp-image-undo-enable out-imagestack)
|
||||
(gimp-display-new out-imagestack))))
|
||||
|
||||
|
|
|
@ -48,21 +48,21 @@
|
|||
|
||||
(gimp-edit-copy drawable)
|
||||
|
||||
(set! brush-image (car (gimp-image-new selection-width selection-height image-type)))
|
||||
(set! brush-draw (car (gimp-layer-new brush-image selection-width selection-height draw-type "Sloth" 100 NORMAL)))
|
||||
(gimp-image-add-layer brush-image brush-draw 0)
|
||||
(gimp-drawable-fill brush-draw BG-IMAGE-FILL)
|
||||
(set! new-image (car (gimp-image-new selection-width selection-height image-type)))
|
||||
(set! new-draw (car (gimp-layer-new new-image selection-width selection-height draw-type "Selection" 100 NORMAL)))
|
||||
(gimp-image-add-layer new-image new-draw 0)
|
||||
(gimp-drawable-fill new-draw BG-IMAGE-FILL)
|
||||
|
||||
(let ((floating-sel (car (gimp-edit-paste brush-draw FALSE))))
|
||||
(let ((floating-sel (car (gimp-edit-paste new-draw FALSE))))
|
||||
(gimp-floating-sel-anchor floating-sel)
|
||||
)
|
||||
|
||||
(gimp-palette-set-background old-bg)
|
||||
(gimp-image-undo-enable image)
|
||||
(gimp-image-set-active-layer image drawable)
|
||||
(gimp-display-new brush-image)
|
||||
(gimp-display-new new-image)
|
||||
(gimp-displays-flush)
|
||||
(script-fu-export-file 1 img drawable RGB 255 FALSE 2 "-export" "png")
|
||||
; (script-fu-export-file 1 img drawable RGB 255 FALSE 2 "-export" "png")
|
||||
|
||||
))
|
||||
|
||||
|
|
|
@ -48,21 +48,21 @@
|
|||
|
||||
(gimp-edit-copy drawable)
|
||||
|
||||
(set! brush-image (car (gimp-image-new selection-width selection-height image-type)))
|
||||
(set! brush-draw (car (gimp-layer-new brush-image selection-width selection-height draw-type "Sloth" 100 NORMAL)))
|
||||
(gimp-image-add-layer brush-image brush-draw 0)
|
||||
(gimp-drawable-fill brush-draw BG-IMAGE-FILL)
|
||||
(set! new-image (car (gimp-image-new selection-width selection-height image-type)))
|
||||
(set! new-draw (car (gimp-layer-new new-image selection-width selection-height draw-type "Selection" 100 NORMAL)))
|
||||
(gimp-image-add-layer new-image new-draw 0)
|
||||
(gimp-drawable-fill new-draw BG-IMAGE-FILL)
|
||||
|
||||
(let ((floating-sel (car (gimp-edit-paste brush-draw FALSE))))
|
||||
(let ((floating-sel (car (gimp-edit-paste new-draw FALSE))))
|
||||
(gimp-floating-sel-anchor floating-sel)
|
||||
)
|
||||
|
||||
(gimp-palette-set-background old-bg)
|
||||
(gimp-image-undo-enable image)
|
||||
(gimp-image-set-active-layer image drawable)
|
||||
(gimp-display-new brush-image)
|
||||
(gimp-display-new new-image)
|
||||
(gimp-displays-flush)
|
||||
(script-fu-export-file 1 img drawable RGB 255 FALSE 2 "-export" "png")
|
||||
; (script-fu-export-file 1 img drawable RGB 255 FALSE 2 "-export" "png")
|
||||
|
||||
))
|
||||
|
||||
|
|
|
@ -108,6 +108,8 @@
|
|||
(text-extents (gimp-text-get-extents-fontname text size PIXELS font))
|
||||
(x-position (- cx (/ (car text-extents) 2)))
|
||||
(y-position (- cy (/ (cadr text-extents) 2)))
|
||||
(old-pattern (car (gimp-patterns-get-pattern)))
|
||||
(old-gradient (car (gimp-gradients-get-active)))
|
||||
(old-fg (car (gimp-palette-get-foreground)))
|
||||
(old-bg (car (gimp-palette-get-background))))
|
||||
(gimp-image-undo-disable img)
|
||||
|
@ -148,6 +150,8 @@
|
|||
size PIXELS
|
||||
font)))
|
||||
|
||||
(gimp-gradients-set-active old-gradient)
|
||||
(gimp-patterns-set-pattern old-pattern)
|
||||
(gimp-palette-set-background old-bg)
|
||||
(gimp-palette-set-foreground old-fg)
|
||||
(gimp-image-undo-enable img)
|
||||
|
|
|
@ -24,7 +24,8 @@
|
|||
(drop-shadow-layer (car (gimp-layer-new img width height RGBA_IMAGE "Drop Shadow" 100 MULTIPLY)))
|
||||
(dsl-layer-mask (car (gimp-layer-create-mask drop-shadow-layer BLACK-MASK)))
|
||||
(old-fg (car (gimp-palette-get-foreground)))
|
||||
(old-bg (car (gimp-palette-get-background))))
|
||||
(old-bg (car (gimp-palette-get-background)))
|
||||
(old-pattern (car (gimp-patterns-get-pattern))))
|
||||
(gimp-image-undo-disable img)
|
||||
(gimp-image-resize img width height 0 0)
|
||||
(gimp-image-add-layer img shadow-layer 1)
|
||||
|
@ -70,6 +71,7 @@
|
|||
(gimp-image-remove-layer-mask img drop-shadow-layer APPLY)
|
||||
(gimp-selection-none img)
|
||||
(gimp-layer-set-name text-layer text)
|
||||
(gimp-patterns-set-pattern old-pattern)
|
||||
(gimp-palette-set-foreground old-fg)
|
||||
(gimp-palette-set-background old-bg)
|
||||
(gimp-image-undo-enable img)
|
||||
|
|
|
@ -331,7 +331,6 @@
|
|||
background-color
|
||||
stroke-overwrite brush-opacity paint-mode))))
|
||||
;; start of script-fu-trochoid
|
||||
(gimp-brushes-set-brush (car brush-details))
|
||||
(let* ((base-radius (floor (abs base-radius-f))) ; to int
|
||||
(wheel-radius (floor wheel-radius-f)) ; to int
|
||||
(total-step-num (if (or (= 0 base-radius) (= 0 wheel-radius))
|
||||
|
@ -350,7 +349,9 @@
|
|||
(layer-paint-mode 0)
|
||||
(the-layer #f)
|
||||
(old-paint-mode (car (gimp-brushes-get-paint-mode)))
|
||||
(old-brush (car (gimp-brushes-get-brush)))
|
||||
(old-rgb (car (gimp-palette-get-foreground))))
|
||||
(gimp-brushes-set-brush (car brush-details))
|
||||
(gimp-image-undo-disable img)
|
||||
(gimp-image-add-layer img BG-layer 0)
|
||||
(gimp-edit-fill BG-layer)
|
||||
|
@ -377,6 +378,7 @@
|
|||
base-radius wheel-radius pen-pos hue-rate
|
||||
layer-paint-mode (= 0 erase-before-draw) brush-details))
|
||||
(gimp-palette-set-foreground old-rgb)
|
||||
(gimp-brushes-set-brush old-brush)
|
||||
(gimp-brushes-set-paint-mode old-paint-mode)
|
||||
(gimp-image-undo-enable img)
|
||||
(gimp-displays-flush)))
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
; The GIMP -- an image manipulation program
|
||||
; Copyright (C) 1995 Spencer Kimball and Peter Mattis
|
||||
;
|
||||
|
@ -104,6 +103,7 @@
|
|||
(tiledraw2 (car (gimp-layer-new tile size size RGB "Cooper" 100 NORMAL)))
|
||||
(Xindex 0)
|
||||
(Yindex 0)
|
||||
(old-bg (car (gimp-palette-get-background)))
|
||||
)
|
||||
|
||||
(gimp-image-undo-disable img)
|
||||
|
@ -137,6 +137,7 @@
|
|||
|
||||
|
||||
(gimp-image-delete tile)
|
||||
(gimp-palette-set-background old-bg)
|
||||
(gimp-image-undo-enable img)
|
||||
(gimp-display-new img)
|
||||
)
|
||||
|
|
|
@ -111,7 +111,7 @@
|
|||
(gimp-displays-flush)))
|
||||
|
||||
(script-fu-register "script-fu-xach-effect"
|
||||
"<Image>/Script-Fu/Decor/Xach-Effect..."
|
||||
"<Image>/Script-Fu/Shadow/Xach-Effect..."
|
||||
"Add a subtle translucent 3-d effect to the current selection or alpha channel"
|
||||
"Adrian Likins <adrian@gimp.org>"
|
||||
"Adrian Likins"
|
||||
|
|
Loading…
Reference in New Issue