see plug-ins/perl/Changes

This commit is contained in:
Marc Lehmann 1999-07-13 16:09:23 +00:00
parent 6994f8467a
commit bf952c65c2
7 changed files with 56 additions and 19 deletions

View File

@ -2,6 +2,12 @@ Revision history for Gimp-Perl extension.
- updated perlotine. - updated perlotine.
- updated pixelmap with stub documentation. - updated pixelmap with stub documentation.
- redim_pdl calls affine_new directly rather than via the
perl interpreter -> smaller Perl-Server, faster operation.
- try to uninstall. Of course this doesn't work here, so just
trust it will work elsewhere.
- improved yinyang for the perl calendar ;)
- added perl_fu_ as prefix for Image, Drawables and Channels.
1.096 Thu Jul 8 21:36:36 CEST 1999 1.096 Thu Jul 8 21:36:36 CEST 1999
- fix around PDL-2.002 exporting its own ppport.h. - fix around PDL-2.002 exporting its own ppport.h.

View File

@ -482,11 +482,11 @@ sub _pseudoclass {
push(@{"$class\::PREFIXES"} , @prefixes); @prefixes=@{"$class\::PREFIXES"}; push(@{"$class\::PREFIXES"} , @prefixes); @prefixes=@{"$class\::PREFIXES"};
} }
_pseudoclass qw(Layer gimp_layer_ gimp_drawable_ gimp_floating_sel_ gimp_image_ gimp_ plug_in_); _pseudoclass qw(Layer gimp_layer_ gimp_drawable_ gimp_floating_sel_ gimp_image_ gimp_ plug_in_ perl_fu_);
_pseudoclass qw(Image gimp_image_ gimp_drawable_ gimp_ plug_in_); _pseudoclass qw(Image gimp_image_ gimp_drawable_ gimp_ plug_in_ perl_fu_);
_pseudoclass qw(Drawable gimp_drawable_ gimp_layer_ gimp_channel_ gimp_image_ gimp_ plug_in_); _pseudoclass qw(Drawable gimp_drawable_ gimp_layer_ gimp_channel_ gimp_image_ gimp_ plug_in_ perl_fu_);
_pseudoclass qw(Selection gimp_selection_); _pseudoclass qw(Selection gimp_selection_);
_pseudoclass qw(Channel gimp_channel_ gimp_drawable_ gimp_selection_ gimp_image_ gimp_ plug_in_); _pseudoclass qw(Channel gimp_channel_ gimp_drawable_ gimp_selection_ gimp_image_ gimp_ plug_in_ perl_fu_);
_pseudoclass qw(Display gimp_display_ gimp_); _pseudoclass qw(Display gimp_display_ gimp_);
_pseudoclass qw(Plugin plug_in_); _pseudoclass qw(Plugin plug_in_);
_pseudoclass qw(Gradients gimp_gradients_); _pseudoclass qw(Gradients gimp_gradients_);

View File

