Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features.
BUG:215923 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdetoys@1054174 283d02a7-25f6-0310-bc7c-ecb5cbfe19dav3.5.13-sru
@ -0,0 +1,4 @@
|
||||
|
||||
Look in the subdirs to get infos about the authors.
|
||||
|
||||
The package is maintained by Stephan Kulow <coolo@kde.org>
|
@ -0,0 +1,397 @@
|
||||
GNU Free Documentation License
|
||||
Version 1.2, November 2002
|
||||
|
||||
|
||||
Copyright (C) 2000,2001,2002 Free Software Foundation, Inc.
|
||||
51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
Everyone is permitted to copy and distribute verbatim copies
|
||||
of this license document, but changing it is not allowed.
|
||||
|
||||
|
||||
0. PREAMBLE
|
||||
|
||||
The purpose of this License is to make a manual, textbook, or other
|
||||
functional and useful document "free" in the sense of freedom: to
|
||||
assure everyone the effective freedom to copy and redistribute it,
|
||||
with or without modifying it, either commercially or noncommercially.
|
||||
Secondarily, this License preserves for the author and publisher a way
|
||||
to get credit for their work, while not being considered responsible
|
||||
for modifications made by others.
|
||||
|
||||
This License is a kind of "copyleft", which means that derivative
|
||||
works of the document must themselves be free in the same sense. It
|
||||
complements the GNU General Public License, which is a copyleft
|
||||
license designed for free software.
|
||||
|
||||
We have designed this License in order to use it for manuals for free
|
||||
software, because free software needs free documentation: a free
|
||||
program should come with manuals providing the same freedoms that the
|
||||
software does. But this License is not limited to software manuals;
|
||||
it can be used for any textual work, regardless of subject matter or
|
||||
whether it is published as a printed book. We recommend this License
|
||||
principally for works whose purpose is instruction or reference.
|
||||
|
||||
|
||||
1. APPLICABILITY AND DEFINITIONS
|
||||
|
||||
This License applies to any manual or other work, in any medium, that
|
||||
contains a notice placed by the copyright holder saying it can be
|
||||
distributed under the terms of this License. Such a notice grants a
|
||||
world-wide, royalty-free license, unlimited in duration, to use that
|
||||
work under the conditions stated herein. The "Document", below,
|
||||
refers to any such manual or work. Any member of the public is a
|
||||
licensee, and is addressed as "you". You accept the license if you
|
||||
copy, modify or distribute the work in a way requiring permission
|
||||
under copyright law.
|
||||
|
||||
A "Modified Version" of the Document means any work containing the
|
||||
Document or a portion of it, either copied verbatim, or with
|
||||
modifications and/or translated into another language.
|
||||
|
||||
A "Secondary Section" is a named appendix or a front-matter section of
|
||||
the Document that deals exclusively with the relationship of the
|
||||
publishers or authors of the Document to the Document's overall subject
|
||||
(or to related matters) and contains nothing that could fall directly
|
||||
within that overall subject. (Thus, if the Document is in part a
|
||||
textbook of mathematics, a Secondary Section may not explain any
|
||||
mathematics.) The relationship could be a matter of historical
|
||||
connection with the subject or with related matters, or of legal,
|
||||
commercial, philosophical, ethical or political position regarding
|
||||
them.
|
||||
|
||||
The "Invariant Sections" are certain Secondary Sections whose titles
|
||||
are designated, as being those of Invariant Sections, in the notice
|
||||
that says that the Document is released under this License. If a
|
||||
section does not fit the above definition of Secondary then it is not
|
||||
allowed to be designated as Invariant. The Document may contain zero
|
||||
Invariant Sections. If the Document does not identify any Invariant
|
||||
Sections then there are none.
|
||||
|
||||
The "Cover Texts" are certain short passages of text that are listed,
|
||||
as Front-Cover Texts or Back-Cover Texts, in the notice that says that
|
||||
the Document is released under this License. A Front-Cover Text may
|
||||
be at most 5 words, and a Back-Cover Text may be at most 25 words.
|
||||
|
||||
A "Transparent" copy of the Document means a machine-readable copy,
|
||||
represented in a format whose specification is available to the
|
||||
general public, that is suitable for revising the document
|
||||
straightforwardly with generic text editors or (for images composed of
|
||||
pixels) generic paint programs or (for drawings) some widely available
|
||||
drawing editor, and that is suitable for input to text formatters or
|
||||
for automatic translation to a variety of formats suitable for input
|
||||
to text formatters. A copy made in an otherwise Transparent file
|
||||
format whose markup, or absence of markup, has been arranged to thwart
|
||||
or discourage subsequent modification by readers is not Transparent.
|
||||
An image format is not Transparent if used for any substantial amount
|
||||
of text. A copy that is not "Transparent" is called "Opaque".
|
||||
|
||||
Examples of suitable formats for Transparent copies include plain
|
||||
ASCII without markup, Texinfo input format, LaTeX input format, SGML
|
||||
or XML using a publicly available DTD, and standard-conforming simple
|
||||
HTML, PostScript or PDF designed for human modification. Examples of
|
||||
transparent image formats include PNG, XCF and JPG. Opaque formats
|
||||
include proprietary formats that can be read and edited only by
|
||||
proprietary word processors, SGML or XML for which the DTD and/or
|
||||
processing tools are not generally available, and the
|
||||
machine-generated HTML, PostScript or PDF produced by some word
|
||||
processors for output purposes only.
|
||||
|
||||
The "Title Page" means, for a printed book, the title page itself,
|
||||
plus such following pages as are needed to hold, legibly, the material
|
||||
this License requires to appear in the title page. For works in
|
||||
formats which do not have any title page as such, "Title Page" means
|
||||
the text near the most prominent appearance of the work's title,
|
||||
preceding the beginning of the body of the text.
|
||||
|
||||
A section "Entitled XYZ" means a named subunit of the Document whose
|
||||
title either is precisely XYZ or contains XYZ in parentheses following
|
||||
text that translates XYZ in another language. (Here XYZ stands for a
|
||||
specific section name mentioned below, such as "Acknowledgements",
|
||||
"Dedications", "Endorsements", or "History".) To "Preserve the Title"
|
||||
of such a section when you modify the Document means that it remains a
|
||||
section "Entitled XYZ" according to this definition.
|
||||
|
||||
The Document may include Warranty Disclaimers next to the notice which
|
||||
states that this License applies to the Document. These Warranty
|
||||
Disclaimers are considered to be included by reference in this
|
||||
License, but only as regards disclaiming warranties: any other
|
||||
implication that these Warranty Disclaimers may have is void and has
|
||||
no effect on the meaning of this License.
|
||||
|
||||
|
||||
2. VERBATIM COPYING
|
||||
|
||||
You may copy and distribute the Document in any medium, either
|
||||
commercially or noncommercially, provided that this License, the
|
||||
copyright notices, and the license notice saying this License applies
|
||||
to the Document are reproduced in all copies, and that you add no other
|
||||
conditions whatsoever to those of this License. You may not use
|
||||
technical measures to obstruct or control the reading or further
|
||||
copying of the copies you make or distribute. However, you may accept
|
||||
compensation in exchange for copies. If you distribute a large enough
|
||||
number of copies you must also follow the conditions in section 3.
|
||||
|
||||
You may also lend copies, under the same conditions stated above, and
|
||||
you may publicly display copies.
|
||||
|
||||
|
||||
3. COPYING IN QUANTITY
|
||||
|
||||
If you publish printed copies (or copies in media that commonly have
|
||||
printed covers) of the Document, numbering more than 100, and the
|
||||
Document's license notice requires Cover Texts, you must enclose the
|
||||
copies in covers that carry, clearly and legibly, all these Cover
|
||||
Texts: Front-Cover Texts on the front cover, and Back-Cover Texts on
|
||||
the back cover. Both covers must also clearly and legibly identify
|
||||
you as the publisher of these copies. The front cover must present
|
||||
the full title with all words of the title equally prominent and
|
||||
visible. You may add other material on the covers in addition.
|
||||
Copying with changes limited to the covers, as long as they preserve
|
||||
the title of the Document and satisfy these conditions, can be treated
|
||||
as verbatim copying in other respects.
|
||||
|
||||
If the required texts for either cover are too voluminous to fit
|
||||
legibly, you should put the first ones listed (as many as fit
|
||||
reasonably) on the actual cover, and continue the rest onto adjacent
|
||||
pages.
|
||||
|
||||
If you publish or distribute Opaque copies of the Document numbering
|
||||
more than 100, you must either include a machine-readable Transparent
|
||||
copy along with each Opaque copy, or state in or with each Opaque copy
|
||||
a computer-network location from which the general network-using
|
||||
public has access to download using public-standard network protocols
|
||||
a complete Transparent copy of the Document, free of added material.
|
||||
If you use the latter option, you must take reasonably prudent steps,
|
||||
when you begin distribution of Opaque copies in quantity, to ensure
|
||||
that this Transparent copy will remain thus accessible at the stated
|
||||
location until at least one year after the last time you distribute an
|
||||
Opaque copy (directly or through your agents or retailers) of that
|
||||
edition to the public.
|
||||
|
||||
It is requested, but not required, that you contact the authors of the
|
||||
Document well before redistributing any large number of copies, to give
|
||||
them a chance to provide you with an updated version of the Document.
|
||||
|
||||
|
||||
4. MODIFICATIONS
|
||||
|
||||
You may copy and distribute a Modified Version of the Document under
|
||||
the conditions of sections 2 and 3 above, provided that you release
|
||||
the Modified Version under precisely this License, with the Modified
|
||||
Version filling the role of the Document, thus licensing distribution
|
||||
and modification of the Modified Version to whoever possesses a copy
|
||||
of it. In addition, you must do these things in the Modified Version:
|
||||
|
||||
A. Use in the Title Page (and on the covers, if any) a title distinct
|
||||
from that of the Document, and from those of previous versions
|
||||
(which should, if there were any, be listed in the History section
|
||||
of the Document). You may use the same title as a previous version
|
||||
if the original publisher of that version gives permission.
|
||||
B. List on the Title Page, as authors, one or more persons or entities
|
||||
responsible for authorship of the modifications in the Modified
|
||||
Version, together with at least five of the principal authors of the
|
||||
Document (all of its principal authors, if it has fewer than five),
|
||||
unless they release you from this requirement.
|
||||
C. State on the Title page the name of the publisher of the
|
||||
Modified Version, as the publisher.
|
||||
D. Preserve all the copyright notices of the Document.
|
||||
E. Add an appropriate copyright notice for your modifications
|
||||
adjacent to the other copyright notices.
|
||||
F. Include, immediately after the copyright notices, a license notice
|
||||
giving the public permission to use the Modified Version under the
|
||||
terms of this License, in the form shown in the Addendum below.
|
||||
G. Preserve in that license notice the full lists of Invariant Sections
|
||||
and required Cover Texts given in the Document's license notice.
|
||||
H. Include an unaltered copy of this License.
|
||||
I. Preserve the section Entitled "History", Preserve its Title, and add
|
||||
to it an item stating at least the title, year, new authors, and
|
||||
publisher of the Modified Version as given on the Title Page. If
|
||||
there is no section Entitled "History" in the Document, create one
|
||||
stating the title, year, authors, and publisher of the Document as
|
||||
given on its Title Page, then add an item describing the Modified
|
||||
Version as stated in the previous sentence.
|
||||
J. Preserve the network location, if any, given in the Document for
|
||||
public access to a Transparent copy of the Document, and likewise
|
||||
the network locations given in the Document for previous versions
|
||||
it was based on. These may be placed in the "History" section.
|
||||
You may omit a network location for a work that was published at
|
||||
least four years before the Document itself, or if the original
|
||||
publisher of the version it refers to gives permission.
|
||||
K. For any section Entitled "Acknowledgements" or "Dedications",
|
||||
Preserve the Title of the section, and preserve in the section all
|
||||
the substance and tone of each of the contributor acknowledgements
|
||||
and/or dedications given therein.
|
||||
L. Preserve all the Invariant Sections of the Document,
|
||||
unaltered in their text and in their titles. Section numbers
|
||||
or the equivalent are not considered part of the section titles.
|
||||
M. Delete any section Entitled "Endorsements". Such a section
|
||||
may not be included in the Modified Version.
|
||||
N. Do not retitle any existing section to be Entitled "Endorsements"
|
||||
or to conflict in title with any Invariant Section.
|
||||
O. Preserve any Warranty Disclaimers.
|
||||
|
||||
If the Modified Version includes new front-matter sections or
|
||||
appendices that qualify as Secondary Sections and contain no material
|
||||
copied from the Document, you may at your option designate some or all
|
||||
of these sections as invariant. To do this, add their titles to the
|
||||
list of Invariant Sections in the Modified Version's license notice.
|
||||
These titles must be distinct from any other section titles.
|
||||
|
||||
You may add a section Entitled "Endorsements", provided it contains
|
||||
nothing but endorsements of your Modified Version by various
|
||||
parties--for example, statements of peer review or that the text has
|
||||
been approved by an organization as the authoritative definition of a
|
||||
standard.
|
||||
|
||||
You may add a passage of up to five words as a Front-Cover Text, and a
|
||||
passage of up to 25 words as a Back-Cover Text, to the end of the list
|
||||
of Cover Texts in the Modified Version. Only one passage of
|
||||
Front-Cover Text and one of Back-Cover Text may be added by (or
|
||||
through arrangements made by) any one entity. If the Document already
|
||||
includes a cover text for the same cover, previously added by you or
|
||||
by arrangement made by the same entity you are acting on behalf of,
|
||||
you may not add another; but you may replace the old one, on explicit
|
||||
permission from the previous publisher that added the old one.
|
||||
|
||||
The author(s) and publisher(s) of the Document do not by this License
|
||||
give permission to use their names for publicity for or to assert or
|
||||
imply endorsement of any Modified Version.
|
||||
|
||||
|
||||
5. COMBINING DOCUMENTS
|
||||
|
||||
You may combine the Document with other documents released under this
|
||||
License, under the terms defined in section 4 above for modified
|
||||
versions, provided that you include in the combination all of the
|
||||
Invariant Sections of all of the original documents, unmodified, and
|
||||
list them all as Invariant Sections of your combined work in its
|
||||
license notice, and that you preserve all their Warranty Disclaimers.
|
||||
|
||||
The combined work need only contain one copy of this License, and
|
||||
multiple identical Invariant Sections may be replaced with a single
|
||||
copy. If there are multiple Invariant Sections with the same name but
|
||||
different contents, make the title of each such section unique by
|
||||
adding at the end of it, in parentheses, the name of the original
|
||||
author or publisher of that section if known, or else a unique number.
|
||||
Make the same adjustment to the section titles in the list of
|
||||
Invariant Sections in the license notice of the combined work.
|
||||
|
||||
In the combination, you must combine any sections Entitled "History"
|
||||
in the various original documents, forming one section Entitled
|
||||
"History"; likewise combine any sections Entitled "Acknowledgements",
|
||||
and any sections Entitled "Dedications". You must delete all sections
|
||||
Entitled "Endorsements".
|
||||
|
||||
|
||||
6. COLLECTIONS OF DOCUMENTS
|
||||
|
||||
You may make a collection consisting of the Document and other documents
|
||||
released under this License, and replace the individual copies of this
|
||||
License in the various documents with a single copy that is included in
|
||||
the collection, provided that you follow the rules of this License for
|
||||
verbatim copying of each of the documents in all other respects.
|
||||
|
||||
You may extract a single document from such a collection, and distribute
|
||||
it individually under this License, provided you insert a copy of this
|
||||
License into the extracted document, and follow this License in all
|
||||
other respects regarding verbatim copying of that document.
|
||||
|
||||
|
||||
7. AGGREGATION WITH INDEPENDENT WORKS
|
||||
|
||||
A compilation of the Document or its derivatives with other separate
|
||||
and independent documents or works, in or on a volume of a storage or
|
||||
distribution medium, is called an "aggregate" if the copyright
|
||||
resulting from the compilation is not used to limit the legal rights
|
||||
of the compilation's users beyond what the individual works permit.
|
||||
When the Document is included in an aggregate, this License does not
|
||||
apply to the other works in the aggregate which are not themselves
|
||||
derivative works of the Document.
|
||||
|
||||
If the Cover Text requirement of section 3 is applicable to these
|
||||
copies of the Document, then if the Document is less than one half of
|
||||
the entire aggregate, the Document's Cover Texts may be placed on
|
||||
covers that bracket the Document within the aggregate, or the
|
||||
electronic equivalent of covers if the Document is in electronic form.
|
||||
Otherwise they must appear on printed covers that bracket the whole
|
||||
aggregate.
|
||||
|
||||
|
||||
8. TRANSLATION
|
||||
|
||||
Translation is considered a kind of modification, so you may
|
||||
distribute translations of the Document under the terms of section 4.
|
||||
Replacing Invariant Sections with translations requires special
|
||||
permission from their copyright holders, but you may include
|
||||
translations of some or all Invariant Sections in addition to the
|
||||
original versions of these Invariant Sections. You may include a
|
||||
translation of this License, and all the license notices in the
|
||||
Document, and any Warranty Disclaimers, provided that you also include
|
||||
the original English version of this License and the original versions
|
||||
of those notices and disclaimers. In case of a disagreement between
|
||||
the translation and the original version of this License or a notice
|
||||
or disclaimer, the original version will prevail.
|
||||
|
||||
If a section in the Document is Entitled "Acknowledgements",
|
||||
"Dedications", or "History", the requirement (section 4) to Preserve
|
||||
its Title (section 1) will typically require changing the actual
|
||||
title.
|
||||
|
||||
|
||||
9. TERMINATION
|
||||
|
||||
You may not copy, modify, sublicense, or distribute the Document except
|
||||
as expressly provided for under this License. Any other attempt to
|
||||
copy, modify, sublicense or distribute the Document is void, and will
|
||||
automatically terminate your rights under this License. However,
|
||||
parties who have received copies, or rights, from you under this
|
||||
License will not have their licenses terminated so long as such
|
||||
parties remain in full compliance.
|
||||
|
||||
|
||||
10. FUTURE REVISIONS OF THIS LICENSE
|
||||
|
||||
The Free Software Foundation may publish new, revised versions
|
||||
of the GNU Free Documentation License from time to time. Such new
|
||||
versions will be similar in spirit to the present version, but may
|
||||
differ in detail to address new problems or concerns. See
|
||||
http://www.gnu.org/copyleft/.
|
||||
|
||||
Each version of the License is given a distinguishing version number.
|
||||
If the Document specifies that a particular numbered version of this
|
||||
License "or any later version" applies to it, you have the option of
|
||||
following the terms and conditions either of that specified version or
|
||||
of any later version that has been published (not as a draft) by the
|
||||
Free Software Foundation. If the Document does not specify a version
|
||||
number of this License, you may choose any version ever published (not
|
||||
as a draft) by the Free Software Foundation.
|
||||
|
||||
|
||||
ADDENDUM: How to use this License for your documents
|
||||
|
||||
To use this License in a document you have written, include a copy of
|
||||
the License in the document and put the following copyright and
|
||||
license notices just after the title page:
|
||||
|
||||
Copyright (c) YEAR YOUR NAME.
|
||||
Permission is granted to copy, distribute and/or modify this document
|
||||
under the terms of the GNU Free Documentation License, Version 1.2
|
||||
or any later version published by the Free Software Foundation;
|
||||
with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts.
|
||||
A copy of the license is included in the section entitled "GNU
|
||||
Free Documentation License".
|
||||
|
||||
If you have Invariant Sections, Front-Cover Texts and Back-Cover Texts,
|
||||
replace the "with...Texts." line with this:
|
||||
|
||||
with the Invariant Sections being LIST THEIR TITLES, with the
|
||||
Front-Cover Texts being LIST, and with the Back-Cover Texts being LIST.
|
||||
|
||||
If you have Invariant Sections without Cover Texts, or some other
|
||||
combination of the three, merge those two alternatives to suit the
|
||||
situation.
|
||||
|
||||
If your document contains nontrivial examples of program code, we
|
||||
recommend releasing these examples in parallel under your choice of
|
||||
free software license, such as the GNU General Public License,
|
||||
to permit their use in free software.
|
@ -0,0 +1,176 @@
|
||||
Basic Installation
|
||||
==================
|
||||
|
||||
These are generic installation instructions.
|
||||
|
||||
The `configure' shell script attempts to guess correct values for
|
||||
various system-dependent variables used during compilation. It uses
|
||||
those values to create a `Makefile' in each directory of the package.
|
||||
It may also create one or more `.h' files containing system-dependent
|
||||
definitions. Finally, it creates a shell script `config.status' that
|
||||
you can run in the future to recreate the current configuration, a file
|
||||
`config.cache' that saves the results of its tests to speed up
|
||||
reconfiguring, and a file `config.log' containing compiler output
|
||||
(useful mainly for debugging `configure').
|
||||
|
||||
If you need to do unusual things to compile the package, please try
|
||||
to figure out how `configure' could check whether to do them, and mail
|
||||
diffs or instructions to the address given in the `README' so they can
|
||||
be considered for the next release. If at some point `config.cache'
|
||||
contains results you don't want to keep, you may remove or edit it.
|
||||
|
||||
The file `configure.in' is used to create `configure' by a program
|
||||
called `autoconf'. You only need `configure.in' if you want to change
|
||||
it or regenerate `configure' using a newer version of `autoconf'.
|
||||
|
||||
The simplest way to compile this package is:
|
||||
|
||||
1. `cd' to the directory containing the package's source code and type
|
||||
`./configure' to configure the package for your system. If you're
|
||||
using `csh' on an old version of System V, you might need to type
|
||||
`sh ./configure' instead to prevent `csh' from trying to execute
|
||||
`configure' itself.
|
||||
|
||||
Running `configure' takes a while. While running, it prints some
|
||||
messages telling which features it is checking for.
|
||||
|
||||
2. Type `make' to compile the package.
|
||||
|
||||
3. Optionally, type `make check' to run any self-tests that come with
|
||||
the package.
|
||||
|
||||
4. Type `make install' to install the programs and any data files and
|
||||
documentation.
|
||||
|
||||
5. You can remove the program binaries and object files from the
|
||||
source code directory by typing `make clean'. To also remove the
|
||||
files that `configure' created (so you can compile the package for
|
||||
a different kind of computer), type `make distclean'. There is
|
||||
also a `make maintainer-clean' target, but that is intended mainly
|
||||
for the package's developers. If you use it, you may have to get
|
||||
all sorts of other programs in order to regenerate files that came
|
||||
with the distribution.
|
||||
|
||||
Compilers and Options
|
||||
=====================
|
||||
|
||||
Some systems require unusual options for compilation or linking that
|
||||
the `configure' script does not know about. You can give `configure'
|
||||
initial values for variables by setting them in the environment. Using
|
||||
a Bourne-compatible shell, you can do that on the command line like
|
||||
this:
|
||||
CC=c89 CFLAGS=-O2 LIBS=-lposix ./configure
|
||||
|
||||
Or on systems that have the `env' program, you can do it like this:
|
||||
env CPPFLAGS=-I/usr/local/include LDFLAGS=-s ./configure
|
||||
|
||||
Compiling For Multiple Architectures
|
||||
====================================
|
||||
|
||||
You can compile the package for more than one kind of computer at the
|
||||
same time, by placing the object files for each architecture in their
|
||||
own directory. To do this, you must use a version of `make' that
|
||||
supports the `VPATH' variable, such as GNU `make'. `cd' to the
|
||||
directory where you want the object files and executables to go and run
|
||||
the `configure' script. `configure' automatically checks for the
|
||||
source code in the directory that `configure' is in and in `..'.
|
||||
|
||||
If you have to use a `make' that does not supports the `VPATH'
|
||||
variable, you have to compile the package for one architecture at a time
|
||||
in the source code directory. After you have installed the package for
|
||||
one architecture, use `make distclean' before reconfiguring for another
|
||||
architecture.
|
||||
|
||||
Installation Names
|
||||
==================
|
||||
|
||||
By default, `make install' will install the package's files in
|
||||
`/usr/local/kde/bin', `/usr/local/kde/lib', etc. You can specify an
|
||||
installation prefix other than `/usr/local/kde' by giving `configure'
|
||||
the option `--prefix=PATH'.
|
||||
|
||||
You can specify separate installation prefixes for
|
||||
architecture-specific files and architecture-independent files. If you
|
||||
give `configure' the option `--exec-prefix=PATH', the package will use
|
||||
PATH as the prefix for installing programs and libraries.
|
||||
Documentation and other data files will still use the regular prefix.
|
||||
|
||||
If the package supports it, you can cause programs to be installed
|
||||
with an extra prefix or suffix on their names by giving `configure' the
|
||||
option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
|
||||
|
||||
Optional Features
|
||||
=================
|
||||
|
||||
Some packages pay attention to `--enable-FEATURE' options to
|
||||
`configure', where FEATURE indicates an optional part of the package.
|
||||
They may also pay attention to `--with-PACKAGE' options, where PACKAGE
|
||||
is something like `gnu-as' or `x' (for the X Window System). The
|
||||
`README' should mention any `--enable-' and `--with-' options that the
|
||||
package recognizes.
|
||||
|
||||
For packages that use the X Window System, `configure' can usually
|
||||
find the X include and library files automatically, but if it doesn't,
|
||||
you can use the `configure' options `--x-includes=DIR' and
|
||||
`--x-libraries=DIR' to specify their locations.
|
||||
|
||||
Specifying the System Type
|
||||
==========================
|
||||
|
||||
There may be some features `configure' can not figure out
|
||||
automatically, but needs to determine by the type of host the package
|
||||
will run on. Usually `configure' can figure that out, but if it prints
|
||||
a message saying it can not guess the host type, give it the
|
||||
`--host=TYPE' option. TYPE can either be a short name for the system
|
||||
type, such as `sun4', or a canonical name with three fields:
|
||||
CPU-COMPANY-SYSTEM
|
||||
|
||||
See the file `config.sub' for the possible values of each field. If
|
||||
`config.sub' isn't included in this package, then this package doesn't
|
||||
need to know the host type.
|
||||
|
||||
If you are building compiler tools for cross-compiling, you can also
|
||||
use the `--target=TYPE' option to select the type of system they will
|
||||
produce code for and the `--build=TYPE' option to select the type of
|
||||
system on which you are compiling the package.
|
||||
|
||||
Sharing Defaults
|
||||
================
|
||||
|
||||
If you want to set default values for `configure' scripts to share,
|
||||
you can create a site shell script called `config.site' that gives
|
||||
default values for variables like `CC', `cache_file', and `prefix'.
|
||||
`configure' looks for `PREFIX/share/config.site' if it exists, then
|
||||
`PREFIX/etc/config.site' if it exists. Or, you can set the
|
||||
`CONFIG_SITE' environment variable to the location of the site script.
|
||||
A warning: not all `configure' scripts look for a site script.
|
||||
|
||||
Operation Controls
|
||||
==================
|
||||
|
||||
`configure' recognizes the following options to control how it
|
||||
operates.
|
||||
|
||||
`--cache-file=FILE'
|
||||
Use and save the results of the tests in FILE instead of
|
||||
`./config.cache'. Set FILE to `/dev/null' to disable caching, for
|
||||
debugging `configure'.
|
||||
|
||||
`--help'
|
||||
Print a summary of the options to `configure', and exit.
|
||||
|
||||
`--quiet'
|
||||
`--silent'
|
||||
`-q'
|
||||
Do not print messages saying which checks are being made.
|
||||
|
||||
`--srcdir=DIR'
|
||||
Look for the package's source code in directory DIR. Usually
|
||||
`configure' can determine that directory automatically.
|
||||
|
||||
`--version'
|
||||
Print the version of Autoconf used to generate the `configure'
|
||||
script, and exit.
|
||||
|
||||
`configure' also accepts some other, not widely useful, options.
|
||||
|
@ -0,0 +1,6 @@
|
||||
AUTOMAKE_OPTIONS = foreign 1.6.1
|
||||
DISTCLEANFILES = inst-apps
|
||||
|
||||
MAINTAINERCLEANFILES = subdirs configure.in acinclude.m4 SUBDIRS
|
||||
include admin/deps.am
|
||||
|
@ -0,0 +1,14 @@
|
||||
all:
|
||||
@echo "This Makefile is only for the CVS repository"
|
||||
@echo "This will be deleted before making the distribution"
|
||||
@echo ""
|
||||
@if test ! -d admin; then \
|
||||
echo "Please recheckout this module!" ;\
|
||||
echo "for cvs: use checkout once and after that update again" ;\
|
||||
echo "for cvsup: checkout kde-common from cvsup and" ;\
|
||||
echo " link kde-common/admin to ./admin" ;\
|
||||
exit 1 ;\
|
||||
fi
|
||||
$(MAKE) -f admin/Makefile.common cvs
|
||||
|
||||
.SILENT:
|
@ -0,0 +1,47 @@
|
||||
In this file:
|
||||
|
||||
* What it is
|
||||
* Common Mistakes
|
||||
* Debugging
|
||||
* More Info
|
||||
|
||||
What it is
|
||||
----------
|
||||
|
||||
* amor: Amusing Misuse Of Resources put's comic figures above your windows
|
||||
* eyesapplet: a kicker applet similar to XEyes
|
||||
* fifteenapplet: kicker applet, order 15 pieces in a 4x4 square by moving them
|
||||
* kaphorism: displays aphorisms
|
||||
* kmoon: system tray applet showing the moon phase
|
||||
* kodo: mouse movement meter
|
||||
* kscore: kicker applet with a sports ticker
|
||||
* kteatime: system tray applet that makes sure your tea doesn't get too strong
|
||||
* ktux: Tux-in-a-Spaceship screen saver
|
||||
* kweather: kicker applet that will display the current weather outside
|
||||
* kworldwatch: application and kicker applet showing daylight area on the world
|
||||
globe
|
||||
|
||||
Common Mistakes
|
||||
---------------
|
||||
|
||||
If configure claims Qt cannot be found, have a look at http://www.trolltech.com
|
||||
to get the latest copy of Qt 3.3.x version.
|
||||
|
||||
Debugging
|
||||
---------
|
||||
|
||||
You can use --enable-debug with the configure script, if you want to have
|
||||
debug code in your KDE apps and libs. I recommend to do this, since this
|
||||
is alpha software and this makes debugging things a whole lot easier.
|
||||
|
||||
More Info
|
||||
---------
|
||||
|
||||
Have a look at the individual subdirectories, if you want to know, what
|
||||
versions of apps are included.
|
||||
|
||||
Please direct any bug reports to our bug list by visiting
|
||||
http://bugs.kde.org.
|
||||
|
||||
General KDE discussions should go to the KDE mailing list (kde@kde.org).
|
||||
|
@ -0,0 +1,49 @@
|
||||
/* AmorIface.h
|
||||
**
|
||||
** Copyright (c) 1999 Martin R. Jones <mjones@kde.org>
|
||||
**
|
||||
*/
|
||||
|
||||
/*
|
||||
** 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
|
||||
** the Free Software Foundation; either version 2 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program in a file called COPYING; if not, write to
|
||||
** the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
||||
** MA 02110-1301, USA.
|
||||
*/
|
||||
|
||||
/*
|
||||
** Bug reports and questions can be sent to kde-devel@kde.org
|
||||
*/
|
||||
|
||||
#ifndef __AmorIface_h__
|
||||
#define __AmorIface_h__
|
||||
|
||||
#include <dcopobject.h>
|
||||
|
||||
class AmorIface : virtual public DCOPObject
|
||||
{
|
||||
K_DCOP
|
||||
public:
|
||||
|
||||
k_dcop:
|
||||
virtual void showTip(QString tip) = 0;
|
||||
virtual void showMessage(QString message ) = 0;
|
||||
virtual void showMessage(QString message, int msec ) = 0;
|
||||
|
||||
virtual void screenSaverStopped() = 0;
|
||||
virtual void screenSaverStarted() = 0;
|
||||
|
||||
};
|
||||
|
||||
#endif
|
||||
|
@ -0,0 +1,38 @@
|
||||
|
||||
# set the include path for X, qt and KDE
|
||||
INCLUDES= $(all_includes)
|
||||
# claim, which subdirectories you want to install
|
||||
SUBDIRS = data
|
||||
|
||||
####### This part is very amor specific
|
||||
# you can add here more. This one gets installed
|
||||
bin_PROGRAMS = amor
|
||||
|
||||
# Which sources should be compiled for amor.
|
||||
amor_SOURCES = amordialog.cpp amor.cpp amorwidget.cpp main.cpp amoranim.cpp amorpm.cpp\
|
||||
amorbubble.cpp amorconfig.cpp amortips.cpp AmorIface.skel
|
||||
|
||||
include_HEADERS = AmorIface.h
|
||||
|
||||
# the library search path
|
||||
amor_LDFLAGS = $(all_libraries) $(KDE_RPATH)
|
||||
|
||||
# the libraries to link against. Be aware of the order. First the libraries,
|
||||
# that depend on the following ones.
|
||||
amor_LDADD = $(LIB_KDEUI)
|
||||
|
||||
# this option you can leave out. Just, if you use "make dist", you need it
|
||||
noinst_HEADERS = amor.h amorwidget.h amoranim.h amorpm.h amordialog.h\
|
||||
amorbubble.h amorconfig.h amortips.h
|
||||
|
||||
METASOURCES = AUTO
|
||||
|
||||
messages:
|
||||
perl ./preparetips > tips.cpp
|
||||
$(XGETTEXT) tips.cpp *.cpp -o $(podir)/amor.pot
|
||||
rm -f tips.cpp
|
||||
|
||||
xdg_apps_DATA = amor.desktop
|
||||
|
||||
KDE_ICON = amor
|
||||
|
@ -0,0 +1,15 @@
|
||||
As of 04/14/04...
|
||||
|
||||
- find a way to use round bubbles without using Painter.drawRoundRect,
|
||||
because you can only specify the relative roundness of the corners. The corners
|
||||
should have a fixed radius.
|
||||
|
||||
- What should be done about messages that arrive while the screensaver
|
||||
is on?.
|
||||
|
||||
- Clean up the messages queue. Why is the default timing for messages
|
||||
and tips calculated in class queueItem instead of in class Amor?
|
||||
|
||||
- Reduce the delay between a showMessage is received and the bubble is
|
||||
actually shown.
|
||||
|
@ -0,0 +1,164 @@
|
||||
/* amor.h
|
||||
**
|
||||
** Copyright (c) 1999 Martin R. Jones <mjones@kde.org>
|
||||
**
|
||||
*/
|
||||
|
||||
/*
|
||||
** 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
|
||||
** the Free Software Foundation; either version 2 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program in a file called COPYING; if not, write to
|
||||
** the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
||||
** MA 02110-1301, USA.
|
||||
*/
|
||||
|
||||
/*
|
||||
** Bug reports and questions can be sent to kde-devel@kde.org
|
||||
*/
|
||||
#ifndef AMOR_H
|
||||
#define AMOR_H
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include <config.h>
|
||||
#endif
|
||||
|
||||
#include <qwidget.h>
|
||||
#include <qptrqueue.h>
|
||||
|
||||
#include "amoranim.h"
|
||||
#include "amortips.h"
|
||||
#include "amorconfig.h"
|
||||
#include "AmorIface.h"
|
||||
|
||||
class AmorDialog;
|
||||
class AmorBubble;
|
||||
class AmorWidget;
|
||||
|
||||
class QTimer;
|
||||
class KWinModule;
|
||||
class KPopupMenu;
|
||||
|
||||
class QueueItem {
|
||||
public:
|
||||
|
||||
enum itemType { Talk , Tip };
|
||||
|
||||
QueueItem(itemType ty, QString te, int ti = -1);
|
||||
|
||||
itemType type() { return iType; }
|
||||
QString text() { return iText; };
|
||||
int time() { return iTime; };
|
||||
|
||||
void setTime(int newTime) { if (iTime > 0) iTime = newTime; };
|
||||
|
||||
private:
|
||||
itemType iType;
|
||||
QString iText;
|
||||
int iTime;
|
||||
};
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Amor handles window manager input and animation selection and updates.
|
||||
//
|
||||
class Amor : public QObject, virtual public AmorIface
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
Amor();
|
||||
virtual ~Amor();
|
||||
|
||||
virtual void showTip(QString tip);
|
||||
virtual void showMessage(QString message);
|
||||
virtual void showMessage(QString message, int msec);
|
||||
virtual void screenSaverStopped();
|
||||
virtual void screenSaverStarted();
|
||||
|
||||
void reset();
|
||||
|
||||
public slots:
|
||||
void slotWindowActivate(WId);
|
||||
void slotWindowRemove(WId);
|
||||
void slotStackingChanged();
|
||||
void slotWindowChange(WId, const unsigned long * properties);
|
||||
void slotDesktopChange(int);
|
||||
|
||||
protected slots:
|
||||
void slotMouseClicked(const QPoint &pos);
|
||||
void slotTimeout();
|
||||
void slotCursorTimeout();
|
||||
void slotConfigure();
|
||||
void slotConfigChanged();
|
||||
void slotOffsetChanged(int);
|
||||
void slotAbout();
|
||||
void slotWidgetDragged( const QPoint &delta, bool release );
|
||||
void restack();
|
||||
void hideBubble(bool forceDequeue = false);
|
||||
|
||||
void slotBubbleTimeout();
|
||||
|
||||
protected:
|
||||
enum State { Focus, Blur, Normal, Sleeping, Waking, Destroy };
|
||||
|
||||
bool readConfig();
|
||||
void readGroupConfig(KConfigBase &config, QPtrList<AmorAnim> &animList,
|
||||
const char *seq);
|
||||
void showBubble();
|
||||
AmorAnim *randomAnimation(QPtrList<AmorAnim> &animList);
|
||||
void selectAnimation(State state=Normal);
|
||||
void active();
|
||||
|
||||
private:
|
||||
KWinModule *mWin;
|
||||
WId mTargetWin; // The window that the animations sits on
|
||||
QRect mTargetRect; // The goemetry of the target window
|
||||
WId mNextTarget; // The window that will become the target
|
||||
AmorWidget *mAmor; // The widget displaying the animation
|
||||
AmorThemeManager mTheme; // Animations used by current theme
|
||||
AmorAnim *mBaseAnim; // The base animation
|
||||
AmorAnim *mCurrAnim; // The currently running animation
|
||||
int mPosition; // The position of the animation
|
||||
State mState; // The current state of the animation
|
||||
QTimer *mTimer; // Frame timer
|
||||
QTimer *mCursorTimer;// Cursor timer
|
||||
QTimer *mStackTimer; // Restacking timer
|
||||
QTimer *mBubbleTimer;// Bubble tip timer (GP: I didn't create this one, it had no use when I found it)
|
||||
AmorDialog *mAmorDialog; // Setup dialog
|
||||
KPopupMenu *mMenu; // Our menu
|
||||
time_t mActiveTime; // The time an active event occurred
|
||||
QPoint mCursPos; // The last recorded position of the pointer
|
||||
QString mTipText; // Text to display in a bubble when possible
|
||||
AmorBubble *mBubble; // Text bubble
|
||||
AmorTips mTips; // Tips to display in the bubble
|
||||
bool mInDesktopBottom; // the animation is not on top of the
|
||||
// title bar, but at the bottom of the desktop
|
||||
|
||||
AmorConfig mConfig; // Configuration parameters
|
||||
bool mForceHideAmorWidget;
|
||||
|
||||
QPtrQueue<QueueItem> mTipsQueue; // GP: tips queue
|
||||
};
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
|
||||
class AmorSessionWidget : public QWidget
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
AmorSessionWidget();
|
||||
~AmorSessionWidget() {};
|
||||
public slots:
|
||||
void wm_saveyourself();
|
||||
};
|
||||
|
||||
#endif // AMOR_H
|
||||
|
@ -0,0 +1,254 @@
|
||||
/* amoranim.cpp
|
||||
**
|
||||
** Copyright (c) 1999 Martin R. Jones <mjones@kde.org>
|
||||
**
|
||||
*/
|
||||
|
||||
/*
|
||||
** 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
|
||||
** the Free Software Foundation; either version 2 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program in a file called COPYING; if not, write to
|
||||
** the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
||||
** MA 02110-1301, USA.
|
||||
*/
|
||||
|
||||
/*
|
||||
** Bug reports and questions can be sent to kde-devel@kde.org
|
||||
*/
|
||||
#include <stdlib.h>
|
||||
#include <kapplication.h>
|
||||
#include <kstandarddirs.h>
|
||||
#include "amoranim.h"
|
||||
#include "amorpm.h"
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Constructor
|
||||
//
|
||||
AmorAnim::AmorAnim(KConfigBase &config)
|
||||
: mMaximumSize(0, 0)
|
||||
{
|
||||
mCurrent = 0;
|
||||
mTotalMovement = 0;
|
||||
readConfig(config);
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Destructor
|
||||
//
|
||||
AmorAnim::~AmorAnim()
|
||||
{
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Get the Pixmap for the current frame.
|
||||
//
|
||||
const QPixmap *AmorAnim::frame()
|
||||
{
|
||||
const QPixmap *pixmap = 0;
|
||||
|
||||
if (validFrame())
|
||||
pixmap = AmorPixmapManager::manager()->pixmap(*mSequence.at(mCurrent));
|
||||
|
||||
return pixmap;
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Read a single animation's parameters. The config class should already
|
||||
// have its group set to the animation that is to be read.
|
||||
//
|
||||
void AmorAnim::readConfig(KConfigBase &config)
|
||||
{
|
||||
// Read the list of frames to display and load them into the pixmap
|
||||
// manager.
|
||||
mSequence = config.readListEntry("Sequence");
|
||||
int frames = mSequence.count();
|
||||
for ( QStringList::Iterator it = mSequence.begin();
|
||||
it != mSequence.end();
|
||||
++it )
|
||||
{
|
||||
const QPixmap *pixmap =
|
||||
AmorPixmapManager::manager()->load(*it);
|
||||
if (pixmap)
|
||||
mMaximumSize = mMaximumSize.expandedTo(pixmap->size());
|
||||
}
|
||||
|
||||
// Read the delays between frames.
|
||||
QStrList list;
|
||||
int entries = config.readListEntry("Delay",list);
|
||||
mDelay.resize(frames);
|
||||
for (int i = 0; i < entries && i < frames; i++)
|
||||
mDelay[i] = atoi(list.at(i));
|
||||
|
||||
// Read the distance to move between frames and calculate the total
|
||||
// distance that this aniamtion moves from its starting position.
|
||||
entries = config.readListEntry("Movement",list);
|
||||
mMovement.resize(frames);
|
||||
for (int i = 0; i < entries && i < frames; i++)
|
||||
{
|
||||
mMovement[i] = atoi(list.at(i));
|
||||
mTotalMovement += mMovement[i];
|
||||
}
|
||||
|
||||
// Read the hotspot for each frame.
|
||||
entries = config.readListEntry("HotspotX",list);
|
||||
mHotspot.resize(frames);
|
||||
for (int i = 0; i < entries && i < frames; i++)
|
||||
mHotspot[i].setX(atoi(list.at(i)));
|
||||
|
||||
entries = config.readListEntry("HotspotY",list);
|
||||
for (int i = 0; i < entries && i < frames; i++)
|
||||
mHotspot[i].setY(atoi(list.at(i)));
|
||||
|
||||
// Add the overlap of the last frame to the total movement.
|
||||
const QPoint &lastHotspot = mHotspot[mHotspot.size()-1];
|
||||
if (mTotalMovement > 0)
|
||||
{
|
||||
const QPixmap *lastFrame =
|
||||
AmorPixmapManager::manager()->pixmap(mSequence.last());
|
||||
if (lastFrame)
|
||||
{
|
||||
mTotalMovement += (lastFrame->width() - lastHotspot.x());
|
||||
}
|
||||
}
|
||||
else if (mTotalMovement < 0)
|
||||
{
|
||||
mTotalMovement -= lastHotspot.x();
|
||||
}
|
||||
}
|
||||
|
||||
//===========================================================================
|
||||
|
||||
AmorThemeManager::AmorThemeManager()
|
||||
: mMaximumSize(0, 0)
|
||||
{
|
||||
mConfig = 0;
|
||||
mAnimations.setAutoDelete(true);
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
AmorThemeManager::~AmorThemeManager()
|
||||
{
|
||||
delete mConfig;
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
bool AmorThemeManager::setTheme(const QString & file)
|
||||
{
|
||||
mPath = locate("appdata", file);
|
||||
|
||||
delete mConfig;
|
||||
|
||||
mConfig = new KSimpleConfig(mPath, true);
|
||||
mConfig->setGroup("Config");
|
||||
|
||||
// Get the directory where the pixmaps are stored and tell the
|
||||
// pixmap manager.
|
||||
QString pixmapPath = mConfig->readPathEntry("PixmapPath");
|
||||
if (pixmapPath.isEmpty())
|
||||
return false;
|
||||
|
||||
if (pixmapPath[0] == '/')
|
||||
{
|
||||
// absolute path to pixmaps
|
||||
mPath = pixmapPath;
|
||||
}
|
||||
else
|
||||
{
|
||||
// relative to config file.
|
||||
mPath.truncate(mPath.findRev('/')+1);
|
||||
mPath += pixmapPath;
|
||||
}
|
||||
|
||||
mStatic = mConfig->readBoolEntry("Static", false);
|
||||
|
||||
mMaximumSize.setWidth(0);
|
||||
mMaximumSize.setHeight(0);
|
||||
|
||||
mAnimations.clear();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Select an animimation randomly from a group
|
||||
//
|
||||
AmorAnim *AmorThemeManager::random(const QString & group)
|
||||
{
|
||||
QString grp( group );
|
||||
|
||||
if (mStatic)
|
||||
grp = "Base";
|
||||
|
||||
AmorAnimationGroup *animGroup = mAnimations.find(grp);
|
||||
|
||||
if (animGroup) {
|
||||
int idx = kapp->random()%animGroup->count();
|
||||
return animGroup->at( idx );
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Read an animation group.
|
||||
//
|
||||
bool AmorThemeManager::readGroup(const QString & seq)
|
||||
{
|
||||
AmorPixmapManager::manager()->setPixmapDir(mPath);
|
||||
|
||||
AmorAnimationGroup *animList = new AmorAnimationGroup;
|
||||
animList->setAutoDelete(true);
|
||||
|
||||
// Read the list of available animations.
|
||||
mConfig->setGroup("Config");
|
||||
QStrList list;
|
||||
int entries = mConfig->readListEntry(seq, list);
|
||||
|
||||
// Read each individual animation
|
||||
for (int i = 0; i < entries; i++)
|
||||
{
|
||||
mConfig->setGroup(list.at(i));
|
||||
AmorAnim *anim = new AmorAnim(*mConfig);
|
||||
animList->append(anim);
|
||||
mMaximumSize = mMaximumSize.expandedTo(anim->maximumSize());
|
||||
}
|
||||
|
||||
// If no animations were available for this group, just add the base anim
|
||||
if (entries == 0)
|
||||
{
|
||||
mConfig->setGroup("Base");
|
||||
AmorAnim *anim = new AmorAnim(*mConfig);
|
||||
if (anim)
|
||||
{
|
||||
animList->append(anim);
|
||||
mMaximumSize = mMaximumSize.expandedTo(anim->maximumSize());
|
||||
entries++;
|
||||
}
|
||||
}
|
||||
|
||||
// Couldn't read any entries at all
|
||||
if (entries == 0)
|
||||
return false;
|
||||
|
||||
mAnimations.insert(seq, animList);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
@ -0,0 +1,117 @@
|
||||
/* amoranim.h
|
||||
**
|
||||
** Copyright (c) 1999 Martin R. Jones <mjones@kde.org>
|
||||
**
|
||||
*/
|
||||
|
||||
/*
|
||||
** 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
|
||||
** the Free Software Foundation; either version 2 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program in a file called COPYING; if not, write to
|
||||
** the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
||||
** MA 02110-1301, USA.
|
||||
*/
|
||||
|
||||
/*
|
||||
** Bug reports and questions can be sent to kde-devel@kde.org
|
||||
*/
|
||||
#ifndef AMORANIM_H
|
||||
#define AMORANIM_H
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include <config.h>
|
||||
#endif
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <unistd.h>
|
||||
#include <qmemarray.h>
|
||||
#include <qdict.h>
|
||||
#include <qstringlist.h>
|
||||
#include <kconfigbase.h>
|
||||
#include <ksimpleconfig.h>
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// AmorAnim contains the properties of a single animation
|
||||
//
|
||||
class AmorAnim
|
||||
{
|
||||
public:
|
||||
AmorAnim(KConfigBase &config);
|
||||
virtual ~AmorAnim();
|
||||
|
||||
void reset()
|
||||
{ mCurrent = 0; }
|
||||
bool next()
|
||||
{ return (++mCurrent < mSequence.count()); }
|
||||
int frameNum() const
|
||||
{ return mCurrent; }
|
||||
bool validFrame() const
|
||||
{ return (mCurrent < mSequence.count()); }
|
||||
int totalMovement() const
|
||||
{ return mTotalMovement; }
|
||||
QSize maximumSize() const
|
||||
{ return mMaximumSize; }
|
||||
|
||||
int delay() const
|
||||
{ return (validFrame() ? mDelay[mCurrent] : 100); }
|
||||
QPoint hotspot() const
|
||||
{ return (validFrame() ? mHotspot[mCurrent] : QPoint(16,16)); }
|
||||
int movement() const
|
||||
{ return (validFrame() ? mMovement[mCurrent] : 0); }
|
||||
const QPixmap *frame();
|
||||
|
||||
protected:
|
||||
void readConfig(KConfigBase &config);
|
||||
|
||||
protected:
|
||||
unsigned int mCurrent; // current frame in sequence
|
||||
QStringList mSequence; // sequence of images to display
|
||||
QMemArray<int> mDelay; // delay between frames
|
||||
QMemArray<QPoint> mHotspot; // the hotspot in a frame
|
||||
QMemArray<int> mMovement; // the distance to move between frames
|
||||
int mTotalMovement; // the total distance this animation moves
|
||||
QSize mMaximumSize; // the maximum size of any frame
|
||||
};
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
typedef QPtrList<AmorAnim> AmorAnimationGroup;
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// AmorThemeManager maintains an animation theme
|
||||
//
|
||||
class AmorThemeManager
|
||||
{
|
||||
public:
|
||||
AmorThemeManager();
|
||||
virtual ~AmorThemeManager();
|
||||
|
||||
bool setTheme(const QString & file);
|
||||
bool readGroup(const QString & seq);
|
||||
bool isStatic() const
|
||||
{ return mStatic; }
|
||||
|
||||
AmorAnim *random(const QString & group);
|
||||
|
||||
QSize maximumSize() const { return mMaximumSize; }
|
||||
|
||||
protected:
|
||||
QString mPath;
|
||||
KSimpleConfig *mConfig;
|
||||
QSize mMaximumSize; // The largest pixmap used
|
||||
QDict<AmorAnimationGroup> mAnimations; // list of animation groups
|
||||
bool mStatic; // static image
|
||||
};
|
||||
|
||||
#endif // AMORANIM_H
|
||||
|
@ -0,0 +1,250 @@
|
||||
/* amorbubble.cpp
|
||||
**
|
||||
** Copyright (c) 1999 Martin R. Jones <mjones@kde.org>
|
||||
**
|
||||
*/
|
||||
|
||||
/*
|
||||
** 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
|
||||
** the Free Software Foundation; either version 2 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program in a file called COPYING; if not, write to
|
||||
** the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
||||
** MA 02110-1301, USA.
|
||||
*/
|
||||
|
||||
/*
|
||||
** Bug reports and questions can be sent to kde-devel@kde.org
|
||||
*/
|
||||
#include "amorbubble.h"
|
||||
#include "amorbubble.moc"
|
||||
#include <qpainter.h>
|
||||
#include <ktextbrowser.h>
|
||||
#include <qtooltip.h>
|
||||
#include <kstandarddirs.h>
|
||||
#include <X11/Xlib.h>
|
||||
#include <X11/extensions/shape.h>
|
||||
#include <qtimer.h>
|
||||
|
||||
#define ARROW_WIDTH 10
|
||||
#define ARROW_HEIGHT 12
|
||||
#define BORDER_SIZE 4
|
||||
#define BUBBLE_OFFSET 16
|
||||
#define BUBBLE_TIMEOUT 4000 // Minimum milliseconds to display a tip
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Constructor
|
||||
//
|
||||
AmorBubble::AmorBubble()
|
||||
: QWidget(0, 0, WStyle_Customize | WStyle_NoBorder | WX11BypassWM )
|
||||
{
|
||||
mOriginX = 0;
|
||||
mOriginY = 0;
|
||||
mBrowser = new KTextBrowser( this );
|
||||
mBrowser->setFrameStyle( QFrame::NoFrame | QFrame::Plain );
|
||||
mBrowser->setMargin( 0 );
|
||||
|
||||
mBrowser->setWrapPolicy(QTextEdit::AtWordOrDocumentBoundary); // too long to fit in one line?
|
||||
|
||||
QColorGroup clgrp = mBrowser->colorGroup();
|
||||
clgrp.setColor(QColorGroup::Text, Qt::black);
|
||||
//Laurent QTextBrowser didn't have this function FIX me
|
||||
//mBrowser->setPaperColorGroup( clgrp );
|
||||
mBrowser->setPaper( QToolTip::palette().active().brush( QColorGroup::Background ) );
|
||||
mBrowser->setVScrollBarMode( QTextBrowser::AlwaysOff );
|
||||
mBrowser->setHScrollBarMode( QTextBrowser::AlwaysOff );
|
||||
mBrowser->viewport()->installEventFilter( this );
|
||||
|
||||
mBrowser->mimeSourceFactory()->addFilePath(KGlobal::dirs()->findResourceDir("data", "kdewizard/pics")+"kdewizard/pics/");
|
||||
QStringList icons = KGlobal::dirs()->resourceDirs("icon");
|
||||
QStringList::Iterator it;
|
||||
for (it = icons.begin(); it != icons.end(); ++it)
|
||||
mBrowser->mimeSourceFactory()->addFilePath(*it);
|
||||
|
||||
mMouseWithin = false;
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Destructor
|
||||
//
|
||||
AmorBubble::~AmorBubble()
|
||||
{
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Set the message to display in the bubble. Causes the geometry of the
|
||||
// widget to be recalculated.
|
||||
//
|
||||
void AmorBubble::setMessage(const QString& message)
|
||||
{
|
||||
mMessage = QString( "<html>%1</html>" ).arg( message );
|
||||
// hacks because heightForWidth() doesn't work.
|
||||
setGeometry( -1000, 0, 300, 1000 );
|
||||
show();
|
||||
mBrowser->setGeometry( 0, 0, 250, 1000 );
|
||||
mBrowser->setText( mMessage );
|
||||
calcGeometry();
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Calculates the size, position and mask of the bubble
|
||||
//
|
||||
void AmorBubble::calcGeometry()
|
||||
{
|
||||
mBound = QRect( 0, 0, 250, 0 );
|
||||
// mBound.setHeight( mBrowser->heightForWidth( mBound.width() ) );
|
||||
mBound.setHeight( mBrowser->contentsHeight() );
|
||||
mBound.moveBy(ARROW_WIDTH+BORDER_SIZE, BORDER_SIZE);
|
||||
|
||||
// initialise the default geometry of the bubble
|
||||
int w = mBound.width() + BORDER_SIZE * 2 + ARROW_WIDTH;
|
||||
int h = mBound.height() + BORDER_SIZE * 2;
|
||||
int xpos = mOriginX + BUBBLE_OFFSET;
|
||||
int ypos = mOriginY - BORDER_SIZE - ARROW_HEIGHT / 2;
|
||||
|
||||
mArrowVert = Top;
|
||||
mArrowHorz = Left;
|
||||
|
||||
// The actual position of the bubble may change if it is too close to
|
||||
// the desktop boundary.
|
||||
if (mOriginX + w > kapp->desktop()->width())
|
||||
{
|
||||
// source on right
|
||||
xpos = mOriginX - w - BUBBLE_OFFSET;
|
||||
mArrowHorz = Right;
|
||||
mBound.moveBy( -ARROW_WIDTH, 0 );
|
||||
}
|
||||
|
||||
if (mOriginY + h > kapp->desktop()->height())
|
||||
{
|
||||
// source at bottom
|
||||
ypos = mOriginY - h + BORDER_SIZE + ARROW_HEIGHT / 2;
|
||||
mArrowVert = Bottom;
|
||||
}
|
||||
|
||||
// Check for negative vertical bubble position (top of the screen)
|
||||
if ( ypos < 0 )
|
||||
ypos = 0;
|
||||
|
||||
setGeometry(xpos, ypos, w, h);
|
||||
mBrowser->setGeometry( mBound );
|
||||
|
||||
// create and apply the shape mask
|
||||
mMask.resize(w, h);
|
||||
mMask.fill(color0);
|
||||
QPainter maskPainter(&mMask);
|
||||
maskPainter.setPen(color1);
|
||||
maskPainter.setBrush(color1);
|
||||
drawBubble(maskPainter);
|
||||
XShapeCombineMask( x11Display(), winId(), ShapeBounding, 0, 0,
|
||||
mMask.handle(), ShapeSet );
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Draw the bubble that text will be draw into using the current pen
|
||||
// as the outline and the current brush as the fill.
|
||||
//
|
||||
void AmorBubble::drawBubble(QPainter &p)
|
||||
{
|
||||
QPointArray pointArray(3);
|
||||
|
||||
int left = ARROW_WIDTH;
|
||||
|
||||
if (mArrowHorz == Left)
|
||||
{
|
||||
pointArray.setPoint(0, ARROW_WIDTH+1, 0);
|
||||
pointArray.setPoint(1, 0, -3);
|
||||
pointArray.setPoint(2, ARROW_WIDTH+1, ARROW_HEIGHT);
|
||||
}
|
||||
else
|
||||
{
|
||||
pointArray.setPoint(0, 0, 0);
|
||||
pointArray.setPoint(1, ARROW_WIDTH+1, -3);
|
||||
pointArray.setPoint(2, 0, ARROW_HEIGHT);
|
||||
pointArray.translate(width() - ARROW_WIDTH - 1, 0);
|
||||
left = 0;
|
||||
}
|
||||
|
||||
if (mArrowVert == Top)
|
||||
{
|
||||
pointArray.translate(0, BORDER_SIZE + ARROW_HEIGHT / 2);
|
||||
}
|
||||
else
|
||||
{
|
||||
pointArray.translate(0, height() - BORDER_SIZE - ARROW_HEIGHT / 2);
|
||||
}
|
||||
|
||||
// p.drawRoundRect(left, 0, width() - ARROW_WIDTH, height(), 10, 20);
|
||||
p.drawRect(left, 0, width() - ARROW_WIDTH, height());
|
||||
|
||||
QPen pen(p.pen());
|
||||
p.setPen(NoPen);
|
||||
p.drawPolygon(pointArray);
|
||||
|
||||
p.setPen(pen);
|
||||
p.drawPolyline(pointArray, 0, 3);
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Draw the message in a bubble
|
||||
//
|
||||
void AmorBubble::paintEvent(QPaintEvent *)
|
||||
{
|
||||
QPainter painter(this);
|
||||
painter.setPen(black);
|
||||
painter.setBrush( QToolTip::palette().active().brush( QColorGroup::Background ) );
|
||||
drawBubble(painter);
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// The user clicked on the widget
|
||||
//
|
||||
void AmorBubble::mouseReleaseEvent(QMouseEvent *)
|
||||
{
|
||||
hide();
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
bool AmorBubble::eventFilter( QObject *, QEvent *e )
|
||||
{
|
||||
switch ( e->type() )
|
||||
{
|
||||
|
||||
// GP case QEvent::Enter:
|
||||
// GP mBubbleTimer->stop();
|
||||
// GP break;
|
||||
// GP case QEvent::Leave:
|
||||
// GP if ( isVisible() )
|
||||
// GP mBubbleTimer->start( 1000, true );
|
||||
// GP break;
|
||||
case QEvent::Enter:
|
||||
mMouseWithin = true;
|
||||
break;
|
||||
case QEvent::Leave:
|
||||
mMouseWithin = false;
|
||||
break;
|
||||
case QEvent::MouseButtonRelease:
|
||||
hide(); // GP This is the only reason a bubble might posibly be created but hidden
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
@ -0,0 +1,81 @@
|
||||
/* amorbubble.h
|
||||
**
|
||||
** Copyright (c) 1999 Martin R. Jones <mjones@kde.org>
|
||||
**
|
||||
*/
|
||||
|
||||
/*
|
||||
** 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
|
||||
** the Free Software Foundation; either version 2 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program in a file called COPYING; if not, write to
|
||||
** the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
||||
** MA 02110-1301, USA.
|
||||
*/
|
||||
|
||||
/*
|
||||
** Bug reports and questions can be sent to kde-devel@kde.org
|
||||
*/
|
||||
#ifndef AMORBUBBLE_H
|
||||
#define AMORBUBBLE_H
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include <config.h>
|
||||
#endif
|
||||
|
||||
#include <kapplication.h>
|
||||
#include <qwidget.h>
|
||||
#include <qbitmap.h>
|
||||
|
||||
class QTextBrowser;
|
||||
class QTimer;
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// AmorBubble displays a message in a shaped window
|
||||
//
|
||||
class AmorBubble : public QWidget
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
AmorBubble();
|
||||
virtual ~AmorBubble();
|
||||
|
||||
void setOrigin(int x, int y) { mOriginX = x; mOriginY = y; }
|
||||
void setMessage(const QString& message);
|
||||
|
||||
bool mouseWithin() { return mMouseWithin; }
|
||||
|
||||
protected:
|
||||
enum VertPos { Top, Bottom };
|
||||
enum HorzPos { Left, Right };
|
||||
|
||||
void calcGeometry();
|
||||
void drawBubble(QPainter &p);
|
||||
virtual void paintEvent(QPaintEvent *);
|
||||
virtual void mouseReleaseEvent(QMouseEvent *);
|
||||
virtual bool eventFilter( QObject *, QEvent * );
|
||||
|
||||
protected:
|
||||
QString mMessage; // message to display
|
||||
int mOriginX; // X origin of bubble arrow
|
||||
int mOriginY; // Y origin of bubble arrow
|
||||
QRect mBound; // bounds of the text
|
||||
QBitmap mMask; // shape mask
|
||||
VertPos mArrowVert; // vertical position of the arrow
|
||||
HorzPos mArrowHorz; // horizontal position of the arrow
|
||||
QTextBrowser *mBrowser; // displays the message
|
||||
|
||||
bool mMouseWithin; // the mouse pointer is inside the bubble
|
||||
};
|
||||
|
||||
#endif // AMORBUBBLE_H
|
||||
|
@ -0,0 +1,83 @@
|
||||
/* amorconfig.cpp
|
||||
**
|
||||
** Copyright (c) 1999 Martin R. Jones <mjones@kde.org>
|
||||
**
|
||||
*/
|
||||
|
||||
/*
|
||||
** 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
|
||||
** the Free Software Foundation; either version 2 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program in a file called COPYING; if not, write to
|
||||
** the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
||||
** MA 02110-1301, USA.
|
||||
*/
|
||||
|
||||
/*
|
||||
** Bug reports and questions can be sent to kde-devel@kde.org
|
||||
*/
|
||||
#include <kapplication.h>
|
||||
#include "amorconfig.h"
|
||||
#include <kconfig.h>
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Constructor
|
||||
//
|
||||
AmorConfig::AmorConfig()
|
||||
{
|
||||
mOnTop = false;
|
||||
mOffset = 0;
|
||||
mTheme = "blobrc";
|
||||
mTips = false;
|
||||
mAppTips = true;
|
||||
mStaticPos = 20;
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Read the configuration
|
||||
//
|
||||
void AmorConfig::read()
|
||||
{
|
||||
KConfig *config = kapp->config();
|
||||
KConfigGroupSaver cs(config, "General");
|
||||
|
||||
mOnTop = config->readBoolEntry("OnTop", false);
|
||||
mOffset = config->readNumEntry("Offset", 0);
|
||||
mTheme = config->readEntry("Theme", "blobrc");
|
||||
mTips = config->readBoolEntry("Tips", false);
|
||||
mRandomTheme = config->readBoolEntry("RandomTheme", false);
|
||||
mAppTips = config->readBoolEntry("ApplicationTips", true);
|
||||
mStaticPos = config->readNumEntry("StaticPosition", 20);
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Write the configuration
|
||||
//
|
||||
void AmorConfig::write()
|
||||
{
|
||||
KConfig *config = kapp->config();
|
||||
KConfigGroupSaver cs(config, "General");
|
||||
|
||||
config->writeEntry("OnTop", mOnTop);
|
||||
config->writeEntry("Offset", mOffset);
|
||||
config->writeEntry("Theme", mTheme);
|
||||
config->writeEntry("Tips", mTips);
|
||||
config->writeEntry("RandomTheme", mRandomTheme);
|
||||
config->writeEntry("ApplicationTips", mAppTips);
|
||||
config->writeEntry("StaticPosition", mStaticPos);
|
||||
|
||||
config->sync();
|
||||
}
|
||||
|
||||
|
@ -0,0 +1,58 @@
|
||||
/* amorconfig.h
|
||||
**
|
||||
** Copyright (c) 1999 Martin R. Jones <mjones@kde.org>
|
||||
**
|
||||
*/
|
||||
|
||||
/*
|
||||
** 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
|
||||
** the Free Software Foundation; either version 2 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program in a file called COPYING; if not, write to
|
||||
** the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
||||
** MA 02110-1301, USA.
|
||||
*/
|
||||
|
||||
/*
|
||||
** Bug reports and questions can be sent to kde-devel@kde.org
|
||||
*/
|
||||
#ifndef AMORCONFIG_H
|
||||
#define AMORCONFIG_H
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include <config.h>
|
||||
#endif
|
||||
|
||||
#include <qstring.h>
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// AmorConfig contains amor configuration parameters
|
||||
//
|
||||
class AmorConfig
|
||||
{
|
||||
public:
|
||||
AmorConfig();
|
||||
|
||||
void read();
|
||||
void write();
|
||||
|
||||
QString mTheme;
|
||||
bool mOnTop;
|
||||
int mOffset;
|
||||
bool mTips;
|
||||
bool mRandomTheme;
|
||||
bool mAppTips;
|
||||
int mStaticPos;
|
||||
};
|
||||
|
||||
#endif // AMORCONFIG_H
|
||||
|
@ -0,0 +1,285 @@
|
||||
/* amordialog.cpp
|
||||
**
|
||||
** Copyright (c) 1999 Martin R. Jones <mjones@kde.org>
|
||||
**
|
||||
*/
|
||||
|
||||
/*
|
||||
** 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
|
||||
** the Free Software Foundation; either version 2 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program in a file called COPYING; if not, write to
|
||||
** the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
||||
** MA 02110-1301, USA.
|
||||
*/
|
||||
|
||||
/*
|
||||
** Bug reports and questions can be sent to kde-devel@kde.org
|
||||
*/
|
||||
|
||||
#include <qcheckbox.h>
|
||||
#include <qlabel.h>
|
||||
#include <qslider.h>
|
||||
#include <qpainter.h>
|
||||
#include <kapplication.h>
|
||||
#include <ksimpleconfig.h>
|
||||
#include "amordialog.h"
|
||||
#include "amordialog.moc"
|
||||
#include "version.h"
|
||||
#include <klocale.h>
|
||||
#include <qvbox.h>
|
||||
#include <kstandarddirs.h>
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Constructor
|
||||
//
|
||||
AmorDialog::AmorDialog()
|
||||
: KDialogBase(0, "amordlg", false, i18n("Options"), Ok|Apply|Cancel, Ok )
|
||||
{
|
||||
mConfig.read();
|
||||
QVBox *mainwidget = makeVBoxMainWidget();
|
||||
|
||||
QHBox *hb = new QHBox(mainwidget);
|
||||
|
||||
// Theme list
|
||||
QVBox *themeBox = new QVBox(hb);
|
||||
themeBox->setSpacing(spacingHint());
|
||||
|
||||
QLabel *label = new QLabel(i18n("Theme:"), themeBox);
|
||||
|
||||
mThemeListBox = new QListBox(themeBox);
|
||||
connect(mThemeListBox,SIGNAL(highlighted(int)),SLOT(slotHighlighted(int)));
|
||||
mThemeListBox->setMinimumSize( fontMetrics().maxWidth()*20,
|
||||
fontMetrics().lineSpacing()*6 );
|
||||
|
||||
mAboutEdit = new QMultiLineEdit(themeBox);
|
||||
mAboutEdit->setReadOnly(true);
|
||||
mAboutEdit->setMinimumHeight( fontMetrics().lineSpacing()*4 );
|
||||
|
||||
themeBox->setStretchFactor(mThemeListBox, 4);
|
||||
themeBox->setStretchFactor(mAboutEdit, 1);
|
||||
|
||||
// Animation offset
|
||||
QVBox *offsetBox = new QVBox(hb);
|
||||
offsetBox->setSpacing(spacingHint());
|
||||
label = new QLabel(i18n("Offset:"), offsetBox);
|
||||
|
||||
QSlider *slider = new QSlider(-40, 40, 5, mConfig.mOffset,
|
||||
QSlider::Vertical, offsetBox);
|
||||
connect(slider, SIGNAL(valueChanged(int)), SLOT(slotOffset(int)));
|
||||
|
||||
// Always on top
|
||||
QCheckBox *checkBox = new QCheckBox(i18n("Always on top"), mainwidget);
|
||||
connect(checkBox, SIGNAL(toggled(bool)), SLOT(slotOnTop(bool)));
|
||||
checkBox->setChecked(mConfig.mOnTop);
|
||||
|
||||
checkBox = new QCheckBox(i18n("Show random tips"), mainwidget);
|
||||
connect(checkBox, SIGNAL(toggled(bool)), SLOT(slotRandomTips(bool)));
|
||||
checkBox->setChecked(mConfig.mTips); // always keep this one after the connect, or the QList would not be grayed when it should
|
||||
|
||||
checkBox = new QCheckBox(i18n("Use a random character"), mainwidget);
|
||||
connect(checkBox, SIGNAL(toggled(bool)), SLOT(slotRandomTheme(bool)));
|
||||
checkBox->setChecked(mConfig.mRandomTheme);
|
||||
|
||||
checkBox = new QCheckBox(i18n("Allow application tips"), mainwidget);
|
||||
connect(checkBox, SIGNAL(toggled(bool)), SLOT(slotApplicationTips(bool)));
|
||||
checkBox->setChecked(mConfig.mAppTips);
|
||||
|
||||
readThemes();
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Destructor
|
||||
//
|
||||
AmorDialog::~AmorDialog()
|
||||
{
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Get list of all themes
|
||||
//
|
||||
void AmorDialog::readThemes()
|
||||
{
|
||||
QStringList files;
|
||||
|
||||
// Non-recursive search for theme files, with the relative paths stored
|
||||
// in files so that absolute paths are not used.
|
||||
KGlobal::dirs()->findAllResources("appdata", "*rc", false, false, files);
|
||||
|
||||
for (QStringList::ConstIterator it = files.begin();
|
||||
it != files.end();
|
||||
it++)
|
||||
addTheme(*it);
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Add a single theme to the list
|
||||
//
|
||||
void AmorDialog::addTheme(const QString& file)
|
||||
{
|
||||
KSimpleConfig config(locate("appdata", file), true);
|
||||
|
||||
config.setGroup("Config");
|
||||
|
||||
QString pixmapPath = config.readPathEntry("PixmapPath");
|
||||
if (pixmapPath.isEmpty())
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
pixmapPath += "/";
|
||||
|
||||
if (pixmapPath[0] != '/')
|
||||
{
|
||||
// relative to config file. We add a / to indicate the dir
|
||||
pixmapPath = locate("appdata", pixmapPath);
|
||||
}
|
||||
|
||||
QString description = config.readEntry("Description");
|
||||
QString about = config.readEntry("About", " ");
|
||||
QString pixmapName = config.readEntry("Icon");
|
||||
|
||||
pixmapPath += pixmapName;
|
||||
|
||||
QPixmap pixmap(pixmapPath);
|
||||
|
||||
AmorListBoxItem *item = new AmorListBoxItem(description, pixmap);
|
||||
mThemeListBox->insertItem(item);
|
||||
mThemes.append(file);
|
||||
mThemeAbout.append(about);
|
||||
|
||||
if (mConfig.mTheme == file)
|
||||
{
|
||||
mThemeListBox->setSelected(mThemeListBox->count()-1, true);
|
||||
}
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// User highlighted a theme
|
||||
//
|
||||
void AmorDialog::slotHighlighted(int index)
|
||||
{
|
||||
mConfig.mTheme = *mThemes.at(index);
|
||||
mAboutEdit->setText(*mThemeAbout.at(index));
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// User changed offset
|
||||
//
|
||||
void AmorDialog::slotOffset(int off)
|
||||
{
|
||||
mConfig.mOffset = off;
|
||||
emit offsetChanged(mConfig.mOffset);
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// User toggled always on top
|
||||
//
|
||||
void AmorDialog::slotOnTop(bool onTop)
|
||||
{
|
||||
mConfig.mOnTop = onTop;
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// User toggled random tips
|
||||
//
|
||||
void AmorDialog::slotRandomTips(bool tips)
|
||||
{
|
||||
mConfig.mTips = tips;
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// User toggled random character
|
||||
//
|
||||
void AmorDialog::slotRandomTheme(bool randomTheme)
|
||||
{
|
||||
mThemeListBox->setEnabled(!randomTheme);
|
||||
mConfig.mRandomTheme = randomTheme;
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// User toggled application tips
|
||||
//
|
||||
void AmorDialog::slotApplicationTips(bool tips)
|
||||
{
|
||||
mConfig.mAppTips = tips;
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// User clicked Ok
|
||||
//
|
||||
void AmorDialog::slotOk()
|
||||
{
|
||||
mConfig.write();
|
||||
emit changed();
|
||||
accept();
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// User clicked Ok
|
||||
//
|
||||
void AmorDialog::slotApply()
|
||||
{
|
||||
mConfig.write();
|
||||
emit changed();
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// User clicked Cancel
|
||||
//
|
||||
void AmorDialog::slotCancel()
|
||||
{
|
||||
// restore offset
|
||||
KConfig *config = kapp->config();
|
||||
KConfigGroupSaver cs(config, "General");
|
||||
emit offsetChanged(config->readNumEntry("Offset"));
|
||||
reject();
|
||||
}
|
||||
|
||||
//===========================================================================
|
||||
//
|
||||
// AmorListBoxItem implements a list box items for selection of themes
|
||||
//
|
||||
void AmorListBoxItem::paint( QPainter *p )
|
||||
{
|
||||
p->drawPixmap( 3, 0, mPixmap );
|
||||
QFontMetrics fm = p->fontMetrics();
|
||||
int yPos; // vertical text position
|
||||
if ( mPixmap.height() < fm.height() )
|
||||
yPos = fm.ascent() + fm.leading()/2;
|
||||
else
|
||||
yPos = mPixmap.height()/2 - fm.height()/2 + fm.ascent();
|
||||
p->drawText( mPixmap.width() + 5, yPos, text() );
|
||||
}
|
||||
|
||||
int AmorListBoxItem::height(const QListBox *lb ) const
|
||||
{
|
||||
return QMAX( mPixmap.height(), lb->fontMetrics().lineSpacing() + 1 );
|
||||
}
|
||||
|
||||
int AmorListBoxItem::width(const QListBox *lb ) const
|
||||
{
|
||||
return mPixmap.width() + lb->fontMetrics().width( text() ) + 6;
|
||||
}
|
||||
|
@ -0,0 +1,107 @@
|
||||
/* amordialog.h
|
||||
**
|
||||
** Copyright (c) 1999 Martin R. Jones <mjones@kde.org>
|
||||
**
|
||||
*/
|
||||
|
||||
/*
|
||||
** 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
|
||||
** the Free Software Foundation; either version 2 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program in a file called COPYING; if not, write to
|
||||
** the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
||||
** MA 02110-1301, USA.
|
||||
*/
|
||||
|
||||
/*
|
||||
** Bug reports and questions can be sent to kde-devel@kde.org
|
||||
*/
|
||||
#ifndef AMORDIALOG_H
|
||||
#define AMORDIALOG_H
|
||||
|
||||
#include <qdialog.h>
|
||||
#include <qlistbox.h>
|
||||
#include <qptrlist.h>
|
||||
#include <qmultilineedit.h>
|
||||
#include "amorconfig.h"
|
||||
#include <kdialogbase.h>
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// AmorDialog provides a setup dialog.
|
||||
//
|
||||
class AmorDialog : public KDialogBase
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
AmorDialog();
|
||||
virtual ~AmorDialog();
|
||||
|
||||
signals:
|
||||
//-----------------------------------------------------------------------
|
||||
//
|
||||
// The configuration has changed in some way.
|
||||
//
|
||||
void changed();
|
||||
|
||||
//-----------------------------------------------------------------------
|
||||
//
|
||||
// The animation offset has been changed.
|
||||
//
|
||||
void offsetChanged(int);
|
||||
|
||||
protected slots:
|
||||
void slotHighlighted(int);
|
||||
void slotOnTop(bool);
|
||||
void slotRandomTips(bool);
|
||||
void slotRandomTheme(bool);
|
||||
void slotApplicationTips(bool);
|
||||
void slotOffset(int);
|
||||
void slotOk();
|
||||
void slotApply();
|
||||
void slotCancel();
|
||||
|
||||
protected:
|
||||
void readThemes();
|
||||
void addTheme(const QString& file);
|
||||
|
||||
protected:
|
||||
QListBox *mThemeListBox;
|
||||
QMultiLineEdit *mAboutEdit;
|
||||
QStringList mThemes;
|
||||
QStringList mThemeAbout;
|
||||
AmorConfig mConfig;
|
||||
};
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// AmorListBoxItem implements a list box items for selection of themes
|
||||
//
|
||||
class AmorListBoxItem : public QListBoxItem
|
||||
{
|
||||
public:
|
||||
AmorListBoxItem(const QString & s, const QPixmap& p)
|
||||
: QListBoxItem(), mPixmap(p)
|
||||
{ setText(s); }
|
||||
|
||||
protected:
|
||||
virtual void paint(QPainter *);
|
||||
virtual int height(const QListBox *) const;
|
||||
virtual int width(const QListBox *) const;
|
||||
virtual const QPixmap *pixmap() const { return &mPixmap; }
|
||||
|
||||
private:
|
||||
QPixmap mPixmap;
|
||||
};
|
||||
|
||||
#endif // AMORDIALOG_H
|
||||
|
@ -0,0 +1,94 @@
|
||||
/* amorpm.cpp
|
||||
**
|
||||
** Copyright (c) 1999 Martin R. Jones <mjones@kde.org>
|
||||
**
|
||||
*/
|
||||
|
||||
/*
|
||||
** 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
|
||||
** the Free Software Foundation; either version 2 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program in a file called COPYING; if not, write to
|
||||
** the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
||||
** MA 02110-1301, USA.
|
||||
*/
|
||||
|
||||
/*
|
||||
** Bug reports and questions can be sent to kde-devel@kde.org
|
||||
*/
|
||||
#include "amorpm.h"
|
||||
|
||||
// static
|
||||
AmorPixmapManager *AmorPixmapManager::mManager = 0;
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Constructor
|
||||
//
|
||||
AmorPixmapManager::AmorPixmapManager()
|
||||
: mPixmapDir(".")
|
||||
{
|
||||
mPixmaps.setAutoDelete(true);
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Destructor
|
||||
//
|
||||
AmorPixmapManager::~AmorPixmapManager()
|
||||
{
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Load an image into the image manager
|
||||
//
|
||||
// Returns:
|
||||
// pointer to pixmap if loaded successfully, 0 otherwise.
|
||||
//
|
||||
const QPixmap *AmorPixmapManager::load(const QString & img)
|
||||
{
|
||||
QPixmap *pixmap = mPixmaps.find(img);
|
||||
|
||||
if (!pixmap)
|
||||
{
|
||||
// pixmap has not yet been loaded.
|
||||
QString path = mPixmapDir + QString("/") + img;
|
||||
pixmap = new QPixmap(path);
|
||||
|
||||
if (!pixmap->isNull())
|
||||
{
|
||||
mPixmaps.insert(img,pixmap);
|
||||
}
|
||||
else
|
||||
{
|
||||
delete pixmap;
|
||||
pixmap = 0;
|
||||
}
|
||||
}
|
||||
|
||||
return pixmap;
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// returns a pointer to the pixmap manager.
|
||||
//
|
||||
AmorPixmapManager *AmorPixmapManager::manager()
|
||||
{
|
||||
if (!mManager)
|
||||
{
|
||||
mManager = new AmorPixmapManager();
|
||||
}
|
||||
|
||||
return mManager;
|
||||
}
|
||||
|
@ -0,0 +1,64 @@
|
||||
/* amorpm.h
|
||||
**
|
||||
** Copyright (c) 1999 Martin R. Jones <mjones@kde.org>
|
||||
**
|
||||
*/
|
||||
|
||||
/*
|
||||
** 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
|
||||
** the Free Software Foundation; either version 2 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program in a file called COPYING; if not, write to
|
||||
** the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
||||
** MA 02110-1301, USA.
|
||||
*/
|
||||
|
||||
/*
|
||||
** Bug reports and questions can be sent to kde-devel@kde.org
|
||||
*/
|
||||
#ifndef AMORPM_H
|
||||
#define AMORPM_H
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include <config.h>
|
||||
#endif
|
||||
|
||||
#include <qdict.h>
|
||||
#include <qpixmap.h>
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// AmorPixmapManager stores the frames used in animations.
|
||||
//
|
||||
class AmorPixmapManager
|
||||
{
|
||||
public:
|
||||
AmorPixmapManager();
|
||||
virtual ~AmorPixmapManager();
|
||||
|
||||
void setPixmapDir(const QString &dir)
|
||||
{ mPixmapDir = dir; }
|
||||
void reset()
|
||||
{ mPixmapDir = "."; mPixmaps.clear(); }
|
||||
const QPixmap *load(const QString & img);
|
||||
const QPixmap *pixmap(const QString & img) const
|
||||
{ return mPixmaps.find(img); }
|
||||
|
||||
static AmorPixmapManager *manager();
|
||||
|
||||
public:
|
||||
QString mPixmapDir; // get pixmaps from here
|
||||
QDict<QPixmap> mPixmaps; // list of pixmaps
|
||||
static AmorPixmapManager *mManager; // static pointer to instance
|
||||
};
|
||||
|
||||
#endif // AMORPM_H
|
||||
|
@ -0,0 +1,181 @@
|
||||
/* amortips.cpp
|
||||
**
|
||||
** Copyright (c) 1999 Martin R. Jones <mjones@kde.org>
|
||||
**
|
||||
*/
|
||||
|
||||
/*
|
||||
** 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
|
||||
** the Free Software Foundation; either version 2 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program in a file called COPYING; if not, write to
|
||||
** the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
||||
** MA 02110-1301, USA.
|
||||
*/
|
||||
|
||||
/*
|
||||
** Bug reports and questions can be sent to kde-devel@kde.org
|
||||
*/
|
||||
#include <stdlib.h>
|
||||
#include <kapplication.h>
|
||||
#include "amortips.h"
|
||||
#include <kstandarddirs.h>
|
||||
#include <klocale.h>
|
||||
#include <qfile.h>
|
||||
#include <qregexp.h>
|
||||
#include <kdebug.h>
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
AmorTips::AmorTips()
|
||||
{
|
||||
KGlobal::locale()->insertCatalogue("ktip"); // For ktip tip translations
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Set the file containing tips. This reads all tips into memory at the
|
||||
// moment - need to make more efficient.
|
||||
//
|
||||
bool AmorTips::setFile(const QString& file)
|
||||
{
|
||||
bool rv = false;
|
||||
|
||||
QString path( locate("appdata", file) );
|
||||
if(path.length() && read(path))
|
||||
rv = true;
|
||||
|
||||
rv |= readKTips();
|
||||
|
||||
return rv;
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Clear all tips from memory
|
||||
//
|
||||
void AmorTips::reset()
|
||||
{
|
||||
mTips.clear();
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Get a tip randomly from the list
|
||||
//
|
||||
QString AmorTips::tip()
|
||||
{
|
||||
if (mTips.count())
|
||||
{
|
||||
QString tip = *mTips.at(kapp->random() % mTips.count());
|
||||
return i18n(tip.utf8());
|
||||
}
|
||||
|
||||
return i18n("No tip");
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Read the tips from ktip's file
|
||||
//
|
||||
bool AmorTips::readKTips()
|
||||
{
|
||||
QString fname;
|
||||
|
||||
fname = locate("data", QString("kdewizard/tips"));
|
||||
|
||||
if (fname.isEmpty())
|
||||
return false;
|
||||
|
||||
QFile f(fname);
|
||||
if (f.open(IO_ReadOnly))
|
||||
{
|
||||
// Reading of tips must be exactly as in KTipDatabase::loadTips for translation
|
||||
QString content = f.readAll();
|
||||
const QRegExp rx("\\n+");
|
||||
|
||||
int pos = -1;
|
||||
while ((pos = content.find("<html>", pos + 1, false)) != -1)
|
||||
{
|
||||
QString tip = content
|
||||
.mid(pos + 6, content.find("</html>", pos, false) - pos - 6)
|
||||
.replace(rx, "\n");
|
||||
if (!tip.endsWith("\n"))
|
||||
tip += "\n";
|
||||
if (tip.startsWith("\n"))
|
||||
tip = tip.mid(1);
|
||||
if (tip.isEmpty())
|
||||
{
|
||||
kdDebug() << "Empty tip found! Skipping! " << pos << endl;
|
||||
continue;
|
||||
}
|
||||
mTips.append(tip);
|
||||
}
|
||||
|
||||
f.close();
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Read all tips from the specified file.
|
||||
//
|
||||
bool AmorTips::read(const QString& path)
|
||||
{
|
||||
QFile file(path);
|
||||
|
||||
if (file.open(IO_ReadOnly))
|
||||
{
|
||||
while (!file.atEnd())
|
||||
{
|
||||
readTip(file);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Read a single tip.
|
||||
//
|
||||
bool AmorTips::readTip(QFile &file)
|
||||
{
|
||||
char buffer[1024] = "";
|
||||
QString tip;
|
||||
|
||||
while (!file.atEnd() && buffer[0] != '%')
|
||||
{
|
||||
file.readLine(buffer, 1024);
|
||||
if (buffer[0] != '%')
|
||||
{
|
||||
tip += QString::fromUtf8(buffer);
|
||||
}
|
||||
}
|
||||
|
||||
if (!tip.isEmpty())
|
||||
{
|
||||
if (tip[tip.length()-1] == '\n')
|
||||
{
|
||||
tip.truncate(tip.length()-1);
|
||||
}
|
||||
mTips.append(tip);
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -0,0 +1,60 @@
|
||||
/* amortips.h
|
||||
**
|
||||
** Copyright (c) 1999 Martin R. Jones <mjones@kde.org>
|
||||
**
|
||||
*/
|
||||
|
||||
/*
|
||||
** 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
|
||||
** the Free Software Foundation; either version 2 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program in a file called COPYING; if not, write to
|
||||
** the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
||||
** MA 02110-1301, USA.
|
||||
*/
|
||||
|
||||
/*
|
||||
** Bug reports and questions can be sent to kde-devel@kde.org
|
||||
*/
|
||||
#ifndef AMORTIPS_H
|
||||
#define AMORTIPS_H
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include <config.h>
|
||||
#endif
|
||||
|
||||
#include <qstrlist.h>
|
||||
class QFile;
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// AmorTips selects random tips from a data file
|
||||
//
|
||||
class AmorTips
|
||||
{
|
||||
public:
|
||||
AmorTips();
|
||||
|
||||
bool setFile(const QString& file);
|
||||
void reset();
|
||||
QString tip();
|
||||
|
||||
protected:
|
||||
bool readKTips();
|
||||
bool read(const QString& file);
|
||||
bool readTip(QFile &file);
|
||||
|
||||
protected:
|
||||
QStringList mTips;
|
||||
};
|
||||
|
||||
#endif // AMORTIPS_H
|
||||
|
@ -0,0 +1,125 @@
|
||||
/* amorwidget.cpp
|
||||
**
|
||||
** Copyright (c) 1999 Martin R. Jones <mjones@kde.org>
|
||||
**
|
||||
*/
|
||||
|
||||
/*
|
||||
** 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
|
||||
** the Free Software Foundation; either version 2 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program in a file called COPYING; if not, write to
|
||||
** the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
||||
** MA 02110-1301, USA.
|
||||
*/
|
||||
|
||||
/*
|
||||
** Bug reports and questions can be sent to kde-devel@kde.org
|
||||
*/
|
||||
#include "amorwidget.h"
|
||||
#include "amorwidget.moc"
|
||||
#include <qbitmap.h>
|
||||
#include <X11/Xlib.h>
|
||||
#include <X11/extensions/shape.h>
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Constructor
|
||||
//
|
||||
AmorWidget::AmorWidget()
|
||||
: QWidget(0, 0, WStyle_Customize | WStyle_NoBorder | WX11BypassWM ),
|
||||
mPixmap(0)
|
||||
{
|
||||
setBackgroundMode( NoBackground );
|
||||
dragging = false;
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Destructor
|
||||
//
|
||||
AmorWidget::~AmorWidget()
|
||||
{
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Set the pixmap to display
|
||||
//
|
||||
void AmorWidget::setPixmap(const QPixmap *pixmap)
|
||||
{
|
||||
mPixmap = pixmap;
|
||||
|
||||
if (mPixmap)
|
||||
{
|
||||
if (mPixmap->mask())
|
||||
{
|
||||
XShapeCombineMask( x11Display(), winId(), ShapeBounding, 0, 0,
|
||||
mPixmap->mask()->handle(), ShapeSet );
|
||||
repaint(false);
|
||||
}
|
||||
|
||||
update();
|
||||
}
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// Draw the pixmap
|
||||
//
|
||||
void AmorWidget::paintEvent(QPaintEvent *)
|
||||
{
|
||||
if (mPixmap)
|
||||
bitBlt( this, 0, 0, mPixmap );
|
||||
else
|
||||
erase();
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// The user clicked on the widget
|
||||
//
|
||||
void AmorWidget::mousePressEvent(QMouseEvent *me)
|
||||
{
|
||||
clickPos = me->globalPos();
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// The user moved the mouse
|
||||
//
|
||||
void AmorWidget::mouseMoveEvent(QMouseEvent *me)
|
||||
{
|
||||
if ( me->state() == LeftButton ) {
|
||||
if ( !dragging && (clickPos-me->globalPos()).manhattanLength() > 3 )
|
||||
dragging = true;
|
||||
if ( dragging ) {
|
||||
emit dragged( me->globalPos() - clickPos, false );
|
||||
clickPos = me->globalPos();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// The user clicked on the widget
|
||||
//
|
||||
void AmorWidget::mouseReleaseEvent(QMouseEvent *me)
|
||||
{
|
||||
if ( dragging )
|
||||
emit dragged( me->globalPos() - clickPos, true );
|
||||
else if ( me->state() == RightButton )
|
||||
emit mouseClicked(clickPos);
|
||||
|
||||
clickPos = QPoint();
|
||||
dragging = false;
|
||||
}
|
||||
|
@ -0,0 +1,67 @@
|
||||
/* amorwidget.h
|
||||
**
|
||||
** Copyright (c) 1999 Martin R. Jones <mjones@kde.org>
|
||||
**
|
||||
*/
|
||||
|
||||
/*
|
||||
** 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
|
||||
** the Free Software Foundation; either version 2 of the License, or
|
||||
** (at your option) any later version.
|
||||
**
|
||||
** This program is distributed in the hope that it will be useful,
|
||||
** but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
** GNU General Public License for more details.
|
||||
**
|
||||
** You should have received a copy of the GNU General Public License
|
||||
** along with this program in a file called COPYING; if not, write to
|
||||
** the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
||||
** MA 02110-1301, USA.
|
||||
*/
|
||||
|
||||
/*
|
||||
** Bug reports and questions can be sent to kde-devel@kde.org
|
||||
*/
|
||||
#ifndef AMORWIDGET_H
|
||||
#define AMORWIDGET_H
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include <config.h>
|
||||
#endif
|
||||
|
||||
#include <kapplication.h>
|
||||
#include <qwidget.h>
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
//
|
||||
// AmorWidget displays a shaped pixmap
|
||||
//
|
||||
class AmorWidget : public QWidget
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
AmorWidget();
|
||||
virtual ~AmorWidget();
|
||||
|
||||
void setPixmap(const QPixmap *pixmap);
|
||||
|
||||
signals:
|
||||
void mouseClicked(const QPoint &pos);
|
||||
void dragged( const QPoint &delta, bool release );
|
||||
|
||||
protected:
|
||||
void paintEvent(QPaintEvent *);
|
||||
void mousePressEvent(QMouseEvent *);
|
||||
void mouseMoveEvent(QMouseEvent *);
|
||||
void mouseReleaseEvent(QMouseEvent *);
|
||||
|
||||
protected:
|
||||
const QPixmap *mPixmap;
|
||||
QPoint clickPos;
|
||||
bool dragging;
|
||||
};
|
||||
|
||||
#endif // AMORWIDGET_H
|
||||
|
@ -0,0 +1,3 @@
|
||||
if test "x$kde_use_qt_mac" = "xyes"; then
|
||||
DO_NOT_COMPILE="$DO_NOT_COMPILE amor"
|
||||
fi
|
@ -0,0 +1,14 @@
|
||||
SUBDIRS = pics
|
||||
|
||||
amor_DATA = blobrc ghostrc eyesrc bonhommerc nekorc pingurc wormrc tips-en \
|
||||
billyrc bsdrc tuxrc taorc
|
||||
|
||||
# This is where it will all be installed
|
||||
amordir = $(kde_datadir)/amor
|
||||
|
||||
install-data-local:
|
||||
-rm -f $(DESTDIR)$(amordir)/tips
|
||||
$(LN_S) $(amordir)/tips-en $(DESTDIR)$(amordir)/tips
|
||||
|
||||
uninstall-local:
|
||||
-rm -f $(DESTDIR)$(amordir)/tips
|
@ -0,0 +1 @@
|
||||
SUBDIRS = animated preview static
|
@ -0,0 +1 @@
|
||||
SUBDIRS = blob bonhomme eyes ghost neko pingu tao worm
|
@ -0,0 +1,82 @@
|
||||
# Add all your pic files here
|
||||
amor_DATA = blob_b1.png \
|
||||
blob_b2.png \
|
||||
blob_BeamDown1.png \
|
||||
blob_BeamDown2.png \
|
||||
blob_BeamDown3.png \
|
||||
blob_BeamDown4.png \
|
||||
blob_BeamDown5.png \
|
||||
blob_BeamDown6.png \
|
||||
blob_BeamDown7.png \
|
||||
blob_BeamDown8.png \
|
||||
blob_BeamDown9.png \
|
||||
blob_BeamUp10.png \
|
||||
blob_BeamUp1.png \
|
||||
blob_BeamUp2.png \
|
||||
blob_BeamUp3.png \
|
||||
blob_BeamUp4.png \
|
||||
blob_BeamUp5.png \
|
||||
blob_BeamUp6.png \
|
||||
blob_BeamUp7.png \
|
||||
blob_BeamUp8.png \
|
||||
blob_BeamUp9.png \
|
||||
blob_e1.png \
|
||||
blob_ex1.png \
|
||||
blob_f1.png \
|
||||
blob_f2.png \
|
||||
blob_f3.png \
|
||||
blob_fire10.png \
|
||||
blob_fire11.png \
|
||||
blob_fire2.png \
|
||||
blob_fire3.png \
|
||||
blob_fire4.png \
|
||||
blob_fire5.png \
|
||||
blob_fire6.png \
|
||||
blob_fire7.png \
|
||||
blob_fire8.png \
|
||||
blob_fire9.png \
|
||||
blob_g1.png \
|
||||
blob_g2.png \
|
||||
blob_gl1.png \
|
||||
blob_gl2.png \
|
||||
blob_gl3.png \
|
||||
blob_h1.png \
|
||||
blob_h2.png \
|
||||
blob_h3.png \
|
||||
blob_jet1.png \
|
||||
blob_jet2.png \
|
||||
blob_jet3.png \
|
||||
blob_jet4.png \
|
||||
blob_l_jet1.png \
|
||||
blob_l_jet2.png \
|
||||
blob_l_jet3.png \
|
||||
blob_l_jet4.png \
|
||||
blob_l_turn1.png \
|
||||
blob_l_turn2.png \
|
||||
blob_l_turn3.png \
|
||||
blob_l_turn4.png \
|
||||
blob.png \
|
||||
blob_r135.png \
|
||||
blob_r180.png \
|
||||
blob_r225.png \
|
||||
blob_r270.png \
|
||||
blob_r315.png \
|
||||
blob_r45.png \
|
||||
blob_r90.png \
|
||||
blob_r_turn1.png \
|
||||
blob_r_turn2.png \
|
||||
blob_r_turn3.png \
|
||||
blob_r_turn4.png \
|
||||
blob_s1.png \
|
||||
blob_s2.png \
|
||||
blob_s3.png \
|
||||
blob_sl1.png \
|
||||
blob_sl2.png \
|
||||
blob_sl3.png \
|
||||
blob_sl4.png \
|
||||
blob_z1.png \
|
||||
blob_z2.png \
|
||||
blob_z3.png
|
||||
|
||||
# This is where it will all be installed
|
||||
amordir = $(kde_datadir)/amor/pics/animated/blob
|
After Width: | Height: | Size: 556 B |
After Width: | Height: | Size: 186 B |
After Width: | Height: | Size: 247 B |
After Width: | Height: | Size: 465 B |
After Width: | Height: | Size: 720 B |
After Width: | Height: | Size: 662 B |
After Width: | Height: | Size: 727 B |
After Width: | Height: | Size: 879 B |
After Width: | Height: | Size: 924 B |
After Width: | Height: | Size: 689 B |
After Width: | Height: | Size: 646 B |
After Width: | Height: | Size: 345 B |
After Width: | Height: | Size: 648 B |
After Width: | Height: | Size: 713 B |
After Width: | Height: | Size: 787 B |
After Width: | Height: | Size: 615 B |
After Width: | Height: | Size: 581 B |
After Width: | Height: | Size: 582 B |
After Width: | Height: | Size: 701 B |
After Width: | Height: | Size: 611 B |
After Width: | Height: | Size: 511 B |
After Width: | Height: | Size: 431 B |
After Width: | Height: | Size: 618 B |
After Width: | Height: | Size: 580 B |
After Width: | Height: | Size: 478 B |
After Width: | Height: | Size: 388 B |
After Width: | Height: | Size: 272 B |
After Width: | Height: | Size: 235 B |
After Width: | Height: | Size: 166 B |
After Width: | Height: | Size: 594 B |
After Width: | Height: | Size: 651 B |
After Width: | Height: | Size: 681 B |
After Width: | Height: | Size: 600 B |
After Width: | Height: | Size: 627 B |
After Width: | Height: | Size: 574 B |
After Width: | Height: | Size: 391 B |
After Width: | Height: | Size: 243 B |
After Width: | Height: | Size: 593 B |
After Width: | Height: | Size: 573 B |
After Width: | Height: | Size: 587 B |
After Width: | Height: | Size: 587 B |
After Width: | Height: | Size: 468 B |
After Width: | Height: | Size: 606 B |
After Width: | Height: | Size: 617 B |
After Width: | Height: | Size: 623 B |
After Width: | Height: | Size: 559 B |
After Width: | Height: | Size: 574 B |
After Width: | Height: | Size: 608 B |
After Width: | Height: | Size: 638 B |
After Width: | Height: | Size: 556 B |
After Width: | Height: | Size: 566 B |
After Width: | Height: | Size: 603 B |
After Width: | Height: | Size: 637 B |
After Width: | Height: | Size: 605 B |
After Width: | Height: | Size: 526 B |
After Width: | Height: | Size: 482 B |
After Width: | Height: | Size: 472 B |
After Width: | Height: | Size: 633 B |
After Width: | Height: | Size: 574 B |
After Width: | Height: | Size: 656 B |
After Width: | Height: | Size: 553 B |
After Width: | Height: | Size: 639 B |
After Width: | Height: | Size: 649 B |
After Width: | Height: | Size: 559 B |
After Width: | Height: | Size: 594 B |
After Width: | Height: | Size: 505 B |
After Width: | Height: | Size: 475 B |
After Width: | Height: | Size: 465 B |
After Width: | Height: | Size: 586 B |
After Width: | Height: | Size: 605 B |
After Width: | Height: | Size: 610 B |
After Width: | Height: | Size: 511 B |
After Width: | Height: | Size: 498 B |
After Width: | Height: | Size: 487 B |
After Width: | Height: | Size: 454 B |
After Width: | Height: | Size: 400 B |
After Width: | Height: | Size: 251 B |
After Width: | Height: | Size: 222 B |
@ -0,0 +1,46 @@
|
||||
# Add all your pic files here
|
||||
amor_DATA = b1.png \
|
||||
b1-r.png \
|
||||
b2.png \
|
||||
b2-r.png \
|
||||
b3.png \
|
||||
b3-r.png \
|
||||
b4.png \
|
||||
b4-r.png \
|
||||
bcol1.png \
|
||||
bcol2.png \
|
||||
bdrib1.png \
|
||||
bdrib2.png \
|
||||
bdrib3.png \
|
||||
bdrib4.png \
|
||||
bdrib5.png \
|
||||
bdrib6.png \
|
||||
bdrib7.png \
|
||||
bdrop.png \
|
||||
b-f2.png \
|
||||
b-f.png \
|
||||
bgo1.png \
|
||||
bgo2.png \
|
||||
bgo3.png \
|
||||
bgo4.png \
|
||||
bgo5.png \
|
||||
bgo6.png \
|
||||
bgo7.png \
|
||||
bh1.png \
|
||||
bpof1.png \
|
||||
bpof2.png \
|
||||
bpof3.png \
|
||||
bpof4.png \
|
||||
bpof5.png \
|
||||
bpof6.png \
|
||||
sa1.png \
|
||||
sa2a.png \
|
||||
sa2b.png \
|
||||
sa2c.png \
|
||||
sa2.png \
|
||||
salut1.png \
|
||||
salut.png
|
||||
|
||||
|
||||
# This is where it will all be installed
|
||||
amordir = $(kde_datadir)/amor/pics/animated/bonhomme
|
After Width: | Height: | Size: 276 B |
After Width: | Height: | Size: 285 B |
After Width: | Height: | Size: 325 B |
After Width: | Height: | Size: 322 B |
After Width: | Height: | Size: 301 B |
After Width: | Height: | Size: 295 B |
After Width: | Height: | Size: 238 B |
After Width: | Height: | Size: 236 B |
After Width: | Height: | Size: 216 B |
After Width: | Height: | Size: 209 B |
After Width: | Height: | Size: 321 B |
After Width: | Height: | Size: 318 B |
After Width: | Height: | Size: 289 B |
After Width: | Height: | Size: 304 B |
After Width: | Height: | Size: 302 B |
After Width: | Height: | Size: 305 B |
After Width: | Height: | Size: 307 B |
After Width: | Height: | Size: 304 B |
After Width: | Height: | Size: 298 B |
After Width: | Height: | Size: 321 B |
After Width: | Height: | Size: 270 B |
After Width: | Height: | Size: 250 B |
After Width: | Height: | Size: 244 B |
After Width: | Height: | Size: 231 B |
After Width: | Height: | Size: 223 B |
After Width: | Height: | Size: 197 B |
After Width: | Height: | Size: 157 B |
After Width: | Height: | Size: 248 B |
After Width: | Height: | Size: 313 B |
After Width: | Height: | Size: 306 B |
After Width: | Height: | Size: 315 B |
After Width: | Height: | Size: 338 B |
After Width: | Height: | Size: 339 B |
After Width: | Height: | Size: 306 B |
After Width: | Height: | Size: 310 B |
After Width: | Height: | Size: 377 B |
After Width: | Height: | Size: 389 B |
After Width: | Height: | Size: 394 B |
After Width: | Height: | Size: 375 B |
After Width: | Height: | Size: 303 B |
After Width: | Height: | Size: 269 B |
@ -0,0 +1,31 @@
|
||||
# Add all your pic files here
|
||||
amor_DATA = eye_1.png \
|
||||
eye_2.png \
|
||||
eye_b.png \
|
||||
eye_d.png \
|
||||
eye_e.png \
|
||||
eye_h1.png \
|
||||
eye_h2.png \
|
||||
eye_h3.png \
|
||||
eye_h4.png \
|
||||
eye_l.png \
|
||||
eye_m1.png \
|
||||
eye_m2.png \
|
||||
eye_m3.png \
|
||||
eye_m4.png \
|
||||
eye_m5.png \
|
||||
eye_m6.png \
|
||||
eye_m7.png \
|
||||
eye_s1.png \
|
||||
eye_s2.png \
|
||||
eye_s3.png \
|
||||
eye_s4.png \
|
||||
eye_u.png \
|
||||
eye_z1.png \
|
||||
eye_z2.png \
|
||||
eye_z3.png \
|
||||
eye_z4.png \
|
||||
eye_z5.png
|
||||
|
||||
# This is where it will all be installed
|
||||
amordir = $(kde_datadir)/amor/pics/animated/eyes
|
After Width: | Height: | Size: 241 B |
After Width: | Height: | Size: 202 B |
After Width: | Height: | Size: 254 B |
After Width: | Height: | Size: 231 B |
After Width: | Height: | Size: 241 B |
After Width: | Height: | Size: 242 B |
After Width: | Height: | Size: 251 B |
After Width: | Height: | Size: 258 B |
After Width: | Height: | Size: 252 B |
After Width: | Height: | Size: 244 B |
After Width: | Height: | Size: 508 B |
After Width: | Height: | Size: 525 B |
After Width: | Height: | Size: 548 B |
After Width: | Height: | Size: 430 B |
After Width: | Height: | Size: 326 B |
After Width: | Height: | Size: 220 B |
After Width: | Height: | Size: 166 B |
After Width: | Height: | Size: 285 B |
After Width: | Height: | Size: 271 B |
After Width: | Height: | Size: 274 B |
After Width: | Height: | Size: 274 B |
After Width: | Height: | Size: 228 B |
After Width: | Height: | Size: 273 B |
After Width: | Height: | Size: 231 B |
After Width: | Height: | Size: 269 B |
After Width: | Height: | Size: 241 B |
After Width: | Height: | Size: 202 B |
@ -0,0 +1,19 @@
|
||||
# Add all your pic files here
|
||||
amor_DATA = ghost_1.png \
|
||||
ghost_2.png \
|
||||
ghost_e.png \
|
||||
ghost_m1.png \
|
||||
ghost_m2.png \
|
||||
ghost_m3.png \
|
||||
ghost_m4.png \
|
||||
ghost_m5.png \
|
||||
ghost_m6.png \
|
||||
ghost_m7.png \
|
||||
ghost_z1.png \
|
||||
ghost_z2.png \
|
||||
ghost_z3.png \
|
||||
ghost_z4.png \
|
||||
ghost_z5.png
|
||||
|
||||
# This is where it will all be installed
|
||||
amordir = $(kde_datadir)/amor/pics/animated/ghost
|
After Width: | Height: | Size: 425 B |
After Width: | Height: | Size: 407 B |
After Width: | Height: | Size: 185 B |
After Width: | Height: | Size: 394 B |
After Width: | Height: | Size: 347 B |
After Width: | Height: | Size: 312 B |
After Width: | Height: | Size: 290 B |
After Width: | Height: | Size: 254 B |
After Width: | Height: | Size: 240 B |
After Width: | Height: | Size: 224 B |
After Width: | Height: | Size: 198 B |
After Width: | Height: | Size: 237 B |
After Width: | Height: | Size: 300 B |
After Width: | Height: | Size: 310 B |
After Width: | Height: | Size: 378 B |
@ -0,0 +1,31 @@
|
||||
# Add all your pic files here
|
||||
amor_DATA = claw1.png \
|
||||
claw2.png \
|
||||
jump1.png \
|
||||
jump2.png \
|
||||
jump3.png \
|
||||
jump4.png \
|
||||
jumpl1.png \
|
||||
jumpl2.png \
|
||||
jumpl3.png \
|
||||
jumpl4.png \
|
||||
lick2.png \
|
||||
lick.png \
|
||||
run1.png \
|
||||
run2.png \
|
||||
run3.png \
|
||||
run4.png \
|
||||
scratch1.png \
|
||||
scratch2.png \
|
||||
scratch3.png \
|
||||
scratch4.png \
|
||||
sitleft.png \
|
||||
sit.png \
|
||||
sleep1.png \
|
||||
sleep2.png \
|
||||
surprise.png \
|
||||
tail.png \
|
||||
yawn.png
|
||||
|
||||
# This is where it will all be installed
|
||||
amordir = $(kde_datadir)/amor/pics/animated/neko
|
After Width: | Height: | Size: 327 B |
After Width: | Height: | Size: 322 B |
After Width: | Height: | Size: 351 B |
After Width: | Height: | Size: 359 B |
After Width: | Height: | Size: 355 B |
After Width: | Height: | Size: 341 B |
After Width: | Height: | Size: 336 B |
After Width: | Height: | Size: 363 B |
After Width: | Height: | Size: 361 B |
After Width: | Height: | Size: 344 B |
After Width: | Height: | Size: 339 B |
After Width: | Height: | Size: 339 B |
After Width: | Height: | Size: 351 B |
After Width: | Height: | Size: 338 B |
After Width: | Height: | Size: 351 B |
After Width: | Height: | Size: 337 B |
After Width: | Height: | Size: 343 B |
After Width: | Height: | Size: 316 B |
After Width: | Height: | Size: 331 B |
After Width: | Height: | Size: 318 B |
After Width: | Height: | Size: 315 B |
After Width: | Height: | Size: 316 B |
After Width: | Height: | Size: 323 B |
After Width: | Height: | Size: 321 B |
After Width: | Height: | Size: 355 B |
After Width: | Height: | Size: 321 B |
After Width: | Height: | Size: 338 B |
@ -0,0 +1,104 @@
|
||||
# Add all your pic files here
|
||||
amor_DATA = bash_l10.png \
|
||||
bash_l11.png \
|
||||
bash_l12.png \
|
||||
bash_l1.png \
|
||||
bash_l2.png \
|
||||
bash_l3.png \
|
||||
bash_l4.png \
|
||||
bash_l5.png \
|
||||
bash_l6.png \
|
||||
bash_l7.png \
|
||||
bash_l8.png \
|
||||
bash_l9.png \
|
||||
bash_r10.png \
|
||||
bash_r11.png \
|
||||
bash_r12.png \
|
||||
bash_r1.png \
|
||||
bash_r2.png \
|
||||
bash_r3.png \
|
||||
bash_r4.png \
|
||||
bash_r5.png \
|
||||
bash_r6.png \
|
||||
bash_r7.png \
|
||||
bash_r8.png \
|
||||
bash_r9.png \
|
||||
blocker1.png \
|
||||
blocker2.png \
|
||||
blocker3.png \
|
||||
blocker4.png \
|
||||
blocker5.png \
|
||||
blocker6.png \
|
||||
bomber10.png \
|
||||
bomber11.png \
|
||||
bomber12.png \
|
||||
bomber13.png \
|
||||
bomber14.png \
|
||||
bomber15.png \
|
||||
bomber16.png \
|
||||
bomber1.png \
|
||||
bomber2.png \
|
||||
bomber3.png \
|
||||
bomber4.png \
|
||||
bomber5.png \
|
||||
bomber6.png \
|
||||
bomber7.png \
|
||||
bomber8.png \
|
||||
bomber9.png \
|
||||
digger10.png \
|
||||
digger11.png \
|
||||
digger12.png \
|
||||
digger13.png \
|
||||
digger14.png \
|
||||
digger1.png \
|
||||
digger2.png \
|
||||
digger3.png \
|
||||
digger4.png \
|
||||
digger5.png \
|
||||
digger6.png \
|
||||
digger7.png \
|
||||
digger8.png \
|
||||
digger9.png \
|
||||
faller1.png \
|
||||
faller2.png \
|
||||
faller3.png \
|
||||
faller4.png \
|
||||
faller5.png \
|
||||
faller6.png \
|
||||
faller7.png \
|
||||
faller8.png \
|
||||
floater1.png \
|
||||
floater2.png \
|
||||
floater3.png \
|
||||
floater4.png \
|
||||
floater5.png \
|
||||
floater6.png \
|
||||
floater7.png \
|
||||
floater8.png \
|
||||
tumble1.png \
|
||||
tumble2.png \
|
||||
tumble3.png \
|
||||
tumble4.png \
|
||||
tumble5.png \
|
||||
tumble6.png \
|
||||
tumble7.png \
|
||||
tumble8.png \
|
||||
walk_l1.png \
|
||||
walk_l2.png \
|
||||
walk_l3.png \
|
||||
walk_l4.png \
|
||||
walk_l5.png \
|
||||
walk_l6.png \
|
||||
walk_l7.png \
|
||||
walk_l8.png \
|
||||
walk_r1.png \
|
||||
walk_r2.png \
|
||||
walk_r3.png \
|
||||
walk_r4.png \
|
||||
walk_r5.png \
|
||||
walk_r6.png \
|
||||
walk_r7.png \
|
||||
walk_r8.png
|
||||
|
||||
# This is where it will all be installed
|
||||
amordir = $(kde_datadir)/amor/pics/animated/pingu
|
After Width: | Height: | Size: 967 B |
After Width: | Height: | Size: 1014 B |
After Width: | Height: | Size: 1002 B |
After Width: | Height: | Size: 1.0 KiB |
After Width: | Height: | Size: 894 B |
After Width: | Height: | Size: 797 B |
After Width: | Height: | Size: 638 B |
After Width: | Height: | Size: 677 B |
After Width: | Height: | Size: 745 B |
After Width: | Height: | Size: 703 B |
After Width: | Height: | Size: 862 B |
After Width: | Height: | Size: 893 B |
After Width: | Height: | Size: 954 B |
After Width: | Height: | Size: 977 B |
After Width: | Height: | Size: 981 B |
After Width: | Height: | Size: 1.0 KiB |
After Width: | Height: | Size: 898 B |
After Width: | Height: | Size: 797 B |
After Width: | Height: | Size: 628 B |
After Width: | Height: | Size: 679 B |
After Width: | Height: | Size: 747 B |
After Width: | Height: | Size: 694 B |
After Width: | Height: | Size: 865 B |
After Width: | Height: | Size: 907 B |
After Width: | Height: | Size: 1.5 KiB |
After Width: | Height: | Size: 1.4 KiB |
After Width: | Height: | Size: 1.4 KiB |
After Width: | Height: | Size: 1.4 KiB |
After Width: | Height: | Size: 1.4 KiB |
After Width: | Height: | Size: 1.4 KiB |
After Width: | Height: | Size: 964 B |
After Width: | Height: | Size: 952 B |
After Width: | Height: | Size: 852 B |
After Width: | Height: | Size: 753 B |
After Width: | Height: | Size: 756 B |
After Width: | Height: | Size: 324 B |
After Width: | Height: | Size: 262 B |
After Width: | Height: | Size: 162 B |
After Width: | Height: | Size: 964 B |
After Width: | Height: | Size: 964 B |
After Width: | Height: | Size: 1001 B |
After Width: | Height: | Size: 998 B |
After Width: | Height: | Size: 987 B |
After Width: | Height: | Size: 986 B |
After Width: | Height: | Size: 960 B |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1.4 KiB |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1.4 KiB |
After Width: | Height: | Size: 1.0 KiB |
After Width: | Height: | Size: 1002 B |
After Width: | Height: | Size: 990 B |
After Width: | Height: | Size: 926 B |
After Width: | Height: | Size: 973 B |
After Width: | Height: | Size: 1002 B |
After Width: | Height: | Size: 1.0 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 960 B |
After Width: | Height: | Size: 960 B |
After Width: | Height: | Size: 961 B |
After Width: | Height: | Size: 967 B |
After Width: | Height: | Size: 960 B |
After Width: | Height: | Size: 965 B |
After Width: | Height: | Size: 959 B |
After Width: | Height: | Size: 965 B |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 873 B |
After Width: | Height: | Size: 847 B |
After Width: | Height: | Size: 587 B |
After Width: | Height: | Size: 764 B |
After Width: | Height: | Size: 693 B |
After Width: | Height: | Size: 725 B |
After Width: | Height: | Size: 1.0 KiB |
After Width: | Height: | Size: 869 B |
After Width: | Height: | Size: 859 B |
After Width: | Height: | Size: 927 B |
After Width: | Height: | Size: 858 B |
After Width: | Height: | Size: 842 B |
After Width: | Height: | Size: 744 B |
After Width: | Height: | Size: 909 B |
After Width: | Height: | Size: 958 B |
After Width: | Height: | Size: 1008 B |
After Width: | Height: | Size: 868 B |
After Width: | Height: | Size: 753 B |
After Width: | Height: | Size: 844 B |
After Width: | Height: | Size: 896 B |
After Width: | Height: | Size: 959 B |
After Width: | Height: | Size: 845 B |
After Width: | Height: | Size: 848 B |
@ -0,0 +1,50 @@
|
||||
# Add all your pic files here
|
||||
amor_DATA = yy105.png \
|
||||
yy120.png \
|
||||
yy135.png \
|
||||
yy150.png \
|
||||
yy15.png \
|
||||
yy165.png \
|
||||
yy180.png \
|
||||
yy195.png \
|
||||
yy-1.png \
|
||||
yy210.png \
|
||||
yy225.png \
|
||||
yy240.png \
|
||||
yy255.png \
|
||||
yy270.png \
|
||||
yy285.png \
|
||||
yy-2.png \
|
||||
yy300.png \
|
||||
yy30.png \
|
||||
yy315.png \
|
||||
yy330.png \
|
||||
yy345.png \
|
||||
yy-3.png \
|
||||
yy45.png \
|
||||
yy-4.png \
|
||||
yy-5.png \
|
||||
yy60.png \
|
||||
yy-6.png \
|
||||
yy75.png \
|
||||
yy-7.png \
|
||||
yy-8.png \
|
||||
yy90.png \
|
||||
yy-9.png \
|
||||
yy.png \
|
||||
yyx10.png \
|
||||
yyx12.png \
|
||||
yyx14.png \
|
||||
yyx16.png \
|
||||
yyx18.png \
|
||||
yyx20.png \
|
||||
yyx22.png \
|
||||
yyx24.png \
|
||||
yyx26.png \
|
||||
yyx28.png \
|
||||
yyx30.png \
|
||||
yyx6.png \
|
||||
yyx8.png
|
||||
|
||||
# This is where it will all be installed
|
||||
amordir = $(kde_datadir)/amor/pics/animated/tao
|
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 1.0 KiB |
After Width: | Height: | Size: 985 B |
After Width: | Height: | Size: 985 B |
After Width: | Height: | Size: 953 B |
After Width: | Height: | Size: 924 B |
After Width: | Height: | Size: 887 B |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 332 B |
After Width: | Height: | Size: 365 B |
After Width: | Height: | Size: 485 B |
After Width: | Height: | Size: 495 B |
After Width: | Height: | Size: 647 B |
After Width: | Height: | Size: 716 B |
After Width: | Height: | Size: 743 B |
After Width: | Height: | Size: 817 B |
After Width: | Height: | Size: 913 B |
After Width: | Height: | Size: 947 B |
After Width: | Height: | Size: 1.0 KiB |
After Width: | Height: | Size: 206 B |
After Width: | Height: | Size: 267 B |
@ -0,0 +1,40 @@
|
||||
# Add all your pic files here
|
||||
amor_DATA = w-a1.png \
|
||||
w-a2.png \
|
||||
w-b1.png \
|
||||
w-b2.png \
|
||||
w-be1.png \
|
||||
w-be2.png \
|
||||
w-be3.png \
|
||||
w-be4.png \
|
||||
w-d1.png \
|
||||
w-d2.png \
|
||||
w-d3.png \
|
||||
w-d4.png \
|
||||
w-d5.png \
|
||||
w-dr1.png \
|
||||
w-e1.png \
|
||||
w-l1.png \
|
||||
w-l2.png \
|
||||
w-l3.png \
|
||||
w-ml0.png \
|
||||
w-ml1.png \
|
||||
w-ml2.png \
|
||||
w-ml3.png \
|
||||
w-mr0.png \
|
||||
w-mr1.png \
|
||||
w-mr2.png \
|
||||
w-mr3.png \
|
||||
w-s1.png \
|
||||
w-s2.png \
|
||||
w-s3.png \
|
||||
w-u1.png \
|
||||
w-u2.png \
|
||||
w-u3.png \
|
||||
w-wl1.png \
|
||||
w-wl2.png \
|
||||
w-wr1.png \
|
||||
w-wr2.png
|
||||
|
||||
# This is where it will all be installed
|
||||
amordir = $(kde_datadir)/amor/pics/animated/worm
|
After Width: | Height: | Size: 332 B |
After Width: | Height: | Size: 339 B |
After Width: | Height: | Size: 306 B |
After Width: | Height: | Size: 304 B |
After Width: | Height: | Size: 310 B |
After Width: | Height: | Size: 305 B |
After Width: | Height: | Size: 312 B |
After Width: | Height: | Size: 325 B |
After Width: | Height: | Size: 290 B |
After Width: | Height: | Size: 259 B |
After Width: | Height: | Size: 259 B |
After Width: | Height: | Size: 241 B |
After Width: | Height: | Size: 180 B |
After Width: | Height: | Size: 321 B |
After Width: | Height: | Size: 293 B |
After Width: | Height: | Size: 333 B |
After Width: | Height: | Size: 335 B |
After Width: | Height: | Size: 344 B |
After Width: | Height: | Size: 315 B |
After Width: | Height: | Size: 330 B |
After Width: | Height: | Size: 322 B |
After Width: | Height: | Size: 319 B |
After Width: | Height: | Size: 311 B |
After Width: | Height: | Size: 326 B |
After Width: | Height: | Size: 318 B |
After Width: | Height: | Size: 327 B |
After Width: | Height: | Size: 235 B |
After Width: | Height: | Size: 257 B |
After Width: | Height: | Size: 251 B |
After Width: | Height: | Size: 218 B |
After Width: | Height: | Size: 260 B |
After Width: | Height: | Size: 276 B |
After Width: | Height: | Size: 322 B |
After Width: | Height: | Size: 329 B |
After Width: | Height: | Size: 317 B |
After Width: | Height: | Size: 327 B |
@ -0,0 +1,5 @@
|
||||
# Add all your pic files here
|
||||
amor_DATA = billy.png bonhomme.png ghost.png neko.png tux.png blob.png bsd.png eyes.png tao.png worm.png
|
||||
|
||||
# This is where it will all be installed
|
||||
amordir = $(kde_datadir)/amor/pics/preview
|
After Width: | Height: | Size: 547 B |
After Width: | Height: | Size: 556 B |
After Width: | Height: | Size: 296 B |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 241 B |
After Width: | Height: | Size: 425 B |
After Width: | Height: | Size: 315 B |
After Width: | Height: | Size: 1.7 KiB |
After Width: | Height: | Size: 605 B |
After Width: | Height: | Size: 311 B |
@ -0,0 +1,5 @@
|
||||
# Add all your pic files here
|
||||
amor_DATA = billy.png bsd.png tux.png
|
||||
|
||||
# This is where it will all be installed
|
||||
amordir = $(kde_datadir)/amor/pics/static
|
After Width: | Height: | Size: 824 B |
After Width: | Height: | Size: 2.3 KiB |
After Width: | Height: | Size: 1.7 KiB |