initial commit
This commit is contained in:
commit
3cdfeaaf1c
7
.gitignore
vendored
Normal file
7
.gitignore
vendored
Normal file
@ -0,0 +1,7 @@
|
||||
Makefile
|
||||
obj
|
||||
moc
|
||||
rcc
|
||||
lib
|
||||
bin
|
||||
qvg
|
524
COPYING
Normal file
524
COPYING
Normal file
@ -0,0 +1,524 @@
|
||||
QSkinny License
|
||||
Version 1.0, November 1, 2016
|
||||
|
||||
QSkinny is Copyright (C) 2016 Uwe Rathmann
|
||||
|
||||
You may use, distribute and copy QSkinny under the terms of
|
||||
GNU Lesser General Public License version 2.1, which is displayed below
|
||||
with the following exceptions:
|
||||
|
||||
1. The object code form of a "work that uses the Library" may incorporate
|
||||
material from a header file that is part of the Library. You may
|
||||
distribute such object code under terms of your choice, provided that:
|
||||
|
||||
(i) the header files of the Library have not been modified; and
|
||||
(ii) the incorporated material is limited to numerical parameters, data
|
||||
structure layouts, accessors, macros, inline functions and
|
||||
templates; and
|
||||
(iii) you comply with the terms of Section 6 of the GNU Lesser General
|
||||
Public License version 2.1.
|
||||
|
||||
-------------------------------------------------------------------------
|
||||
|
||||
GNU LESSER GENERAL PUBLIC LICENSE
|
||||
Version 2.1, February 1999
|
||||
|
||||
Copyright (C) 1991, 1999 Free Software Foundation, Inc.
|
||||
51 Franklin Street, 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.
|
||||
|
||||
[This is the first released version of the Lesser GPL. It also counts
|
||||
as the successor of the GNU Library Public License, version 2, hence
|
||||
the version number 2.1.]
|
||||
|
||||
Preamble
|
||||
|
||||
The licenses for most software are designed to take away your
|
||||
freedom to share and change it. By contrast, the GNU General Public
|
||||
Licenses are intended to guarantee your freedom to share and change
|
||||
free software--to make sure the software is free for all its users.
|
||||
|
||||
This license, the Lesser General Public License, applies to some
|
||||
specially designated software packages--typically libraries--of the
|
||||
Free Software Foundation and other authors who decide to use it. You
|
||||
can use it too, but we suggest you first think carefully about whether
|
||||
this license or the ordinary General Public License is the better
|
||||
strategy to use in any particular case, based on the explanations below.
|
||||
|
||||
When we speak of free software, we are referring to freedom of use,
|
||||
not price. Our General Public Licenses are designed to make sure that
|
||||
you have the freedom to distribute copies of free software (and charge
|
||||
for this service if you wish); that you receive source code or can get
|
||||
it if you want it; that you can change the software and use pieces of
|
||||
it in new free programs; and that you are informed that you can do
|
||||
these things.
|
||||
|
||||
To protect your rights, we need to make restrictions that forbid
|
||||
distributors to deny you these rights or to ask you to surrender these
|
||||
rights. These restrictions translate to certain responsibilities for
|
||||
you if you distribute copies of the library or if you modify it.
|
||||
|
||||
For example, if you distribute copies of the library, whether gratis
|
||||
or for a fee, you must give the recipients all the rights that we gave
|
||||
you. You must make sure that they, too, receive or can get the source
|
||||
code. If you link other code with the library, you must provide
|
||||
complete object files to the recipients, so that they can relink them
|
||||
with the library after making changes to the library and recompiling
|
||||
it. And you must show them these terms so they know their rights.
|
||||
|
||||
We protect your rights with a two-step method: (1) we copyright the
|
||||
library, and (2) we offer you this license, which gives you legal
|
||||
permission to copy, distribute and/or modify the library.
|
||||
|
||||
To protect each distributor, we want to make it very clear that
|
||||
there is no warranty for the free library. Also, if the library is
|
||||
modified by someone else and passed on, the recipients should know
|
||||
that what they have is not the original version, so that the original
|
||||
author's reputation will not be affected by problems that might be
|
||||
introduced by others.
|
||||
|
||||
Finally, software patents pose a constant threat to the existence of
|
||||
any free program. We wish to make sure that a company cannot
|
||||
effectively restrict the users of a free program by obtaining a
|
||||
restrictive license from a patent holder. Therefore, we insist that
|
||||
any patent license obtained for a version of the library must be
|
||||
consistent with the full freedom of use specified in this license.
|
||||
|
||||
Most GNU software, including some libraries, is covered by the
|
||||
ordinary GNU General Public License. This license, the GNU Lesser
|
||||
General Public License, applies to certain designated libraries, and
|
||||
is quite different from the ordinary General Public License. We use
|
||||
this license for certain libraries in order to permit linking those
|
||||
libraries into non-free programs.
|
||||
|
||||
When a program is linked with a library, whether statically or using
|
||||
a shared library, the combination of the two is legally speaking a
|
||||
combined work, a derivative of the original library. The ordinary
|
||||
General Public License therefore permits such linking only if the
|
||||
entire combination fits its criteria of freedom. The Lesser General
|
||||
Public License permits more lax criteria for linking other code with
|
||||
the library.
|
||||
|
||||
We call this license the "Lesser" General Public License because it
|
||||
does Less to protect the user's freedom than the ordinary General
|
||||
Public License. It also provides other free software developers Less
|
||||
of an advantage over competing non-free programs. These disadvantages
|
||||
are the reason we use the ordinary General Public License for many
|
||||
libraries. However, the Lesser license provides advantages in certain
|
||||
special circumstances.
|
||||
|
||||
For example, on rare occasions, there may be a special need to
|
||||
encourage the widest possible use of a certain library, so that it becomes
|
||||
a de-facto standard. To achieve this, non-free programs must be
|
||||
allowed to use the library. A more frequent case is that a free
|
||||
library does the same job as widely used non-free libraries. In this
|
||||
case, there is little to gain by limiting the free library to free
|
||||
software only, so we use the Lesser General Public License.
|
||||
|
||||
In other cases, permission to use a particular library in non-free
|
||||
programs enables a greater number of people to use a large body of
|
||||
free software. For example, permission to use the GNU C Library in
|
||||
non-free programs enables many more people to use the whole GNU
|
||||
operating system, as well as its variant, the GNU/Linux operating
|
||||
system.
|
||||
|
||||
Although the Lesser General Public License is Less protective of the
|
||||
users' freedom, it does ensure that the user of a program that is
|
||||
linked with the Library has the freedom and the wherewithal to run
|
||||
that program using a modified version of the Library.
|
||||
|
||||
The precise terms and conditions for copying, distribution and
|
||||
modification follow. Pay close attention to the difference between a
|
||||
"work based on the library" and a "work that uses the library". The
|
||||
former contains code derived from the library, whereas the latter must
|
||||
be combined with the library in order to run.
|
||||
|
||||
GNU LESSER GENERAL PUBLIC LICENSE
|
||||
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
|
||||
|
||||
0. This License Agreement applies to any software library or other
|
||||
program which contains a notice placed by the copyright holder or
|
||||
other authorized party saying it may be distributed under the terms of
|
||||
this Lesser General Public License (also called "this License").
|
||||
Each licensee is addressed as "you".
|
||||
|
||||
A "library" means a collection of software functions and/or data
|
||||
prepared so as to be conveniently linked with application programs
|
||||
(which use some of those functions and data) to form executables.
|
||||
|
||||
The "Library", below, refers to any such software library or work
|
||||
which has been distributed under these terms. A "work based on the
|
||||
Library" means either the Library or any derivative work under
|
||||
copyright law: that is to say, a work containing the Library or a
|
||||
portion of it, either verbatim or with modifications and/or translated
|
||||
straightforwardly into another language. (Hereinafter, translation is
|
||||
included without limitation in the term "modification".)
|
||||
|
||||
"Source code" for a work means the preferred form of the work for
|
||||
making modifications to it. For a library, complete source code means
|
||||
all the source code for all modules it contains, plus any associated
|
||||
interface definition files, plus the scripts used to control compilation
|
||||
and installation of the library.
|
||||
|
||||
Activities other than copying, distribution and modification are not
|
||||
covered by this License; they are outside its scope. The act of
|
||||
running a program using the Library is not restricted, and output from
|
||||
such a program is covered only if its contents constitute a work based
|
||||
on the Library (independent of the use of the Library in a tool for
|
||||
writing it). Whether that is true depends on what the Library does
|
||||
and what the program that uses the Library does.
|
||||
|
||||
1. You may copy and distribute verbatim copies of the Library's
|
||||
complete source code as you receive it, in any medium, provided that
|
||||
you conspicuously and appropriately publish on each copy an
|
||||
appropriate copyright notice and disclaimer of warranty; keep intact
|
||||
all the notices that refer to this License and to the absence of any
|
||||
warranty; and distribute a copy of this License along with the
|
||||
Library.
|
||||
|
||||
You may charge a fee for the physical act of transferring a copy,
|
||||
and you may at your option offer warranty protection in exchange for a
|
||||
fee.
|
||||
|
||||
2. You may modify your copy or copies of the Library or any portion
|
||||
of it, thus forming a work based on the Library, and copy and
|
||||
distribute such modifications or work under the terms of Section 1
|
||||
above, provided that you also meet all of these conditions:
|
||||
|
||||
a) The modified work must itself be a software library.
|
||||
|
||||
b) You must cause the files modified to carry prominent notices
|
||||
stating that you changed the files and the date of any change.
|
||||
|
||||
c) You must cause the whole of the work to be licensed at no
|
||||
charge to all third parties under the terms of this License.
|
||||
|
||||
d) If a facility in the modified Library refers to a function or a
|
||||
table of data to be supplied by an application program that uses
|
||||
the facility, other than as an argument passed when the facility
|
||||
is invoked, then you must make a good faith effort to ensure that,
|
||||
in the event an application does not supply such function or
|
||||
table, the facility still operates, and performs whatever part of
|
||||
its purpose remains meaningful.
|
||||
|
||||
(For example, a function in a library to compute square roots has
|
||||
a purpose that is entirely well-defined independent of the
|
||||
application. Therefore, Subsection 2d requires that any
|
||||
application-supplied function or table used by this function must
|
||||
be optional: if the application does not supply it, the square
|
||||
root function must still compute square roots.)
|
||||
|
||||
These requirements apply to the modified work as a whole. If
|
||||
identifiable sections of that work are not derived from the Library,
|
||||
and can be reasonably considered independent and separate works in
|
||||
themselves, then this License, and its terms, do not apply to those
|
||||
sections when you distribute them as separate works. But when you
|
||||
distribute the same sections as part of a whole which is a work based
|
||||
on the Library, the distribution of the whole must be on the terms of
|
||||
this License, whose permissions for other licensees extend to the
|
||||
entire whole, and thus to each and every part regardless of who wrote
|
||||
it.
|
||||
|
||||
Thus, it is not the intent of this section to claim rights or contest
|
||||
your rights to work written entirely by you; rather, the intent is to
|
||||
exercise the right to control the distribution of derivative or
|
||||
collective works based on the Library.
|
||||
|
||||
In addition, mere aggregation of another work not based on the Library
|
||||
with the Library (or with a work based on the Library) on a volume of
|
||||
a storage or distribution medium does not bring the other work under
|
||||
the scope of this License.
|
||||
|
||||
3. You may opt to apply the terms of the ordinary GNU General Public
|
||||
License instead of this License to a given copy of the Library. To do
|
||||
this, you must alter all the notices that refer to this License, so
|
||||
that they refer to the ordinary GNU General Public License, version 2,
|
||||
instead of to this License. (If a newer version than version 2 of the
|
||||
ordinary GNU General Public License has appeared, then you can specify
|
||||
that version instead if you wish.) Do not make any other change in
|
||||
these notices.
|
||||
|
||||
Once this change is made in a given copy, it is irreversible for
|
||||
that copy, so the ordinary GNU General Public License applies to all
|
||||
subsequent copies and derivative works made from that copy.
|
||||
|
||||
This option is useful when you wish to copy part of the code of
|
||||
the Library into a program that is not a library.
|
||||
|
||||
4. You may copy and distribute the Library (or a portion or
|
||||
derivative of it, under Section 2) in object code or executable form
|
||||
under the terms of Sections 1 and 2 above provided that you accompany
|
||||
it with the complete corresponding machine-readable source code, which
|
||||
must be distributed under the terms of Sections 1 and 2 above on a
|
||||
medium customarily used for software interchange.
|
||||
|
||||
If distribution of object code is made by offering access to copy
|
||||
from a designated place, then offering equivalent access to copy the
|
||||
source code from the same place satisfies the requirement to
|
||||
distribute the source code, even though third parties are not
|
||||
compelled to copy the source along with the object code.
|
||||
|
||||
5. A program that contains no derivative of any portion of the
|
||||
Library, but is designed to work with the Library by being compiled or
|
||||
linked with it, is called a "work that uses the Library". Such a
|
||||
work, in isolation, is not a derivative work of the Library, and
|
||||
therefore falls outside the scope of this License.
|
||||
|
||||
However, linking a "work that uses the Library" with the Library
|
||||
creates an executable that is a derivative of the Library (because it
|
||||
contains portions of the Library), rather than a "work that uses the
|
||||
library". The executable is therefore covered by this License.
|
||||
Section 6 states terms for distribution of such executables.
|
||||
|
||||
When a "work that uses the Library" uses material from a header file
|
||||
that is part of the Library, the object code for the work may be a
|
||||
derivative work of the Library even though the source code is not.
|
||||
Whether this is true is especially significant if the work can be
|
||||
linked without the Library, or if the work is itself a library. The
|
||||
threshold for this to be true is not precisely defined by law.
|
||||
|
||||
If such an object file uses only numerical parameters, data
|
||||
structure layouts and accessors, and small macros and small inline
|
||||
functions (ten lines or less in length), then the use of the object
|
||||
file is unrestricted, regardless of whether it is legally a derivative
|
||||
work. (Executables containing this object code plus portions of the
|
||||
Library will still fall under Section 6.)
|
||||
|
||||
Otherwise, if the work is a derivative of the Library, you may
|
||||
distribute the object code for the work under the terms of Section 6.
|
||||
Any executables containing that work also fall under Section 6,
|
||||
whether or not they are linked directly with the Library itself.
|
||||
|
||||
6. As an exception to the Sections above, you may also combine or
|
||||
link a "work that uses the Library" with the Library to produce a
|
||||
work containing portions of the Library, and distribute that work
|
||||
under terms of your choice, provided that the terms permit
|
||||
modification of the work for the customer's own use and reverse
|
||||
engineering for debugging such modifications.
|
||||
|
||||
You must give prominent notice with each copy of the work that the
|
||||
Library is used in it and that the Library and its use are covered by
|
||||
this License. You must supply a copy of this License. If the work
|
||||
during execution displays copyright notices, you must include the
|
||||
copyright notice for the Library among them, as well as a reference
|
||||
directing the user to the copy of this License. Also, you must do one
|
||||
of these things:
|
||||
|
||||
a) Accompany the work with the complete corresponding
|
||||
machine-readable source code for the Library including whatever
|
||||
changes were used in the work (which must be distributed under
|
||||
Sections 1 and 2 above); and, if the work is an executable linked
|
||||
with the Library, with the complete machine-readable "work that
|
||||
uses the Library", as object code and/or source code, so that the
|
||||
user can modify the Library and then relink to produce a modified
|
||||
executable containing the modified Library. (It is understood
|
||||
that the user who changes the contents of definitions files in the
|
||||
Library will not necessarily be able to recompile the application
|
||||
to use the modified definitions.)
|
||||
|
||||
b) Use a suitable shared library mechanism for linking with the
|
||||
Library. A suitable mechanism is one that (1) uses at run time a
|
||||
copy of the library already present on the user's computer system,
|
||||
rather than copying library functions into the executable, and (2)
|
||||
will operate properly with a modified version of the library, if
|
||||
the user installs one, as long as the modified version is
|
||||
interface-compatible with the version that the work was made with.
|
||||
|
||||
c) Accompany the work with a written offer, valid for at
|
||||
least three years, to give the same user the materials
|
||||
specified in Subsection 6a, above, for a charge no more
|
||||
than the cost of performing this distribution.
|
||||
|
||||
d) If distribution of the work is made by offering access to copy
|
||||
from a designated place, offer equivalent access to copy the above
|
||||
specified materials from the same place.
|
||||
|
||||
e) Verify that the user has already received a copy of these
|
||||
materials or that you have already sent this user a copy.
|
||||
|
||||
For an executable, the required form of the "work that uses the
|
||||
Library" must include any data and utility programs needed for
|
||||
reproducing the executable from it. However, as a special exception,
|
||||
the materials to be distributed need not include anything that is
|
||||
normally distributed (in either source or binary form) with the major
|
||||
components (compiler, kernel, and so on) of the operating system on
|
||||
which the executable runs, unless that component itself accompanies
|
||||
the executable.
|
||||
|
||||
It may happen that this requirement contradicts the license
|
||||
restrictions of other proprietary libraries that do not normally
|
||||
accompany the operating system. Such a contradiction means you cannot
|
||||
use both them and the Library together in an executable that you
|
||||
distribute.
|
||||
|
||||
7. You may place library facilities that are a work based on the
|
||||
Library side-by-side in a single library together with other library
|
||||
facilities not covered by this License, and distribute such a combined
|
||||
library, provided that the separate distribution of the work based on
|
||||
the Library and of the other library facilities is otherwise
|
||||
permitted, and provided that you do these two things:
|
||||
|
||||
a) Accompany the combined library with a copy of the same work
|
||||
based on the Library, uncombined with any other library
|
||||
facilities. This must be distributed under the terms of the
|
||||
Sections above.
|
||||
|
||||
b) Give prominent notice with the combined library of the fact
|
||||
that part of it is a work based on the Library, and explaining
|
||||
where to find the accompanying uncombined form of the same work.
|
||||
|
||||
8. You may not copy, modify, sublicense, link with, or distribute
|
||||
the Library except as expressly provided under this License. Any
|
||||
attempt otherwise to copy, modify, sublicense, link with, or
|
||||
distribute the Library 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.
|
||||
|
||||
9. You are not required to accept this License, since you have not
|
||||
signed it. However, nothing else grants you permission to modify or
|
||||
distribute the Library or its derivative works. These actions are
|
||||
prohibited by law if you do not accept this License. Therefore, by
|
||||
modifying or distributing the Library (or any work based on the
|
||||
Library), you indicate your acceptance of this License to do so, and
|
||||
all its terms and conditions for copying, distributing or modifying
|
||||
the Library or works based on it.
|
||||
|
||||
10. Each time you redistribute the Library (or any work based on the
|
||||
Library), the recipient automatically receives a license from the
|
||||
original licensor to copy, distribute, link with or modify the Library
|
||||
subject to these terms and conditions. You may not impose any further
|
||||
restrictions on the recipients' exercise of the rights granted herein.
|
||||
You are not responsible for enforcing compliance by third parties with
|
||||
this License.
|
||||
|
||||
11. If, as a consequence of a court judgment or allegation of patent
|
||||
infringement or for any other reason (not limited to patent issues),
|
||||
conditions are imposed on you (whether by court order, agreement or
|
||||
otherwise) that contradict the conditions of this License, they do not
|
||||
excuse you from the conditions of this License. If you cannot
|
||||
distribute so as to satisfy simultaneously your obligations under this
|
||||
License and any other pertinent obligations, then as a consequence you
|
||||
may not distribute the Library at all. For example, if a patent
|
||||
license would not permit royalty-free redistribution of the Library by
|
||||
all those who receive copies directly or indirectly through you, then
|
||||
the only way you could satisfy both it and this License would be to
|
||||
refrain entirely from distribution of the Library.
|
||||
|
||||
If any portion of this section is held invalid or unenforceable under any
|
||||
particular circumstance, the balance of the section is intended to apply,
|
||||
and the section as a whole is intended to apply in other circumstances.
|
||||
|
||||
It is not the purpose of this section to induce you to infringe any
|
||||
patents or other property right claims or to contest validity of any
|
||||
such claims; this section has the sole purpose of protecting the
|
||||
integrity of the free software distribution system which is
|
||||
implemented by public license practices. Many people have made
|
||||
generous contributions to the wide range of software distributed
|
||||
through that system in reliance on consistent application of that
|
||||
system; it is up to the author/donor to decide if he or she is willing
|
||||
to distribute software through any other system and a licensee cannot
|
||||
impose that choice.
|
||||
|
||||
This section is intended to make thoroughly clear what is believed to
|
||||
be a consequence of the rest of this License.
|
||||
|
||||
12. If the distribution and/or use of the Library is restricted in
|
||||
certain countries either by patents or by copyrighted interfaces, the
|
||||
original copyright holder who places the Library under this License may add
|
||||
an explicit geographical distribution limitation excluding those countries,
|
||||
so that distribution is permitted only in or among countries not thus
|
||||
excluded. In such case, this License incorporates the limitation as if
|
||||
written in the body of this License.
|
||||
|
||||
13. The Free Software Foundation may publish revised and/or new
|
||||
versions of the Lesser General Public 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.
|
||||
|
||||
Each version is given a distinguishing version number. If the Library
|
||||
specifies a version number of this License which applies to it and
|
||||
"any later version", you have the option of following the terms and
|
||||
conditions either of that version or of any later version published by
|
||||
the Free Software Foundation. If the Library does not specify a
|
||||
license version number, you may choose any version ever published by
|
||||
the Free Software Foundation.
|
||||
|
||||
14. If you wish to incorporate parts of the Library into other free
|
||||
programs whose distribution conditions are incompatible with these,
|
||||
write to the author to ask for permission. For software which is
|
||||
copyrighted by the Free Software Foundation, write to the Free
|
||||
Software Foundation; we sometimes make exceptions for this. Our
|
||||
decision will be guided by the two goals of preserving the free status
|
||||
of all derivatives of our free software and of promoting the sharing
|
||||
and reuse of software generally.
|
||||
|
||||
NO WARRANTY
|
||||
|
||||
15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO
|
||||
WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW.
|
||||
EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR
|
||||
OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY
|
||||
KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
||||
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE
|
||||
LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME
|
||||
THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
|
||||
|
||||
16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN
|
||||
WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY
|
||||
AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU
|
||||
FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR
|
||||
CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE
|
||||
LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING
|
||||
RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A
|
||||
FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF
|
||||
SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
|
||||
DAMAGES.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
||||
|
||||
How to Apply These Terms to Your New Libraries
|
||||
|
||||
If you develop a new library, and you want it to be of the greatest
|
||||
possible use to the public, we recommend making it free software that
|
||||
everyone can redistribute and change. You can do so by permitting
|
||||
redistribution under these terms (or, alternatively, under the terms of the
|
||||
ordinary General Public License).
|
||||
|
||||
To apply these terms, attach the following notices to the library. It is
|
||||
safest to attach them to the start of each source file to most effectively
|
||||
convey the exclusion of warranty; and each file should have at least the
|
||||
"copyright" line and a pointer to where the full notice is found.
|
||||
|
||||
<one line to give the library's name and a brief idea of what it does.>
|
||||
Copyright (C) <year> <name of author>
|
||||
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
This library 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
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with this library; if not, write to the Free Software
|
||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
|
||||
Also add information on how to contact you by electronic and paper mail.
|
||||
|
||||
You should also get your employer (if you work as a programmer) or your
|
||||
school, if any, to sign a "copyright disclaimer" for the library, if
|
||||
necessary. Here is a sample; alter the names:
|
||||
|
||||
Yoyodyne, Inc., hereby disclaims all copyright interest in the
|
||||
library `Frob' (a library for tweaking knobs) written by James Random Hacker.
|
||||
|
||||
<signature of Ty Coon>, 1 April 1990
|
||||
Ty Coon, President of Vice
|
||||
|
||||
That's all there is to it!
|
5
README.md
Normal file
5
README.md
Normal file
@ -0,0 +1,5 @@
|
||||
QSkinny
|
||||
-------
|
||||
|
||||
The (Q)Skinny library contains a set of lightweight Qt Quick Controls.
|
||||
It is implemented to 100% in C++, and can be used from C++ and/or QML application code.
|
60
TODO
Normal file
60
TODO
Normal file
@ -0,0 +1,60 @@
|
||||
- Layouts
|
||||
|
||||
There are no spacing/stretch getters for spacer items
|
||||
The initial spacings/margins have to be from the theme ( see QskLayoutEngineStyleInfo )
|
||||
|
||||
Code review 21-23.11
|
||||
--------------------
|
||||
|
||||
Add auto-add-children property to QskTabBar
|
||||
|
||||
Making QskGradient into QGradient (i.e. exposing QGradient to QML)
|
||||
|
||||
Replace QSK_DLL with QSK_STATIC (or possibly remove it if not needed)
|
||||
|
||||
Add QML module for QskModule, find a way to not link directly to QtQML
|
||||
|
||||
Move relevant properties from QskAbstractButton to QskPushButton (checkable, isChecked)
|
||||
|
||||
Hide classes inherited from QskAnimation
|
||||
|
||||
|
||||
Focus indicator: missing focus hints
|
||||
|
||||
Move QskImage to an example
|
||||
|
||||
Polish QskLineEdit & remove line edit example
|
||||
|
||||
QskIndexedLayout: equal width for all horizontal elements
|
||||
|
||||
Create skins as plugins; add squiek plugin as static plugin; use Q_IMPORT_PLUGIN for the examples (including Material)
|
||||
|
||||
Create playground directory for less-polished test examples
|
||||
|
||||
Finish slider API by introducing remaining pieces from QSlider ( inverted, inverted controls etc )
|
||||
|
||||
Add a cross-fade feature to QskWindow which freezes the frame and fades it out over an interval
|
||||
|
||||
qvg compiler only is built and run on the host
|
||||
|
||||
QskWindow: Add convenience methods for controlling resizing and preventing
|
||||
window visibility until first frame is rendered
|
||||
|
||||
QskListBox: make the text geometry calculation numerically stable ( see result with a million items )
|
||||
|
||||
Add additional connection overloads to QskShortcut (see QTimer for inspiration)
|
||||
|
||||
Add a "Tab" QML type which is simply a QML wrapper for QskTabButton to form a QQC1-compatible API
|
||||
|
||||
|
||||
Other stuff
|
||||
--------------------
|
||||
|
||||
QskGridBox needs to have a mode for static grids ( reserving space for potential gaps )
|
||||
|
||||
something like QskControl::setClipRect could be implemented on the scene graph
|
||||
level to make certain animations like in dcugui possible without introducing an extra item
|
||||
|
||||
State specific animators ( animators being related to the target state, what is
|
||||
not exactly the perfect solution what would be related to transitions ( Moore vs. Mealy )
|
||||
|
2309
doc/Doxyfile
Normal file
2309
doc/Doxyfile
Normal file
File diff suppressed because it is too large
Load Diff
194
doc/DoxygenLayout.xml
Normal file
194
doc/DoxygenLayout.xml
Normal file
@ -0,0 +1,194 @@
|
||||
<doxygenlayout version="1.0">
|
||||
<!-- Generated by doxygen 1.8.11 -->
|
||||
<!-- Navigation index tabs for HTML output -->
|
||||
<navindex>
|
||||
<tab type="mainpage" visible="yes" title=""/>
|
||||
<tab type="pages" visible="no" title="Pages" intro=""/>
|
||||
<tab type="modules" visible="yes" title="" intro=""/>
|
||||
<tab type="namespaces" visible="no" title="">
|
||||
<tab type="namespacelist" visible="no" title="" intro=""/>
|
||||
<tab type="namespacemembers" visible="no" title="" intro=""/>
|
||||
</tab>
|
||||
<tab type="classindex" visible="$ALPHABETICAL_INDEX" title="Index"/>
|
||||
<tab type="classes" visible="no" title="">
|
||||
<tab type="classlist" visible="no" title="" intro=""/>
|
||||
<tab type="hierarchy" visible="no" title="" intro=""/>
|
||||
<tab type="classmembers" visible="no" title="" intro=""/>
|
||||
</tab>
|
||||
<tab type="filelist" visible="yes" title="Files" intro=""/>
|
||||
<tab type="files" visible="no" title="">
|
||||
<tab type="globals" visible="no" title="" intro=""/>
|
||||
</tab>
|
||||
<tab type="examples" visible="yes" title="" intro=""/>
|
||||
</navindex>
|
||||
|
||||
<!-- Layout definition for a class page -->
|
||||
<class>
|
||||
<briefdescription visible="yes"/>
|
||||
<includes visible="$SHOW_INCLUDE_FILES"/>
|
||||
<inheritancegraph visible="$CLASS_GRAPH"/>
|
||||
<collaborationgraph visible="$COLLABORATION_GRAPH"/>
|
||||
<memberdecl>
|
||||
<nestedclasses visible="yes" title=""/>
|
||||
<publictypes title=""/>
|
||||
<services title=""/>
|
||||
<interfaces title=""/>
|
||||
<properties title=""/>
|
||||
<signals title=""/>
|
||||
<publicmethods title=""/>
|
||||
<publicstaticmethods title=""/>
|
||||
<publicslots title=""/>
|
||||
<publicattributes title=""/>
|
||||
<publicstaticattributes title=""/>
|
||||
<protectedtypes title=""/>
|
||||
<protectedslots title=""/>
|
||||
<protectedmethods title=""/>
|
||||
<protectedstaticmethods title=""/>
|
||||
<protectedattributes title=""/>
|
||||
<protectedstaticattributes title=""/>
|
||||
<packagetypes title=""/>
|
||||
<packagemethods title=""/>
|
||||
<packagestaticmethods title=""/>
|
||||
<packageattributes title=""/>
|
||||
<packagestaticattributes title=""/>
|
||||
<events title=""/>
|
||||
<privatetypes title=""/>
|
||||
<privateslots title=""/>
|
||||
<privatemethods title=""/>
|
||||
<privatestaticmethods title=""/>
|
||||
<privateattributes title=""/>
|
||||
<privatestaticattributes title=""/>
|
||||
<friends title=""/>
|
||||
<related title="" subtitle=""/>
|
||||
<membergroups visible="yes"/>
|
||||
</memberdecl>
|
||||
<detaileddescription title=""/>
|
||||
<memberdef>
|
||||
<inlineclasses title=""/>
|
||||
<typedefs title=""/>
|
||||
<enums title=""/>
|
||||
<services title=""/>
|
||||
<interfaces title=""/>
|
||||
<constructors title=""/>
|
||||
<functions title=""/>
|
||||
<related title=""/>
|
||||
<variables title=""/>
|
||||
<properties title=""/>
|
||||
<events title=""/>
|
||||
</memberdef>
|
||||
<allmemberslink visible="yes"/>
|
||||
<usedfiles visible="$SHOW_USED_FILES"/>
|
||||
<authorsection visible="yes"/>
|
||||
</class>
|
||||
|
||||
<!-- Layout definition for a namespace page -->
|
||||
<namespace>
|
||||
<briefdescription visible="yes"/>
|
||||
<memberdecl>
|
||||
<nestednamespaces visible="yes" title=""/>
|
||||
<constantgroups visible="yes" title=""/>
|
||||
<classes visible="yes" title=""/>
|
||||
<typedefs title=""/>
|
||||
<enums title=""/>
|
||||
<functions title=""/>
|
||||
<variables title=""/>
|
||||
<membergroups visible="yes"/>
|
||||
</memberdecl>
|
||||
<detaileddescription title=""/>
|
||||
<memberdef>
|
||||
<inlineclasses title=""/>
|
||||
<typedefs title=""/>
|
||||
<enums title=""/>
|
||||
<functions title=""/>
|
||||
<variables title=""/>
|
||||
</memberdef>
|
||||
<authorsection visible="yes"/>
|
||||
</namespace>
|
||||
|
||||
<!-- Layout definition for a file page -->
|
||||
<file>
|
||||
<briefdescription visible="yes"/>
|
||||
<includes visible="$SHOW_INCLUDE_FILES"/>
|
||||
<includegraph visible="$INCLUDE_GRAPH"/>
|
||||
<includedbygraph visible="$INCLUDED_BY_GRAPH"/>
|
||||
<sourcelink visible="yes"/>
|
||||
<memberdecl>
|
||||
<classes visible="yes" title=""/>
|
||||
<namespaces visible="yes" title=""/>
|
||||
<constantgroups visible="yes" title=""/>
|
||||
<defines title=""/>
|
||||
<typedefs title=""/>
|
||||
<enums title=""/>
|
||||
<functions title=""/>
|
||||
<variables title=""/>
|
||||
<membergroups visible="yes"/>
|
||||
</memberdecl>
|
||||
<detaileddescription title=""/>
|
||||
<memberdef>
|
||||
<inlineclasses title=""/>
|
||||
<defines title=""/>
|
||||
<typedefs title=""/>
|
||||
<enums title=""/>
|
||||
<functions title=""/>
|
||||
<variables title=""/>
|
||||
</memberdef>
|
||||
<authorsection/>
|
||||
</file>
|
||||
|
||||
<!-- Layout definition for a group page -->
|
||||
<group>
|
||||
<briefdescription visible="yes"/>
|
||||
<groupgraph visible="$GROUP_GRAPHS"/>
|
||||
<memberdecl>
|
||||
<nestedgroups visible="yes" title=""/>
|
||||
<dirs visible="yes" title=""/>
|
||||
<files visible="yes" title=""/>
|
||||
<namespaces visible="yes" title=""/>
|
||||
<classes visible="yes" title=""/>
|
||||
<defines title=""/>
|
||||
<typedefs title=""/>
|
||||
<enums title=""/>
|
||||
<enumvalues title=""/>
|
||||
<functions title=""/>
|
||||
<variables title=""/>
|
||||
<signals title=""/>
|
||||
<publicslots title=""/>
|
||||
<protectedslots title=""/>
|
||||
<privateslots title=""/>
|
||||
<events title=""/>
|
||||
<properties title=""/>
|
||||
<friends title=""/>
|
||||
<membergroups visible="yes"/>
|
||||
</memberdecl>
|
||||
<detaileddescription title=""/>
|
||||
<memberdef>
|
||||
<pagedocs/>
|
||||
<inlineclasses title=""/>
|
||||
<defines title=""/>
|
||||
<typedefs title=""/>
|
||||
<enums title=""/>
|
||||
<enumvalues title=""/>
|
||||
<functions title=""/>
|
||||
<variables title=""/>
|
||||
<signals title=""/>
|
||||
<publicslots title=""/>
|
||||
<protectedslots title=""/>
|
||||
<privateslots title=""/>
|
||||
<events title=""/>
|
||||
<properties title=""/>
|
||||
<friends title=""/>
|
||||
</memberdef>
|
||||
<authorsection visible="yes"/>
|
||||
</group>
|
||||
|
||||
<!-- Layout definition for a directory page -->
|
||||
<directory>
|
||||
<briefdescription visible="yes"/>
|
||||
<directorygraph visible="yes"/>
|
||||
<memberdecl>
|
||||
<dirs visible="yes"/>
|
||||
<files visible="yes"/>
|
||||
</memberdecl>
|
||||
<detaileddescription title=""/>
|
||||
</directory>
|
||||
</doxygenlayout>
|
13
doc/classes/QskAbstractButton.metadox
Normal file
13
doc/classes/QskAbstractButton.metadox
Normal file
@ -0,0 +1,13 @@
|
||||
INTERFACE
|
||||
CLASS: QskAbstractButton
|
||||
BASE: QskControl
|
||||
|
||||
QMLCLASS: AbstractButton
|
||||
QMLBASE: Control
|
||||
|
||||
HEADER: QskAbstractButton.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief Base class of all Qsk buttons
|
||||
END
|
||||
END
|
12
doc/classes/QskAnimation.dox
Normal file
12
doc/classes/QskAnimation.dox
Normal file
@ -0,0 +1,12 @@
|
||||
/*!
|
||||
\headerfile QskAnimation.h
|
||||
\brief Yet another system for animations
|
||||
*/
|
||||
|
||||
class QskAnimation
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
||||
|
11
doc/classes/QskArcIterator.dox
Normal file
11
doc/classes/QskArcIterator.dox
Normal file
@ -0,0 +1,11 @@
|
||||
/*!
|
||||
\headerfile QskArcIterator.h
|
||||
\brief A helper class for interpolating an arc with lines
|
||||
*/
|
||||
|
||||
class QskArcIterator
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
191
doc/classes/QskAspect.dox
Normal file
191
doc/classes/QskAspect.dox
Normal file
@ -0,0 +1,191 @@
|
||||
/*!
|
||||
\brief Defines a series of enum values for describing particular aspects of controls
|
||||
|
||||
\sa QskSkinHint
|
||||
\sa QskControl::skinHint
|
||||
\sa QskSkin::skinHint
|
||||
*/
|
||||
namespace QskAspect
|
||||
{
|
||||
/*!
|
||||
\var Aspect
|
||||
|
||||
Used by the \ref qskskinning "skin engine" to determine how a given aspect
|
||||
of a control is drawn. While Aspect is simply a 64-bit unsigned integer, it
|
||||
is composed of smaller enum bitfields which can be ORed together to
|
||||
describe a more specific part of the user interface.
|
||||
|
||||
For example, the top border color of a QskPushButton while pressed is
|
||||
defined by combining the State (QskAbstractButton::Pressed) with the
|
||||
Subcontrol (QskPushButton::Panel), the Primitive (Border),
|
||||
the edge/corner (Top), and the Type (Color) as so:
|
||||
|
||||
auto aspect = QskAbstractButton::Pressed | QskPushButton::Panel | QskAspect::Border | QskAspect::Top | QskAspect::Color
|
||||
|
||||
This `aspect` can then be passed to, e.g., QskSkin::setSkinHint as the first
|
||||
argument.
|
||||
|
||||
The 64 bits in Aspect are partitioned as follows (Note: flags are
|
||||
interpreted as single bits, while IDs are interpreted as aggregate integer
|
||||
values):
|
||||
0xFFFF000000000000 | 0x0000FFFF00000000 | 0x00000000FFF00000 | 0x00000000000F0000 | 0x000000000000F000 | 0x0000000000000800 | 0x0000000000000700 | 0x00000000000000FF
|
||||
-------------------| --------------------------- | -------------------------------- | ------------------------------ | -------------------------------------------- | ---------------------------- | ------------------------- | --------------------------
|
||||
Unused | QskAspect::State (16 flags) | QskAspect::Subcontrol (4096 IDs) | QskAspect::Primitive (255 IDs) | QskAspect::Corner, QskAspect::Edge (4 flags) | QskAspect::Modifier (1 flag) | QskAspect::Type (128 IDs) | QskAspect::Index (256 IDs)
|
||||
|
||||
\note The above structure may change in the future as features are added
|
||||
and/or sections are be expanded to accommodate wider information types.
|
||||
*/
|
||||
|
||||
/*! Represents a specific "subresource" ID, usually a FontRole or ColorRole.
|
||||
In most cases, the default (`0`) is appropriate. */
|
||||
enum Index : std::uint8_t
|
||||
{
|
||||
FirstIndex = 0x00,
|
||||
LastIndex = 0xFF,
|
||||
};
|
||||
|
||||
/*! Represents the data type of the Aspect. The default is Flag, but
|
||||
more commonly this will be a Color or Metric. Colors are 32-bit ARGB
|
||||
values (see QRgb), and Metrics are `float` values typically
|
||||
corresponding to pixel distances. */
|
||||
enum Type : std::uint16_t
|
||||
{
|
||||
Flag = 0x0000, // default, enum / int
|
||||
Metric = 0x0100, // float
|
||||
Color = 0x0200, // QRgb (uint)
|
||||
};
|
||||
|
||||
/*! Adds extra information to Type. Currently, the only modifier is Animator,
|
||||
which specifies that skinhint corresponds to the animation data for this
|
||||
Aspect. */
|
||||
enum Modifier : std::uint16_t
|
||||
{
|
||||
Animator = 0x0800 ///< Denotes that the skin hint affects the animation timing/easing.
|
||||
};
|
||||
|
||||
/*! Used with certain Primitives (such as Border) to specify an edge. Zero or
|
||||
more Edges can be combined to denote which edge(s) the Aspect is concerned.
|
||||
The default value of `0` implies AllEdges. */
|
||||
enum Edge : std::uint32_t
|
||||
{
|
||||
Left = 0x00001000,
|
||||
Top = 0x00002000,
|
||||
Right = 0x00004000,
|
||||
Bottom = 0x00008000,
|
||||
AllEdges = Top | Left | Right | Bottom
|
||||
};
|
||||
|
||||
/*! Used with certain Primitives (such as Radius) to specify a corner. Zero or
|
||||
more Corners can be combined to denote which corner(s) the Aspect is concerned.
|
||||
The default value of `0` implies AllCorners. */
|
||||
enum Corner : std::uint32_t
|
||||
{
|
||||
TopLeft = 0x00001000,
|
||||
TopRight = 0x00002000,
|
||||
BottomRight = 0x00004000,
|
||||
BottomLeft = 0x00008000,
|
||||
LeftCorners = TopLeft | BottomLeft,
|
||||
RightCorners = TopRight | BottomRight,
|
||||
TopCorners = TopLeft | TopRight,
|
||||
BottomCorners = BottomLeft | BottomRight,
|
||||
AllCorners = TopLeft | TopRight | BottomLeft | BottomRight
|
||||
};
|
||||
|
||||
/*! The fundamental building blocks of box-like UI components, based on the
|
||||
<a>CSS box model</a>. See QskSkinRenderer::updateBox for more information. */
|
||||
enum Primitive : std::uint32_t
|
||||
{
|
||||
Background = 0x00000000, ///< The default primitive, the background color(s)
|
||||
|
||||
Margin = 0x00010000, ///< The margin, according to the CSS box model
|
||||
Padding = 0x00020000, ///< The padding, according to the CSS box model
|
||||
RadiusX = 0x00030000, ///< The horizontal corner radius, according to the CSS box model
|
||||
RadiusY = 0x00040000, ///< The vertical corner radius, according to the CSS box model
|
||||
Border = 0x00050000, ///< The border thickness/color, according to the CSS box model
|
||||
Shadow = 0x00060000, ///< The shadow thickness/color, according to the CSS box model
|
||||
Radius = RadiusX | RadiusY, // 0x70000 ///< Convenience enum for specifying both horizontal and vertical radii
|
||||
|
||||
Fundamental = 0x00080000 // Disables edge/corner routing
|
||||
};
|
||||
|
||||
/*! For use within the rendering of a specific QskSkinnable. While the Default
|
||||
value applies to any control (and can be used as a fallback), specifying a
|
||||
Subcontrol limits the aspect's scope to that sub-component (or \em subcontrol)
|
||||
of the control. For example, the Subcontrol type QskPushButton::Panel refers
|
||||
to the background panel of a push button. */
|
||||
enum Subcontrol : std::uint32_t
|
||||
{
|
||||
Default = 0x00000000,
|
||||
FirstSubcontrol = 0x00100000,
|
||||
LastSubcontrol = 0xFFF00000
|
||||
};
|
||||
|
||||
/*! Applies to a given aspect when the control is in a given state.
|
||||
QskSkinnable subclasses (typically QskControl subclasses) can define UI
|
||||
states, as denoted by any OR combination of State flags. For example, a
|
||||
checked QskPushButton has the QskPushButton::Checked state flag set when
|
||||
it is checked. */
|
||||
enum State : std::uint64_t
|
||||
{
|
||||
FirstSystemState = 0x0000000100000000, ///< The first state bit reserved for framework use
|
||||
FirstUserState = 0x0000001000000000, ///< The first state bit reserved for application use
|
||||
LastUserState = 0x0000080000000000, ///< The last state bit reserved for applicaiton use
|
||||
LastSystemState = 0x0000800000000000, ///< The last state bit reserved for framework use
|
||||
Automatic = 0x0000000000000000, ///< No specified state (the default)
|
||||
NoState = 0x0000FFFF00000000 ///< Empty state, explicitly specified. Useful in some types of animators.
|
||||
};
|
||||
|
||||
/*! These Aspects are for convenience, providing commonly combined values
|
||||
to limit the verbosity of combining Aspects in application code. */
|
||||
enum : Aspect
|
||||
{
|
||||
MarginTop = Margin | Top, ///< The top margin
|
||||
MarginLeft = Margin | Left, ///< The left margin
|
||||
MarginRight = Margin | Right, ///< The right margin
|
||||
MarginBottom = Margin | Bottom, ///< The bottom margin
|
||||
PaddingTop = Padding | Top, ///< The top padding
|
||||
PaddingLeft = Padding | Left, ///< The left padding
|
||||
PaddingRight = Padding | Right, ///< The right padding
|
||||
PaddingBottom = Padding | Bottom, ///< The bottom padding
|
||||
BorderTop = Border | Top, ///< The top border
|
||||
BorderLeft = Border | Left, ///< The left border
|
||||
BorderRight = Border | Right, ///< The right border
|
||||
BorderBottom = Border | Bottom, ///< The bottom border
|
||||
ShadowTop = Shadow | Top, ///< The top shadow
|
||||
ShadowLeft = Shadow | Left, ///< The left shadow
|
||||
ShadowRight = Shadow | Right, ///< The right shadow
|
||||
ShadowBottom = Shadow | Bottom, ///< The bottom shadow
|
||||
|
||||
RadiusXTopLeft = RadiusX | TopLeft, ///< The top-left horizontal radius
|
||||
RadiusXTopRight = RadiusX | TopRight, ///< The top-right horizontal radius
|
||||
RadiusXBottomLeft = RadiusX | BottomLeft, ///< The bottom-left horizontal radius
|
||||
RadiusXBottomRight = RadiusX | BottomRight, ///< The bottom-right horizontal radius
|
||||
RadiusYTopLeft = RadiusY | TopLeft, ///< The top-left vertical radius
|
||||
RadiusYTopRight = RadiusY | TopRight, ///< The top-right vertical radius
|
||||
RadiusYBottomLeft = RadiusY | BottomLeft, ///< The bottom-left vertical radius
|
||||
RadiusYBottomRight = RadiusY | BottomRight, ///< The bottom-right vertical radius
|
||||
|
||||
// Standard metrics
|
||||
Size = 0x0000000000000000 | Fundamental | Metric, ///< A "size" placeholder, like width or height
|
||||
Position = 0x0000000000010000 | Fundamental | Metric, ///< A "position" placeholder, like the position of a QskSlider
|
||||
MinimumWidth = 0x0000000000020000 | Fundamental | Metric, ///< A minimum width hint
|
||||
MinimumHeight = 0x0000000000030000 | Fundamental | Metric, ///< A minimum height hint
|
||||
MaximumWidth = 0x0000000000040000 | Fundamental | Metric, ///< A maximum width hint
|
||||
MaximumHeight = 0x0000000000050000 | Fundamental | Metric, ///< A maximum height hint
|
||||
Spacing = 0x0000000000060000 | Fundamental | Metric, ///< A spacing hint, such as between rows in a QskListBox
|
||||
|
||||
// Standard flags
|
||||
Alignment = 0x0000000000000000 | Fundamental | Flag, ///< A flag typically used for storing text alignments (Qt::Alignment)
|
||||
Style = 0x0000000000010000 | Fundamental | Flag, ///< A flag for storing text style (Qsk::Style)
|
||||
Decoration = 0x0000000000020000 | Fundamental | Flag, ///< A flag for storing decoration information
|
||||
ColorRole = 0x0000000000060000 | Fundamental | Flag, ///< A flag for specifying a QRgb value at a given QskAspect::Index
|
||||
FontRole = 0x0000000000070000 | Fundamental | Flag, ///< A flag for specifying a QFont value at a given QskAspect::Index
|
||||
|
||||
// Standard colors
|
||||
TextColor = 0x0000000000000000 | Fundamental | Color, ///< A placeholder for text color
|
||||
StyleColor = 0x0000000000010000 | Fundamental | Color, ///< A placeholder for text style color
|
||||
LinkColor = 0x0000000000020000 | Fundamental | Color, ///< A placeholder for text link color
|
||||
|
||||
AllAspects = 0xFFFFFFFFFFFFFFFF ///< All possible bits in Aspect (useful for e.g. QskSkinnable::markDirty).
|
||||
};
|
||||
}
|
11
doc/classes/QskBorder.dox
Normal file
11
doc/classes/QskBorder.dox
Normal file
@ -0,0 +1,11 @@
|
||||
/*!
|
||||
\headerfile QskBorder.h
|
||||
\brief Border attributes that can be used from QML
|
||||
*/
|
||||
|
||||
class QskBorder
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
13
doc/classes/QskClipNode.dox
Normal file
13
doc/classes/QskClipNode.dox
Normal file
@ -0,0 +1,13 @@
|
||||
/*!
|
||||
\headerfile QskClipNode.h
|
||||
\brief A clip node for rectangles with rounded borders
|
||||
|
||||
\sa QskVertexRenderer
|
||||
*/
|
||||
|
||||
class QskClipNode
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
195
doc/classes/QskControl.metadox
Normal file
195
doc/classes/QskControl.metadox
Normal file
@ -0,0 +1,195 @@
|
||||
INTERFACE
|
||||
CLASS: QskControl
|
||||
BASE: QQuickItem
|
||||
|
||||
QMLCLASS: Control
|
||||
QMLBASE: Item
|
||||
|
||||
HEADER: QskControl.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief Base class of all Qsk controls
|
||||
|
||||
QskControl is the base class for most visible Qsk controls.
|
||||
|
||||
It re-establishes several concepts known from QWidget, that got lost
|
||||
with QQuickItem:
|
||||
|
||||
- contentsRect()
|
||||
- autoFillBackground()
|
||||
- support of layout rules: sizeHint(), sizePolicy()
|
||||
- font, palette, locale and their propagation on the item tree
|
||||
|
||||
Even if QQuickItem is part of the public C++ API it has obviously been
|
||||
designed for implementing custom items, but not for using them in C++
|
||||
code. To support this use case a lot of trivial methods have been added.
|
||||
|
||||
For some reason the QQuick classes introduced proprietory notfier hooks
|
||||
instead of using the well established and powerful concept of events.
|
||||
QskControl tries to revert this decision by mapping notifications
|
||||
to events, when possible.
|
||||
|
||||
The following events are currently implemented:
|
||||
|
||||
- QEvent::FontChange
|
||||
- QEvent::PaletteChange
|
||||
- QEvent::LocaleChange
|
||||
- QEvent::LayoutDirectionChange
|
||||
- QEvent::ContentsRectChange
|
||||
- QEvent::LayoutRequest
|
||||
END
|
||||
|
||||
ENUM
|
||||
CLASS: Flag
|
||||
QMLCLASS: Flag
|
||||
|
||||
DESCRIPTION
|
||||
QQuick classes have a tendency to update items too early
|
||||
and too often. To avoid processing of unwanted operations
|
||||
QskControl implements a couple of modifications, that
|
||||
can be en/disabled individually.
|
||||
|
||||
The default setting enables all attributes.
|
||||
|
||||
\var ClipBoundary
|
||||
|
||||
If ClipBoundary is enabled the control initially sets a
|
||||
clip for its bounding rectangle.
|
||||
|
||||
\sa QQuickItem::setClip()
|
||||
|
||||
\var DeferredUpdate
|
||||
|
||||
Creating of paint nodes is blocked for all invisible nodes
|
||||
( QQuickItem::isVisible() ).
|
||||
|
||||
\note Some more advanced algorithms have not yet been implemented,
|
||||
such as viewport frustrum culling (i.e. hiding items outside of the
|
||||
window geometry).
|
||||
|
||||
\var DeferredPolish
|
||||
|
||||
Calculation of layouts ( updateLayout() ) is blocked for all invisible
|
||||
nodes ( QQuickItem::isVisible() ).
|
||||
|
||||
\var DeferredLayout
|
||||
|
||||
Updates of the implicit size is blocked until effectiveConstraint() or sizeHint()
|
||||
is explicitly called. When being enabled the implicit size is not recalculated before
|
||||
being requested - usually by a QskLayout.
|
||||
|
||||
\var CleanupOnVisibility
|
||||
|
||||
Delete scene graph nodes, when the item becomes hidden ( QQuickItem::isVisible() ).
|
||||
Enabling this mode will reduce the memory footprint, but comes at the cost
|
||||
of having to recreate nodes later.
|
||||
|
||||
\var PreferRasterForTextures
|
||||
|
||||
When creating textures from QskGraphic, prefer the raster paint
|
||||
engine over the OpenGL paint engine.
|
||||
|
||||
\var DebugForceBackground
|
||||
|
||||
Always fill the background of thecontrol with a random color.
|
||||
\note This flag is useful when analyzing layouts.
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setControlFlag( Flag, bool on = true );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void resetControlFlag( Flag );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: bool testControlFlag( Flag ) const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: void setColor( QskAspect::Aspect aspect, const QColor &color )
|
||||
DESCRIPTION: Sets the color (as a QColor) for the given QskSkinHint.
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: void setColor( QskAspect::Aspect aspect, Qt::GlobalColor color )
|
||||
DESCRIPTION: Sets the color (as a Qt::GlobalColor) for the given QskSkinHint.
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: void setColor( QskAspect::Aspect aspect, QRgb color )
|
||||
DESCRIPTION: Sets the color (as a QRgb value) for the given QskSkinHint.
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: QRgb color( QskAspect::Aspect aspect ) const
|
||||
DESCRIPTION: A convenience method equivalent to QskControl::skinHint().color.
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: void setMetric( QskAspect::Aspect aspect, float metric )
|
||||
DESCRIPTION: Sets the metric for the given QskSkinHint.
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: float metric( QskAspect::Aspect aspect ) const
|
||||
DESCRIPTION
|
||||
A convenience method equivalent to skinHint( aspect ).metric. The
|
||||
QskSkinHint::TypeMask is set to QskSkinHint::Metric.
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: void setSkinlet( QskSkinlet* skinlet )
|
||||
DESCRIPTION
|
||||
Allows overriding the QskControl::Skin used by this control to render its
|
||||
contents.
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: const QskSkinlet* skinlet() const;
|
||||
DESCRIPTION
|
||||
\return Skinlet assigned by setSkinlet().
|
||||
\sa effectiveSkinlet()
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: QskSkinHint skinHint( QskAspect::Aspect aspect ) const
|
||||
DESCRIPTION
|
||||
Returns the QskSkinHint value for a QskAspect::Aspect. If none is set for
|
||||
this control, the value for QskSkin::skinHint() is returned.
|
||||
|
||||
\note If a QskSkinHintProvider is animating the color when called, the returned
|
||||
value will be the current value, not the target value, unless a state mask
|
||||
is requested as part of the aspect.
|
||||
|
||||
\param aspect Aspect
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: void updateNode( QSGNode* parentNode )
|
||||
DESCRIPTION
|
||||
This method replaces the QQuickItem::updatePaintNode method as the
|
||||
preferred paint method to override when subclassing QskControl. This allows
|
||||
QskControl to perform some additional steps before calling updateNode(),
|
||||
and provides a consistent parent node which subclasses can rely on.
|
||||
|
||||
Subclasses should call their Skin's updateNode() method inside this
|
||||
method.
|
||||
|
||||
\param parentNode The parent of the nodes to be added in this method.
|
||||
\return The parent node.
|
||||
END
|
||||
END
|
||||
END
|
11
doc/classes/QskCorner.dox
Normal file
11
doc/classes/QskCorner.dox
Normal file
@ -0,0 +1,11 @@
|
||||
/*!
|
||||
\headerfile QskCorner.h
|
||||
\brief Attributes of a rounded corner that can be used from QML
|
||||
*/
|
||||
|
||||
class QskCorner
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
14
doc/classes/QskDialog.metadox
Normal file
14
doc/classes/QskDialog.metadox
Normal file
@ -0,0 +1,14 @@
|
||||
INTERFACE
|
||||
CLASS: QskDialog
|
||||
BASE: QskWindow
|
||||
|
||||
QMLCLASS: Dialog
|
||||
QMLBASE: Window
|
||||
|
||||
HEADER: QskDialog.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief A quick window for dialogs, reintroducing lost concepts
|
||||
of the QWidget framwork.
|
||||
END
|
||||
END
|
14
doc/classes/QskDialogButtonBox.metadox
Normal file
14
doc/classes/QskDialogButtonBox.metadox
Normal file
@ -0,0 +1,14 @@
|
||||
INTERFACE
|
||||
CLASS: QskDialogButtonBox
|
||||
BASE: QskControl
|
||||
|
||||
QMLCLASS: DialogButtonBox
|
||||
QMLBASE: Control
|
||||
|
||||
HEADER: QskDialogButtonBox.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief A button box for dialogs affected by layout policies
|
||||
of the platform theme.
|
||||
END
|
||||
END
|
14
doc/classes/QskFocusIndicator.metadox
Normal file
14
doc/classes/QskFocusIndicator.metadox
Normal file
@ -0,0 +1,14 @@
|
||||
INTERFACE
|
||||
CLASS: QskFocusIndicator
|
||||
BASE: QskControl
|
||||
|
||||
QMLCLASS: FocusIndicator
|
||||
QMLBASE: Control
|
||||
|
||||
HEADER: QskFocusIndicator.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief An indicator showing the current position of the keyboard focus
|
||||
END
|
||||
END
|
||||
|
12
doc/classes/QskFocusIndicatorSkinlet.dox
Normal file
12
doc/classes/QskFocusIndicatorSkinlet.dox
Normal file
@ -0,0 +1,12 @@
|
||||
/*!
|
||||
\headerfile QskFocusIndicatorSkinlet.h
|
||||
\brief Base class of all skinlets for QskFocusIndicator
|
||||
*/
|
||||
|
||||
class QskFocusIndicatorSkinlet
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
||||
|
13
doc/classes/QskFrame.metadox
Normal file
13
doc/classes/QskFrame.metadox
Normal file
@ -0,0 +1,13 @@
|
||||
INTERFACE
|
||||
CLASS: QskFrame
|
||||
BASE: QskControl
|
||||
|
||||
QMLCLASS: Frame
|
||||
QMLBASE: Control
|
||||
|
||||
HEADER: QskFrame.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief A container with a frame
|
||||
END
|
||||
END
|
13
doc/classes/QskFrameNode.dox
Normal file
13
doc/classes/QskFrameNode.dox
Normal file
@ -0,0 +1,13 @@
|
||||
/*!
|
||||
\headerfile QskFrameNode.h
|
||||
\brief A geometry node for displaying a frame
|
||||
|
||||
\sa QskVertexRendererColored
|
||||
*/
|
||||
|
||||
class QskFrameNode
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
11
doc/classes/QskFrameSkinlet.dox
Normal file
11
doc/classes/QskFrameSkinlet.dox
Normal file
@ -0,0 +1,11 @@
|
||||
/*!
|
||||
\headerfile QskFrameSkinlet.h
|
||||
\brief Base class of all skinlets for QskFrame
|
||||
*/
|
||||
|
||||
class QskFrameSkinlet
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
19
doc/classes/QskGeometry.dox
Normal file
19
doc/classes/QskGeometry.dox
Normal file
@ -0,0 +1,19 @@
|
||||
/*! \namespace QskGeometry
|
||||
|
||||
\brief A collection of utility classes for manipulating Scene Graph geometry.
|
||||
*/
|
||||
|
||||
/*! \class QskSimpleBorderGeometry
|
||||
|
||||
\brief A convenience class for managing nine-patch images. To be used with
|
||||
materials rendering textured vertices, such as QSGTextureMaterial or
|
||||
QskFlatColorSymbolMaterial. To combine per-vertex colors with textured
|
||||
materials, use QskColoredBorderGeometry.
|
||||
*/
|
||||
|
||||
/*! \class QskColoredBorderGeometry
|
||||
|
||||
\brief A convenience class for managing nine-patch images. To be used with
|
||||
materials providing per-vertex colored textured vertices, such as
|
||||
QskVertexColoredSymbolMaterial.
|
||||
*/
|
9
doc/classes/QskGradient.dox
Normal file
9
doc/classes/QskGradient.dox
Normal file
@ -0,0 +1,9 @@
|
||||
/*! \class QskGradientStop
|
||||
|
||||
\brief A color stop of a QskGradient
|
||||
*/
|
||||
|
||||
/*! \class QskGradient
|
||||
|
||||
\brief Attributes of a linear gradient that can be set from QML
|
||||
*/
|
51
doc/classes/QskGraphic.dox
Normal file
51
doc/classes/QskGraphic.dox
Normal file
@ -0,0 +1,51 @@
|
||||
/*!
|
||||
\headerfile QskGraphic.h
|
||||
\brief A paint device for scalable graphics
|
||||
|
||||
QskGraphic is the representation of a graphic that is tailored for
|
||||
scalability. Like QPicture it will be initialized by QPainter
|
||||
operations and can be replayed later to any target paint device.
|
||||
It can be stored and loaded from disk using the operators
|
||||
from QskGraphicIO. Together with QSvgRenderer it can be used to
|
||||
implement a simple SVG compiler.
|
||||
|
||||
QskGraphic maps all scalable drawing primitives to a QPainterPath
|
||||
and stores them together with the painter state changes
|
||||
( pen, brush, transformation ... ) in a list of QskPainterCommand.
|
||||
For being a complete QPaintDevice it also stores pixmaps or images,
|
||||
what is somehow against the idea of the class, because these objects
|
||||
can't be scaled without a loss in quality.
|
||||
|
||||
The main issue about scaling a QskGraphic object are the pens used for
|
||||
drawing the outlines of the painter paths. While non cosmetic pens
|
||||
( QPen::isCosmetic() ) are scaled with the same ratio as the path,
|
||||
cosmetic pens have a fixed width. A graphic might have paths with
|
||||
different pens - cosmetic and non-cosmetic.
|
||||
|
||||
QskGraphic caches 2 different rectangles:
|
||||
|
||||
- control point rectangle\n
|
||||
The control point rectangle is the bounding rectangle of all
|
||||
control point rectangles of the painter paths, or the target
|
||||
rectangle of the pixmaps/images.
|
||||
|
||||
- bounding rectangle\n
|
||||
The bounding rectangle extends the control point rectangle by
|
||||
what is needed for rendering the outline with an unscaled pen.
|
||||
|
||||
Because the offset for drawing the outline depends on the shape
|
||||
of the painter path ( the peak of a triangle is different than the flat side )
|
||||
scaling with a fixed aspect ratio always needs to be calculated from the
|
||||
control point rectangle.
|
||||
|
||||
\sa QskGraphicIO, QskPainterCommand
|
||||
\note This class is a clone of QwtGraphic ( http://qwt.sf.net/class_qwt_graphic.html )
|
||||
*/
|
||||
|
||||
class QskGraphic
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
||||
|
14
doc/classes/QskGraphicIO.dox
Normal file
14
doc/classes/QskGraphicIO.dox
Normal file
@ -0,0 +1,14 @@
|
||||
/*!
|
||||
\headerfile QskGraphicImageProvider.h
|
||||
|
||||
\brief I/O operations for a QskGraphic
|
||||
|
||||
\note QskGraphicIO does not store/reload the meta information yet,
|
||||
what would improve the performance of loading.
|
||||
*/
|
||||
|
||||
namespace QskGraphicIO
|
||||
{
|
||||
/*!
|
||||
*/
|
||||
}
|
18
doc/classes/QskGraphicImageProvider.dox
Normal file
18
doc/classes/QskGraphicImageProvider.dox
Normal file
@ -0,0 +1,18 @@
|
||||
/*!
|
||||
\headerfile QskGraphicImageProvider.h
|
||||
\brief A QQuickImageProvider making QskGraphicProvider available
|
||||
for QQuickImage items.
|
||||
|
||||
QskGraphicImageProvider supports images, pixmaps or textures, but only
|
||||
when requesting a QQuickTextureFactory the item will be able to
|
||||
scale the image without a loss in quality.
|
||||
|
||||
\sa QskGraphicTextureFactory, QskGraphicProvider, Qsk::addGraphicProvider
|
||||
*/
|
||||
|
||||
class QskGraphicImageProvider
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
13
doc/classes/QskGraphicLabel.metadox
Normal file
13
doc/classes/QskGraphicLabel.metadox
Normal file
@ -0,0 +1,13 @@
|
||||
INTERFACE
|
||||
CLASS: QskGraphicLabel
|
||||
BASE: QskControl
|
||||
|
||||
QMLCLASS: GraphicLabel
|
||||
QMLBASE: Control
|
||||
|
||||
HEADER: QskGraphicLabel.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief A control displaying a graphic.
|
||||
END
|
||||
END
|
11
doc/classes/QskGraphicLabelSkinlet,dox
Normal file
11
doc/classes/QskGraphicLabelSkinlet,dox
Normal file
@ -0,0 +1,11 @@
|
||||
/*!
|
||||
\headerfile QskGraphicLabelSkin.h
|
||||
\brief Base class of all skins for QskGraphicLabel
|
||||
*/
|
||||
|
||||
class QskGraphicLabelSkin
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
11
doc/classes/QskGraphicPaintEngine.dox
Normal file
11
doc/classes/QskGraphicPaintEngine.dox
Normal file
@ -0,0 +1,11 @@
|
||||
/*!
|
||||
\headerfile QskGraphicPaintEngine.h
|
||||
\brief The paint engine for QskGraphic
|
||||
*/
|
||||
|
||||
class QskGraphicPaintEngine
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
18
doc/classes/QskGraphicPaintFilter.dox
Normal file
18
doc/classes/QskGraphicPaintFilter.dox
Normal file
@ -0,0 +1,18 @@
|
||||
/*!
|
||||
\headerfile QskGraphicPaintFilter.h
|
||||
|
||||
\brief A filter for substituting colors of a QskGraphic
|
||||
|
||||
A color filter can be used to avoid having to create
|
||||
variations of an image for different color themes.
|
||||
|
||||
\sa QskGraphic::render(), QskGraphicLabel::setGraphicFilter(),
|
||||
QskGraphicTextureFactory::setGraphicFilter()
|
||||
*/
|
||||
|
||||
class QskGraphicPaintFilter
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
13
doc/classes/QskGraphicProvider.dox
Normal file
13
doc/classes/QskGraphicProvider.dox
Normal file
@ -0,0 +1,13 @@
|
||||
/*!
|
||||
\headerfile QskGraphicProvider.h
|
||||
|
||||
\brief QskGraphicProvider loads QskGraphic from a source URL.
|
||||
\sa QskGraphicImageProvider, Qsk::addGraphicProvider
|
||||
*/
|
||||
|
||||
class QskGraphicProvider
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
16
doc/classes/QskGraphicTextureFactory.dox
Normal file
16
doc/classes/QskGraphicTextureFactory.dox
Normal file
@ -0,0 +1,16 @@
|
||||
/*!
|
||||
\headerfile QskGraphicTextureFactory.h
|
||||
\brief A QQuickTextureFactory creating a QSGTexture from a QskGraphic.
|
||||
|
||||
QskGraphicTextureFactory is a helper class to forward the creation
|
||||
of textures for QQuickImage to the scene graph thread.
|
||||
|
||||
\sa QskGraphicImageProvider
|
||||
*/
|
||||
|
||||
class QskGraphicTextureFactory
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
369
doc/classes/QskGridBox.metadox
Normal file
369
doc/classes/QskGridBox.metadox
Normal file
@ -0,0 +1,369 @@
|
||||
INTERFACE
|
||||
|
||||
CLASS: QskGridBox
|
||||
BASE: QskLayout
|
||||
|
||||
QMLCLASS: GridBox
|
||||
QMLBASE: Layout
|
||||
|
||||
HEADER: QskGridBox.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief Layout organizing quick items in grid
|
||||
END
|
||||
|
||||
PROPERTY
|
||||
NAME: horizontalSpacing
|
||||
TYPE: double
|
||||
|
||||
READ: horizontalSpacing()
|
||||
WRITE: setHorizontalSpacing()
|
||||
NOTIFY: horizontalSpacingChanged()
|
||||
|
||||
DESCRIPTION
|
||||
Horizontal spacing between items
|
||||
\sa verticalSpacing
|
||||
END
|
||||
END
|
||||
|
||||
PROPERTY
|
||||
NAME: verticalSpacing
|
||||
TYPE: double
|
||||
|
||||
READ: verticalSpacing()
|
||||
WRITE: setVerticalSpacing()
|
||||
NOTIFY: verticalSpacingChanged()
|
||||
|
||||
DESCRIPTION
|
||||
Vertical spacing between items
|
||||
\sa horizontalSpacing
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: QskGridBox( QUICKITEM parent )
|
||||
DESCRIPTION
|
||||
\brief Constructor
|
||||
|
||||
Create an empty layout
|
||||
\param parent Parent item
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: ~QskGridBox()
|
||||
DESCRIPTION: \brief Destructor
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE
|
||||
void addItem(
|
||||
QUICKITEM, int row, int column, int rowSpan,
|
||||
int columnSpan, Qt::Alignment alignment );
|
||||
END
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE
|
||||
void addItem( QUICKITEM, int row, int column, Qt::Alignment alignment );
|
||||
END
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: int rowCount() const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: int columnCount() const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: QUICKITEM itemAt( int row, int column ) const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: int rowOfIndex( int index ) const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: int rowSpanOfIndex( int index ) const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: int columnOfIndex( int index ) const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: int columnSpanOfIndex( int index ) const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: setHorizontalSpacing( qreal spacing );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: resetHorizontalSpacing();
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: int horizontalSpacing() const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: int setVerticalSpacing() const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: void resetVerticalSpacing();
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: int verticalSpacing() const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setRowSpacing( int row, qreal spacing );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: qreal rowSpacing( int row ) const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setColumnSpacing( int column, qreal spacing );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: qreal columnSpacing( int column ) const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setRowStretchFactor( int row, int stretch );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: int rowStretchFactor( int row ) const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setColumnStretchFactor( int column, int stretch );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: int columnStretchFactor( int column ) const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setRowMinimumHeight( int row, qreal height );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: qreal rowMinimumHeight( int row ) const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setRowPreferredHeight( int row, qreal height );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: qreal rowPreferredHeight( int row ) const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setRowMaximumHeight( int row, qreal height );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: qreal rowMaximumHeight( int row ) const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setRowFixedHeight( int row, qreal height );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setColumnMinimumWidth( int column, qreal width );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: qreal columnMinimumWidth( int column ) const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setColumnPreferredWidth( int column, qreal width );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: qreal columnPreferredWidth( int column ) const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setColumnMaximumWidth( int column, qreal width );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: qreal columnMaximumWidth( int column ) const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setColumnFixedWidth( int column, qreal width );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setRowAlignment( int row, Qt::Alignment alignment );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: Qt::Alignment rowAlignment( int row ) const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setColumnAlignment( int column, Qt::Alignment alignment );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: Qt::Alignment columnAlignment( int column ) const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setAlignment( QQuickItem *item, Qt::Alignment alignment );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: Qt::Alignment alignment( QQuickItem *item ) const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: bool retainSizeWhenHidden( QQuickItem * ) const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setRetainSizeWhenHidden( QQuickItem *, bool on );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: QSizeF contentsSizeHint() const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
SIGNAL
|
||||
SIGNATURE: verticalSpacingChanged();
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
SIGNAL
|
||||
SIGNATURE: horizontalSpacingChanged();
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: void setupLayoutItem( QskLayoutItem*, int index );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: void layoutItemInserted( QskLayoutItem*, int index );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: void layoutItemRemoved( QskLayoutItem*, int index );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
END
|
16
doc/classes/QskImage.metadox
Normal file
16
doc/classes/QskImage.metadox
Normal file
@ -0,0 +1,16 @@
|
||||
INTERFACE
|
||||
CLASS: QskImage
|
||||
BASE: QQuickImage
|
||||
|
||||
QMLCLASS: Image
|
||||
|
||||
# Not true as we inherit from QQuickImage ( = Image )
|
||||
# how to solve this ???
|
||||
QMLBASE: Item
|
||||
|
||||
HEADER: QskImage.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief An extended version of QQuickImage
|
||||
END
|
||||
END
|
185
doc/classes/QskIndexedLayoutBox.metadox
Normal file
185
doc/classes/QskIndexedLayoutBox.metadox
Normal file
@ -0,0 +1,185 @@
|
||||
INTERFACE
|
||||
|
||||
CLASS: QskIndexedLayoutBox
|
||||
BASE: QskLayout
|
||||
|
||||
QMLCLASS: IndexedLayoutBox
|
||||
QMLBASE: Layout
|
||||
|
||||
HEADER: QskIndexedLayoutBox.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief Base class of layouts with index ordered elements
|
||||
END
|
||||
|
||||
PROPERTY
|
||||
NAME: autoAddChildren
|
||||
TYPE: bool
|
||||
|
||||
READ: autoAddChildren()
|
||||
WRITE: setAutoAddChildren()
|
||||
NOTIFY: autoAddChildrenChanged()
|
||||
|
||||
DESCRIPTION
|
||||
\brief Flag controlling whether to automatically append
|
||||
children to the layout.
|
||||
|
||||
When autoAddChildren is enabled new children are automatically
|
||||
appended to the layout. Otherwise items have to be inserted
|
||||
manually using addItem() or insertItem().
|
||||
|
||||
\note Children being transparent for positioners are ignored
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: QskIndexedLayoutBox( QUICKITEM parent )
|
||||
DESCRIPTION
|
||||
\brief Constructor
|
||||
|
||||
Create a layout having autoAddChildren set to false.
|
||||
|
||||
\param parent Parent item
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: ~QskIndexedLayoutBox()
|
||||
DESCRIPTION: \brief Destructor
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void addItem( QUICKITEM item, Qt::Alignment alignment )
|
||||
DESCRIPTION
|
||||
\brief Insert an item at the end
|
||||
|
||||
The geometries of items being inserted be controlled by the layout.
|
||||
|
||||
\param item Item to be inserted
|
||||
\param alignment Flags to control how to align a non expandable element
|
||||
inside of the available space.
|
||||
|
||||
\sa insertItem()
|
||||
\sa INHERITED::itemAtIndex()
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE
|
||||
void insertItem( int index, QUICKITEM item,
|
||||
Qt::Alignment alignment = Qt::Alignment() );
|
||||
END
|
||||
|
||||
DESCRIPTION
|
||||
\brief Insert an item
|
||||
|
||||
The geometries of items being inserted be controlled by the layout.
|
||||
|
||||
\param index Position, where to insert the item. If index is < 0
|
||||
or beyond INHERITED::itemCount() the item will be appended.
|
||||
\param item Item to be inserted
|
||||
\param alignment Flags to control how to align a non expandable element
|
||||
inside of the available space.
|
||||
|
||||
\sa addItem(), INHERITED::itemAtIndex()
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setAlignment( int index, Qt::Alignment alignment );
|
||||
|
||||
DESCRIPTION
|
||||
\brief Modify the alignment of a layout element
|
||||
|
||||
\param index Position of the inserted element
|
||||
\param alignment Flags to control how to align a non expandable element
|
||||
inside of the available space
|
||||
|
||||
\note The alignment has only an effect, when the item can't be extended
|
||||
to fill the cell geometry.
|
||||
\sa alignment()
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: Qt::Alignment alignment( int index ) const;
|
||||
|
||||
DESCRIPTION
|
||||
\param index Position of the inserted element
|
||||
\return Flags to control how to align a non expandable element
|
||||
inside of the available space
|
||||
|
||||
\sa setAlignment()
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setAlignment( const QUICKITEM item, Qt::Alignment alignment );
|
||||
|
||||
DESCRIPTION
|
||||
\brief Modify the alignment of a layout element
|
||||
|
||||
\param item Inserted item
|
||||
\param alignment Flags to control how to align a non expandable element
|
||||
inside of the available space
|
||||
|
||||
\note The alignment has only an effect, when the item can't be extended
|
||||
to fill the cell geometry.
|
||||
\sa alignment()
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: Qt::Alignment alignment( const QUICKITEM item ) const;
|
||||
|
||||
DESCRIPTION
|
||||
\param item Inserted item
|
||||
\return Flags to control how to align a non expandable element
|
||||
inside of the available space
|
||||
|
||||
\sa setAlignment()
|
||||
END
|
||||
END
|
||||
|
||||
SIGNAL
|
||||
SIGNATURE: void autoAddChildrenChanged()
|
||||
|
||||
DESCRIPTION
|
||||
The autoAddChildren property has changed
|
||||
\sa setAutoAddChildren(), autoAddChildren()
|
||||
END
|
||||
END
|
||||
|
||||
SLOT
|
||||
SIGNATURE: void setAutoAddChildren( bool on )
|
||||
|
||||
DESCRIPTION
|
||||
\brief En/Disable auto appending of children
|
||||
|
||||
When autoAddChildren() is enabled new children are automatically
|
||||
appended to the layout. Otherwise items have to be inserted
|
||||
manually using addItem() or insertItem().
|
||||
|
||||
\param on When true autoAddChildren is enabled
|
||||
|
||||
\note Existing children, that have not been inserted before
|
||||
remain being not seen by the layout.
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: bool autoAddChildren(void) const
|
||||
DESCRIPTION: \return Value of the \ref autoAddChildren property
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: void itemChange( QQUICKITEM::ItemChange, const QQUICKITEM::ItemChangeData & )
|
||||
|
||||
DESCRIPTION
|
||||
Checking ItemChildAddedChange/ItemChildRemovedChange changes to
|
||||
implement the \ref autoAddChildren mode
|
||||
|
||||
\sa autoAddChildren
|
||||
END
|
||||
END
|
||||
END
|
92
doc/classes/QskLayout.metadox
Normal file
92
doc/classes/QskLayout.metadox
Normal file
@ -0,0 +1,92 @@
|
||||
INTERFACE
|
||||
CLASS: QskLayout
|
||||
BASE: QskControl
|
||||
|
||||
QMLCLASS: Layout
|
||||
QMLBASE: Control
|
||||
|
||||
HEADER: QskLayout.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief Base class of all Qsk layouts using a QGridLayoutEngine workhorse
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: bool isEmpty() const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: int itemCount() const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: QUICKITEM itemAtIndex( int index ) const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: int indexOf( const QUICKITEM item ) const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: removeItem( const QUICKITEM item );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void removeAt( int index );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void clear();
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setActive( bool on );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: bool isActive() const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
SLOT
|
||||
SIGNATURE: void activate();
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
SLOT
|
||||
SIGNATURE: void invalidate();
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: void adjustItem( const QUICKITEM item );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: void adjustItemAt( const QUICKITEM item );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
END
|
12
doc/classes/QskLayoutEngine.dox
Normal file
12
doc/classes/QskLayoutEngine.dox
Normal file
@ -0,0 +1,12 @@
|
||||
/*!
|
||||
\headerfile QskLayoutEngine.h
|
||||
\brief A QGridLayoutEngine tailored for Qsk layouts
|
||||
*/
|
||||
|
||||
class QskLayoutEngine
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
||||
|
11
doc/classes/QskLayoutItem.dox
Normal file
11
doc/classes/QskLayoutItem.dox
Normal file
@ -0,0 +1,11 @@
|
||||
/*!
|
||||
\headerfile QskLayoutItem.h
|
||||
\brief A QGridLayoutItem tailored for Qsk layouts
|
||||
*/
|
||||
|
||||
class QskLayoutItem
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
533
doc/classes/QskLinearBox.metadox
Normal file
533
doc/classes/QskLinearBox.metadox
Normal file
@ -0,0 +1,533 @@
|
||||
INTERFACE
|
||||
CLASS: QskLinearBox
|
||||
BASE: QskIndexedLayoutBox
|
||||
|
||||
QMLCLASS: LinearBox
|
||||
QMLBASE: IndexedLayoutBox
|
||||
|
||||
HEADER: QskLinearBox.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief Layout stringing items in rows and columns
|
||||
|
||||
QskLinearBox organizes layout items in vertical or horizontal order
|
||||
( \ref orientation ). When the number of items for a row/column has
|
||||
reached an upper limit ( \ref dimension ) the following items will be
|
||||
added to a new row/column.
|
||||
|
||||
When having the \ref dimension being set to unlimited ( or 1 with the
|
||||
inverted \ref orientation ) the string layout behaves similar to
|
||||
QBoxLayout, RowLayout/ColumnLayout ( QML ) or what is
|
||||
sometimes called a linear layout.
|
||||
|
||||
When not restricting the layout to one row/column only the layout can
|
||||
be used to set up simple grid formations.
|
||||
|
||||
Layout items may be QUICKITEMs or spacers - both having a stretch factor
|
||||
in the range of [0..10];
|
||||
|
||||
\note All available Qsk layouts are thin layers on top of the same grid
|
||||
based workhorse ( = QGridLayoutEngine ). QskLinearBox offers
|
||||
a reasonable subset of features, tailored for an index based
|
||||
point of view.
|
||||
|
||||
\sa QskGridBox, QskStackBox
|
||||
END
|
||||
|
||||
PROPERTY
|
||||
NAME: orientation
|
||||
TYPE: Qt::Orientation
|
||||
|
||||
READ: orientation()
|
||||
WRITE: setOrientation()
|
||||
NOTIFY: orientationChanged()
|
||||
|
||||
DESCRIPTION
|
||||
|
||||
\brief Direction of flow for laying out the items
|
||||
|
||||
In case of Qt::Horizontal the elements are organized horizontally
|
||||
increasing the column index, when appending an item. When the
|
||||
number of columns exceeds the \ref dimension the next item will be
|
||||
in the first column of the next row ( v.v for Qt::Vertical ).
|
||||
|
||||
The horizontal layout direction is affected by its state
|
||||
of QskControl::layoutMirroring(), what might depend on the
|
||||
QskControl::locale().
|
||||
|
||||
\sa transpose(), dimension
|
||||
END
|
||||
END
|
||||
|
||||
PROPERTY
|
||||
NAME: dimension
|
||||
TYPE: uint
|
||||
|
||||
READ: dimension()
|
||||
WRITE: setDimension()
|
||||
NOTIFY: dimensionChanged()
|
||||
|
||||
DESCRIPTION
|
||||
\brief Upper limit for the number of elements in a row or column
|
||||
|
||||
According to the orientation the layout is organized in
|
||||
rows or columns. The dimension is an upper limit for the number
|
||||
of elements in a row/column.
|
||||
|
||||
When the number of elements exceeds the dimension the following element
|
||||
will be inserted in the following row/column.
|
||||
|
||||
\sa orientation
|
||||
END
|
||||
END
|
||||
|
||||
PROPERTY
|
||||
NAME: spacing
|
||||
TYPE: qreal
|
||||
|
||||
READ: spacing()
|
||||
WRITE: setSpacing()
|
||||
NOTIFY: spacingChanged()
|
||||
|
||||
DESCRIPTION
|
||||
\brief Global layout spacing
|
||||
|
||||
The spacing is the distance between each cell and row
|
||||
of the layout. Its initial value depend on the current theme.
|
||||
|
||||
Beside setting the global spacing it is also possible to add
|
||||
individual spacings at the end of each row and column.
|
||||
|
||||
\note In opposite to a spacer, the global spacing does not insert
|
||||
elements.
|
||||
|
||||
\sa setRowSpacing(), setColumnSpacing(),
|
||||
insertSpacer(), QskControl::setMargins()
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: QskLinearBox( QUICKITEM parent );
|
||||
DESCRIPTION
|
||||
\brief Create a row layout
|
||||
|
||||
The \ref orientation is set to Qt::Horizontal orientation having
|
||||
an unlimited \ref dimension.
|
||||
|
||||
\param parent Parent item
|
||||
|
||||
\sa orientation, dimension
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: QskLinearBox( Qt::Orientation orientation, QUICKITEM parent );
|
||||
DESCRIPTION
|
||||
\brief Create a row or column layout
|
||||
|
||||
The \ref dimension is unlimited.
|
||||
|
||||
\param orientation Qt::Horizontal or Qt::Vertical
|
||||
\param parent Parent item
|
||||
|
||||
\sa orientation, dimension
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE
|
||||
QskLinearBox( Qt::Orientation orientation,
|
||||
int dimension, QUICKITEM parent );
|
||||
END
|
||||
|
||||
DESCRIPTION
|
||||
\brief Constructor
|
||||
|
||||
\param orientation Qt::Horizontal or Qt::Vertical
|
||||
\param dimension Upper limit for the number of elements
|
||||
in a row or column
|
||||
|
||||
\param parent Parent item
|
||||
|
||||
\sa orientation, dimension
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: ~QskLinearBox();
|
||||
DESCRIPTION: Destructor
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: void setOrientation( Qt::Orientation orientation );
|
||||
DESCRIPTION
|
||||
\brief Set the orientation of the layout
|
||||
\param orientation Qt::Vertical or Qt::Horizontal
|
||||
\sa orientation
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: Qt::Orientation orientation(void) const;
|
||||
DESCRIPTION: \return Value of the \ref orientation property
|
||||
END
|
||||
|
||||
SLOT
|
||||
SIGNATURE: void transpose()
|
||||
DESCRIPTION
|
||||
BEGIN
|
||||
\brief Invert the orientation of the layout
|
||||
|
||||
Qt::Horizontal becomes to Qt::Vertical and v.v.
|
||||
\sa setOrientation(), orientation(), orientationChanged()
|
||||
END
|
||||
END
|
||||
|
||||
SIGNAL
|
||||
SIGNATURE: void orientationChanged()
|
||||
DESCRIPTION
|
||||
The orientation of the layout has changed
|
||||
\sa orientation
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: void setDimension( uint dimension );
|
||||
DESCRIPTION
|
||||
\brief Set the dimension of the layout
|
||||
|
||||
\param dimension Upper limit for the number of elements in a row or column
|
||||
|
||||
\warning A value of 0 is invalid and will be set to 1
|
||||
\sa dimension
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: uint dimension(void);
|
||||
DESCRIPTION: \return Value of the \ref dimension property const
|
||||
END
|
||||
|
||||
SIGNAL
|
||||
SIGNATURE: void dimensionChanged()
|
||||
DESCRIPTION
|
||||
The dimension of the layout has changed
|
||||
\sa setDimension(), dimension()
|
||||
END
|
||||
END
|
||||
|
||||
SIGNAL
|
||||
SIGNATURE: void spacingChanged()
|
||||
DESCRIPTION
|
||||
The spacing of the layout has changed
|
||||
\sa setSpacing(), spacing(), setRowSpacing(), setColumnSpacing()
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: void setSpacing( qreal spacing )
|
||||
DESCRIPTION
|
||||
\brief Set the global spacing of the layout
|
||||
\param spacing Distance between each cell and row
|
||||
\sa spacing
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: void resetSpacing()
|
||||
DESCRIPTION
|
||||
\brief Reset the global spacing to its initial value
|
||||
\sa spacing
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: qreal spacing(void) const
|
||||
DESCRIPTION
|
||||
\return Value of the \ref spacing property
|
||||
END
|
||||
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void addSpacer( qreal spacing, int stretchFactor )
|
||||
DESCRIPTION
|
||||
\brief Append a spacer to the layout
|
||||
|
||||
The same as \ref insertSpacer( -1, spacing, stretchFactor );
|
||||
|
||||
\param spacing Spacing
|
||||
\param stretchFactor A value between [0..10].
|
||||
The ratio of the stretch factors of expandable
|
||||
candidates decides about how to distribute extra space.
|
||||
\sa insertSpacer()
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void insertSpacer( int index, qreal spacing, int stretchFactor )
|
||||
DESCRIPTION
|
||||
\brief Insert a spacer at a specific position
|
||||
|
||||
Spacers being inserted to the layout are elements having
|
||||
an index - like regular QUICKITEMs and participate in the
|
||||
calculation of the geometries.
|
||||
|
||||
A spacer is treated like being an item with a preferred
|
||||
width/height of spacing. In case of having a stretchFactor > 0
|
||||
the width/height might exceed spacing.
|
||||
|
||||
\param index Position, where to insert the spacer. If index is < 0
|
||||
or beyond QskLayout::itemCount() the spacer will be appended.
|
||||
|
||||
\param spacing Spacing Minimum for width/height
|
||||
|
||||
\param stretchFactor A value between [0..10].
|
||||
The ratio of the stretch factors of expandable
|
||||
candidates decides about how to distribute extra space.
|
||||
|
||||
\note Calling QskLayout::itemAtIndex( index ) will return a nullptr.
|
||||
\sa insertItem(), QskLayout::itemAtIndex()
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void addStretch( int stretchFactor )
|
||||
DESCRIPTION
|
||||
\brief Append a stretch to the layout
|
||||
|
||||
The same as \ref insertStretch( -1, stretchFactor );
|
||||
|
||||
\param stretchFactor A value between [0..10].
|
||||
The ratio of the stretch factors of expandable
|
||||
candidates decides about how to distribute extra space.
|
||||
|
||||
\sa insertStretch(), addSpacer()
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void insertStretch( int index, int stretchFactor )
|
||||
DESCRIPTION
|
||||
\brief Insert a stretch at a specific position
|
||||
|
||||
A stretch is simply a spacer with a spacing of 0
|
||||
|
||||
\param index Position, where to insert the stretch. If index is < 0
|
||||
or beyond QskLayout::itemCount() the stretch will be appended.
|
||||
\param stretchFactor A value between [0..10].
|
||||
The ratio of the stretch factors of expandable
|
||||
candidates decides about how to distribute extra space.
|
||||
|
||||
\note Calling QskLayout::itemAtIndex( index ) will return a nullptr.
|
||||
\sa insertSpacer(), QskLayout::itemAtIndex()
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setStretchFactor( int index, int stretchFactor )
|
||||
DESCRIPTION
|
||||
\brief Modify the stretch factor of a layout element
|
||||
|
||||
\param index Position of the element
|
||||
\param stretchFactor A value between [0..10].
|
||||
The ratio of the stretch factors of expandable
|
||||
candidates decides about how to distribute extra space.
|
||||
|
||||
\sa stretchFactor()
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: int stretchFactor( int index ) const
|
||||
DESCRIPTION
|
||||
\param index Position of the inserted element
|
||||
\return Stretch factor of a layout element
|
||||
|
||||
\sa setStretchFactor()
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setStretchFactor( const QUICKITEM item, int stretchFactor )
|
||||
DESCRIPTION
|
||||
\brief Modify the stretch factor of an inserted item
|
||||
|
||||
\param item Inserted item
|
||||
\param stretchFactor A value between [0..10].
|
||||
The ratio of the stretch factors of expandable
|
||||
candidates decides about how to distribute extra space.
|
||||
|
||||
\sa stretchFactor()
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: int stretchFactor( const QUICKITEM item ) const
|
||||
DESCRIPTION
|
||||
\param item Inserted item
|
||||
\return Stretch factor of a layout element
|
||||
|
||||
\sa setStretchFactor()
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setRetainSizeWhenHidden( int index, bool on )
|
||||
DESCRIPTION
|
||||
\brief Modify the effect of an element on the layout, when being hidden
|
||||
|
||||
The retainSizeWhenHidden() flag controls how the layout will treat
|
||||
an item, when being explicitely hidden.
|
||||
|
||||
When being enabled the corresponding cell will be resized like in the visible
|
||||
state ( showing a blank space ). Otherwise the cell will disappear and all
|
||||
following cells will be shifted down.
|
||||
|
||||
\param index Position of the inserted element
|
||||
\param on En/Disable the retainSizeWhenHidden() flag
|
||||
|
||||
\sa QQuickItem::isVisible()
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: bool retainSizeWhenHidden( int index ) const
|
||||
DESCRIPTION
|
||||
\param index Position of the inserted element
|
||||
\return True, when the retainSizeWhenHidden() flag is enabled
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setRetainSizeWhenHidden( const QUICKITEM item, bool on )
|
||||
DESCRIPTION
|
||||
\brief Modify the effect of an element on the layout, when being hidden
|
||||
|
||||
The retainSizeWhenHidden() flag controls how the layout will treat
|
||||
an item, when being explicitely hidden.
|
||||
|
||||
When being enabled the corresponding cell will be resized like in the visible
|
||||
state ( showing a blank space ). Otherwise the cell will disappear and all
|
||||
following cells will be shifted down.
|
||||
|
||||
\param item Inserted item
|
||||
\param on En/Disable the retainSizeWhenHidden() flag
|
||||
|
||||
\sa QQuickItem::isVisible()
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: bool retainSizeWhenHidden( const QUICKITEM item ) const
|
||||
DESCRIPTION
|
||||
\param item Inserted item
|
||||
\return True, when the retainSizeWhenHidden() flag is enabled
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setRowSpacing( int row, qreal spacing )
|
||||
DESCRIPTION
|
||||
\brief Add an extra spacing at the end of a row
|
||||
|
||||
\param row Row index
|
||||
\param spacing Extra space at the end of a row
|
||||
|
||||
\note The spacing has no effect for the last row
|
||||
\sa rowSpacing(), setColumnSpacing(), spacing
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: qreal rowSpacing( int row ) const
|
||||
DESCRIPTION
|
||||
\param row Row index
|
||||
\return Extra space at the end of a row
|
||||
\sa setRowSpacing(), spacing
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setColumnSpacing( int column, qreal spacing )
|
||||
DESCRIPTION
|
||||
\brief Add an extra spacing at the end of a column
|
||||
|
||||
\param column Column index
|
||||
\param spacing Extra space at the end of a column
|
||||
|
||||
\note The spacing has no effect for the last column
|
||||
\sa columnSpacing(), setRowSpacing(), spacing
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: qreal columnSpacing( int column ) const
|
||||
DESCRIPTION
|
||||
\param column Column index
|
||||
\return Extra space at the end of a column
|
||||
\sa setColumnSpacing(), rowSpacing(), spacing
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setRowStretchFactor( int row, int stretchFactor )
|
||||
DESCRIPTION
|
||||
\brief Modify the stretch factor of a row
|
||||
|
||||
\param row Index of the row
|
||||
\param stretchFactor A value between [0..10].
|
||||
The ratio of the stretch factors of expandable
|
||||
candidates decides about how to distribute extra space.
|
||||
|
||||
\note Having a stretch factor for the row and for an item of the same row
|
||||
might lead to confusing results
|
||||
|
||||
\sa rowStretchFactor(), stretchFactor()
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: int rowStretchFactor( int row ) const
|
||||
DESCRIPTION
|
||||
\param row Index of the row
|
||||
\return Stretch factor of the row
|
||||
\sa setRowStretchFactor(), colulnStretchFactor()
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setColumnStretchFactor( int column, int stretchFactor )
|
||||
DESCRIPTION
|
||||
\brief Modify the stretch factor of a column
|
||||
|
||||
\param column Index of the column
|
||||
\param stretchFactor A value between [0..10].
|
||||
The ratio of the stretch factors of expandable
|
||||
candidates decides about how to distribute extra space.
|
||||
|
||||
\note Having a stretch factor for the column and for an item of the same column
|
||||
might lead to confusing results
|
||||
|
||||
\sa rowStretchFactor(), stretchFactor()
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: int QskLinearBox::columnStretchFactor( int column ) const
|
||||
DESCRIPTION
|
||||
\param column Index of the column
|
||||
\return Stretch factor of the column
|
||||
\sa setColumnStretchFactor(), rowStretchFactor()
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: QSizeF QskLinearBox::contentsSizeHint() const
|
||||
DESCRIPTION
|
||||
\return Preferred size without the contents margins
|
||||
\note The calculation of the hint depends ob the hints
|
||||
of the items inserted to the layout.
|
||||
END
|
||||
END
|
||||
END
|
17
doc/classes/QskListView.metadox
Normal file
17
doc/classes/QskListView.metadox
Normal file
@ -0,0 +1,17 @@
|
||||
INTERFACE
|
||||
CLASS: QskListView
|
||||
BASE: QskScrollView
|
||||
|
||||
QMLCLASS: ScrollListView
|
||||
QMLBASE: ScrollView
|
||||
|
||||
HEADER: QskListView.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief Base class for scrollable list views
|
||||
|
||||
\note Implementation/Design is incomplete and will be totally
|
||||
different in the final version.
|
||||
END
|
||||
END
|
||||
|
14
doc/classes/QskMessageBox.metadox
Normal file
14
doc/classes/QskMessageBox.metadox
Normal file
@ -0,0 +1,14 @@
|
||||
INTERFACE
|
||||
CLASS: QskMessageBox
|
||||
BASE: QskDialog
|
||||
|
||||
QMLCLASS: MessageBox
|
||||
QMLBASE: Dialog
|
||||
|
||||
HEADER: QskMessageBox.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief A dialog displaying a message
|
||||
\sa QskMessage
|
||||
END
|
||||
END
|
10
doc/classes/QskModule.dox
Normal file
10
doc/classes/QskModule.dox
Normal file
@ -0,0 +1,10 @@
|
||||
/*!
|
||||
\headerfile QskModule.h
|
||||
\brief A collection of global methods of the Qsk module.
|
||||
*/
|
||||
|
||||
namespace QskModule
|
||||
{
|
||||
/*!
|
||||
*/
|
||||
}
|
12
doc/classes/QskObjectCounter.dox
Normal file
12
doc/classes/QskObjectCounter.dox
Normal file
@ -0,0 +1,12 @@
|
||||
/*!
|
||||
\headerfile QskAbstractButton.h
|
||||
\brief An object counter using Qt hooks to create statistics
|
||||
about QObject and QQuickItem instantiations
|
||||
*/
|
||||
|
||||
class QskAbstractButton
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
11
doc/classes/QskObjectResolver.dox
Normal file
11
doc/classes/QskObjectResolver.dox
Normal file
@ -0,0 +1,11 @@
|
||||
/*!
|
||||
\headerfile QskObjectResolver.h
|
||||
\brief A helper class for resolving properties on the window/item tree
|
||||
*/
|
||||
|
||||
class QskObjectResolver
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
7
doc/classes/QskObjectWalker.dox
Normal file
7
doc/classes/QskObjectWalker.dox
Normal file
@ -0,0 +1,7 @@
|
||||
/*! \class QskObjectAttributes
|
||||
\brief A helper class for resolving properties on the window/item tree
|
||||
*/
|
||||
|
||||
/*! \class QskObjectWalker
|
||||
\brief A helper class for resolving properties on the window/item tree
|
||||
*/
|
77
doc/classes/QskPainterCommand.dox
Normal file
77
doc/classes/QskPainterCommand.dox
Normal file
@ -0,0 +1,77 @@
|
||||
/*!
|
||||
\headerfile QskPainterCommand.h
|
||||
\brief Attributes of a QPainter operation.
|
||||
|
||||
It is used by QskGraphic to record and replay paint operations
|
||||
|
||||
\sa QskGraphic::commands()
|
||||
*/
|
||||
|
||||
class QskPainterCommand
|
||||
{
|
||||
/*!
|
||||
\fn QskPainterCommand()
|
||||
|
||||
Construct an invalid command
|
||||
|
||||
\fn QskPainterCommand( const QPainterPath &path )
|
||||
Constructor for path paint operation
|
||||
|
||||
\fn QskPainterCommand( const QRectF &rect,
|
||||
const QPixmap &pixmap, const QRectF& subRect )
|
||||
|
||||
Constructor for Pixmap paint operation
|
||||
|
||||
\param rect Target rectangle
|
||||
\param pixmap Pixmap
|
||||
\param subRect Rectangle inside the pixmap
|
||||
|
||||
\sa QPainter::drawPixmap()
|
||||
|
||||
\fn QskPainterCommand( const QRectF &rect, const QImage &image,
|
||||
const QRectF& subRect, Qt::ImageConversionFlags flags )
|
||||
|
||||
Constructor for Image paint operation
|
||||
|
||||
\param rect Target rectangle
|
||||
\param image Image
|
||||
\param subRect Rectangle inside the image
|
||||
\param flags Conversion flags
|
||||
|
||||
\sa QPainter::drawImage()
|
||||
|
||||
\fn QskPainterCommand( const QPaintEngineState &state )
|
||||
|
||||
Constructor for State paint operation
|
||||
|
||||
\param state Paint engine state
|
||||
|
||||
\fn QskPainterCommand( const QskPainterCommand &other )
|
||||
|
||||
Copy constructor
|
||||
|
||||
\param other Command to be copied
|
||||
|
||||
\fn ~QskPainterCommand()
|
||||
Destructor
|
||||
|
||||
\fn QskPainterCommand &operator=( const QskPainterCommand &other )
|
||||
|
||||
Assignment operator
|
||||
|
||||
\param other Command to be copied
|
||||
\return Modified command
|
||||
|
||||
\fn QPainterPath *path()
|
||||
\return Painter path to be painted
|
||||
|
||||
\fn PixmapData* pixmapData()
|
||||
\return Attributes how to paint a QPixmap
|
||||
|
||||
\fn ImageData* imageData()
|
||||
\return Attributes how to paint a QImage
|
||||
|
||||
\fn StateData* stateData()
|
||||
\return Attributes of a state change
|
||||
*/
|
||||
};
|
14
doc/classes/QskPlainTextRenderer.dox
Normal file
14
doc/classes/QskPlainTextRenderer.dox
Normal file
@ -0,0 +1,14 @@
|
||||
/*!
|
||||
\headerfile QskPlainTextRenderer.h
|
||||
\brief A renderer for creating a scene graph subtree from plain text content
|
||||
\sa QskTextRenderer
|
||||
*/
|
||||
|
||||
class QskPlainTextRenderer
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
||||
|
||||
|
14
doc/classes/QskPushButton.metadox
Normal file
14
doc/classes/QskPushButton.metadox
Normal file
@ -0,0 +1,14 @@
|
||||
INTERFACE
|
||||
CLASS: QskPushButton
|
||||
BASE: QskAbstractButton
|
||||
|
||||
QMLCLASS: PushButton
|
||||
QMLBASE: AbstractButton
|
||||
|
||||
HEADER: QskPushButton.h
|
||||
|
||||
DESCRIPTION
|
||||
\headerfile QskPushButton.h
|
||||
\brief A push button
|
||||
END
|
||||
END
|
12
doc/classes/QskPushButtonSkinlet.dox
Normal file
12
doc/classes/QskPushButtonSkinlet.dox
Normal file
@ -0,0 +1,12 @@
|
||||
/*!
|
||||
\headerfile QskPushButtonSkinlet.h
|
||||
\brief Base class of all skinlets for QskPushButton
|
||||
*/
|
||||
|
||||
class QskPushButtonSkinlet
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
||||
|
13
doc/classes/QskRangeControl.metadox
Normal file
13
doc/classes/QskRangeControl.metadox
Normal file
@ -0,0 +1,13 @@
|
||||
INTERFACE
|
||||
CLASS: QskRangeControl
|
||||
BASE: QskControl
|
||||
|
||||
QMLCLASS: RangeControl
|
||||
QMLBASE: Control
|
||||
|
||||
HEADER: QskRangeControl.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief A push button
|
||||
END
|
||||
END
|
12
doc/classes/QskRectNode.dox
Normal file
12
doc/classes/QskRectNode.dox
Normal file
@ -0,0 +1,12 @@
|
||||
/*!
|
||||
\headerfile QskRectNode.h
|
||||
\brief A scene graph node for rounded rectangles with an optional border
|
||||
*/
|
||||
|
||||
class QskRectNode
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
||||
|
13
doc/classes/QskRectangle.metadox
Normal file
13
doc/classes/QskRectangle.metadox
Normal file
@ -0,0 +1,13 @@
|
||||
INTERFACE
|
||||
CLASS: QskRectangle
|
||||
BASE: QskControl
|
||||
|
||||
QMLCLASS: Rectangle
|
||||
QMLBASE: Control
|
||||
|
||||
HEADER: QskRectangle.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief An item displaying a filled rectangle with optional borders
|
||||
END
|
||||
END
|
11
doc/classes/QskResizable.dox
Normal file
11
doc/classes/QskResizable.dox
Normal file
@ -0,0 +1,11 @@
|
||||
/*!
|
||||
\headerfile QskResizable.h
|
||||
*/
|
||||
|
||||
class QskResizable
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
||||
|
17
doc/classes/QskScrollView.metadox
Normal file
17
doc/classes/QskScrollView.metadox
Normal file
@ -0,0 +1,17 @@
|
||||
INTERFACE
|
||||
CLASS: QskScrollView
|
||||
BASE: QskControl
|
||||
|
||||
QMLCLASS: ScrollView
|
||||
QMLBASE: Control
|
||||
|
||||
HEADER: QskScrollView.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief A lightweight scroll view made of one QObject only
|
||||
|
||||
\note Implementation/Design is incomplete and might be totally
|
||||
different in the final version.
|
||||
END
|
||||
END
|
||||
|
14
doc/classes/QskSeparator.metadox
Normal file
14
doc/classes/QskSeparator.metadox
Normal file
@ -0,0 +1,14 @@
|
||||
INTERFACE
|
||||
CLASS: QskSeparator
|
||||
BASE: QskControl
|
||||
|
||||
QMLCLASS: Separator
|
||||
QMLBASE: Control
|
||||
|
||||
HEADER: QskSeparator.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief A separator line
|
||||
\note Not implemented yet, but intended to work like a flat QGroupBox
|
||||
END
|
||||
END
|
121
doc/classes/QskSetup.metadox
Normal file
121
doc/classes/QskSetup.metadox
Normal file
@ -0,0 +1,121 @@
|
||||
INTERFACE
|
||||
CLASS: QskSetup
|
||||
BASE: QObject
|
||||
|
||||
HEADER: QskSetup.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief Singleton maintaining the global settings of an application using Qsk controls
|
||||
END
|
||||
|
||||
ENUM
|
||||
CLASS: Flag
|
||||
QMLCLASS: Flag
|
||||
|
||||
DESCRIPTION
|
||||
\var ClipBoundary
|
||||
\var DeferredUpdate
|
||||
\var DeferredPolish
|
||||
\var DeferredLayout
|
||||
\var CleanupOnVisibility
|
||||
\var PreferRasterForTextures
|
||||
\var DebugForceBackground
|
||||
\var DebugSkinColors
|
||||
END
|
||||
END
|
||||
|
||||
PROPERTY
|
||||
NAME: skin
|
||||
TYPE: QskSkin*
|
||||
|
||||
READ: skin()
|
||||
WRITE: setSkin()
|
||||
NOTIFY: skinChanged()
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: void setup()
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: void cleanup()
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: QskSetup* instance();
|
||||
DESCRIPTION
|
||||
\sa qskSetup()
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: void setSkin( QskSkin* );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: QskSkin* skin();
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
SIGNAL
|
||||
SIGNATURE: void skinChanged( QskSkin* );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
SIGNAL
|
||||
SIGNATURE: void controlFlagsChanged();
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: QskSkinlet* skinlet( const QskControl* );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setControlFlags( Flags );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void resetControlFlags();
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: Flags controlFlags() const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void setControlFlag( Flag, bool on = true );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: void resetControlFlag( Flag );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
INVOKABLE
|
||||
SIGNATURE: bool testControlFlag( Flag );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
END
|
17
doc/classes/QskSimpleListBox.metadox
Normal file
17
doc/classes/QskSimpleListBox.metadox
Normal file
@ -0,0 +1,17 @@
|
||||
INTERFACE
|
||||
CLASS: QskSimpleListBox
|
||||
BASE: QskListView
|
||||
|
||||
QMLCLASS: SimpleListBox
|
||||
QMLBASE: ListView
|
||||
|
||||
HEADER: QskSimpleListBox.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief A lightweight list box made from one QObject only
|
||||
|
||||
\note Implementation/Design is incomplete and will be totally
|
||||
different in the final version.
|
||||
END
|
||||
END
|
||||
|
12
doc/classes/QskSizePolicy.dox
Normal file
12
doc/classes/QskSizePolicy.dox
Normal file
@ -0,0 +1,12 @@
|
||||
/*!
|
||||
\headerfile QskSizePolicy.h
|
||||
\brief A size policy ( similar to QSizePolicy )
|
||||
*/
|
||||
|
||||
class QskSizePolicy
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
||||
|
48
doc/classes/QskSkin.dox
Normal file
48
doc/classes/QskSkin.dox
Normal file
@ -0,0 +1,48 @@
|
||||
/*!
|
||||
\fn void QskSkin::setColor( QskAspect::Aspect aspect, QRgb color )
|
||||
|
||||
Sets the default color (as a QRgb value) for the given QskAspect::Aspect. The QskSkinHint::TypeMask is
|
||||
implicitly set to QskSkinHint::Color.
|
||||
*/
|
||||
|
||||
/*!
|
||||
\fn void QskSkin::setColor(QskAspect::Aspect aspect, Qt::GlobalColor color)
|
||||
|
||||
Sets the color (as a Qt::GlobalColor) for the given QskAspect::Aspect. The QskSkinHint::TypeMask is
|
||||
implicitly set to QskSkinHint::Color.
|
||||
*/
|
||||
|
||||
/*!
|
||||
\fn void QskSkin::setColor(QskAspect::Aspect aspect, const QColor &color)
|
||||
Sets the color (as a QColor) for the given QskAspect::Aspect. The QskSkinHint::TypeMask is
|
||||
implicitly set to QskSkinHint::Color.
|
||||
*/
|
||||
|
||||
/*!
|
||||
\fn QRgb QskSkin::color( QskAspect::Aspect aspect ) const
|
||||
|
||||
Gets the color (as a QRgb value) for the given QskAspect::Aspect. Equivalent to QskSkin::skinHint( aspect ).color.
|
||||
*/
|
||||
|
||||
/*!
|
||||
\fn void QskSkin::setMetric(QskAspect::Aspect aspect, float metric)
|
||||
|
||||
Sets the metric for the given QskAspect::Aspect. The QskSkinHint::TypeMask is
|
||||
implicitly set to QskSkinHint::Metric.
|
||||
*/
|
||||
|
||||
/*!
|
||||
\fn float QskSkin::metric( QskAspect::Aspect aspect ) const
|
||||
|
||||
Gets the metric for the given QskAspect::Aspect. Equivalent to QskSkin::skinHint( aspect ).metric.
|
||||
*/
|
||||
|
||||
/*!
|
||||
\fn void QskSkin::setSkinHint( QskAspect::Aspect aspect, QskSkinHint option )
|
||||
Sets the option for the given QskAspect::Aspect. */
|
||||
*/
|
||||
|
||||
/*!
|
||||
\fn QskSkinHint QskSkin::skinHint( QskAspect::Aspect aspect ) const
|
||||
Gets the option for the given QskAspect::Aspect. */
|
||||
*/
|
35
doc/classes/QskSkinAnimator.dox
Normal file
35
doc/classes/QskSkinAnimator.dox
Normal file
@ -0,0 +1,35 @@
|
||||
/*!
|
||||
\headerfile QskSkinAnimator.h
|
||||
|
||||
\brief A helper class for delegating transitions between skin states. For
|
||||
example, if you wish to smoothly transition from one color to another, you
|
||||
should use QskControl::skinAnimator.
|
||||
|
||||
QskSkinAnimator is a low-level API which allows for smooth transitions
|
||||
between values stored by QskSkinHint. Depending on the QskControl::skinState(),
|
||||
a different value may be returned by a call to QskControl::skinHint().
|
||||
By specifying an animator for the same QskAspect, an automatic transition
|
||||
can occur between those two values.
|
||||
|
||||
In the simple case, you can create a hint animator by calling
|
||||
QskSkinlet::animator() to get a default animator for that skin aspect.
|
||||
Then, set the duration value:
|
||||
|
||||
\code
|
||||
control->skinAnimator( QskSkinHint::Background ).setDuration<500>(); // Set the color transition to 500ms.
|
||||
\endcode
|
||||
|
||||
To animate using an easing curve, you can replace the progress functor with
|
||||
one utilizing a QEasingCurve:
|
||||
\code
|
||||
control->skinAnimator( QskSkinHint::Background ).progress = &QskSkinHint::easingProgress<QEasingCurve::InOutBounce>;
|
||||
\endcode
|
||||
*/
|
||||
|
||||
class QskSkinAnimator
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
||||
|
6
doc/classes/QskSkinHint.dox
Normal file
6
doc/classes/QskSkinHint.dox
Normal file
@ -0,0 +1,6 @@
|
||||
/*! \struct QskSkinHint
|
||||
This struct acts as a union between option types used by the framework.
|
||||
Skin hints are attributes of a given control which affect the visual
|
||||
representation of the control. They can also be animated using
|
||||
QskSkinHintAnimator.
|
||||
*/
|
27
doc/classes/QskSkinlet.dox
Normal file
27
doc/classes/QskSkinlet.dox
Normal file
@ -0,0 +1,27 @@
|
||||
/*!
|
||||
\headerfile QskSkinlet.h
|
||||
|
||||
\brief Describes the rendering interface of a QskControl. Change the
|
||||
skinlet to change the appearance of the control using the low-level scene
|
||||
graph API.
|
||||
|
||||
\sa QskControl::setSkinlet()
|
||||
\sa QskSkin
|
||||
\sa setMetric()
|
||||
\sa setColor()
|
||||
*/
|
||||
|
||||
class QskSkinlet
|
||||
{
|
||||
/*!
|
||||
\fn QSGNode* findNode( QSGNode *parent, quint8 nodeRole )
|
||||
|
||||
A convenience method for finding the first top level child node
|
||||
with the given nodeRole.
|
||||
|
||||
\param parent Parent node
|
||||
\param nodeRole Unique identifier
|
||||
|
||||
\return the node, if found, or nullptr if not found.
|
||||
*/
|
||||
};
|
20
doc/classes/QskSkinnable.dox
Normal file
20
doc/classes/QskSkinnable.dox
Normal file
@ -0,0 +1,20 @@
|
||||
/*!
|
||||
\fn void QskSkinnable::markDirty( QskAspect::Aspect aspect )
|
||||
|
||||
ORs the bits from aspect to the dirty state (QskSkinnable::dirtyAspects).
|
||||
The dirty state is used by skinlets to minimize updates when rendering.
|
||||
*/
|
||||
|
||||
/*!
|
||||
\fn QskAspect::Aspect QskSkinnable::dirtyAspects()
|
||||
|
||||
Returns the current dirty state. \sa QskSkinnable::markDirty
|
||||
*/
|
||||
|
||||
/*!
|
||||
\fn void QskSkinnable::updateNode( QSGNode* parentNode )
|
||||
|
||||
Instructs the skinnable to update its paint node(s), which should be added
|
||||
to the parentNode as children. The same constrains as
|
||||
QQuickItem::updatePaintNode should be observed.
|
||||
*/
|
13
doc/classes/QskSlider.metadox
Normal file
13
doc/classes/QskSlider.metadox
Normal file
@ -0,0 +1,13 @@
|
||||
INTERFACE
|
||||
CLASS: QskSlider
|
||||
BASE: QskRangeControl
|
||||
|
||||
QMLCLASS: Slider
|
||||
QMLBASE: RangeControl
|
||||
|
||||
HEADER: QskSlider.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief A slider
|
||||
END
|
||||
END
|
12
doc/classes/QskSliderSkinlet.dox
Normal file
12
doc/classes/QskSliderSkinlet.dox
Normal file
@ -0,0 +1,12 @@
|
||||
/*!
|
||||
\headerfile QskSliderSkinlet.h
|
||||
\brief Base class of all skinlets for QskSlider
|
||||
*/
|
||||
|
||||
class QskSliderSkinlet
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
||||
|
94
doc/classes/QskStackBox.metadox
Normal file
94
doc/classes/QskStackBox.metadox
Normal file
@ -0,0 +1,94 @@
|
||||
INTERFACE
|
||||
CLASS: QskStackBox
|
||||
BASE: QskIndexedLayoutBox
|
||||
|
||||
QMLCLASS: StackBox
|
||||
QMLBASE: IndexedBox
|
||||
|
||||
HEADER: QskStackBox.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief A layout, stacking quick items
|
||||
END
|
||||
|
||||
PROPERTY
|
||||
NAME: currentIndex
|
||||
TYPE: int
|
||||
|
||||
READ: currentIndex()
|
||||
WRITE: setCurrentIndex()
|
||||
NOTIFY: currentIndexChanged()
|
||||
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
PROPERTY
|
||||
NAME: currentItem
|
||||
TYPE: QUICKITEM
|
||||
|
||||
READ: currentItem()
|
||||
WRITE: setCurrentItem()
|
||||
NOTIFY: currentItemChanged()
|
||||
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE
|
||||
QskStackBox( QUICKITEM parent = nullptr );
|
||||
END
|
||||
DESCRIPTION
|
||||
\brief Constructor
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: QskStackBox( bool autoAddChildren, QUICKITEM parent = nullptr );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: ~QskStackBox()
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
SLOT
|
||||
SIGNATURE: setCurrentIndex( int index );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: int currentIndex() const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
SIGNAL
|
||||
SIGNATURE: void currentIndexChanged( int index );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
SLOT
|
||||
SIGNATURE: setCurrentItem( const QUICKITEM );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
FUNCTION
|
||||
SIGNATURE: QUICKITEM currentItem() const;
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
|
||||
SIGNAL
|
||||
SIGNATURE: void currentItemChanged( QUICKITEM );
|
||||
DESCRIPTION
|
||||
END
|
||||
END
|
||||
END
|
0
doc/classes/QskStackBoxAnimation.dox
Normal file
0
doc/classes/QskStackBoxAnimation.dox
Normal file
6
doc/classes/QskStandardIcons.dox
Normal file
6
doc/classes/QskStandardIcons.dox
Normal file
@ -0,0 +1,6 @@
|
||||
/*! \namespace QskStandardIcons
|
||||
|
||||
\brief A image provider for standard dialog icons
|
||||
|
||||
\note Will be replaced by a QskGraphicProvider
|
||||
*/
|
11
doc/classes/QskSymbolMaterial.dox
Normal file
11
doc/classes/QskSymbolMaterial.dox
Normal file
@ -0,0 +1,11 @@
|
||||
/*!
|
||||
\headerfile QskSymbolMaterial.h
|
||||
*/
|
||||
|
||||
class QskSymbolMaterial
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
||||
|
14
doc/classes/QskTabBar.metadox
Normal file
14
doc/classes/QskTabBar.metadox
Normal file
@ -0,0 +1,14 @@
|
||||
INTERFACE
|
||||
CLASS: QskTabBar
|
||||
BASE: QskControl
|
||||
|
||||
QMLCLASS: TabBar
|
||||
QMLBASE: Control
|
||||
|
||||
HEADER: QskTabBar.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief A tab bar, that can be used to implement tab view alike controls
|
||||
\sa QskTabView, QskTabButton
|
||||
END
|
||||
END
|
15
doc/classes/QskTabButton.metadox
Normal file
15
doc/classes/QskTabButton.metadox
Normal file
@ -0,0 +1,15 @@
|
||||
INTERFACE
|
||||
CLASS: QskTabButton
|
||||
BASE: QskAbstractButton
|
||||
|
||||
QMLCLASS: TabButton
|
||||
QMLBASE: AbstractButton
|
||||
|
||||
HEADER: QskTabButton.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief A tab button, that can be used for tab bars
|
||||
\sa QskTabBar, QskTabView
|
||||
END
|
||||
END
|
||||
|
12
doc/classes/QskTabButtonSkinlet.dox
Normal file
12
doc/classes/QskTabButtonSkinlet.dox
Normal file
@ -0,0 +1,12 @@
|
||||
/*!
|
||||
\headerfile QskTabButtonSkinlet.h
|
||||
\brief Base class of all skinlets for QskTabButton
|
||||
*/
|
||||
|
||||
class QskTabButtonSkinlet
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
||||
|
14
doc/classes/QskTabView.metadox
Normal file
14
doc/classes/QskTabView.metadox
Normal file
@ -0,0 +1,14 @@
|
||||
INTERFACE
|
||||
CLASS: QskTabView
|
||||
BASE: QskControl
|
||||
|
||||
QMLCLASS: TabView
|
||||
QMLBASE: Control
|
||||
|
||||
HEADER: QskTabView.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief A stack of controls, with a tab bar to raise a current one
|
||||
\sa QskTabButton, QskTabView
|
||||
END
|
||||
END
|
13
doc/classes/QskTextLabel.metadox
Normal file
13
doc/classes/QskTextLabel.metadox
Normal file
@ -0,0 +1,13 @@
|
||||
INTERFACE
|
||||
CLASS: QskTextLabel
|
||||
BASE: QskControl
|
||||
|
||||
QMLCLASS: TextLabel
|
||||
QMLBASE: Control
|
||||
|
||||
HEADER: QskTextLabel.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief A control displaying a text.
|
||||
END
|
||||
END
|
12
doc/classes/QskTextLabelSkinlet.dox
Normal file
12
doc/classes/QskTextLabelSkinlet.dox
Normal file
@ -0,0 +1,12 @@
|
||||
/*!
|
||||
\headerfile QskTextLabelSkinlet.h
|
||||
\brief Base class of all skinlets for QskTextLabel
|
||||
*/
|
||||
|
||||
class QskTextLabelSkinlet
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
||||
|
11
doc/classes/QskTextOptions.dox
Normal file
11
doc/classes/QskTextOptions.dox
Normal file
@ -0,0 +1,11 @@
|
||||
/*!
|
||||
\headerfile QskTextOptions.h
|
||||
\brief Text attributes that can be set from QML
|
||||
*/
|
||||
|
||||
class QskTextOptions
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
15
doc/classes/QskTextRenderer.dox
Normal file
15
doc/classes/QskTextRenderer.dox
Normal file
@ -0,0 +1,15 @@
|
||||
/*!
|
||||
\headerfile QskTextRenderer.h
|
||||
\brief A renderer creating a scene graph subtree from a text
|
||||
|
||||
\note The current implementation relies on QQuickText item
|
||||
using one global instance for the application.
|
||||
*/
|
||||
|
||||
class QskTextRenderer
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
||||
|
11
doc/classes/QskTextureNode.dox
Normal file
11
doc/classes/QskTextureNode.dox
Normal file
@ -0,0 +1,11 @@
|
||||
/*!
|
||||
\headerfile QskTextureNode.h
|
||||
\brief QSGSimpleTextureNode under control of a QSGTransformNode
|
||||
*/
|
||||
|
||||
class QskTextureNode
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
13
doc/classes/QskTextureRenderer.dox
Normal file
13
doc/classes/QskTextureRenderer.dox
Normal file
@ -0,0 +1,13 @@
|
||||
/*!
|
||||
\headerfile QskTextureRenderer.h
|
||||
\brief A renderer creating a QSGSimpleTextureNode from a QskGraphic
|
||||
\sa QskGraphicTextureFactory::createTexture()
|
||||
*/
|
||||
|
||||
class QskTextureRenderer
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
||||
|
9
doc/classes/QskVertexColor.dox
Normal file
9
doc/classes/QskVertexColor.dox
Normal file
@ -0,0 +1,9 @@
|
||||
/*! \class QskVertexColor
|
||||
|
||||
\brief An RGBA color that can be used for vertex lists of QSGGeometryNode
|
||||
*/
|
||||
|
||||
/*! \class QskVertexColorMap
|
||||
|
||||
\brief An color map interpolating between QskVertexColor colors.
|
||||
*/
|
0
doc/classes/QskVertexPen.dox
Normal file
0
doc/classes/QskVertexPen.dox
Normal file
12
doc/classes/QskVertexRenderer.dox
Normal file
12
doc/classes/QskVertexRenderer.dox
Normal file
@ -0,0 +1,12 @@
|
||||
/*!
|
||||
\headerfile QskVertexRenderer.h
|
||||
\brief A vertex renderer for creating vertex lists for monochrome shapes
|
||||
*/
|
||||
|
||||
class QskVertexRenderer
|
||||
{
|
||||
/*!
|
||||
|
||||
*/
|
||||
};
|
||||
|
5
doc/classes/QskVertexRendererColored.dox
Normal file
5
doc/classes/QskVertexRendererColored.dox
Normal file
@ -0,0 +1,5 @@
|
||||
/*! \class QskVertexRendererColored
|
||||
|
||||
\brief A vertex renderer for creating vertex lists for multicolored shapes
|
||||
*/
|
||||
|
53
doc/classes/QskWindow.metadox
Normal file
53
doc/classes/QskWindow.metadox
Normal file
@ -0,0 +1,53 @@
|
||||
INTERFACE
|
||||
CLASS: QskWindow
|
||||
BASE: QQuickWindow
|
||||
|
||||
QMLCLASS: Window
|
||||
|
||||
# Window ( Qsk ) inherits from Window ( Quick ) - how to solve this ???
|
||||
QMLBASE: QuickWindow
|
||||
|
||||
HEADER: QskWindow.h
|
||||
|
||||
DESCRIPTION
|
||||
\brief A quick window reintroducing lost concepts of the QWidget framwork.
|
||||
END
|
||||
|
||||
ENUM
|
||||
CLASS: FramebufferMode
|
||||
QMLCLASS: FramebufferMode
|
||||
|
||||
DESCRIPTION
|
||||
\var DefaultFramebufferMode
|
||||
The default framebuffer is used for rendering.
|
||||
\var OffscreenFramebufferMode
|
||||
An offscreen framebuffer object (FBO) is used as the render
|
||||
target, and it is blitted to the screen after rendering.
|
||||
END
|
||||
END
|
||||
|
||||
PROPERTY
|
||||
NAME: framebufferMode
|
||||
TYPE: QskWindow::FramebufferMode
|
||||
|
||||
READ: framebufferMode()
|
||||
WRITE: setFramebufferMode()
|
||||
NOTIFY: framebufferModeChanged()
|
||||
|
||||
DESCRIPTION
|
||||
\brief the mode to render the framebuffer
|
||||
|
||||
A default QskWindow uses the default framebuffer to present its
|
||||
contents. On some platforms, this may limit the number of
|
||||
samples available to the the multi-sampled antialiasing (MSAA)
|
||||
implementation.
|
||||
|
||||
By setting the framebufferMode to OffscreenFramebufferMode,
|
||||
the window will render to an offscreen surface before
|
||||
flushing the contents to the screen. This generally provides
|
||||
access to framebuffer objects with a greater number of
|
||||
samples, leading to higher quality rendering results. The
|
||||
sample count is taken from the window's surfaceFormat().
|
||||
END
|
||||
END
|
||||
END
|
72
doc/qsk.dox
Normal file
72
doc/qsk.dox
Normal file
@ -0,0 +1,72 @@
|
||||
/*!
|
||||
\mainpage Introduction
|
||||
|
||||
The (Q)Skinny library contains a set of lightweight Qt Quick Controls.
|
||||
It is implemented to be 100% usable in C++, but can be used from C++ and/or QML
|
||||
application code. Being "skinny", the framework is intended to be both lightweight
|
||||
and skinnable.
|
||||
|
||||
The framework separates concerns between the API and logic of the controls
|
||||
themselves, the styling of these controls, and the delegated rendering of the
|
||||
controls to the screen.
|
||||
|
||||
@dot
|
||||
digraph skinny {
|
||||
table [ shape=record, label="{
|
||||
QSkinny: key functionality and classes |
|
||||
{
|
||||
{ Controls | <Controls>API, logic and layout of UI } |
|
||||
{ Rendering | <Rendering>Delegation of rendering commands } |
|
||||
{ Styling | <Styling>Visual configuration }
|
||||
}
|
||||
}"];
|
||||
|
||||
QskControl [ URL="\ref QskControl"]
|
||||
QskLayout [ URL="\ref QskLayout"]
|
||||
QskSkinlet [ URL="\ref QskSkinlet"]
|
||||
QskGraphic [ URL="\ref QskGraphic"]
|
||||
QskSkin [ URL="\ref QskSkin"]
|
||||
QskSkinnable [ URL="\ref QskSkinnable"]
|
||||
|
||||
table:Controls:s -> QskControl
|
||||
table:Controls:s -> QskLayout
|
||||
|
||||
table:Rendering:s -> QskSkinlet
|
||||
table:Rendering:s -> QskGraphic
|
||||
|
||||
table:Styling:s -> QskSkin
|
||||
table:Styling:s -> QskSkinnable
|
||||
}
|
||||
@enddot
|
||||
|
||||
Besides establishing a more complete C++ API for Qt Quick application development,
|
||||
the QSkinny project offers:
|
||||
|
||||
- Special attention to resource requirements (i.e. memory consumption and
|
||||
start-up performance), with a number of \ref qskoptimizations "optimizations"
|
||||
enabled by default
|
||||
- A \ref qsklayouts "layout system" comparable to the one available for \ref QWidget "Qt Widgets"
|
||||
- A way to \ref qskskinning "skin" (theme/style) applications entirely from C++,
|
||||
including built-in support for CSS-like inheritance and \ref qskanimations "animated transitions"
|
||||
- Better support for \ref qskvectorgraphics "vector image formats" to aid in
|
||||
scalable UI creation
|
||||
|
||||
Doing the implementation in C++ allows to make use of the \ref qsknodes "scene graph"
|
||||
classes. Building controls from scene graph nodes allows for a lighter implementation
|
||||
than found with stacking "heavier" objects like QObject or QQuickItem.
|
||||
|
||||
\note The current selection of implemented controls is driven by the needs of specific
|
||||
projects and therefore may feel a bit random. Conceptually, though, any type of
|
||||
control fits into QSkinny, as long as it is usable from C++ (as opposed to only
|
||||
QML).
|
||||
|
||||
\section license License
|
||||
|
||||
QSkinny is distributed under the terms of the QSkinny license.
|
||||
|
||||
\section platforms Platforms
|
||||
|
||||
QSkinny 0.0.1 might be source code compatible in all environments where you find
|
||||
Qt >= 5.6. Due to its use of private Qt headers, it might be necessary to
|
||||
recompile QSkinny for different Qt versions.
|
||||
*/
|
0
doc/qskanimations.dox
Normal file
0
doc/qskanimations.dox
Normal file
12
doc/qsklayouts.dox
Normal file
12
doc/qsklayouts.dox
Normal file
@ -0,0 +1,12 @@
|
||||
/*!
|
||||
\page qsklayouts Layouts
|
||||
|
||||
- QskResizable
|
||||
- QskSizePolicy
|
||||
- QskControl::sizeHint
|
||||
- QskLayout
|
||||
- QskGridBox
|
||||
- QskLinearBox
|
||||
- QskStackBox
|
||||
|
||||
*/
|
131
doc/qskmodules.dox
Normal file
131
doc/qskmodules.dox
Normal file
@ -0,0 +1,131 @@
|
||||
/*!
|
||||
\defgroup Classes C++ Classes
|
||||
\{
|
||||
\defgroup Controls Controls
|
||||
\{
|
||||
\class QskSetup
|
||||
\class QskControl
|
||||
\class QskAbstractButton
|
||||
\class QskRangeControl
|
||||
\class QskPushButton
|
||||
\class QskFocusIndicator
|
||||
\class QskFrame
|
||||
\class QskGraphicLabel
|
||||
\class QskImage
|
||||
\class QskRectangle
|
||||
\class QskResizable
|
||||
\class QskScrollView
|
||||
\class QskListView
|
||||
\class QskSeparator
|
||||
\class QskSimpleListBox
|
||||
\class QskSlider
|
||||
\class QskTabBar
|
||||
\class QskTabButton
|
||||
\class QskTabView
|
||||
\class QskTextLabel
|
||||
\class QskWindow
|
||||
\class QskDialogButtonBox
|
||||
\class QskDialog
|
||||
\class QskMessageBox
|
||||
\class QskStandardIcons
|
||||
\}
|
||||
|
||||
\defgroup Layouts
|
||||
\{
|
||||
\class QskLayout
|
||||
\class QskGridBox
|
||||
\class QskIndexedLayoutBox
|
||||
\class QskLayoutEngine
|
||||
\class QskLayoutItem
|
||||
\class QskStackLayoutAnimation
|
||||
\class QskStackBox
|
||||
\class QskLinearBox
|
||||
\}
|
||||
|
||||
\defgroup Graphic
|
||||
\{
|
||||
\class QskGraphic
|
||||
\class QskGraphicImageProvider
|
||||
\class QskGraphicPaintEngine
|
||||
\class QskGraphicPaintFilter
|
||||
\class QskGraphicProvider
|
||||
\class QskGraphicTextureFactory
|
||||
\class QskPainterCommand
|
||||
|
||||
\namespace QskGraphicIO
|
||||
\}
|
||||
|
||||
\defgroup Skins
|
||||
\{
|
||||
\namespace QskAspect
|
||||
\struct QskSkinHint
|
||||
\class QskSkin
|
||||
\class QskSkinnable
|
||||
\class QskSkinlet
|
||||
\class QskPushButtonSkinlet
|
||||
\class QskFocusIndicatorSkinlet
|
||||
\class QskFrameSkinlet
|
||||
\class QskGraphicLabelSkinlet
|
||||
\class QskSliderSkinlet
|
||||
\class QskTabButtonSkinlet
|
||||
\class QskTextLabelSkinlet
|
||||
\}
|
||||
|
||||
\defgroup Nodes
|
||||
\{
|
||||
\class QskArcIterator
|
||||
\class QskClipNode
|
||||
\class QskFrameNode
|
||||
\class QskGeometry
|
||||
\class QskPlainTextRenderer
|
||||
\class QskRectNode
|
||||
\class QskSymbolMaterial
|
||||
\class QskTextRenderer
|
||||
\class QskTextureNode
|
||||
\class QskTextureRenderer
|
||||
\class QskVertexColor
|
||||
\class QskVertexPen
|
||||
\class QskVertexRendererColored
|
||||
\class QskVertexRenderer
|
||||
\}
|
||||
\}
|
||||
|
||||
\defgroup QMLTypes QML Types
|
||||
\{
|
||||
\defgroup QMLControls Controls
|
||||
\{
|
||||
\class Control
|
||||
|
||||
\class AbstractButton
|
||||
\class RangeControl
|
||||
\class PushButton
|
||||
\class FocusIndicator
|
||||
\class Frame
|
||||
\class GraphicLabel
|
||||
\class Image
|
||||
\class ListView
|
||||
\class Rectangle
|
||||
\class SimpleListBox
|
||||
\class ScrollView
|
||||
\class Separator
|
||||
\class Slider
|
||||
\class TabBar
|
||||
\class TabButton
|
||||
\class TabView
|
||||
\class TextLabel
|
||||
\class Window
|
||||
\class DialogButtonBox
|
||||
\class Dialog
|
||||
\class MessageBox
|
||||
\}
|
||||
|
||||
\defgroup QMLLayouts Layouts
|
||||
\{
|
||||
\class Layout
|
||||
\class GridBox
|
||||
\class IndexedLayoutBox
|
||||
\class StackBox
|
||||
\class LinearBox
|
||||
\}
|
||||
\}
|
||||
*/
|
25
doc/qsknodes.dox
Normal file
25
doc/qsknodes.dox
Normal file
@ -0,0 +1,25 @@
|
||||
/*!
|
||||
\page qsknodes Scene graph
|
||||
|
||||
The most significant benefit of the Qt Quick graphics stack is its backend - a
|
||||
layer on top of hardware APIs (notably OpenGL). Instead of a simple
|
||||
immediate-mode drawing API like QPainter, the
|
||||
<a href=http://doc.qt.io/qt-5/qtquick-visualcanvas-scenegraph.html>implementation</a>
|
||||
utilizes a <a href=https://en.wikipedia.org/wiki/Scene_graph>scene graph</a> to
|
||||
minimize state changes between rendered frames.
|
||||
|
||||
While a minimal C++ scene graph API is exported by Qt, it is not the primary
|
||||
way to build user interfaces with Qt Quick. As such, QSkinny leverages its own
|
||||
code and private classes in Qt to provide additional support not found in Qt
|
||||
Quick:
|
||||
|
||||
- Text node creation
|
||||
- Direct creation of QPainter-drawn textures
|
||||
- Frames and borders with raised or sunken effects
|
||||
- Vertex list generation for all types of gradients
|
||||
|
||||
\note The set of Qsk classes around the scene graph nodes is currently a lose
|
||||
collection of code sequences needed for implementing the Qsk Controls. Once
|
||||
these classes have become more stable the code fragments will be rearranged
|
||||
into a proper class design.
|
||||
*/
|
53
doc/qskoptimizations.dox
Normal file
53
doc/qskoptimizations.dox
Normal file
@ -0,0 +1,53 @@
|
||||
/*!
|
||||
\page qskoptimizations Optimizations
|
||||
|
||||
The main optimizations found in QSkinny stem from the usage of C++ as a
|
||||
first-class citizen, allowing for "lighter" classes to be leveraged when
|
||||
building UIs. In QML, most types are backed by a corresponding QObject, or
|
||||
possibly multiple QObjects in order to deal with grouped properties and styling.
|
||||
QskControls, on the other hand, strive to encapsulate all functionality within
|
||||
a single QObject and delegate styling and other options to Q_GADGET classes and
|
||||
scene graph nodes.
|
||||
|
||||
Fewer QObjects leads to less memory consumption, generally fewer memory
|
||||
allocations, and better start-up times (especially when QML is avoided
|
||||
altogether).
|
||||
|
||||
\par Scene graph timing optimizations
|
||||
|
||||
The \ref QQuickItem "Qt Quick" framework has a tendency to perform some operations
|
||||
too soon and too often, possibly leading to negative effects on performance or
|
||||
memory consumption. As some of these behaviors can be deferred at runtime,
|
||||
QskControl exposes a number of \ref QskControl::Flag "flags" (enabled by
|
||||
default) to avoid these issues.
|
||||
|
||||
More specifically, the following observations and associated actions have been
|
||||
made:
|
||||
|
||||
\par Delaying node creation
|
||||
When calling QQuickItem::update(), the scene graph schedules a call to
|
||||
QQuickItem::updatePaintNode(), regardless of whether the item is visible. Naïve
|
||||
implementations tend to always update the node, resulting in possibly extra work
|
||||
(especially at start-up time). QSkinny defers the creation of this paint node by
|
||||
blocking the subsequent call to QskSkinnable::updateNode unless the item is
|
||||
visible. The behavior can be disabled via QskControl::DeferredUpdate.
|
||||
|
||||
\par Deferring polish
|
||||
Similar to deferred updates (see above), calls to QQuickItem::polish are
|
||||
deferred until the item is visible and its geometry is known. The behavior is
|
||||
controlled by QskControl::DeferredPolish.
|
||||
|
||||
\par Deferring unnecessary re-layout
|
||||
By default, the implicit approach to layouts found in QML can generate
|
||||
superfluous changes to the geometry of an item, especially during application
|
||||
start-up. The QskControl::DeferredLayout flag attempts to block most of these
|
||||
changes. When using QSkinny layouts, it is recommended to leave this flag
|
||||
enabled, but it may be necessary to disable it when working with standard QML
|
||||
layouts.
|
||||
|
||||
\par Deleting invisible nodes
|
||||
The default scene graph does not implicitly delete nodes which become invisible.
|
||||
As this might result in a useful memory savings, QSkinny deletes, by default,
|
||||
nodes belonging to items which have been made invisible. To change this behavior,
|
||||
disable the QskControl::CleanupOnVisibility flag.
|
||||
*/
|
35
doc/qskskinning.dox
Normal file
35
doc/qskskinning.dox
Normal file
@ -0,0 +1,35 @@
|
||||
/*!
|
||||
\page qskskinning Skinning
|
||||
|
||||
Controls in QSkinny are designed from the ground up to be skinnable (that is,
|
||||
easily styled/themed). QSkinny includes both a high-level API consisting of
|
||||
\em skin \em hints (QskSkinHint) and a low-level API based on C++ delegates, or
|
||||
\em skinlets (QskSkinlet). In fact, the two approaches are used in tandem to
|
||||
provide custom \em skins (QskSkin) to applications.
|
||||
|
||||
Inspired by CSS, skin hints consist of basic types (e.g. colors or distances)
|
||||
which are used to describe the rendering of a user interface (i.e.,
|
||||
\em skinnable - QskSkinnable - components). The particular element of the UI affected by this
|
||||
skin hint is described by an \em aspect (QskAspect). Not unlike CSS selectors, aspects are
|
||||
created by combining a series of flags together. This combination of flags (called
|
||||
an aspect) determines the rendering scope to which the skin hint applies.
|
||||
|
||||
More concretely, modifying the look & feel of QskControls can be acheived by:
|
||||
- (Basic) Calling QskSkin::setSkinHint (or the more specific methods
|
||||
QskSkin::setRgb or QskSkin::setMetric). Setting a value for a given aspect will change the
|
||||
rendering of that aspect for all skinlets which use it.
|
||||
- (Basic) Calling QskSkinnable::setSkinHint on a \ref QskSkinnable "skinnable",
|
||||
typically a \ref QskControl "control".
|
||||
- (Advanced) Subclassing QskSkin and registering a custom skinlet with
|
||||
QskSkin::declareSkinlet. The custom skinlet can be used to change the C++
|
||||
drawing routines via overridden method calls.
|
||||
- (Advanced) Subclassing a QskSkinlet and calling QskSkinnable::setSkinlet directly on a
|
||||
given skinnable. This allows changing the drawing routines for a specific
|
||||
control instance rather than every control instance in the application.
|
||||
|
||||
The default skin in QSkinny is intended to be flexible enough that the most
|
||||
common visual changes can be acheived without subclassing QskSkinlet. That is,
|
||||
they can be styled entirely by setting skin hints for aspects used by the
|
||||
built-in skinlets. For more information about how aspects are used to control
|
||||
rendering in the built-in skinlets, see QskAspect.
|
||||
*/
|
8
doc/qskvectorgraphics.dox
Normal file
8
doc/qskvectorgraphics.dox
Normal file
@ -0,0 +1,8 @@
|
||||
/*!
|
||||
\page qskvectorgraphics Vector graphics
|
||||
|
||||
- QskGraphic
|
||||
- QskGraphicProvider
|
||||
- QskTextureRenderer
|
||||
|
||||
*/
|
42
examples/buttons/TestButton.qml
Normal file
42
examples/buttons/TestButton.qml
Normal file
@ -0,0 +1,42 @@
|
||||
import QtQuick 2.0
|
||||
import Skinny 1.0 as Qsk
|
||||
|
||||
Qsk.PushButton
|
||||
{
|
||||
sizePolicy
|
||||
{
|
||||
horizontalPolicy: Qsk.SizePolicy.Ignored
|
||||
verticalPolicy: Qsk.SizePolicy.Ignored
|
||||
}
|
||||
|
||||
corner
|
||||
{
|
||||
mode: Qt.RelativeSize
|
||||
radius: 10
|
||||
}
|
||||
|
||||
onClicked:
|
||||
{
|
||||
console.log( "Clicked" )
|
||||
}
|
||||
|
||||
onPressed:
|
||||
{
|
||||
console.log( "Pressed" )
|
||||
}
|
||||
|
||||
onReleased:
|
||||
{
|
||||
console.log( "Released" )
|
||||
}
|
||||
|
||||
onCanceled:
|
||||
{
|
||||
console.log( "Canceled" )
|
||||
}
|
||||
|
||||
onToggled:
|
||||
{
|
||||
console.log( "Toggled" )
|
||||
}
|
||||
}
|
9
examples/buttons/buttons.pro
Normal file
9
examples/buttons/buttons.pro
Normal file
@ -0,0 +1,9 @@
|
||||
include( $${PWD}/../examples.pri )
|
||||
|
||||
TARGET = buttons
|
||||
|
||||
RESOURCES += \
|
||||
buttons.qrc
|
||||
|
||||
SOURCES += \
|
||||
main.cpp
|
122
examples/buttons/buttons.qml
Normal file
122
examples/buttons/buttons.qml
Normal file
@ -0,0 +1,122 @@
|
||||
import Skinny 1.0 as Qsk
|
||||
import QtQuick 2.5
|
||||
import "qrc:/qml"
|
||||
|
||||
Qsk.Window
|
||||
{
|
||||
id: window
|
||||
visible: true
|
||||
// visibility: QskWindow.Minimized
|
||||
|
||||
width: 600
|
||||
height: 600
|
||||
color: "Beige"
|
||||
|
||||
Qsk.LinearBox
|
||||
{
|
||||
orientation: Qt.Horizontal
|
||||
dimension: 3
|
||||
|
||||
margins: 10
|
||||
spacing: 10
|
||||
|
||||
TestButton
|
||||
{
|
||||
text: "Push Me"
|
||||
focus: true
|
||||
}
|
||||
|
||||
TestButton
|
||||
{
|
||||
text: "Disabled"
|
||||
enabled: false
|
||||
}
|
||||
|
||||
TestButton
|
||||
{
|
||||
text: "The quick brown fox jumps over the lazy dog !"
|
||||
clip: true
|
||||
|
||||
textOptions
|
||||
{
|
||||
elideMode: Qt.ElideNone
|
||||
wrapMode: Qsk.TextOptions.WordWrap
|
||||
}
|
||||
}
|
||||
|
||||
TestButton
|
||||
{
|
||||
text: "The <b><font color='red'>quick</font></b> brown fox jumps over the lazy dog !"
|
||||
textOptions
|
||||
{
|
||||
format: Qsk.TextOptions.AutoText
|
||||
elideMode: Qt.ElideRight
|
||||
}
|
||||
|
||||
onClicked:
|
||||
{
|
||||
textOptions.format = textOptions.format === Qsk.TextOptions.AutoText
|
||||
? Qsk.TextOptions.PlainText : Qsk.TextOptions.AutoText
|
||||
}
|
||||
}
|
||||
|
||||
TestButton
|
||||
{
|
||||
text: "Autorepeater"
|
||||
|
||||
autoRepeat: true
|
||||
autoRepeatDelay: 500
|
||||
autoRepeatInterval: 200
|
||||
}
|
||||
|
||||
TestButton
|
||||
{
|
||||
text: "Check Me"
|
||||
graphicSource: "image://shapes/Ring/Khaki"
|
||||
|
||||
checkable: true
|
||||
}
|
||||
|
||||
TestButton
|
||||
{
|
||||
text: "Check Me"
|
||||
|
||||
flat: true
|
||||
|
||||
checkable: true
|
||||
}
|
||||
|
||||
TestButton
|
||||
{
|
||||
text: "Push Me"
|
||||
|
||||
flat: true
|
||||
}
|
||||
|
||||
TestButton
|
||||
{
|
||||
graphicSource: "image://shapes/Diamond/SandyBrown"
|
||||
|
||||
corner
|
||||
{
|
||||
mode: Qt.RelativeSize
|
||||
radius: 100
|
||||
}
|
||||
}
|
||||
|
||||
TestButton
|
||||
{
|
||||
text: "Push Me"
|
||||
|
||||
corner
|
||||
{
|
||||
mode: Qt.AbsoluteSize
|
||||
radius: 0.0
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Qsk.FocusIndicator
|
||||
{
|
||||
}
|
||||
}
|
6
examples/buttons/buttons.qrc
Normal file
6
examples/buttons/buttons.qrc
Normal file
@ -0,0 +1,6 @@
|
||||
<RCC>
|
||||
<qresource prefix="/qml">
|
||||
<file>TestButton.qml</file>
|
||||
<file>buttons.qml</file>
|
||||
</qresource>
|
||||
</RCC>
|
33
examples/buttons/main.cpp
Normal file
33
examples/buttons/main.cpp
Normal file
@ -0,0 +1,33 @@
|
||||
/******************************************************************************
|
||||
* QSkinny - Copyright (C) 2016 Uwe Rathmann
|
||||
* This file may be used under the terms of the 3-clause BSD License
|
||||
*****************************************************************************/
|
||||
|
||||
#include <SkinnyShapeProvider.h>
|
||||
#include <SkinnyFont.h>
|
||||
#include <SkinnyShortcut.h>
|
||||
|
||||
#include <QskModule.h>
|
||||
#include <QskObjectCounter.h>
|
||||
|
||||
#include <QQmlApplicationEngine>
|
||||
#include <QGuiApplication>
|
||||
|
||||
int main( int argc, char* argv[] )
|
||||
{
|
||||
#ifdef ITEM_STATISTICS
|
||||
QskObjectCounter counter( true );
|
||||
#endif
|
||||
|
||||
QskModule::registerTypes();
|
||||
Qsk::addGraphicProvider( "shapes", new SkinnyShapeProvider() );
|
||||
|
||||
QGuiApplication app( argc, argv );
|
||||
|
||||
SkinnyFont::init( &app );
|
||||
SkinnyShortcut::enable( SkinnyShortcut::AllShortcuts );
|
||||
|
||||
QQmlApplicationEngine engine( QUrl( "qrc:/qml/buttons.qml" ) );
|
||||
|
||||
return app.exec();
|
||||
}
|
8
examples/desktop/desktop.pro
Normal file
8
examples/desktop/desktop.pro
Normal file
@ -0,0 +1,8 @@
|
||||
include( $${PWD}/../examples.pri )
|
||||
|
||||
TARGET = desktop
|
||||
|
||||
QT += quick
|
||||
|
||||
SOURCES += \
|
||||
main.cpp
|
76
examples/desktop/main.cpp
Normal file
76
examples/desktop/main.cpp
Normal file
@ -0,0 +1,76 @@
|
||||
/******************************************************************************
|
||||
* QSkinny - Copyright (C) 2016 Uwe Rathmann
|
||||
* This file may be used under the terms of the 3-clause BSD License
|
||||
*****************************************************************************/
|
||||
|
||||
#include <SkinnyShortcut.h>
|
||||
#include <SkinnyShapeProvider.h>
|
||||
|
||||
#include <QskObjectCounter.h>
|
||||
#include <QskWindow.h>
|
||||
#include <QskSubWindow.h>
|
||||
#include <QskSubWindowArea.h>
|
||||
#include <QskGraphicLabel.h>
|
||||
#include <QskGradient.h>
|
||||
#include <QskAspect.h>
|
||||
|
||||
#include <QGuiApplication>
|
||||
|
||||
class SubWindow : public QskSubWindow
|
||||
{
|
||||
public:
|
||||
SubWindow( const QString& graphicSource, QQuickItem* parent = nullptr ):
|
||||
QskSubWindow( parent )
|
||||
{
|
||||
setObjectName( graphicSource );
|
||||
|
||||
setColor( QskSubWindow::Panel | QskAspect::Background, "Wheat" );
|
||||
|
||||
auto label = new QskGraphicLabel( this );
|
||||
label->setSource( graphicSource );
|
||||
label->setAlignment( Qt::AlignCenter );
|
||||
|
||||
setSizePolicy( QskSizePolicy::MinimumExpanding,
|
||||
QskSizePolicy::MinimumExpanding );
|
||||
}
|
||||
};
|
||||
|
||||
int main( int argc, char* argv[] )
|
||||
{
|
||||
#ifdef ITEM_STATISTICS
|
||||
QskObjectCounter counter( true );
|
||||
#endif
|
||||
|
||||
const char providerId[] = "shapes";
|
||||
Qsk::addGraphicProvider( providerId, new SkinnyShapeProvider() );
|
||||
|
||||
QGuiApplication app( argc, argv );
|
||||
|
||||
SkinnyShortcut::enable( SkinnyShortcut::AllShortcuts );
|
||||
|
||||
QskSubWindowArea* area = new QskSubWindowArea();
|
||||
area->setGradient( QskGradient( QskGradient::Diagonal,
|
||||
"DarkSlateGray", "LightSlateGray" ) );
|
||||
|
||||
QRectF windowRect( 0, 0, 250, 250 );
|
||||
|
||||
const QStringList shapes = { "ellipse", "ring", "star", "hexagon" };
|
||||
|
||||
const QString url = QString( "image://%1/" ).arg( providerId );
|
||||
|
||||
for ( int i = 0; i < shapes.count(); i++ )
|
||||
{
|
||||
const qreal off = ( i + 1 ) * 100;
|
||||
|
||||
SubWindow* subWindow = new SubWindow( url + shapes[i], area );
|
||||
subWindow->setGeometry( windowRect.translated( off, off ) );
|
||||
}
|
||||
|
||||
QskWindow window;
|
||||
|
||||
window.addItem( area );
|
||||
window.resize( 800, 800 );
|
||||
window.show();
|
||||
|
||||
return app.exec();
|
||||
}
|
111
examples/dialogbuttons/Window.cpp
Normal file
111
examples/dialogbuttons/Window.cpp
Normal file
@ -0,0 +1,111 @@
|
||||
/******************************************************************************
|
||||
* QSkinny - Copyright (C) 2016 Uwe Rathmann
|
||||
* This file may be used under the terms of the 3-clause BSD License
|
||||
*****************************************************************************/
|
||||
|
||||
#include <QskLinearBox.h>
|
||||
#include <QskDialogButtonBox.h>
|
||||
#include <QskPushButton.h>
|
||||
#include "Window.h"
|
||||
|
||||
Window::Window( Qt::Orientation orientation ):
|
||||
m_orientation( orientation )
|
||||
{
|
||||
m_layoutBox = new QskLinearBox( invertedOrientation() );
|
||||
m_layoutBox->setObjectName( "MainBox" );
|
||||
m_layoutBox->setMargins( 10 );
|
||||
m_layoutBox->setExtraSpacingAt( Qt::BottomEdge | Qt::RightEdge );
|
||||
|
||||
addBox( QskDialog::Ok );
|
||||
addBox( QskDialog::StandardButtons( QskDialog::Ok | QskDialog::Cancel ) );
|
||||
addBox( QskDialog::StandardButtons( QskDialog::Yes | QskDialog::No ) );
|
||||
addBox( QskDialog::StandardButtons( QskDialog::Save | QskDialog::Discard
|
||||
| QskDialog::RestoreDefaults | QskDialog::Help ) );
|
||||
addBox( QskDialog::StandardButtons( QskDialog::Abort
|
||||
| QskDialog::Retry | QskDialog::Ignore ) );
|
||||
|
||||
addActionBox();
|
||||
addItem( m_layoutBox );
|
||||
}
|
||||
|
||||
void Window::addBox( QskDialog::StandardButtons standardButtons )
|
||||
{
|
||||
QskDialogButtonBox* box = new QskDialogButtonBox( m_orientation );
|
||||
box->setStandardButtons( standardButtons );
|
||||
box->setObjectName( "DialogBox" );
|
||||
|
||||
m_layoutBox->addItem( box );
|
||||
}
|
||||
|
||||
void Window::addActionBox()
|
||||
{
|
||||
QskPushButton* flipButton = new QskPushButton( "Flip" );
|
||||
QskPushButton* centerButton = new QskPushButton( "Center" );
|
||||
|
||||
QskDialogButtonBox* box = new QskDialogButtonBox( m_orientation );
|
||||
box->addButton( flipButton, QskDialog::ActionRole );
|
||||
box->addButton( centerButton, QskDialog::ActionRole );
|
||||
box->setObjectName( "ActionBox" );
|
||||
|
||||
m_layoutBox->addItem( box );
|
||||
|
||||
connect( flipButton, &QskPushButton::clicked, this, &Window::flipOrientation );
|
||||
connect( centerButton, &QskPushButton::clicked, this, &Window::centerButtons );
|
||||
}
|
||||
|
||||
void Window::flipOrientation()
|
||||
{
|
||||
auto newBox = new QskLinearBox( m_orientation );
|
||||
newBox->setObjectName( m_layoutBox->objectName() );
|
||||
newBox->setExtraSpacingAt( m_layoutBox->extraSpacingAt() );
|
||||
newBox->setMargins( m_layoutBox->margins() );
|
||||
|
||||
m_orientation = invertedOrientation();
|
||||
m_layoutBox->setActive( false );
|
||||
|
||||
const QVector< QskDialogButtonBox* > boxes = dialogBoxes();
|
||||
for ( QskDialogButtonBox* box : boxes )
|
||||
{
|
||||
box->setOrientation( m_orientation );
|
||||
box->setParent( nullptr );
|
||||
|
||||
newBox->addItem( box );
|
||||
}
|
||||
|
||||
delete m_layoutBox;
|
||||
m_layoutBox = newBox;
|
||||
|
||||
addItem( m_layoutBox );
|
||||
}
|
||||
|
||||
void Window::centerButtons()
|
||||
{
|
||||
const QVector< QskDialogButtonBox* > boxes = dialogBoxes();
|
||||
for ( QskDialogButtonBox* box : boxes )
|
||||
box->setCenteredButtons( !box->centeredButtons() );
|
||||
}
|
||||
|
||||
QVector< QskDialogButtonBox* > Window::dialogBoxes() const
|
||||
{
|
||||
QVector< QskDialogButtonBox* > boxes;
|
||||
for ( int i = 0; i < m_layoutBox->itemCount(); i++ )
|
||||
{
|
||||
if ( QskDialogButtonBox* box =
|
||||
qobject_cast< QskDialogButtonBox* >( m_layoutBox->itemAtIndex( i ) ) )
|
||||
{
|
||||
boxes += box;
|
||||
}
|
||||
}
|
||||
|
||||
return boxes;
|
||||
}
|
||||
|
||||
Qt::Orientation Window::invertedOrientation() const
|
||||
{
|
||||
if ( m_orientation == Qt::Vertical )
|
||||
return Qt::Horizontal;
|
||||
else
|
||||
return Qt::Vertical;
|
||||
}
|
||||
|
||||
#include "moc_Window.cpp"
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user