Re: program to run another program
From: Lee Sau Dan (danlee_at_informatik.uni-freiburg.de)
Date: 08/17/05
- Next message: Bob Hauck: "Re: modem 82801DB AC and kernel 2.6.11 up-4GB"
- Previous message: bi-weekly: "A new reader? Welcome to comp.os.linux.misc, read this first if you're new here (FAQ)"
- In reply to: Mike Ballard: "program to run another program"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: 17 Aug 2005 07:54:29 +0800
>>>>> "Mike" == Mike Ballard <dont_w@nt_spam.org> writes:
Mike> This is going to sound loopy but is there any program that
Mike> can run and operate another program's GUI?
No, in general. GUI programs are meant to be "user" friendly, where
"user" != "programmer". Most GUIs are not designed with scriptability
in mind.
Yes, it is possible to write a program to similate mouse clicks and
mouse movements. The challenge is determining where and when and how
to click. You use your brain and the clever vision system to do that
when operating manually. Programmatically, you can't do that
reliably.
Now, you know why I like CLI more? Ease of scriptability!
Few GUI programs (such as GIMP, Emacs) are designed with scriptability
in mind. Sigh...
Mike> I have a ton of jpgs from scans and have discovered that
Mike> loading any into xv and resaving them the file sizes are
Mike> (sometimes) reduced up to 90%. The problem is xv has no
Mike> batch mode and I can't see manually loading/resaving every
Mike> single scan.
The problem is not the problem itself, but the tool you're using.
It's not designed with scriptability in mind.
Why not use a scriptable program that can do what you want? GIMP can
be scripted to do that, provided that you're willing to learn its
Scheme dialect (Scheme is a dialect of LISP).
But why GUI when you're doing batch conversions? What's the point of
displaying those images WYSIWYGly when all you want is just to save
them back to disk immediately? Who is there to see the display?
So, ImageMagick is the tool that suits your needs. install it and
then "man convert" to find out how to use it. You can then write a
simple shell-script, or even 1-liner.
--
Lee Sau Dan §õ¦u´° ~{@nJX6X~}
E-mail: danlee@informatik.uni-freiburg.de
Home page: http://www.informatik.uni-freiburg.de/~danlee
- Next message: Bob Hauck: "Re: modem 82801DB AC and kernel 2.6.11 up-4GB"
- Previous message: bi-weekly: "A new reader? Welcome to comp.os.linux.misc, read this first if you're new here (FAQ)"
- In reply to: Mike Ballard: "program to run another program"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|