@ -84,8 +84,6 @@ static void need_pdl (void)
{ {
/* the perl-server can't be bothered to do this itself! */ /* the perl-server can't be bothered to do this itself! */
perl_require_pv ("PDL::Core"); perl_require_pv ("PDL::Core");
/* required for kludgy redim_pdl */
perl_require_pv ("PDL::Slices");
/* Get pointer to structure of core shared C routines */ /* Get pointer to structure of core shared C routines */
if (!(CoreSV = perl_get_sv("PDL::SHARE",FALSE))) if (!(CoreSV = perl_get_sv("PDL::SHARE",FALSE)))
@ -132,16 +130,26 @@ static void pixel_rgn_pdl_delete_data (pdl *p, int param)
/* please optimize! */ /* please optimize! */
static pdl *redim_pdl (pdl *p, int ndim, int newsize) static pdl *redim_pdl (pdl *p, int ndim, int newsize)
{ {
SV *sv; pdl *r = PDL->null ();
char reslice[512]; AV *dims, *dimincs;
int i;
sprintf (reslice,"$Gimp::_pdl->slice('%s0:%d')",(ndim ? "," : ""),newsize); dims = newAV ();
dimincs = newAV ();
PDL->SetSV_PDL (perl_get_sv ("Gimp::_pdl", TRUE), p); for (i = 0; i < p->ndims; i++)
if (!(sv = perl_eval_pv (reslice,1))) {
croak ("FATAL: reslicing did not return a value! Please report!"); av_push (dims , newSViv (p->dims [i]));
av_push (dimincs, newSViv (p->dimincs[i]));
}
return PDL->SvPDLV (sv); sv_setiv (*av_fetch (dims, ndim, 0), newsize);
PDL->affine_new (p, r, 0,
sv_2mortal (newRV_noinc ((SV*)dims)),
sv_2mortal (newRV_noinc ((SV*)dimincs)));
return r;
} }
#endif #endif

View File

@ -98,6 +98,7 @@ that are checked are shown as well (the null prefix "" is implicit).
gimp_image_ gimp_image_
gimp_ gimp_
plug_in_ plug_in_
perl_fu_
=item Image =item Image
@ -105,6 +106,7 @@ that are checked are shown as well (the null prefix "" is implicit).
gimp_drawable_ gimp_drawable_
gimp_ gimp_
plug_in_ plug_in_
perl_fu_
=item Drawable =item Drawable
@ -113,6 +115,7 @@ that are checked are shown as well (the null prefix "" is implicit).
gimp_image_ gimp_image_
gimp_ gimp_
plug_in_ plug_in_
perl_fu_
=item Selection =item Selection
@ -126,6 +129,7 @@ that are checked are shown as well (the null prefix "" is implicit).
gimp_image_ gimp_image_
gimp_ gimp_
plug_in_ plug_in_
perl_fu_
=item Display =item Display

View File

@ -115,9 +115,10 @@ EOF
($major,$minor,$patch)=split /[._]/,$Gtk::VERSION; ($major,$minor,$patch)=split /[._]/,$Gtk::VERSION;
sub MY::install { sub MY::install {
my $self=shift;
package MY; package MY;
my $install = shift->SUPER::install(@_); my $install = $self->SUPER::install(@_);
($install =~ s/^install\b/really-install/m) or return $install; ($install =~ s/^(un)?install\b/really-$1install/gm) or return $install;
' '
install :: install ::
@for dir in \ @for dir in \
@ -144,7 +145,9 @@ install ::
} }
sub MY::postamble { sub MY::postamble {
my $self=shift;
my $GT = $IN_GIMP ? '$(INSTALL_PROGRAM)' : "$GIMPTOOL --install-admin-bin"; my $GT = $IN_GIMP ? '$(INSTALL_PROGRAM)' : "$GIMPTOOL --install-admin-bin";
my $UT = $IN_GIMP ? '$(RM_F)' : "$GIMPTOOL --uninstall-admin-bin";
my $GT2 = $IN_GIMP ? '$(gimpplugindir)/plug-ins/' : ''; my $GT2 = $IN_GIMP ? '$(gimpplugindir)/plug-ins/' : '';
my $postamble=" my $postamble="
@ -175,6 +178,18 @@ install-plugins ::
$GT \"\$\$plugin\" $GT2 ; \\ $GT \"\$\$plugin\" $GT2 ; \\
done done
\$(RM_RF) inst-temp \$(RM_RF) inst-temp
uninstall :: force_uninstall_from_\$(INSTALLDIRS)dirs
for plugin in Perl-Server @examples; do \\
$UT $GT2\$\$plugin; \\
done
force_uninstall_from_perldirs ::
\$(PERL) -MExtUtils::Install -e 'uninstall(\$\$ARGV[0],1,0)' ".$self->catfile('$(PERL_ARCHLIB)','auto','$(FULLEXT)','.packlist')."
force_uninstall_from_sitedirs ::
\$(PERL) -MExtUtils::Install -e 'uninstall(\$\$ARGV[0],1,0)' ".$self->catfile('$(SITEARCHEXP)','auto','$(FULLEXT)','.packlist')."
"; ";
} }

View File

@ -11,9 +11,10 @@ make test TEST_VERBOSE=1
bugs bugs
* replöace examples/pixemap pod by (.*) and watch it die! * replöace examples/pixemap pod by (.*) and watch it die!
* empty desfiption -> no display in PDB?`
* make uninstall is actually a concern: make it work * make uninstall is actually a concern: make it work
[DONE] * PF_TEXT has no Load/Save buttons [DONE] * PF_TEXT has no Load/Save buttons
* Christian Soeller told me its easy: apply the affine transformation from C [DONE] * Christian Soeller told me its easy: apply the affine transformation from C
* podestions are not expanded in dialog help strings etc.. * podestions are not expanded in dialog help strings etc..
* Document spawn_options in Gimp::Net. * Document spawn_options in Gimp::Net.
* Selection => To Brush. * Selection => To Brush.

View File

@ -65,8 +65,8 @@ sub yinyang {
# Finish up # Finish up
gimp_palette_set_foreground($oldcolor); gimp_palette_set_foreground($oldcolor);
gimp_selection_none($img); gimp_selection_none($img);
gimp_display_new($img);
gimp_displays_flush(); $img;
} }
# This subroutine inserts an "eye" (a dot in the center of the cicular # This subroutine inserts an "eye" (a dot in the center of the cicular
@ -106,7 +106,7 @@ register("yinyang", "Render a stand-alone Yin/Yang image",
"Renders a black-and-white Yin/Yang symbol optionally "Renders a black-and-white Yin/Yang symbol optionally
with \"eyes\" that may optionally be images.", with \"eyes\" that may optionally be images.",
"Aaron Sherman", "(c) 1998, Aaron Sherman", "Aaron Sherman", "(c) 1998, Aaron Sherman",
"1999a", "<Toolbox>/Xtns/Render/Yin-Yang", "*", "1999b", "<Toolbox>/Xtns/Render/Yin-Yang", "*",
[ [
[PF_INT32, "width", "Width", 256], [PF_INT32, "width", "Width", 256],
[PF_INT32, "height", "Height", 256], [PF_INT32, "height", "Height", 256],
@ -116,6 +116,9 @@ register("yinyang", "Render a stand-alone Yin/Yang image",
[PF_STRING, "aobttom_eye_filename", "eye 2", ""], [PF_STRING, "aobttom_eye_filename", "eye 2", ""],
[PF_TOGGLE, "anti_aliasing", "", 1] [PF_TOGGLE, "anti_aliasing", "", 1]
], ],
[
[PF_IMAGE, "image", "Resulting Image"],
],
\&yinyang); \&yinyang);
exit main; exit main;