diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-07-01 20:29:58 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-07-01 20:29:58 +0000 |
commit | d5c0d088adcff6364f6154eb26d38bd57b535e25 (patch) | |
tree | d43637b281c5676b0be1fd5a22b0741f2fb317a9 | |
parent | 17177ee9cca7ff6e48b03b66fa9213cd08213609 (diff) | |
download | kuickshow-d5c0d088adcff6364f6154eb26d38bd57b535e25.tar.gz kuickshow-d5c0d088adcff6364f6154eb26d38bd57b535e25.zip |
TQt4 port kuickshow
This enables compilation under both Qt3 and Qt4
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/kuickshow@1239028 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
51 files changed, 791 insertions, 1634 deletions
diff --git a/debian/cdbs/debian-qt-kde.mk b/debian/cdbs/debian-qt-kde.mk deleted file mode 100644 index 41c3dd4..0000000 --- a/debian/cdbs/debian-qt-kde.mk +++ /dev/null @@ -1,108 +0,0 @@ -ifndef _cdbs_bootstrap -_cdbs_scripts_path ?= /usr/lib/cdbs -_cdbs_rules_path ?= /usr/share/cdbs/1/rules -_cdbs_class_path ?= /usr/share/cdbs/1/class -endif - -ifndef _cdbs_class_debian-qt-kde -_cdbs_class_debian-qt-kde := 1 - -# Note: This _must_ be included before autotools.mk, or it won't work. -common-configure-arch common-configure-indep:: debian/stamp-cvs-make -debian/stamp-cvs-make: - if test -n "$(DEB_KDE_CVS_MAKE)" -a ! -f configure; then \ - $(MAKE) -C $(DEB_SRCDIR) -f admin/Makefile.common dist; \ - fi - touch debian/stamp-cvs-make - -include /usr/share/cdbs/1/class/kde.mk$(_cdbs_makefile_suffix) - -DEB_PATCHDIRS := debian/patches/common debian/patches - -DEB_KDE_ENABLE_FINAL := yes -DEB_INSTALL_DOCS_ALL := - -DEB_DH_MAKESHLIBS_ARGS_ALL := -V -DEB_SHLIBDEPS_INCLUDE = $(foreach p,$(PACKAGES_WITH_LIBS),debian/$(p)/usr/lib) - -ifeq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) - cdbs_treat_me_gently_arches := arm m68k alpha ppc64 - ifeq (,$(filter $(DEB_HOST_ARCH_CPU),$(cdbs_treat_me_gently_arches))) - cdbs_kde_enable_final = $(if $(DEB_KDE_ENABLE_FINAL),--enable-final,) - else - cdbs_kde_enable_final = - endif -endif - -common-build-arch:: debian/stamp-man-pages -debian/stamp-man-pages: - if ! test -d debian/man/out; then mkdir -p debian/man/out; fi - for f in $$(find debian/man -name '*.sgml'); do \ - docbook-to-man $$f > debian/man/out/`basename $$f .sgml`.1; \ - done - for f in $$(find debian/man -name '*.man'); do \ - soelim -I debian/man $$f \ - > debian/man/out/`basename $$f .man`.`head -n1 $$f | awk '{print $$NF}'`; \ - done - touch debian/stamp-man-pages - -common-binary-indep:: - ( set -e; \ - tmpf=`mktemp debian/versions.XXXXXX`; \ - perl debian/cdbs/versions.pl >$$tmpf; \ - for p in $(DEB_INDEP_PACKAGES); do \ - cat $$tmpf >>debian/$$p.substvars; \ - done; \ - rm -f $$tmpf ) - -common-binary-arch:: - ( set -e; \ - tmpf=`mktemp debian/versions.XXXXXX`; \ - perl debian/cdbs/versions.pl >$$tmpf; \ - for p in $(DEB_ARCH_PACKAGES); do \ - cat $$tmpf >>debian/$$p.substvars; \ - done; \ - rm -f $$tmpf ) - -clean:: - rm -rf debian/man/out - -rmdir debian/man - rm -f debian/stamp-man-pages - rm -rf debian/shlibs-check - -$(patsubst %,binary-install/%,$(DEB_PACKAGES)) :: binary-install/%: - if test -x /usr/bin/dh_desktop; then dh_desktop -p$(cdbs_curpkg) $(DEB_DH_DESKTOP_ARGS); fi - if test -e debian/$(cdbs_curpkg).lintian; then \ - install -p -D -m644 debian/$(cdbs_curpkg).lintian \ - debian/$(cdbs_curpkg)/usr/share/lintian/overrides/$(cdbs_curpkg); \ - fi - if test -e debian/$(cdbs_curpkg).presubj; then \ - install -p -D -m644 debian/$(cdbs_curpkg).presubj \ - debian/$(cdbs_curpkg)/usr/share/bug/$(cdbs_curpkg)/presubj; \ - fi - -binary-install/$(DEB_SOURCE_PACKAGE)-doc-html:: - set -e; \ - for doc in `cd $(DEB_DESTDIR)/usr/share/doc/kde/HTML/en; find . -name index.docbook`; do \ - pkg=$${doc%/index.docbook}; pkg=$${pkg#./}; \ - echo Building $$pkg HTML docs...; \ - mkdir -p $(CURDIR)/debian/$(DEB_SOURCE_PACKAGE)-doc-html/usr/share/doc/kde/HTML/en/$$pkg; \ - cd $(CURDIR)/debian/$(DEB_SOURCE_PACKAGE)-doc-html/usr/share/doc/kde/HTML/en/$$pkg; \ - /usr/kde3/bin/meinproc $(DEB_DESTDIR)/usr/share/doc/kde/HTML/en/$$pkg/index.docbook; \ - done - for pkg in $(DOC_HTML_PRUNE) ; do \ - rm -rf debian/$(DEB_SOURCE_PACKAGE)-doc-html/usr/share/doc/kde/HTML/en/$$pkg; \ - done - -clean:: - if test -n "$(DEB_KDE_CVS_MAKE)" && test -d $(DEB_SRCDIR); then \ - cd $(DEB_SRCDIR); \ - find . -name Makefile.in -print | \ - xargs --no-run-if-empty rm -f; \ - rm -f Makefile.am acinclude.m4 aclocal.m4 config.h.in \ - configure configure.files configure.in stamp-h.in \ - subdirs; \ - fi - rm -f debian/stamp-cvs-make - -endif diff --git a/debian/cdbs/versions.pl b/debian/cdbs/versions.pl deleted file mode 100644 index 9ce11d8..0000000 --- a/debian/cdbs/versions.pl +++ /dev/null @@ -1,19 +0,0 @@ -#!/usr/bin/env perl - -use strict; -use warnings; - -my $version = `dpkg-parsechangelog | awk '/^Version/ {print \$2}'`; -my ($version3, $version3_next); -my ($version2, $version2_next); - -($version3 = $version) =~ s/-[^-]+$//; -($version2 = $version3) =~ s/\.[^.]+$//; - -($version3_next = $version3) =~ s/(?<=\.)(\d+)[a-z]?$/($1+1)/e; -($version2_next = $version2) =~ s/(?<=\.)(\d+)$/($1+1)/e; - -print "KDE-Version3=$version3\n"; -print "KDE-Version2=$version2\n"; -print "KDE-Next-Version3=$version3_next\n"; -print "KDE-Next-Version2=$version2_next\n"; diff --git a/debian/changelog b/debian/changelog deleted file mode 100644 index 46136aa..0000000 --- a/debian/changelog +++ /dev/null @@ -1,42 +0,0 @@ -kuickshow-kde3 (4:3.5.8-0ubuntu3) karmic; urgency=low - - * Karmic rebuild - - -- Timothy Pearson <[email protected]> Thu, 02 July 2009 16:08:00 -0600 - -kuickshow-kde3 (4:3.5.8-0ubuntu2) intrepid; urgency=low - - * Moved KDE3 to /opt/kde3 - * Integrated properly with KDE4.2+ - - -- Timothy Pearson <[email protected]> Fri, 06 March 2009 01:35:00 -0600 - -kuickshow-kde3 (4:3.5.8-0ubuntu1) intrepid; urgency=low - - * Added -kde3 suffix - - -- Timothy Pearson <[email protected]> Fri, 12 Dec 2008 14:28:00 -0600 - -kuickshow (4:3.5.8-0ubuntu2) hardy; urgency=low - - * No change recompile to build against libgif (not libungif) - - -- Jonathan Riddell <[email protected]> Mon, 07 Jan 2008 10:26:21 +0000 - -kuickshow (4:3.5.8-0ubuntu1) hardy; urgency=low - - * New upstream release, extracted from kdegraphics 3.5.8 - - -- Jonathan Riddell <[email protected]> Wed, 14 Nov 2007 17:59:49 +0000 - -kuickshow (4:3.5.7-0ubuntu1) gutsy; urgency=low - - * New upstream release, extracted from kdegraphics 3.5.7 - - -- Jonathan Riddell <[email protected]> Sun, 03 Jun 2007 14:45:49 +0100 - -kuickshow (4:3.5.6-0ubuntu1) feisty; urgency=low - - * Initial package, separate from kdegraphics due to imlib11 not being in main - - -- Jonathan Riddell <[email protected]> Wed, 28 Feb 2007 16:29:08 +0000 diff --git a/debian/compat b/debian/compat deleted file mode 100644 index 7ed6ff8..0000000 --- a/debian/compat +++ /dev/null @@ -1 +0,0 @@ -5 diff --git a/debian/control b/debian/control deleted file mode 100644 index 92a84ca..0000000 --- a/debian/control +++ /dev/null @@ -1,24 +0,0 @@ -Source: kuickshow-kde3 -Section: kde -Priority: optional -Maintainer: Timothy Pearson <[email protected]> -Build-Depends: cdbs (>= 0.4.39-0.1), debhelper (>= 5.0.31), autotools-dev, gawk, kdelibs4-kde3-dev (>= 4:3.5.6), imlib11-dev -Standards-Version: 3.7.2 - -Package: kuickshow-kde3 -Section: graphics -Architecture: any -Depends: ${shlibs:Depends} -Suggests: khelpcenter-kde3 -Description: KDE image/slideshow viewer [KDE3] - KuickShow is an image browser/viewer with a nice filebrowser to - select images to be shown, slideshow support and the ability to - display the following image formats: jpg, gif, tiff, png, bmp, psd, - xpm, xbm, pbm and eim. Images can be displayed either in their own - window, as large as the image, or fullscreen (which shrinks images too - large to display). KuickShow also has a slideshow mode. - . - This package is part of KDE, as a component of the KDE graphics - module. See the 'kde' and 'kdegraphics' packages for more information. - . - Homepage: http://kuickshow.sourceforge.net diff --git a/debian/copyright b/debian/copyright deleted file mode 100644 index 2373ec1..0000000 --- a/debian/copyright +++ /dev/null @@ -1,424 +0,0 @@ -This package was debianized by Christopher L Cheney <[email protected]> on -Tue, 16 Apr 2002 22:00:00 -0500. - -It was downloaded from: http://www.kde.org/download - -Upstream Authors: Stephan Kulow <[email protected]> and many others. - - -License: - -All programs are under the GPL. On Debian systems, the complete text of -the GPL license can be found in the /usr/share/common-licenses/GPL file. - --------------------- - -DocBook Documentation: - - Permission is granted to copy, distribute and/or modify this - document under the terms of the GNU Free Documentation License, - Version 1.1 or any later version published by the Free Software - Foundation; with no Invariant Sections, with no Front-Cover Texts, - and with no Back-Cover Texts. - - A copy of the GNU Free Documentation License (Version 1.2) is - included below. - - - GNU Free Documentation License - Version 1.2, November 2002 - - - Copyright (C) 2000,2001,2002 Free Software Foundation, Inc. - 51 Franklin St, Fifth Floor, Boston, MA, 02110-1301, USA. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - - 0. PREAMBLE - - The purpose of this License is to make a manual, textbook, or other - functional and useful document "free" in the sense of freedom: to - assure everyone the effective freedom to copy and redistribute it, - with or without modifying it, either commercially or noncommercially. - Secondarily, this License preserves for the author and publisher a way - to get credit for their work, while not being considered responsible - for modifications made by others. - - This License is a kind of "copyleft", which means that derivative - works of the document must themselves be free in the same sense. It - complements the GNU General Public License, which is a copyleft - license designed for free software. - - We have designed this License in order to use it for manuals for free - software, because free software needs free documentation: a free - program should come with manuals providing the same freedoms that the - software does. But this License is not limited to software manuals; - it can be used for any textual work, regardless of subject matter or - whether it is published as a printed book. We recommend this License - principally for works whose purpose is instruction or reference. - - - 1. APPLICABILITY AND DEFINITIONS - - This License applies to any manual or other work, in any medium, that - contains a notice placed by the copyright holder saying it can be - distributed under the terms of this License. Such a notice grants a - world-wide, royalty-free license, unlimited in duration, to use that - work under the conditions stated herein. The "Document", below, - refers to any such manual or work. Any member of the public is a - licensee, and is addressed as "you". You accept the license if you - copy, modify or distribute the work in a way requiring permission - under copyright law. - - A "Modified Version" of the Document means any work containing the - Document or a portion of it, either copied verbatim, or with - modifications and/or translated into another language. - - A "Secondary Section" is a named appendix or a front-matter section of - the Document that deals exclusively with the relationship of the - publishers or authors of the Document to the Document's overall subject - (or to related matters) and contains nothing that could fall directly - within that overall subject. (Thus, if the Document is in part a - textbook of mathematics, a Secondary Section may not explain any - mathematics.) The relationship could be a matter of historical - connection with the subject or with related matters, or of legal, - commercial, philosophical, ethical or political position regarding - them. - - The "Invariant Sections" are certain Secondary Sections whose titles - are designated, as being those of Invariant Sections, in the notice - that says that the Document is released under this License. If a - section does not fit the above definition of Secondary then it is not - allowed to be designated as Invariant. The Document may contain zero - Invariant Sections. If the Document does not identify any Invariant - Sections then there are none. - - The "Cover Texts" are certain short passages of text that are listed, - as Front-Cover Texts or Back-Cover Texts, in the notice that says that - the Document is released under this License. A Front-Cover Text may - be at most 5 words, and a Back-Cover Text may be at most 25 words. - - A "Transparent" copy of the Document means a machine-readable copy, - represented in a format whose specification is available to the - general public, that is suitable for revising the document - straightforwardly with generic text editors or (for images composed of - pixels) generic paint programs or (for drawings) some widely available - drawing editor, and that is suitable for input to text formatters or - for automatic translation to a variety of formats suitable for input - to text formatters. A copy made in an otherwise Transparent file - format whose markup, or absence of markup, has been arranged to thwart - or discourage subsequent modification by readers is not Transparent. - An image format is not Transparent if used for any substantial amount - of text. A copy that is not "Transparent" is called "Opaque". - - Examples of suitable formats for Transparent copies include plain - ASCII without markup, Texinfo input format, LaTeX input format, SGML - or XML using a publicly available DTD, and standard-conforming simple - HTML, PostScript or PDF designed for human modification. Examples of - transparent image formats include PNG, XCF and JPG. Opaque formats - include proprietary formats that can be read and edited only by - proprietary word processors, SGML or XML for which the DTD and/or - processing tools are not generally available, and the - machine-generated HTML, PostScript or PDF produced by some word - processors for output purposes only. - - The "Title Page" means, for a printed book, the title page itself, - plus such following pages as are needed to hold, legibly, the material - this License requires to appear in the title page. For works in - formats which do not have any title page as such, "Title Page" means - the text near the most prominent appearance of the work's title, - preceding the beginning of the body of the text. - - A section "Entitled XYZ" means a named subunit of the Document whose - title either is precisely XYZ or contains XYZ in parentheses following - text that translates XYZ in another language. (Here XYZ stands for a - specific section name mentioned below, such as "Acknowledgements", - "Dedications", "Endorsements", or "History".) To "Preserve the Title" - of such a section when you modify the Document means that it remains a - section "Entitled XYZ" according to this definition. - - The Document may include Warranty Disclaimers next to the notice which - states that this License applies to the Document. These Warranty - Disclaimers are considered to be included by reference in this - License, but only as regards disclaiming warranties: any other - implication that these Warranty Disclaimers may have is void and has - no effect on the meaning of this License. - - - 2. VERBATIM COPYING - - You may copy and distribute the Document in any medium, either - commercially or noncommercially, provided that this License, the - copyright notices, and the license notice saying this License applies - to the Document are reproduced in all copies, and that you add no other - conditions whatsoever to those of this License. You may not use - technical measures to obstruct or control the reading or further - copying of the copies you make or distribute. However, you may accept - compensation in exchange for copies. If you distribute a large enough - number of copies you must also follow the conditions in section 3. - - You may also lend copies, under the same conditions stated above, and - you may publicly display copies. - - - 3. COPYING IN QUANTITY - - If you publish printed copies (or copies in media that commonly have - printed covers) of the Document, numbering more than 100, and the - Document's license notice requires Cover Texts, you must enclose the - copies in covers that carry, clearly and legibly, all these Cover - Texts: Front-Cover Texts on the front cover, and Back-Cover Texts on - the back cover. Both covers must also clearly and legibly identify - you as the publisher of these copies. The front cover must present - the full title with all words of the title equally prominent and - visible. You may add other material on the covers in addition. - Copying with changes limited to the covers, as long as they preserve - the title of the Document and satisfy these conditions, can be treated - as verbatim copying in other respects. - - If the required texts for either cover are too voluminous to fit - legibly, you should put the first ones listed (as many as fit - reasonably) on the actual cover, and continue the rest onto adjacent - pages. - - If you publish or distribute Opaque copies of the Document numbering - more than 100, you must either include a machine-readable Transparent - copy along with each Opaque copy, or state in or with each Opaque copy - a computer-network location from which the general network-using - public has access to download using public-standard network protocols - a complete Transparent copy of the Document, free of added material. - If you use the latter option, you must take reasonably prudent steps, - when you begin distribution of Opaque copies in quantity, to ensure - that this Transparent copy will remain thus accessible at the stated - location until at least one year after the last time you distribute an - Opaque copy (directly or through your agents or retailers) of that - edition to the public. - - It is requested, but not required, that you contact the authors of the - Document well before redistributing any large number of copies, to give - them a chance to provide you with an updated version of the Document. - - - 4. MODIFICATIONS - - You may copy and distribute a Modified Version of the Document under - the conditions of sections 2 and 3 above, provided that you release - the Modified Version under precisely this License, with the Modified - Version filling the role of the Document, thus licensing distribution - and modification of the Modified Version to whoever possesses a copy - of it. In addition, you must do these things in the Modified Version: - - A. Use in the Title Page (and on the covers, if any) a title distinct - from that of the Document, and from those of previous versions - (which should, if there were any, be listed in the History section - of the Document). You may use the same title as a previous version - if the original publisher of that version gives permission. - B. List on the Title Page, as authors, one or more persons or entities - responsible for authorship of the modifications in the Modified - Version, together with at least five of the principal authors of the - Document (all of its principal authors, if it has fewer than five), - unless they release you from this requirement. - C. State on the Title page the name of the publisher of the - Modified Version, as the publisher. - D. Preserve all the copyright notices of the Document. - E. Add an appropriate copyright notice for your modifications - adjacent to the other copyright notices. - F. Include, immediately after the copyright notices, a license notice - giving the public permission to use the Modified Version under the - terms of this License, in the form shown in the Addendum below. - G. Preserve in that license notice the full lists of Invariant Sections - and required Cover Texts given in the Document's license notice. - H. Include an unaltered copy of this License. - I. Preserve the section Entitled "History", Preserve its Title, and add - to it an item stating at least the title, year, new authors, and - publisher of the Modified Version as given on the Title Page. If - there is no section Entitled "History" in the Document, create one - stating the title, year, authors, and publisher of the Document as - given on its Title Page, then add an item describing the Modified - Version as stated in the previous sentence. - J. Preserve the network location, if any, given in the Document for - public access to a Transparent copy of the Document, and likewise - the network locations given in the Document for previous versions - it was based on. These may be placed in the "History" section. - You may omit a network location for a work that was published at - least four years before the Document itself, or if the original - publisher of the version it refers to gives permission. - K. For any section Entitled "Acknowledgements" or "Dedications", - Preserve the Title of the section, and preserve in the section all - the substance and tone of each of the contributor acknowledgements - and/or dedications given therein. - L. Preserve all the Invariant Sections of the Document, - unaltered in their text and in their titles. Section numbers - or the equivalent are not considered part of the section titles. - M. Delete any section Entitled "Endorsements". Such a section - may not be included in the Modified Version. - N. Do not retitle any existing section to be Entitled "Endorsements" - or to conflict in title with any Invariant Section. - O. Preserve any Warranty Disclaimers. - - If the Modified Version includes new front-matter sections or - appendices that qualify as Secondary Sections and contain no material - copied from the Document, you may at your option designate some or all - of these sections as invariant. To do this, add their titles to the - list of Invariant Sections in the Modified Version's license notice. - These titles must be distinct from any other section titles. - - You may add a section Entitled "Endorsements", provided it contains - nothing but endorsements of your Modified Version by various - parties--for example, statements of peer review or that the text has - been approved by an organization as the authoritative definition of a - standard. - - You may add a passage of up to five words as a Front-Cover Text, and a - passage of up to 25 words as a Back-Cover Text, to the end of the list - of Cover Texts in the Modified Version. Only one passage of - Front-Cover Text and one of Back-Cover Text may be added by (or - through arrangements made by) any one entity. If the Document already - includes a cover text for the same cover, previously added by you or - by arrangement made by the same entity you are acting on behalf of, - you may not add another; but you may replace the old one, on explicit - permission from the previous publisher that added the old one. - - The author(s) and publisher(s) of the Document do not by this License - give permission to use their names for publicity for or to assert or - imply endorsement of any Modified Version. - - - 5. COMBINING DOCUMENTS - - You may combine the Document with other documents released under this - License, under the terms defined in section 4 above for modified - versions, provided that you include in the combination all of the - Invariant Sections of all of the original documents, unmodified, and - list them all as Invariant Sections of your combined work in its - license notice, and that you preserve all their Warranty Disclaimers. - - The combined work need only contain one copy of this License, and - multiple identical Invariant Sections may be replaced with a single - copy. If there are multiple Invariant Sections with the same name but - different contents, make the title of each such section unique by - adding at the end of it, in parentheses, the name of the original - author or publisher of that section if known, or else a unique number. - Make the same adjustment to the section titles in the list of - Invariant Sections in the license notice of the combined work. - - In the combination, you must combine any sections Entitled "History" - in the various original documents, forming one section Entitled - "History"; likewise combine any sections Entitled "Acknowledgements", - and any sections Entitled "Dedications". You must delete all sections - Entitled "Endorsements". - - - 6. COLLECTIONS OF DOCUMENTS - - You may make a collection consisting of the Document and other documents - released under this License, and replace the individual copies of this - License in the various documents with a single copy that is included in - the collection, provided that you follow the rules of this License for - verbatim copying of each of the documents in all other respects. - - You may extract a single document from such a collection, and distribute - it individually under this License, provided you insert a copy of this - License into the extracted document, and follow this License in all - other respects regarding verbatim copying of that document. - - - 7. AGGREGATION WITH INDEPENDENT WORKS - - A compilation of the Document or its derivatives with other separate - and independent documents or works, in or on a volume of a storage or - distribution medium, is called an "aggregate" if the copyright - resulting from the compilation is not used to limit the legal rights - of the compilation's users beyond what the individual works permit. - When the Document is included in an aggregate, this License does not - apply to the other works in the aggregate which are not themselves - derivative works of the Document. - - If the Cover Text requirement of section 3 is applicable to these - copies of the Document, then if the Document is less than one half of - the entire aggregate, the Document's Cover Texts may be placed on - covers that bracket the Document within the aggregate, or the - electronic equivalent of covers if the Document is in electronic form. - Otherwise they must appear on printed covers that bracket the whole - aggregate. - - - 8. TRANSLATION - - Translation is considered a kind of modification, so you may - distribute translations of the Document under the terms of section 4. - Replacing Invariant Sections with translations requires special - permission from their copyright holders, but you may include - translations of some or all Invariant Sections in addition to the - original versions of these Invariant Sections. You may include a - translation of this License, and all the license notices in the - Document, and any Warranty Disclaimers, provided that you also include - the original English version of this License and the original versions - of those notices and disclaimers. In case of a disagreement between - the translation and the original version of this License or a notice - or disclaimer, the original version will prevail. - - If a section in the Document is Entitled "Acknowledgements", - "Dedications", or "History", the requirement (section 4) to Preserve - its Title (section 1) will typically require changing the actual - title. - - - 9. TERMINATION - - You may not copy, modify, sublicense, or distribute the Document except - as expressly provided for under this License. Any other attempt to - copy, modify, sublicense or distribute the Document is void, and will - automatically terminate your rights under this License. However, - parties who have received copies, or rights, from you under this - License will not have their licenses terminated so long as such - parties remain in full compliance. - - - 10. FUTURE REVISIONS OF THIS LICENSE - - The Free Software Foundation may publish new, revised versions - of the GNU Free Documentation License from time to time. Such new - versions will be similar in spirit to the present version, but may - differ in detail to address new problems or concerns. See - http://www.gnu.org/copyleft/. - - Each version of the License is given a distinguishing version number. - If the Document specifies that a particular numbered version of this - License "or any later version" applies to it, you have the option of - following the terms and conditions either of that specified version or - of any later version that has been published (not as a draft) by the - Free Software Foundation. If the Document does not specify a version - number of this License, you may choose any version ever published (not - as a draft) by the Free Software Foundation. - - - ADDENDUM: How to use this License for your documents - - To use this License in a document you have written, include a copy of - the License in the document and put the following copyright and - license notices just after the title page: - - Copyright (c) YEAR YOUR NAME. - Permission is granted to copy, distribute and/or modify this document - under the terms of the GNU Free Documentation License, Version 1.2 - or any later version published by the Free Software Foundation; - with no Invariant Sections, no Front-Cover Texts, and no Back-Cover - Texts. A copy of the license is included in the section entitled - "GNU Free Documentation License". - - If you have Invariant Sections, Front-Cover Texts and Back-Cover Texts, - replace the "with...Texts." line with this: - - with the Invariant Sections being LIST THEIR TITLES, with the - Front-Cover Texts being LIST, and with the Back-Cover Texts being LIST. - - If you have Invariant Sections without Cover Texts, or some other - combination of the three, merge those two alternatives to suit the - situation. - - If your document contains nontrivial examples of program code, we - recommend releasing these examples in parallel under your choice of - free software license, such as the GNU General Public License, - to permit their use in free software. diff --git a/debian/icons/kuickshow-16.xpm b/debian/icons/kuickshow-16.xpm deleted file mode 100644 index cf91f34..0000000 --- a/debian/icons/kuickshow-16.xpm +++ /dev/null @@ -1,41 +0,0 @@ -/* XPM */ -static char *kuickshow-16[] = { -/* columns rows colors chars-per-pixel */ -"16 14 21 1", -" c black", -". c #000033", -"X c gray20", -"o c #006633", -"O c #336633", -"+ c #0033FF", -"@ c #3333FF", -"# c #6666FF", -"$ c #009933", -"% c #669933", -"& c #9900CC", -"* c #9933CC", -"= c #9933FF", -"- c #9966FF", -"; c #CC66CC", -": c #9999FF", -"> c #CC99FF", -", c #CCCCFF", -"< c #FFCCFF", -"1 c gray100", -"2 c None", -/* pixels */ -"2222222221,:2222", -"22211,:21,>:2222", -"22-<>1>-::->1122", -"22-,:->--:11>--2", -"222:-++@@-+-::#2", -"-11>-=>* @@+:@+2", -"1<::@=. @-:@*222", -">-@>>:@@##>+oo22", -"@@1+@>,#@>-=$%O2", -"-1-+@1:#--&OOXOO", -"-1;:@<:::*&2oOO2", -"2+@@2<:*22o%2222", -"2222222222o%2222", -"22222222222oo222" -}; diff --git a/debian/icons/kuickshow.xpm b/debian/icons/kuickshow.xpm deleted file mode 100644 index 5d2d6ca..0000000 --- a/debian/icons/kuickshow.xpm +++ /dev/null @@ -1,66 +0,0 @@ -/* XPM */ -static char *kuickshow[] = { -/* columns rows colors chars-per-pixel */ -"32 29 31 1", -" c black", -". c #000033", -"X c #003333", -"o c gray20", -"O c #006633", -"+ c #336633", -"@ c #0033FF", -"# c #3333FF", -"$ c #6666FF", -"% c #009933", -"& c #339933", -"* c #669933", -"= c #6699CC", -"- c #6699FF", -"; c #9900CC", -": c #9900FF", -"> c #9933CC", -", c #9933FF", -"< c #9966CC", -"1 c #9966FF", -"2 c #CC00CC", -"3 c #CC66CC", -"4 c #CC66FF", -"5 c #9999CC", -"6 c #9999FF", -"7 c #CC99FF", -"8 c #FF99FF", -"9 c #CCCCFF", -"0 c #FFCCFF", -"q c gray100", -"w c None", -/* pixels */ -"wwwwwwwwwwwwwwwwwww14114wwwwwwww", -"wwwwwwwwwwwwwwwwww6qqqq66wwwwwww", -"wwwwwww464141wwww4q909941wwwwwww", -"wwwwww1qq09976ww1q0917966wwwwwww", -"wwwww4q99171416w7q14117$1764wwww", -"wwwww1q01719176176667167qqqq7www", -"wwwww7q949617116016161qq979916ww", -"wwwww1q94661-761-1@6@q9q4771716w", -"wwwwww499116#@101#@#946$614616#w", -"wwwwwww671#@#@>#@##11@6166666$#w", -"www71717616#>,q, 6@6##@15$11@#>w", -"w1790997616,q7,, #@#@##@#6@##1ww", -"7q971711##>q6>,X#11611@,#@#>,www", -"1q9096@6@#.,,. #@#=1666#,>,wwwww", -"1q71711#@#-;X7#@#@#1611#>wwwwwww", -"1711@##777#67#@##6$6171@,***wwww", -"#66##q71##@710@1@166166#>++%**ww", -">#@#976@1#17961#6#$791#,*%%+++;w", -"w>6q97@6@#q9166$11776@>+o*;%%+:;", -"w1q0614@1#q096<67191#;:+*+%o++%;", -"w7q946616@q68909901@;,w;+o+%%++:", -"w1q963161#@064116@#,%;;w:O++;:;w", -"ww#70616@>,#@####>,w%&,ww;::;www", -"ww,@##@#,ww>,>,>,wwww%*>wwwwwwww", -"www,>,>,wwwwwwwwwwwwww%2wwwwwwww", -"wwwwwwwwwwwwwwwwwwwwww%*2wwwwwww", -"wwwwwwwwwwwwwwwwwwwwwww%:wwwwwww", -"wwwwwwwwwwwwwwwwwwwwwww%*2wwwwww", -"wwwwwwwwwwwwwwwwwwwwwwww>:wwwwww" -}; diff --git a/debian/kuickshow-kde3.install b/debian/kuickshow-kde3.install deleted file mode 100644 index b6c9d60..0000000 --- a/debian/kuickshow-kde3.install +++ /dev/null @@ -1,2 +0,0 @@ -debian/icons/kuickshow.xpm /opt/kde3/share/pixmaps -debian/icons/kuickshow-16.xpm /opt/kde3/share/pixmaps diff --git a/debian/kuickshow-kde3.lintian b/debian/kuickshow-kde3.lintian deleted file mode 100644 index 40ef27b..0000000 --- a/debian/kuickshow-kde3.lintian +++ /dev/null @@ -1,4 +0,0 @@ -kuickshow-kde3: no-shlibs-control-file opt/kde3/lib/libkdeinit_kuickshow.so -kuickshow-kde3: postinst-must-call-ldconfig opt/kde3/lib/libkdeinit_kuickshow.so -kuickshow-kde3: postrm-should-call-ldconfig opt/kde3/lib/libkdeinit_kuickshow.so -kuickshow-kde3: package-name-doesnt-match-sonames libkdeinit-kuickshow diff --git a/debian/kuickshow-kde3.manpages b/debian/kuickshow-kde3.manpages deleted file mode 100644 index 3eadda9..0000000 --- a/debian/kuickshow-kde3.manpages +++ /dev/null @@ -1 +0,0 @@ -debian/man/kuickshow.1 diff --git a/debian/kuickshow-kde3.menu b/debian/kuickshow-kde3.menu deleted file mode 100644 index 430e432..0000000 --- a/debian/kuickshow-kde3.menu +++ /dev/null @@ -1,11 +0,0 @@ -?package(kuickshow):\ - needs="X11"\ - section="Apps/Graphics"\ - hints="KDE"\ - title="Kuickshow"\ - icon32x32="/usr/share/pixmaps/kuickshow.xpm"\ - icon16x16="/usr/share/pixmaps/kuickshow-16.xpm"\ - command="/opt/kde3/bin/kuickshow" - -# Icon 32x32 kuickshow/src/cr32-app-kuickshow.png kuickshow.xpm -# Icon 16x16 kuickshow/src/cr16-app-kuickshow.png kuickshow-16.xpm diff --git a/debian/man/kuickshow.1 b/debian/man/kuickshow.1 deleted file mode 100644 index 2675eae..0000000 --- a/debian/man/kuickshow.1 +++ /dev/null @@ -1,99 +0,0 @@ -.TH KUICKSHOW "1" "September 2002" KDE "KDE Application" -.SH NAME -kuickshow \- KDE Image Viewer -.SH SYNOPSIS -.B kuickshow -[\fIQt-options\fR] [\fIKDE-options\fR] [\fIoptions\fR] [\fIfiles\fR] -.SH DESCRIPTION -This manual page documents briefly the -.B Kuickshow -KDE Application. -This manual page was written for the Debian GNU/Linux distribution -because the original program does not have a manual page. -.P -.B KuickShow -is a comfortable image browser/viewer. It displays a -filebrowser where you can select images which are then shown. -.P -The following image formats are supported: -.P -.RS -\(bu jpg -.br -\(bu gif -.br -\(bu tiff -.br -\(bu png -.br -\(bu bmp -.br -\(bu psd -.br -\(bu xmp -.br -\(bu xbm -.br -\(bu eim -.RE -.P -Images can be displayed either in their own window, as large as the -image, or fullscreen. -.P -This program is part of the official KDE graphics module. -.SS "Generic options:" -.TP -\fB\-\-help\fR -Show help about options -.TP -\fB\-\-help\-qt\fR -Show Qt specific options -.TP -\fB\-\-help\-kde\fR -Show KDE specific options -.TP -\fB\-\-help\-all\fR -Show all options -.TP -\fB\-\-author\fR -Show author information -.TP -\fB\-v\fR, \fB\-\-version\fR -Show version information -.TP -\fB\-\-license\fR -Show license information -.TP -\fB\-\-\fR -End of options -.SH OPTIONS -.TP -\fB\-\-lastdir\fR -Start in the last visited directory, not the current working directory -.SS "Arguments:" -.TP -files -Optional image filenames/urls to show -.SH "SEE ALSO" -The full documentation for -.B Kuickshow -is maintained as a docbook manual. If the -.B khelpcenter -program is properly installed at your site, the command -.IP -.B khelpcenter help:/kuickshow -.PP -should give you access to the complete manual. -.SH AUTHOR -KuickShow was written by -.nh -Carsten Pfeiffer <[email protected]>. -.hy -.br -Please use http://bugs.kde.org to report bugs, do not mail the authors directly. -.br -This manual page was prepared by -.nh -Karolina Lindqvist <pgd\[email protected]> -.hy -for the Debian GNU/Linux system (but may be used by others). diff --git a/debian/rules b/debian/rules deleted file mode 100755 index 8c14ff2..0000000 --- a/debian/rules +++ /dev/null @@ -1,15 +0,0 @@ -#! /usr/bin/make -f - -include /usr/share/cdbs/1/rules/debhelper.mk -include debian/cdbs/debian-qt-kde.mk -include /usr/share/cdbs/1/rules/simple-patchsys.mk -include /usr/share/cdbs/1/rules/utils.mk - -DEB_CONFIGURE_INCLUDEDIR := /opt/kde3/include/kde -DEB_CONFIGURE_MANDIR := /opt/kde3/share/man -DEB_CONFIGURE_PREFIX := /opt/kde3 -DEB_CONFIGURE_INFODIR := /opt/kde3/share/info - -cdbs_configure_flags := --with-qt-dir=/usr/share/qt3 --disable-rpath --with-xinerama $(cdbs_kde_enable_final) $(cdbs_kde_enable_debug) - -DEB_CONFIGURE_EXTRA_FLAGS := --prefix=/opt/kde3 --with-extra-libs=/opt/kde3/lib --with-extra-includes=/opt/kde3/include/kde diff --git a/kuickshow/src/aboutwidget.cpp b/kuickshow/src/aboutwidget.cpp index 2ae4110..f65b522 100644 --- a/kuickshow/src/aboutwidget.cpp +++ b/kuickshow/src/aboutwidget.cpp @@ -16,11 +16,11 @@ Boston, MA 02110-1301, USA. */ -#include <qdatetime.h> -#include <qevent.h> -#include <qglobal.h> -#include <qgroupbox.h> -#include <qlabel.h> +#include <tqdatetime.h> +#include <tqevent.h> +#include <tqglobal.h> +#include <tqgroupbox.h> +#include <tqlabel.h> #include <kwin.h> #include <kstandarddirs.h> @@ -31,40 +31,40 @@ #include "aboutwidget.h" -AboutWidget::AboutWidget( QWidget *parent, const char *name ) - : QVBox( parent, name, Qt::WShowModal ) +AboutWidget::AboutWidget( TQWidget *tqparent, const char *name ) + : TQVBox( tqparent, name, TQt::WShowModal ) { KWin::setType( winId(), NET::Override ); KWin::setState( winId(), NET::SkipTaskbar ); setFrameStyle( WinPanel | Raised ); - QGroupBox *gBox = new QGroupBox( 1, Horizontal, this); + TQGroupBox *gBox = new TQGroupBox( 1,Qt::Horizontal, this); gBox->setGeometry( 10, 10, width()-20, height()-20 ); - gBox->setAlignment( AlignHCenter ); + gBox->tqsetAlignment( AlignHCenter ); gBox->installEventFilter( this ); - gBox->setPalette( QPalette( QColor( white ) ) ); + gBox->setPalette( TQPalette( TQColor( white ) ) ); gBox->setBackgroundMode( PaletteBackground ); - int hour = QTime::currentTime().hour(); - QString file; + int hour = TQTime::currentTime().hour(); + TQString file; if ( hour >= 10 && hour < 16 ) file = locate("appdata", "pics/kuickshow-day.jpg"); else file = locate("appdata", "pics/kuickshow-night.jpg"); - QLabel *authors = new QLabel("Kuickshow " KUICKSHOWVERSION + TQLabel *authors = new TQLabel("Kuickshow " KUICKSHOWVERSION " was brought to you by", gBox); - authors->setAlignment( AlignCenter ); + authors->tqsetAlignment( AlignCenter ); m_homepage = new KURLWidget("Carsten Pfeiffer", gBox); m_homepage->setURL( "http://devel-home.kde.org/~pfeiffer/kuickshow/" ); - m_homepage->setAlignment( AlignCenter ); + m_homepage->tqsetAlignment( AlignCenter ); - QLabel *copy = new QLabel("(C) 1998-2006", gBox); - copy->setAlignment( AlignCenter ); + TQLabel *copy = new TQLabel("(C) 1998-2006", gBox); + copy->tqsetAlignment( AlignCenter ); ImlibWidget *im = new ImlibWidget( 0L, gBox, "KuickShow Logo" ); if ( im->loadImage( file ) ) @@ -80,16 +80,16 @@ AboutWidget::~AboutWidget() { } -bool AboutWidget::eventFilter( QObject *o, QEvent *e ) +bool AboutWidget::eventFilter( TQObject *o, TQEvent *e ) { - if ( e->type() == QEvent::MouseButtonPress ) { - QMouseEvent *ev = static_cast<QMouseEvent*>( e ); - if ( !m_homepage->geometry().contains( ev->pos() ) ) { + if ( e->type() == TQEvent::MouseButtonPress ) { + TQMouseEvent *ev = TQT_TQMOUSEEVENT( e ); + if ( !m_homepage->tqgeometry().tqcontains( ev->pos() ) ) { deleteLater(); return true; } } - return QVBox::eventFilter( o, e ); + return TQVBox::eventFilter( o, e ); } #include "aboutwidget.moc" diff --git a/kuickshow/src/aboutwidget.h b/kuickshow/src/aboutwidget.h index b9bc79d..c3bd487 100644 --- a/kuickshow/src/aboutwidget.h +++ b/kuickshow/src/aboutwidget.h @@ -19,21 +19,22 @@ #ifndef ABOUTWIDGET_H #define ABOUTWIDGET_H -#include <qevent.h> -#include <qvbox.h> +#include <tqevent.h> +#include <tqvbox.h> class KURLWidget; -class AboutWidget : public QVBox +class AboutWidget : public TQVBox { Q_OBJECT + TQ_OBJECT public: - AboutWidget(QWidget *parent = 0, const char *name = 0); + AboutWidget(TQWidget *tqparent = 0, const char *name = 0); protected: ~AboutWidget(); - bool eventFilter( QObject*, QEvent * ); + bool eventFilter( TQObject*, TQEvent * ); private: KURLWidget *m_homepage; diff --git a/kuickshow/src/defaultswidget.cpp b/kuickshow/src/defaultswidget.cpp index 6980725..c059678 100644 --- a/kuickshow/src/defaultswidget.cpp +++ b/kuickshow/src/defaultswidget.cpp @@ -16,11 +16,11 @@ Boston, MA 02110-1301, USA. */ -#include <qcheckbox.h> -#include <qgroupbox.h> -#include <qlabel.h> -#include <qlayout.h> -#include <qvgroupbox.h> +#include <tqcheckbox.h> +#include <tqgroupbox.h> +#include <tqlabel.h> +#include <tqlayout.h> +#include <tqvgroupbox.h> #include <kcombobox.h> #include <kdialog.h> @@ -31,40 +31,40 @@ #include "imlibwidget.h" #include "defaultswidget.h" -DefaultsWidget::DefaultsWidget( QWidget *parent, const char *name) - : QWidget( parent, name ) +DefaultsWidget::DefaultsWidget( TQWidget *tqparent, const char *name) + : TQWidget( tqparent, name ) { imFiltered = 0L; - cbEnableMods = new QCheckBox( i18n("Apply default image modifications"), this ); - connect( cbEnableMods, SIGNAL( toggled(bool) ), SLOT( enableWidgets(bool) )); + cbEnableMods = new TQCheckBox( i18n("Apply default image modifications"), this ); + connect( cbEnableMods, TQT_SIGNAL( toggled(bool) ), TQT_SLOT( enableWidgets(bool) )); // create all the widgets - gbScale = new QGroupBox( i18n("Scaling"), this ); + gbScale = new TQGroupBox( i18n("Scaling"), this ); gbScale->setColumnLayout( 0, Qt::Horizontal ); - cbDownScale = new QCheckBox( i18n("Shrink image to screen size, if larger"), + cbDownScale = new TQCheckBox( i18n("Shrink image to screen size, if larger"), gbScale, "shrinktoscreen" ); - cbUpScale = new QCheckBox( i18n("Scale image to screen size, if smaller, up to factor:"), gbScale, "upscale checkbox" ); + cbUpScale = new TQCheckBox( i18n("Scale image to screen size, if smaller, up to factor:"), gbScale, "upscale checkbox" ); sbMaxUpScaleFactor = new KIntNumInput( gbScale, "upscale factor" ); sbMaxUpScaleFactor->setRange( 1, 100, 1, false ); - connect(cbUpScale, SIGNAL( toggled(bool)), sbMaxUpScaleFactor, - SLOT( setEnabled(bool) )); + connect(cbUpScale, TQT_SIGNAL( toggled(bool)), sbMaxUpScaleFactor, + TQT_SLOT( setEnabled(bool) )); // -- - gbGeometry = new QGroupBox( i18n("Geometry"), this ); + gbGeometry = new TQGroupBox( i18n("Geometry"), this ); gbGeometry->setColumnLayout( 0, Qt::Horizontal ); - cbFlipVertically = new QCheckBox( i18n("Flip vertically"), gbGeometry ); + cbFlipVertically = new TQCheckBox( i18n("Flip vertically"), gbGeometry ); - cbFlipHorizontally = new QCheckBox( i18n("Flip horizontally"), gbGeometry ); + cbFlipHorizontally = new TQCheckBox( i18n("Flip horizontally"), gbGeometry ); - lbRotate = new QLabel( i18n("Rotate image:"), gbGeometry ); + lbRotate = new TQLabel( i18n("Rotate image:"), gbGeometry ); comboRotate = new KComboBox( gbGeometry, "rotate combobox" ); comboRotate->insertItem( i18n("0 Degrees") ); @@ -74,7 +74,7 @@ DefaultsWidget::DefaultsWidget( QWidget *parent, const char *name) // -- - gbAdjust = new QVGroupBox( i18n("Adjustments"), this ); + gbAdjust = new TQVGroupBox( i18n("Adjustments"), this ); sbBrightness = new KIntNumInput( gbAdjust, "brightness spinbox" ); sbBrightness->setRange( -256, 256, 1, true ); @@ -91,37 +91,37 @@ DefaultsWidget::DefaultsWidget( QWidget *parent, const char *name) // -- - gbPreview = new QGroupBox( i18n("Preview"), this ); - gbPreview->setAlignment( AlignCenter ); + gbPreview = new TQGroupBox( i18n("Preview"), this ); + gbPreview->tqsetAlignment( AlignCenter ); - lbImOrig = new QLabel( i18n("Original"), gbPreview ); + lbImOrig = new TQLabel( i18n("Original"), gbPreview ); imOrig = new ImlibWidget( 0L, gbPreview, "original image" ); - lbImFiltered = new QLabel( i18n("Modified"), gbPreview ); + lbImFiltered = new TQLabel( i18n("Modified"), gbPreview ); imFiltered = new ImlibWidget( 0L, imOrig->getImlibData(), gbPreview, "" ); - connect( imFiltered, SIGNAL( destroyed() ), SLOT( slotNoImage() )); + connect( imFiltered, TQT_SIGNAL( destroyed() ), TQT_SLOT( slotNoImage() )); //// //////////////// - // layout management - QVBoxLayout *mainLayout = new QVBoxLayout( this, 0, - KDialog::spacingHint(), "main layout" ); + // tqlayout management + TQVBoxLayout *mainLayout = new TQVBoxLayout( this, 0, + KDialog::spacingHint(), "main tqlayout" ); - QVBoxLayout *gbScaleLayout = new QVBoxLayout( gbScale->layout(), + TQVBoxLayout *gbScaleLayout = new TQVBoxLayout( gbScale->tqlayout(), KDialog::spacingHint()); - QVBoxLayout *gbGeometryLayout = new QVBoxLayout(gbGeometry->layout(), + TQVBoxLayout *gbGeometryLayout = new TQVBoxLayout(gbGeometry->tqlayout(), KDialog::spacingHint()); - QGridLayout *gbPreviewLayout = new QGridLayout(gbPreview, 2, 3, 0, + TQGridLayout *gbPreviewLayout = new TQGridLayout(gbPreview, 2, 3, 0, KDialog::spacingHint()); - QHBoxLayout *scaleLayout = new QHBoxLayout(); - QHBoxLayout *rotateLayout = new QHBoxLayout(); + TQHBoxLayout *scaleLayout = new TQHBoxLayout(); + TQHBoxLayout *rotateLayout = new TQHBoxLayout(); mainLayout->addWidget( cbEnableMods ); mainLayout->addWidget( gbScale ); - QHBoxLayout *hl = new QHBoxLayout(); + TQHBoxLayout *hl = new TQHBoxLayout(); hl->addWidget( gbGeometry ); hl->addWidget( gbAdjust ); mainLayout->addLayout( hl ); @@ -159,19 +159,19 @@ DefaultsWidget::DefaultsWidget( QWidget *parent, const char *name) //////////////// // connect them all to the update slot - connect( cbDownScale, SIGNAL( clicked() ), SLOT( updatePreview() )); - connect( cbUpScale, SIGNAL( clicked() ), SLOT( updatePreview() )); - connect( cbFlipVertically, SIGNAL( clicked() ), SLOT( updatePreview() )); - connect( cbFlipHorizontally, SIGNAL( clicked() ), SLOT( updatePreview() )); - connect( sbMaxUpScaleFactor, SIGNAL( valueChanged(int) ), SLOT( updatePreview() )); - connect( sbBrightness, SIGNAL( valueChanged(int) ), SLOT( updatePreview() )); - connect( sbContrast, SIGNAL( valueChanged(int) ), SLOT( updatePreview() )); - connect( sbGamma, SIGNAL( valueChanged(int) ), SLOT( updatePreview() )); + connect( cbDownScale, TQT_SIGNAL( clicked() ), TQT_SLOT( updatePreview() )); + connect( cbUpScale, TQT_SIGNAL( clicked() ), TQT_SLOT( updatePreview() )); + connect( cbFlipVertically, TQT_SIGNAL( clicked() ), TQT_SLOT( updatePreview() )); + connect( cbFlipHorizontally, TQT_SIGNAL( clicked() ), TQT_SLOT( updatePreview() )); + connect( sbMaxUpScaleFactor, TQT_SIGNAL( valueChanged(int) ), TQT_SLOT( updatePreview() )); + connect( sbBrightness, TQT_SIGNAL( valueChanged(int) ), TQT_SLOT( updatePreview() )); + connect( sbContrast, TQT_SIGNAL( valueChanged(int) ), TQT_SLOT( updatePreview() )); + connect( sbGamma, TQT_SIGNAL( valueChanged(int) ), TQT_SLOT( updatePreview() )); - connect( comboRotate, SIGNAL( activated(int) ), SLOT( updatePreview() )); + connect( comboRotate, TQT_SIGNAL( activated(int) ), TQT_SLOT( updatePreview() )); - QString filename = locate( "data", "kuickshow/pics/calibrate.png" ); + TQString filename = locate( "data", "kuickshow/pics/calibrate.png" ); if ( !imOrig->loadImage( filename ) ) imOrig = 0L; // FIXME - display some errormessage! if ( !imFiltered->loadImage( filename ) ) diff --git a/kuickshow/src/defaultswidget.h b/kuickshow/src/defaultswidget.h index 3febb09..c9f74b6 100644 --- a/kuickshow/src/defaultswidget.h +++ b/kuickshow/src/defaultswidget.h @@ -24,18 +24,19 @@ class ImlibWidget; class ImData; -class QCheckBox; -class QLabel; +class TQCheckBox; +class TQLabel; class KComboBox; class KIntNumInput; -class DefaultsWidget : public QWidget +class DefaultsWidget : public TQWidget { Q_OBJECT + TQ_OBJECT public: - DefaultsWidget( QWidget *parent, const char *name ); + DefaultsWidget( TQWidget *tqparent, const char *name ); ~DefaultsWidget(); void loadSettings( const KuickData& data ); @@ -44,22 +45,22 @@ public: private: Rotation currentRotation() const; - QCheckBox *cbEnableMods; + TQCheckBox *cbEnableMods; - QGroupBox *gbScale; - QCheckBox *cbUpScale, *cbDownScale; + TQGroupBox *gbScale; + TQCheckBox *cbUpScale, *cbDownScale; KIntNumInput *sbMaxUpScaleFactor; - QGroupBox *gbAdjust; + TQGroupBox *gbAdjust; KIntNumInput *sbBrightness, *sbContrast, *sbGamma; - QGroupBox *gbGeometry; - QLabel *lbRotate; + TQGroupBox *gbGeometry; + TQLabel *lbRotate; KComboBox *comboRotate; - QCheckBox *cbFlipVertically, *cbFlipHorizontally; + TQCheckBox *cbFlipVertically, *cbFlipHorizontally; - QGroupBox *gbPreview; - QLabel *lbImOrig, *lbImFiltered; + TQGroupBox *gbPreview; + TQLabel *lbImOrig, *lbImFiltered; ImlibWidget *imOrig, *imFiltered; diff --git a/kuickshow/src/filecache.cpp b/kuickshow/src/filecache.cpp index c1c1aff..5440363 100644 --- a/kuickshow/src/filecache.cpp +++ b/kuickshow/src/filecache.cpp @@ -1,6 +1,6 @@ #include <unistd.h> -#include <qstring.h> +#include <tqstring.h> #include <kdebug.h> #include <kstandarddirs.h> @@ -41,8 +41,8 @@ FileCache * FileCache::self() KuickFile * FileCache::getFile( const KURL& url ) { - QString urlString = url.prettyURL(); - KuickFile *file = m_files.find( urlString ); + TQString urlString = url.prettyURL(); + KuickFile *file = m_files.tqfind( urlString ); if ( !file ) { file = new KuickFile( url ); m_files.insert( urlString, file ); @@ -51,14 +51,14 @@ KuickFile * FileCache::getFile( const KURL& url ) return file; } -QString FileCache::tempDir() +TQString FileCache::tempDir() { if ( !m_tempDir ) { m_tempDir = createTempDir(); if ( !m_tempDir ) { kdWarning() << "Unable to create temporary directory for KuickShow" << endl; - return QString::null; + return TQString(); } } @@ -68,9 +68,9 @@ QString FileCache::tempDir() KTempDir * FileCache::createTempDir() { - QString tmpName = QString::fromLatin1( KGlobal::instance()->instanceName() ); - tmpName.append( QString::number( getpid() ) ); - QString dirName = locateLocal( "tmp", tmpName ); + TQString tmpName = TQString::tqfromLatin1( KGlobal::instance()->instanceName() ); + tmpName.append( TQString::number( getpid() ) ); + TQString dirName = locateLocal( "tmp", tmpName ); KTempDir *dir = new KTempDir( dirName ); dir->setAutoDelete( true ); if ( dir->status() != 0L ) diff --git a/kuickshow/src/filecache.h b/kuickshow/src/filecache.h index 16e5326..2152b5f 100644 --- a/kuickshow/src/filecache.h +++ b/kuickshow/src/filecache.h @@ -10,7 +10,7 @@ #ifndef FILECACHE_H #define FILECACHE_H -#include <qcache.h> +#include <tqcache.h> #include "kuickfile.h" @@ -27,9 +27,9 @@ public: int getLimit() const { return m_limit; } /** - * @return the temporary directory or QString::null if none available + * @return the temporary directory or TQString() if none available */ - QString tempDir(); + TQString tempDir(); private: static FileCache *s_self; @@ -37,7 +37,7 @@ private: ~FileCache(); KTempDir * createTempDir(); - QCache<KuickFile> m_files; + TQCache<KuickFile> m_files; int m_limit; KTempDir *m_tempDir; diff --git a/kuickshow/src/filefinder.cpp b/kuickshow/src/filefinder.cpp index dda5e51..eeb7895 100644 --- a/kuickshow/src/filefinder.cpp +++ b/kuickshow/src/filefinder.cpp @@ -16,7 +16,7 @@ Boston, MA 02110-1301, USA. */ -#include <qkeycode.h> +#include <tqkeycode.h> #include <kapplication.h> #include <kconfig.h> @@ -26,8 +26,8 @@ #include "filefinder.h" -FileFinder::FileFinder( QWidget *parent, const char *name ) - : KLineEdit( parent, name ) +FileFinder::FileFinder( TQWidget *tqparent, const char *name ) + : KLineEdit( tqparent, name ) { // make this widget just as large, as the font is + 8 Pixels int height = fontMetrics().height() + 8; @@ -38,19 +38,19 @@ FileFinder::FileFinder( QWidget *parent, const char *name ) #if KDE_VERSION >= 220 completionBox()->setTabHandling( true ); #endif - connect( completionBox(), SIGNAL( userCancelled(const QString&) ), - SLOT( hide() )); - connect( completionBox(), SIGNAL( activated( const QString& ) ), - SLOT( slotAccept( const QString& ))); - connect( this, SIGNAL( returnPressed( const QString& )), - SLOT( slotAccept( const QString& ) )); + connect( completionBox(), TQT_SIGNAL( userCancelled(const TQString&) ), + TQT_SLOT( hide() )); + connect( completionBox(), TQT_SIGNAL( activated( const TQString& ) ), + TQT_SLOT( slotAccept( const TQString& ))); + connect( this, TQT_SIGNAL( returnPressed( const TQString& )), + TQT_SLOT( slotAccept( const TQString& ) )); KURLCompletion *comp = new KURLCompletion(); comp->setReplaceHome( true ); comp->setReplaceEnv( true ); setCompletionObject( comp, false ); setAutoDeleteCompletionObject( true ); - setFocusPolicy( ClickFocus ); + setFocusPolicy( TQ_ClickFocus ); KConfig *config = KGlobal::config(); KConfigGroupSaver cs( config, "GeneralConfiguration" ); @@ -66,13 +66,13 @@ FileFinder::~FileFinder() config->writeEntry( "FileFinderCompletionMode", completionMode() ); } -void FileFinder::focusOutEvent( QFocusEvent *e ) +void FileFinder::focusOutEvent( TQFocusEvent *e ) { - if ( e->reason() != QFocusEvent::Popup ) + if ( e->reason() != TQFocusEvent::Popup ) hide(); } -void FileFinder::keyPressEvent( QKeyEvent *e ) +void FileFinder::keyPressEvent( TQKeyEvent *e ) { int key = e->key(); if ( key == Key_Escape ) { @@ -88,10 +88,10 @@ void FileFinder::keyPressEvent( QKeyEvent *e ) void FileFinder::hide() { KLineEdit::hide(); - parentWidget()->setFocus(); + tqparentWidget()->setFocus(); } -void FileFinder::slotAccept( const QString& dir ) +void FileFinder::slotAccept( const TQString& dir ) { hide(); emit enterDir( dir ); diff --git a/kuickshow/src/filefinder.h b/kuickshow/src/filefinder.h index f75c69a..3ec7679 100644 --- a/kuickshow/src/filefinder.h +++ b/kuickshow/src/filefinder.h @@ -19,7 +19,7 @@ #ifndef FILEFINDER_H #define FILEFINDER_H -#include <qevent.h> +#include <tqevent.h> #include <klineedit.h> @@ -28,9 +28,10 @@ class KURLCompletion; class FileFinder : public KLineEdit { Q_OBJECT + TQ_OBJECT public: - FileFinder( QWidget *parent=0, const char *name=0 ); + FileFinder( TQWidget *tqparent=0, const char *name=0 ); ~FileFinder(); KURLCompletion *completion() { @@ -40,14 +41,14 @@ public: virtual void hide(); signals: - void enterDir( const QString& ); + void enterDir( const TQString& ); protected: - virtual void focusOutEvent( QFocusEvent * ); - virtual void keyPressEvent( QKeyEvent * ); + virtual void focusOutEvent( TQFocusEvent * ); + virtual void keyPressEvent( TQKeyEvent * ); private slots: - void slotAccept( const QString& ); + void slotAccept( const TQString& ); }; diff --git a/kuickshow/src/filewidget.cpp b/kuickshow/src/filewidget.cpp index d4b99f0..1828489 100644 --- a/kuickshow/src/filewidget.cpp +++ b/kuickshow/src/filewidget.cpp @@ -16,7 +16,7 @@ Boston, MA 02110-1301, USA. */ -#include <qkeycode.h> +#include <tqkeycode.h> #include <kdeversion.h> #include <kglobal.h> @@ -35,8 +35,8 @@ #undef KeyPress #endif -FileWidget::FileWidget( const KURL& url, QWidget *parent, const char *name ) - : KDirOperator( url, parent, name ), +FileWidget::FileWidget( const KURL& url, TQWidget *tqparent, const char *name ) + : KDirOperator( url, tqparent, name ), m_validCompletion( false ), m_fileFinder( 0L ) { @@ -55,21 +55,21 @@ FileWidget::FileWidget( const KURL& url, QWidget *parent, const char *name ) dirCompletionObject()->setCompletionMode( KGlobalSettings::CompletionAuto); slotViewChanged(); - connect( this, SIGNAL( viewChanged( KFileView * )), - SLOT( slotViewChanged() )); + connect( this, TQT_SIGNAL( viewChanged( KFileView * )), + TQT_SLOT( slotViewChanged() )); - connect( dirLister(), SIGNAL( clear() ), SLOT( slotItemsCleared() )); - connect( dirLister(), SIGNAL( deleteItem( KFileItem * ) ), - SLOT( slotItemDeleted( KFileItem *) )); + connect( dirLister(), TQT_SIGNAL( clear() ), TQT_SLOT( slotItemsCleared() )); + connect( dirLister(), TQT_SIGNAL( deleteItem( KFileItem * ) ), + TQT_SLOT( slotItemDeleted( KFileItem *) )); - connect( this, SIGNAL( fileHighlighted( const KFileItem * )), - SLOT( slotHighlighted( const KFileItem * ))); + connect( this, TQT_SIGNAL( fileHighlighted( const KFileItem * )), + TQT_SLOT( slotHighlighted( const KFileItem * ))); - connect( this, SIGNAL(urlEntered(const KURL&)), - SLOT( slotURLEntered( const KURL& ))); + connect( this, TQT_SIGNAL(urlEntered(const KURL&)), + TQT_SLOT( slotURLEntered( const KURL& ))); // should actually be KDirOperator's job! - connect( this, SIGNAL( finishedLoading() ), SLOT( slotFinishedLoading() )); + connect( this, TQT_SIGNAL( finishedLoading() ), TQT_SLOT( slotFinishedLoading() )); } FileWidget::~FileWidget() @@ -97,9 +97,9 @@ void FileWidget::initActions() // so we move it to the real bottom menu->remove( coll->action( "properties" ) ); - QPopupMenu *pMenu = menu->popupMenu(); + TQPopupMenu *pMenu = menu->popupMenu(); int lastItemId = pMenu->idAt( pMenu->count() - 1 ); - QMenuItem *mItem = pMenu->findItem( lastItemId ); + TQMenuItem *mItem = pMenu->tqfindItem( lastItemId ); if ( mItem && !mItem->isSeparator() ) menu->insert( sep ); @@ -113,7 +113,7 @@ void FileWidget::reloadConfiguration() { if ( kdata->fileFilter != nameFilter() ) { // At first, our list must have folders - QStringList mimes; + TQStringList mimes; mimes.append("inode/directory"); // Then, all the images! @@ -133,7 +133,7 @@ bool FileWidget::hasFiles() const return (numFiles() > 0); } -void FileWidget::activatedMenu( const KFileItem *item, const QPoint& pos ) +void FileWidget::activatedMenu( const KFileItem *item, const TQPoint& pos ) { bool image = isImage( item ); actionCollection()->action("kuick_showInSameWindow")->setEnabled( image ); @@ -149,11 +149,11 @@ void FileWidget::activatedMenu( const KFileItem *item, const QPoint& pos ) KDirOperator::activatedMenu( item, pos ); } -void FileWidget::findCompletion( const QString& text ) +void FileWidget::findCompletion( const TQString& text ) { if ( text.at(0) == '/' || text.at(0) == '~' || - text.find('/') != -1 ) { - QString t = m_fileFinder->completion()->makeCompletion( text ); + text.tqfind('/') != -1 ) { + TQString t = m_fileFinder->completion()->makeCompletion( text ); if (m_fileFinder->completionMode() == KGlobalSettings::CompletionPopup || m_fileFinder->completionMode() == KGlobalSettings::CompletionPopupAuto) @@ -166,7 +166,7 @@ void FileWidget::findCompletion( const QString& text ) return; } - QString file = makeDirCompletion( text ); + TQString file = makeDirCompletion( text ); if ( file.isNull() ) file = makeCompletion( text ); @@ -176,10 +176,10 @@ void FileWidget::findCompletion( const QString& text ) KDirOperator::setCurrentItem( file ); } -bool FileWidget::eventFilter( QObject *o, QEvent *e ) +bool FileWidget::eventFilter( TQObject *o, TQEvent *e ) { - if ( e->type() == QEvent::KeyPress ) { - QKeyEvent *k = static_cast<QKeyEvent*>( e ); + if ( e->type() == TQEvent::KeyPress ) { + TQKeyEvent *k = TQT_TQKEYEVENT( e ); if ( (k->state() & (ControlButton | AltButton)) == 0 ) { int key = k->key(); @@ -195,17 +195,17 @@ bool FileWidget::eventFilter( QObject *o, QEvent *e ) return true; } - const QString& text = k->text(); - if ( !text.isEmpty() && text.unicode()->isPrint() ) { + const TQString& text = k->text(); + if ( !text.isEmpty() && text.tqunicode()->isPrint() ) { k->accept(); if ( !m_fileFinder ) { m_fileFinder = new FileFinder( this, "file finder" ); - connect( m_fileFinder, SIGNAL( completion(const QString&)), - SLOT( findCompletion( const QString& ))); + connect( m_fileFinder, TQT_SIGNAL( completion(const TQString&)), + TQT_SLOT( findCompletion( const TQString& ))); connect( m_fileFinder, - SIGNAL( enterDir( const QString& ) ), - SLOT( slotReturnPressed( const QString& ))); + TQT_SIGNAL( enterDir( const TQString& ) ), + TQT_SLOT( slotReturnPressed( const TQString& ))); m_fileFinder->move( width() - m_fileFinder->width(), height() - m_fileFinder->height() ); } @@ -360,7 +360,7 @@ void FileWidget::slotViewChanged() void FileWidget::slotItemsCleared() { - m_currentURL = QString::null; + m_currentURL = TQString(); } void FileWidget::slotItemDeleted( KFileItem *item ) @@ -383,24 +383,24 @@ void FileWidget::slotHighlighted( const KFileItem *item ) m_currentURL = item->url().url(); } -void FileWidget::slotReturnPressed( const QString& t ) +void FileWidget::slotReturnPressed( const TQString& t ) { // we need a / at the end, otherwise replacedPath() will cut off the dir, // assuming it is a filename - QString text = t; + TQString text = t; if ( text.at( text.length()-1 ) != '/' ) text += '/'; if ( text.at(0) == '/' || text.at(0) == '~' ) { - QString dir = m_fileFinder->completion()->replacedPath( text ); + TQString dir = m_fileFinder->completion()->replacedPath( text ); KURL url; url.setPath( dir ); setURL( url, true ); } - else if ( text.find('/') != (int) text.length() -1 ) { // relative path - QString dir = m_fileFinder->completion()->replacedPath( text ); + else if ( text.tqfind('/') != (int) text.length() -1 ) { // relative path + TQString dir = m_fileFinder->completion()->replacedPath( text ); KURL u( url(), dir ); setURL( u, true ); } @@ -425,7 +425,7 @@ void FileWidget::setCurrentItem( const KFileItem *item ) } } -void FileWidget::setInitialItem( const QString& filename ) +void FileWidget::setInitialItem( const TQString& filename ) { m_initialName = filename; } @@ -444,16 +444,16 @@ void FileWidget::slotFinishedLoading() else if ( !current ) setCurrentItem( view()->items()->getFirst() ); - m_initialName = QString::null; + m_initialName = TQString(); emit finished(); } -QSize FileWidget::sizeHint() const +TQSize FileWidget::tqsizeHint() const { - return QSize( 300, 300 ); + return TQSize( 300, 300 ); } -void FileWidget::resizeEvent( QResizeEvent *e ) +void FileWidget::resizeEvent( TQResizeEvent *e ) { KDirOperator::resizeEvent( e ); if ( m_fileFinder ) diff --git a/kuickshow/src/filewidget.h b/kuickshow/src/filewidget.h index a785fd8..8591f9b 100644 --- a/kuickshow/src/filewidget.h +++ b/kuickshow/src/filewidget.h @@ -19,7 +19,7 @@ #ifndef FILEWIDGET_H #define FILEWIDGET_H -#include <qevent.h> +#include <tqevent.h> #include <kdiroperator.h> @@ -29,24 +29,25 @@ class KFileItem; class FileWidget : public KDirOperator { Q_OBJECT + TQ_OBJECT public: enum WhichItem { Previous, Next, Current }; - FileWidget( const KURL& url, QWidget *parent = 0L, const char *name = 0L ); + FileWidget( const KURL& url, TQWidget *tqparent = 0L, const char *name = 0L ); ~FileWidget(); bool hasFiles() const; void reloadConfiguration(); - void setInitialItem( const QString& filename ); + void setInitialItem( const TQString& filename ); KFileItem *getCurrentItem( bool onlyImage ) const { return getItem( Current, onlyImage ); } void setCurrentItem( const KFileItem * ); - void setCurrentItem( const QString& filename ) { + void setCurrentItem( const TQString& filename ) { KDirOperator::setCurrentItem( filename ); } @@ -67,14 +68,14 @@ signals: void finished(); protected: - virtual bool eventFilter( QObject *o, QEvent * ); - virtual void resizeEvent( QResizeEvent * ); - virtual void activatedMenu( const KFileItem *, const QPoint& ); - virtual QSize sizeHint() const; + virtual bool eventFilter( TQObject *o, TQEvent * ); + virtual void resizeEvent( TQResizeEvent * ); + virtual void activatedMenu( const KFileItem *, const TQPoint& ); + virtual TQSize tqsizeHint() const; private slots: - void slotReturnPressed( const QString& text ); - void findCompletion( const QString& ); + void slotReturnPressed( const TQString& text ); + void findCompletion( const TQString& ); void slotViewChanged(); void slotItemsCleared(); @@ -89,8 +90,8 @@ private: bool m_validCompletion; FileFinder *m_fileFinder; - QString m_currentURL; - QString m_initialName; + TQString m_currentURL; + TQString m_initialName; }; diff --git a/kuickshow/src/generalwidget.cpp b/kuickshow/src/generalwidget.cpp index 3b718d6..3b9b035 100644 --- a/kuickshow/src/generalwidget.cpp +++ b/kuickshow/src/generalwidget.cpp @@ -16,11 +16,11 @@ Boston, MA 02110-1301, USA. */ -#include <qcheckbox.h> -#include <qlabel.h> -#include <qlayout.h> -#include <qtooltip.h> -#include <qvgroupbox.h> +#include <tqcheckbox.h> +#include <tqlabel.h> +#include <tqlayout.h> +#include <tqtooltip.h> +#include <tqvgroupbox.h> #include <kapplication.h> #include <kcolorbutton.h> @@ -33,13 +33,13 @@ #include "generalwidget.h" -GeneralWidget::GeneralWidget( QWidget *parent, const char *name ) - : QWidget( parent, name ) +GeneralWidget::GeneralWidget( TQWidget *tqparent, const char *name ) + : TQWidget( tqparent, name ) { - QVBoxLayout *layout = new QVBoxLayout( this ); - layout->setSpacing( KDialog::spacingHint() ); + TQVBoxLayout *tqlayout = new TQVBoxLayout( this ); + tqlayout->setSpacing( KDialog::spacingHint() ); - QPixmap pixmap = UserIcon( "logo" ); + TQPixmap pixmap = UserIcon( "logo" ); KURLLabel *logo = new KURLLabel( this ); logo->setURL( "http://devel-home.kde.org/~pfeiffer/kuickshow/" ); logo->setPixmap( pixmap ); @@ -47,22 +47,22 @@ GeneralWidget::GeneralWidget( QWidget *parent, const char *name ) logo->setTipText( i18n( "Open KuickShow Website" ) ); logo->setUseTips( true ); - connect( logo, SIGNAL( leftClickedURL( const QString & ) ), - SLOT( slotURLClicked( const QString & ) ) ); + connect( logo, TQT_SIGNAL( leftClickedURL( const TQString & ) ), + TQT_SLOT( slotURLClicked( const TQString & ) ) ); - layout->addWidget( logo, 0, AlignRight ); + tqlayout->addWidget( logo, 0, AlignRight ); - cbFullscreen = new QCheckBox( i18n("Fullscreen mode"), this, "boscreen" ); + cbFullscreen = new TQCheckBox( i18n("Fullscreen mode"), this, "boscreen" ); - cbPreload = new QCheckBox( i18n("Preload next image"), this, "preload"); - cbLastdir = new QCheckBox( i18n("Remember last folder"), this, "restart_lastdir"); + cbPreload = new TQCheckBox( i18n("Preload next image"), this, "preload"); + cbLastdir = new TQCheckBox( i18n("Remember last folder"), this, "restart_lastdir"); - QGridLayout *gridLayout = new QGridLayout( 2, 2 ); + TQGridLayout *gridLayout = new TQGridLayout( 2, 2 ); gridLayout->setSpacing( KDialog::spacingHint() ); - QLabel *l0 = new QLabel( i18n("Background color:"), this ); + TQLabel *l0 = new TQLabel( i18n("Background color:"), this ); colorButton = new KColorButton( this ); - QLabel *l1 = new QLabel( i18n("Show only files with extension: "), this, "label" ); + TQLabel *l1 = new TQLabel( i18n("Show only files with extension: "), this, "label" ); editFilter = new KLineEdit( this, "filteredit" ); gridLayout->addWidget( l0, 0, 0 ); @@ -70,31 +70,31 @@ GeneralWidget::GeneralWidget( QWidget *parent, const char *name ) gridLayout->addWidget( l1, 1, 0 ); gridLayout->addWidget( editFilter, 1, 1 ); - layout->addWidget( cbFullscreen ); - layout->addWidget( cbPreload ); - layout->addWidget( cbLastdir ); - layout->addLayout( gridLayout ); + tqlayout->addWidget( cbFullscreen ); + tqlayout->addWidget( cbPreload ); + tqlayout->addWidget( cbLastdir ); + tqlayout->addLayout( gridLayout ); //////////////////////////////////////////////////////////////////////// - QVGroupBox *gbox2 = new QVGroupBox( i18n("Quality/Speed"), + TQVGroupBox *gbox2 = new TQVGroupBox( i18n("Quality/Speed"), this, "qualitybox" ); - layout->addWidget( gbox2 ); - layout->addStretch(); + tqlayout->addWidget( gbox2 ); + tqlayout->addStretch(); - cbSmoothScale = new QCheckBox( i18n("Smooth scaling"), gbox2, "smoothscale" ); - cbFastRender = new QCheckBox( i18n("Fast rendering"), gbox2, "fastrender" ); - cbDither16bit = new QCheckBox( i18n("Dither in HiColor (15/16bit) modes"), + cbSmoothScale = new TQCheckBox( i18n("Smooth scaling"), gbox2, "smoothscale" ); + cbFastRender = new TQCheckBox( i18n("Fast rendering"), gbox2, "fastrender" ); + cbDither16bit = new TQCheckBox( i18n("Dither in HiColor (15/16bit) modes"), gbox2, "dither16bit" ); - cbDither8bit = new QCheckBox( i18n("Dither in LowColor (<=8bit) modes"), + cbDither8bit = new TQCheckBox( i18n("Dither in LowColor (<=8bit) modes"), gbox2, "dither8bit" ); - cbOwnPalette = new QCheckBox( i18n("Use own color palette"), + cbOwnPalette = new TQCheckBox( i18n("Use own color palette"), gbox2, "pal"); - connect( cbOwnPalette, SIGNAL( clicked() ), this, SLOT( useOwnPalette() ) ); + connect( cbOwnPalette, TQT_SIGNAL( clicked() ), this, TQT_SLOT( useOwnPalette() ) ); - cbFastRemap = new QCheckBox( i18n("Fast palette remapping"), gbox2, "remap"); + cbFastRemap = new TQCheckBox( i18n("Fast palette remapping"), gbox2, "remap"); maxCacheSpinBox = new KIntNumInput( gbox2, "editmaxcache" ); maxCacheSpinBox->setLabel( i18n("Maximum cache size: "), AlignVCenter ); @@ -110,7 +110,7 @@ GeneralWidget::~GeneralWidget() { } -void GeneralWidget::slotURLClicked( const QString & url ) +void GeneralWidget::slotURLClicked( const TQString & url ) { kapp->invokeBrowser( url ); } diff --git a/kuickshow/src/generalwidget.h b/kuickshow/src/generalwidget.h index e39eef1..d966517 100644 --- a/kuickshow/src/generalwidget.h +++ b/kuickshow/src/generalwidget.h @@ -19,31 +19,32 @@ #ifndef GENERALWIDGET_H #define GENERALWIDGET_H -#include <qwidget.h> +#include <tqwidget.h> #include "kuickdata.h" -class QCheckBox; +class TQCheckBox; class KColorButton; class KLineEdit; class KIntNumInput; -class GeneralWidget : public QWidget +class GeneralWidget : public TQWidget { Q_OBJECT + TQ_OBJECT public: - GeneralWidget( QWidget *parent, const char *name ); + GeneralWidget( TQWidget *tqparent, const char *name ); ~GeneralWidget(); void loadSettings( const KuickData& data ); void applySettings( KuickData& data ); private: - QCheckBox *cbFullscreen, *cbActiveWindow, *cbPreload, *cbLastdir; - QCheckBox *cbSmoothScale, *cbFastRemap, *cbFastRender; - QCheckBox *cbDither16bit, *cbDither8bit, *cbOwnPalette; + TQCheckBox *cbFullscreen, *cbActiveWindow, *cbPreload, *cbLastdir; + TQCheckBox *cbSmoothScale, *cbFastRemap, *cbFastRender; + TQCheckBox *cbDither16bit, *cbDither8bit, *cbOwnPalette; KLineEdit *editFilter; KIntNumInput *maxCacheSpinBox; @@ -55,7 +56,7 @@ private: private slots: void useOwnPalette(); - void slotURLClicked( const QString & ); + void slotURLClicked( const TQString & ); }; diff --git a/kuickshow/src/imagewindow.cpp b/kuickshow/src/imagewindow.cpp index c63a3c6..915443b 100644 --- a/kuickshow/src/imagewindow.cpp +++ b/kuickshow/src/imagewindow.cpp @@ -18,23 +18,23 @@ #include <stdlib.h> -#include <qcheckbox.h> -#include <qcursor.h> -#include <qdrawutil.h> -#include <qfileinfo.h> -#include <qkeycode.h> -#include <qpainter.h> -#include <qpen.h> -#include <qpopupmenu.h> +#include <tqcheckbox.h> +#include <tqcursor.h> +#include <tqdrawutil.h> +#include <tqfileinfo.h> +#include <tqkeycode.h> +#include <tqpainter.h> +#include <tqpen.h> +#include <tqpopupmenu.h> #ifdef KDE_USE_FINAL #undef GrayScale #undef Color #endif -#include <qrect.h> -#include <qstring.h> -#include <qstringlist.h> -#include <qtimer.h> +#include <tqrect.h> +#include <tqstring.h> +#include <tqstringlist.h> +#include <tqtimer.h> #include <kapplication.h> #include <kconfig.h> @@ -72,17 +72,17 @@ #undef GrayScale -QCursor *ImageWindow::s_handCursor = 0L; +TQCursor *ImageWindow::s_handCursor = 0L; -ImageWindow::ImageWindow( ImData *_idata, ImlibData *id, QWidget *parent, +ImageWindow::ImageWindow( ImData *_idata, ImlibData *id, TQWidget *tqparent, const char *name ) - : ImlibWidget( _idata, id, parent, name ) + : ImlibWidget( _idata, id, tqparent, name ) { init(); } -ImageWindow::ImageWindow( ImData *_idata, QWidget *parent, const char *name ) - : ImlibWidget( _idata, parent, name ) +ImageWindow::ImageWindow( ImData *_idata, TQWidget *tqparent, const char *name ) + : ImlibWidget( _idata, tqparent, name ) { init(); } @@ -94,7 +94,7 @@ ImageWindow::~ImageWindow() void ImageWindow::init() { - setFocusPolicy( QWidget::StrongFocus ); + setFocusPolicy( TQ_StrongFocus ); KCursor::setAutoHideCursor( this, true, true ); KCursor::setHideCursorDelay( 1500 ); @@ -114,11 +114,11 @@ void ImageWindow::init() m_actions = new KActionCollection( this ); if ( !s_handCursor ) { - QString file = locate( "appdata", "pics/handcursor.png" ); + TQString file = locate( "appdata", "pics/handcursor.png" ); if ( !file.isEmpty() ) - s_handCursor = new QCursor( file ); + s_handCursor = new TQCursor( file ); else - s_handCursor = new QCursor( arrowCursor ); + s_handCursor = new TQCursor( arrowCursor ); } setupActions(); @@ -133,8 +133,8 @@ void ImageWindow::init() setAcceptDrops( true ); setBackgroundColor( kdata->backgroundColor ); - static QPixmap imageIcon = UserIcon( "imageviewer-medium" ); - static QPixmap miniImageIcon = UserIcon( "imageviewer-small" ); + static TQPixmap imageIcon = UserIcon( "imageviewer-medium" ); + static TQPixmap miniImageIcon = UserIcon( "imageviewer-small" ); KWin::setIcons( winId(), imageIcon, miniImageIcon ); } @@ -146,103 +146,103 @@ void ImageWindow::updateActions() void ImageWindow::setupActions() { new KAction( i18n("Show Next Image"), KStdAccel::next(), - this, SLOT( slotRequestNext() ), + TQT_TQOBJECT(this), TQT_SLOT( slotRequestNext() ), m_actions, "next_image" ); new KAction( i18n("Show Previous Image"), KStdAccel::prior(), - this, SLOT( slotRequestPrevious() ), + TQT_TQOBJECT(this), TQT_SLOT( slotRequestPrevious() ), m_actions, "previous_image" ); new KAction( i18n("Delete Image"), SHIFT + Key_Delete, - this, SLOT( imageDelete() ), + TQT_TQOBJECT(this), TQT_SLOT( imageDelete() ), m_actions, "delete_image" ); new KAction( i18n("Move Image to Trash"), Key_Delete, - this, SLOT( imageTrash() ), + TQT_TQOBJECT(this), TQT_SLOT( imageTrash() ), m_actions, "trash_image" ); new KAction( i18n("Zoom In"), Key_Plus, - this, SLOT( zoomIn() ), + TQT_TQOBJECT(this), TQT_SLOT( zoomIn() ), m_actions, "zoom_in" ); new KAction( i18n("Zoom Out"), Key_Minus, - this, SLOT( zoomOut() ), + TQT_TQOBJECT(this), TQT_SLOT( zoomOut() ), m_actions, "zoom_out" ); new KAction( i18n("Restore Original Size"), Key_O, - this, SLOT( showImageOriginalSize() ), + TQT_TQOBJECT(this), TQT_SLOT( showImageOriginalSize() ), m_actions, "original_size" ); new KAction( i18n("Maximize"), Key_M, - this, SLOT( maximize() ), + TQT_TQOBJECT(this), TQT_SLOT( maximize() ), m_actions, "maximize" ); new KAction( i18n("Rotate 90 Degrees"), Key_9, - this, SLOT( rotate90() ), + TQT_TQOBJECT(this), TQT_SLOT( rotate90() ), m_actions, "rotate90" ); new KAction( i18n("Rotate 180 Degrees"), Key_8, - this, SLOT( rotate180() ), + TQT_TQOBJECT(this), TQT_SLOT( rotate180() ), m_actions, "rotate180" ); new KAction( i18n("Rotate 270 Degrees"), Key_7, - this, SLOT( rotate270() ), + TQT_TQOBJECT(this), TQT_SLOT( rotate270() ), m_actions, "rotate270" ); - new KAction( i18n("Flip Horizontally"), Key_Asterisk, - this, SLOT( flipHoriz() ), + new KAction( i18n("FlipQt::Horizontally"), Key_Asterisk, + TQT_TQOBJECT(this), TQT_SLOT( flipHoriz() ), m_actions, "flip_horicontally" ); - new KAction( i18n("Flip Vertically"), Key_Slash, - this, SLOT( flipVert() ), + new KAction( i18n("FlipQt::Vertically"), Key_Slash, + TQT_TQOBJECT(this), TQT_SLOT( flipVert() ), m_actions, "flip_vertically" ); new KAction( i18n("Print Image..."), KStdAccel::print(), - this, SLOT( printImage() ), + TQT_TQOBJECT(this), TQT_SLOT( printImage() ), m_actions, "print_image" ); - KStdAction::saveAs( this, SLOT( saveImage() ), + KStdAction::saveAs( TQT_TQOBJECT(this), TQT_SLOT( saveImage() ), m_actions, "save_image_as" ); - KStdAction::close( this, SLOT( close() ), + KStdAction::close( TQT_TQOBJECT(this), TQT_SLOT( close() ), m_actions, "close_image" ); // -------- new KAction( i18n("More Brightness"), Key_B, - this, SLOT( moreBrightness() ), + TQT_TQOBJECT(this), TQT_SLOT( moreBrightness() ), m_actions, "more_brightness" ); new KAction( i18n("Less Brightness"), SHIFT + Key_B, - this, SLOT( lessBrightness() ), + TQT_TQOBJECT(this), TQT_SLOT( lessBrightness() ), m_actions, "less_brightness" ); new KAction( i18n("More Contrast"), Key_C, - this, SLOT( moreContrast() ), + TQT_TQOBJECT(this), TQT_SLOT( moreContrast() ), m_actions, "more_contrast" ); new KAction( i18n("Less Contrast"), SHIFT + Key_C, - this, SLOT( lessContrast() ), + TQT_TQOBJECT(this), TQT_SLOT( lessContrast() ), m_actions, "less_contrast" ); new KAction( i18n("More Gamma"), Key_G, - this, SLOT( moreGamma() ), + TQT_TQOBJECT(this), TQT_SLOT( moreGamma() ), m_actions, "more_gamma" ); new KAction( i18n("Less Gamma"), SHIFT + Key_G, - this, SLOT( lessGamma() ), + TQT_TQOBJECT(this), TQT_SLOT( lessGamma() ), m_actions, "less_gamma" ); // -------- new KAction( i18n("Scroll Up"), Key_Up, - this, SLOT( scrollUp() ), + TQT_TQOBJECT(this), TQT_SLOT( scrollUp() ), m_actions, "scroll_up" ); new KAction( i18n("Scroll Down"), Key_Down, - this, SLOT( scrollDown() ), + TQT_TQOBJECT(this), TQT_SLOT( scrollDown() ), m_actions, "scroll_down" ); new KAction( i18n("Scroll Left"), Key_Left, - this, SLOT( scrollLeft() ), + TQT_TQOBJECT(this), TQT_SLOT( scrollLeft() ), m_actions, "scroll_left" ); new KAction( i18n("Scroll Right"), Key_Right, - this, SLOT( scrollRight() ), + TQT_TQOBJECT(this), TQT_SLOT( scrollRight() ), m_actions, "scroll_right" ); // -------- new KAction( i18n("Pause Slideshow"), Key_P, - this, SLOT( pauseSlideShow() ), + TQT_TQOBJECT(this), TQT_SLOT( pauseSlideShow() ), m_actions, "kuick_slideshow_pause" ); - KAction *fullscreenAction = KStdAction::fullScreen(this, SLOT( toggleFullscreen() ), m_actions, 0 ); + KAction *fullscreenAction = KStdAction::fullScreen(TQT_TQOBJECT(this), TQT_SLOT( toggleFullscreen() ), m_actions, 0 ); KAction *reloadAction = new KAction( i18n("Reload Image"), KStdAccel::shortcut(KStdAccel::Reload), - this, SLOT( reload() ), + TQT_TQOBJECT(this), TQT_SLOT( reload() ), m_actions, "reload_image" ); new KAction( i18n("Properties"), ALT + Key_Return, - this, SLOT( slotProperties() ), + TQT_TQOBJECT(this), TQT_SLOT( slotProperties() ), m_actions, "properties" ); m_actions->readShortcutSettings(); @@ -308,10 +308,10 @@ void ImageWindow::updateGeometry( int imWidth, int imHeight ) updateCursor(); - QString caption = i18n( "Filename (Imagewidth x Imageheight)", + TQString caption = i18n( "Filename (Imagewidth x Imageheight)", "%3 (%1 x %2)" ); - caption = caption.arg( m_kuim->originalWidth() ). - arg( m_kuim->originalHeight() ).arg( m_kuim->url().prettyURL() ); + caption = caption.tqarg( m_kuim->originalWidth() ). + tqarg( m_kuim->originalHeight() ).tqarg( m_kuim->url().prettyURL() ); setCaption( kapp->makeStdCaption( caption ) ); } @@ -321,7 +321,7 @@ void ImageWindow::centerImage() int w, h; if ( myIsFullscreen ) { - QRect desktopRect = KGlobalSettings::desktopGeometry( this ); + TQRect desktopRect = KGlobalSettings::desktopGeometry( this ); w = desktopRect.width(); h = desktopRect.height(); } @@ -403,7 +403,7 @@ void ImageWindow::scrollImage( int x, int y, bool restrict ) // XUnmapWindow(); // XSetWindowBackgroundPixmap() // resize window to fit image size, center image -// XClearWindow(); // repaint +// XClearWindow(); // tqrepaint // XMapWindow(), XSync(); // bool ImageWindow::showNextImage( const KURL& url ) @@ -412,7 +412,7 @@ bool ImageWindow::showNextImage( const KURL& url ) switch ( file->waitForDownload( this ) ) { case KuickFile::ERROR: { - QString tmp = i18n("Unable to download the image from %1.").arg(url.prettyURL()); + TQString tmp = i18n("Unable to download the image from %1.").tqarg(url.prettyURL()); emit sigImageError( file, tmp ); return false; } @@ -428,9 +428,9 @@ bool ImageWindow::showNextImage( const KURL& url ) bool ImageWindow::showNextImage( KuickFile *file ) { if ( !loadImage( file ) ) { - QString tmp = i18n("Unable to load the image %1.\n" + TQString tmp = i18n("Unable to load the image %1.\n" "Perhaps the file format is unsupported or " - "your Imlib is not installed properly.").arg(file->url().prettyURL()); + "your Imlib is not installed properly.").tqarg(file->url().prettyURL()); emit sigImageError( file, tmp ); return false; } @@ -573,7 +573,7 @@ void ImageWindow::imageTrash() //// // event handlers -void ImageWindow::wheelEvent( QWheelEvent *e ) +void ImageWindow::wheelEvent( TQWheelEvent *e ) { e->accept(); static const int WHEEL_DELTA = 120; @@ -586,7 +586,7 @@ void ImageWindow::wheelEvent( QWheelEvent *e ) emit requestImage( this, -steps ); } -void ImageWindow::keyPressEvent( QKeyEvent *e ) +void ImageWindow::keyPressEvent( TQKeyEvent *e ) { uint key = e->key(); @@ -606,7 +606,7 @@ void ImageWindow::keyPressEvent( QKeyEvent *e ) e->accept(); } -void ImageWindow::keyReleaseEvent( QKeyEvent *e ) +void ImageWindow::keyReleaseEvent( TQKeyEvent *e ) { if ( e->state() & ShiftButton ) { // Shift-key released updateCursor(); @@ -619,7 +619,7 @@ void ImageWindow::keyReleaseEvent( QKeyEvent *e ) e->accept(); } -void ImageWindow::mousePressEvent( QMouseEvent *e ) +void ImageWindow::mousePressEvent( TQMouseEvent *e ) { xmove = e->x(); // for moving the image with the mouse ymove = e->y(); @@ -630,7 +630,7 @@ void ImageWindow::mousePressEvent( QMouseEvent *e ) xposPress = xmove; yposPress = ymove; - if ( e->button() == LeftButton ) { + if ( e->button() == Qt::LeftButton ) { if ( e->state() & ShiftButton ) updateCursor( ZoomCursor ); else @@ -640,7 +640,7 @@ void ImageWindow::mousePressEvent( QMouseEvent *e ) ImlibWidget::mousePressEvent( e ); } -void ImageWindow::contextMenuEvent( QContextMenuEvent *e ) +void ImageWindow::contextMenuEvent( TQContextMenuEvent *e ) { e->accept(); @@ -673,26 +673,26 @@ void ImageWindow::updateCursor( KuickCursor cursor ) } } -void ImageWindow::mouseMoveEvent( QMouseEvent *e ) +void ImageWindow::mouseMoveEvent( TQMouseEvent *e ) { - if ( !(e->state() & LeftButton) ) { // only handle LeftButton actions + if ( !(e->state() & Qt::LeftButton) ) { // only handle LeftButton actions return; } if ( e->state() & ShiftButton ) { if ( !transWidget ) { - transWidget = new QWidget( this ); + transWidget = new TQWidget( this ); transWidget->setGeometry( 0, 0, width(), height() ); transWidget->setBackgroundMode( NoBackground ); } transWidget->hide(); - QPainter p( transWidget ); + TQPainter p( transWidget ); // really required? p.eraseRect( transWidget->rect() ); transWidget->show(); - qApp->processOneEvent(); + tqApp->processOneEvent(); int width = e->x() - xposPress; int height = e->y() - yposPress; @@ -707,7 +707,7 @@ void ImageWindow::mouseMoveEvent( QMouseEvent *e ) yzoom = e->y(); } - QPen pen( Qt::white, 1, DashLine ); + TQPen pen( TQt::white, 1, DashLine ); p.setPen( pen ); // for drawing white dashed line p.drawRect( xzoom, yzoom, width, height ); p.setPen( DotLine ); // defaults to black dotted line pen @@ -725,7 +725,7 @@ void ImageWindow::mouseMoveEvent( QMouseEvent *e ) } } -void ImageWindow::mouseReleaseEvent( QMouseEvent *e ) +void ImageWindow::mouseReleaseEvent( TQMouseEvent *e ) { updateCursor(); @@ -736,7 +736,7 @@ void ImageWindow::mouseReleaseEvent( QMouseEvent *e ) } // only proceed if shift-Key is still pressed - if ( !(e->button() == LeftButton && e->state() & ShiftButton) ) + if ( !(e->button() == Qt::LeftButton && e->state() & ShiftButton) ) return; int neww, newh, topX, topY, botX, botY; @@ -806,14 +806,14 @@ void ImageWindow::mouseReleaseEvent( QMouseEvent *e ) } -void ImageWindow::focusInEvent( QFocusEvent *ev ) +void ImageWindow::focusInEvent( TQFocusEvent *ev ) { ImlibWidget::focusInEvent( ev ); emit sigFocusWindow( this ); } -void ImageWindow::resizeEvent( QResizeEvent *e ) +void ImageWindow::resizeEvent( TQResizeEvent *e ) { ImlibWidget::resizeEvent( e ); @@ -822,7 +822,7 @@ void ImageWindow::resizeEvent( QResizeEvent *e ) } -void ImageWindow::dragEnterEvent( QDragEnterEvent *e ) +void ImageWindow::dragEnterEvent( TQDragEnterEvent *e ) { // if ( e->provides( "image/*" ) ) // can't do this right now with Imlib if ( e->provides( "text/uri-list" ) ) @@ -832,12 +832,12 @@ void ImageWindow::dragEnterEvent( QDragEnterEvent *e ) } -void ImageWindow::dropEvent( QDropEvent *e ) +void ImageWindow::dropEvent( TQDropEvent *e ) { // FIXME - only preliminary drop-support for now KURL::List list; if ( KURLDrag::decode( e, list ) && !list.isEmpty()) { - QString tmpFile; + TQString tmpFile; const KURL &url = list.first(); if (KIO::NetAccess::download( url, tmpFile, this ) ) { @@ -858,21 +858,21 @@ void ImageWindow::dropEvent( QDropEvent *e ) void ImageWindow::setPopupMenu() { - viewerMenu = new QPopupMenu( this ); + viewerMenu = new TQPopupMenu( this ); m_actions->action("next_image")->plug( viewerMenu ); m_actions->action("previous_image")->plug( viewerMenu ); viewerMenu->insertSeparator(); - brightnessMenu = new QPopupMenu( viewerMenu ); + brightnessMenu = new TQPopupMenu( viewerMenu ); m_actions->action("more_brightness")->plug(brightnessMenu); m_actions->action("less_brightness")->plug(brightnessMenu); - contrastMenu = new QPopupMenu( viewerMenu ); + contrastMenu = new TQPopupMenu( viewerMenu ); m_actions->action("more_contrast")->plug(contrastMenu); m_actions->action("less_contrast")->plug(contrastMenu); - gammaMenu = new QPopupMenu( viewerMenu ); + gammaMenu = new TQPopupMenu( viewerMenu ); m_actions->action("more_gamma")->plug(gammaMenu); m_actions->action("less_gamma")->plug(gammaMenu); @@ -922,7 +922,7 @@ void ImageWindow::saveImage() return; KuickData tmp; - QCheckBox *keepSize = new QCheckBox( i18n("Keep original image size"), 0L); + TQCheckBox *keepSize = new TQCheckBox( i18n("Keep original image size"), 0L); keepSize->setChecked( true ); KFileDialog dlg( m_saveDirectory, tmp.fileFilter, this, "filedialog", true #if KDE_VERSION >= 310 @@ -930,21 +930,21 @@ void ImageWindow::saveImage() #endif ); - QString selection = m_saveDirectory.isEmpty() ? + TQString selection = m_saveDirectory.isEmpty() ? m_kuim->url().url() : m_kuim->url().fileName(); dlg.setOperationMode( KFileDialog::Saving ); dlg.setMode( KFile::File ); dlg.setSelection( selection ); dlg.setCaption( i18n("Save As") ); - if ( dlg.exec() == QDialog::Accepted ) + if ( dlg.exec() == TQDialog::Accepted ) { KURL url = dlg.selectedURL(); if ( url.isValid() ) { if ( !saveImage( url, keepSize->isChecked() ) ) { - QString tmp = i18n("Couldn't save the file.\n" + TQString tmp = i18n("Couldn't save the file.\n" "Perhaps the disk is full, or you don't " "have write permission to the file."); KMessageBox::sorry( this, tmp, i18n("File Saving Failed")); @@ -958,7 +958,7 @@ void ImageWindow::saveImage() } } - QString lastDir = dlg.baseURL().path(+1); + TQString lastDir = dlg.baseURL().path(+1); if ( lastDir != m_saveDirectory ) m_saveDirectory = lastDir; @@ -972,22 +972,22 @@ bool ImageWindow::saveImage( const KURL& dest, bool keepOriginalSize ) int w = keepOriginalSize ? m_kuim->originalWidth() : m_kuim->width(); int h = keepOriginalSize ? m_kuim->originalHeight() : m_kuim->height(); if ( m_kuim->absRotation() == ROT_90 || m_kuim->absRotation() == ROT_270 ) - qSwap( w, h ); + tqSwap( w, h ); ImlibImage *saveIm = Imlib_clone_scaled_image( id, m_kuim->imlibImage(), w, h ); bool success = false; - QString saveFile; + TQString saveFile; if ( dest.isLocalFile() ) saveFile = dest.path(); else { - QString extension = QFileInfo( dest.fileName() ).extension(); + TQString extension = TQFileInfo( dest.fileName() ).extension(); if ( !extension.isEmpty() ) extension.prepend( '.' ); - KTempFile tmpFile( QString::null, extension ); + KTempFile tmpFile( TQString(), extension ); if ( tmpFile.status() != 0 ) return false; tmpFile.close(); @@ -1000,7 +1000,7 @@ bool ImageWindow::saveImage( const KURL& dest, bool keepOriginalSize ) { Imlib_apply_modifiers_to_rgb( id, saveIm ); success = Imlib_save_image( id, saveIm, - QFile::encodeName( saveFile ).data(), + TQFile::encodeName( saveFile ).data(), NULL ); if ( success && !dest.isLocalFile() ) { @@ -1040,12 +1040,12 @@ void ImageWindow::autoScale( KuickImage *kuim ) int newW = kuim->originalWidth(); int newH = kuim->originalHeight(); - QSize s = maxImageSize(); + TQSize s = maxImageSize(); int mw = s.width(); int mh = s.height(); if ( kuim->absRotation() == ROT_90 || kuim->absRotation() == ROT_270 ) - qSwap( newW, newH ); + tqSwap( newW, newH ); bool doIt = false; @@ -1128,7 +1128,7 @@ int ImageWindow::desktopWidth( bool totalScreen ) const { if ( myIsFullscreen || totalScreen ) { - return KGlobalSettings::desktopGeometry(topLevelWidget()).width(); + return KGlobalSettings::desktopGeometry(tqtopLevelWidget()).width(); } else return Kuick::workArea().width(); } @@ -1137,16 +1137,16 @@ int ImageWindow::desktopWidth( bool totalScreen ) const int ImageWindow::desktopHeight( bool totalScreen ) const { if ( myIsFullscreen || totalScreen ) { - return KGlobalSettings::desktopGeometry(topLevelWidget()).height(); + return KGlobalSettings::desktopGeometry(tqtopLevelWidget()).height(); } else { return Kuick::workArea().height(); } } -QSize ImageWindow::maxImageSize() const +TQSize ImageWindow::maxImageSize() const { if ( myIsFullscreen ) { - return KGlobalSettings::desktopGeometry(topLevelWidget()).size(); + return KGlobalSettings::desktopGeometry(tqtopLevelWidget()).size(); } else { return Kuick::workArea().size() - Kuick::frameSize( winId() ); @@ -1155,7 +1155,7 @@ QSize ImageWindow::maxImageSize() const void ImageWindow::resizeOptimal( int w, int h ) { - QSize s = maxImageSize(); + TQSize s = maxImageSize(); int mw = s.width(); int mh = s.height(); int neww = (w >= mw) ? mw : w; @@ -1193,7 +1193,7 @@ bool ImageWindow::canZoomTo( int newWidth, int newHeight ) if ( !ImlibWidget::canZoomTo( newWidth, newHeight ) ) return false; - QSize desktopSize = KGlobalSettings::desktopGeometry(topLevelWidget()).size(); + TQSize desktopSize = KGlobalSettings::desktopGeometry(tqtopLevelWidget()).size(); int desktopArea = desktopSize.width() * desktopSize.height(); int imageArea = newWidth * newHeight; @@ -1203,8 +1203,8 @@ bool ImageWindow::canZoomTo( int newWidth, int newHeight ) return KMessageBox::warningContinueCancel( this, i18n("You are about to view a very large image (%1 x %2 pixels), which can be very resource-consuming and even make your computer hang.\nDo you want to continue?") - .arg( newWidth ).arg( newHeight ), - QString::null, + .tqarg( newWidth ).tqarg( newHeight ), + TQString(), KStdGuiItem::cont(), "ImageWindow_confirm_very_large_window" ) == KMessageBox::Continue; @@ -1245,7 +1245,7 @@ void ImageWindow::restoreCursor() bool ImageWindow::isCursorHidden() const { - return cursor().shape() == Qt::BlankCursor; + return cursor().shape() == TQt::BlankCursor; } #include "imagewindow.moc" diff --git a/kuickshow/src/imagewindow.h b/kuickshow/src/imagewindow.h index 4a823a0..f755866 100644 --- a/kuickshow/src/imagewindow.h +++ b/kuickshow/src/imagewindow.h @@ -19,30 +19,31 @@ #ifndef IMAGEWINDOW_H #define IMAGEWINDOW_H -#include <qevent.h> +#include <tqevent.h> #include <kaction.h> #include <kurl.h> #include "imlibwidget.h" -class QCursor; -class QPopupMenu; -class QRect; -class QString; -class QTimer; -class QWidget; +class TQCursor; +class TQPopupMenu; +class TQRect; +class TQString; +class TQTimer; +class TQWidget; class KuickFile; class ImageWindow : public ImlibWidget { Q_OBJECT + TQ_OBJECT public: - ImageWindow( ImData *_idata, ImlibData *id, QWidget *parent=0, + ImageWindow( ImData *_idata, ImlibData *id, TQWidget *tqparent=0, const char *name=0 ); - ImageWindow( ImData *_idata=0, QWidget *parent=0, const char *name=0 ); + ImageWindow( ImData *_idata=0, TQWidget *tqparent=0, const char *name=0 ); bool showNextImage( KuickFile * file ); bool showNextImage( const KURL& url ); @@ -105,17 +106,17 @@ protected: virtual bool canZoomTo( int newWidth, int newHeight ); virtual void rotated( KuickImage *kuim, int rotation ); - virtual void wheelEvent( QWheelEvent * ); - virtual void keyPressEvent( QKeyEvent * ); - virtual void keyReleaseEvent( QKeyEvent * ); - virtual void mousePressEvent( QMouseEvent * ); - virtual void mouseReleaseEvent( QMouseEvent * ); - virtual void mouseMoveEvent( QMouseEvent * ); - virtual void focusInEvent( QFocusEvent * ); - virtual void resizeEvent( QResizeEvent * ); - virtual void dragEnterEvent( QDragEnterEvent * ); - virtual void dropEvent( QDropEvent * ); - virtual void contextMenuEvent( QContextMenuEvent * ); + virtual void wheelEvent( TQWheelEvent * ); + virtual void keyPressEvent( TQKeyEvent * ); + virtual void keyReleaseEvent( TQKeyEvent * ); + virtual void mousePressEvent( TQMouseEvent * ); + virtual void mouseReleaseEvent( TQMouseEvent * ); + virtual void mouseMoveEvent( TQMouseEvent * ); + virtual void focusInEvent( TQFocusEvent * ); + virtual void resizeEvent( TQResizeEvent * ); + virtual void dragEnterEvent( TQDragEnterEvent * ); + virtual void dropEvent( TQDropEvent * ); + virtual void contextMenuEvent( TQContextMenuEvent * ); void showWindow(); enum KuickCursor { DefaultCursor = 0, ZoomCursor, MoveCursor }; @@ -138,8 +139,8 @@ protected: uint xposPress, yposPress; - QPopupMenu *viewerMenu, *gammaMenu, *brightnessMenu, *contrastMenu; - QWidget *transWidget; + TQPopupMenu *viewerMenu, *gammaMenu, *brightnessMenu, *contrastMenu; + TQWidget *transWidget; protected slots: @@ -158,18 +159,18 @@ signals: private: int desktopWidth( bool totalScreen = false ) const; int desktopHeight( bool totalScreen = false ) const; - QSize maxImageSize() const; + TQSize maxImageSize() const; void setupActions(); void setPopupMenu(); bool isCursorHidden() const; bool myIsFullscreen; int m_numHeads; - QString m_saveDirectory; + TQString m_saveDirectory; KActionCollection *m_actions; - static QCursor * s_handCursor; + static TQCursor * s_handCursor; }; diff --git a/kuickshow/src/imlibwidget.cpp b/kuickshow/src/imlibwidget.cpp index 5b5cb84..1eddb70 100644 --- a/kuickshow/src/imlibwidget.cpp +++ b/kuickshow/src/imlibwidget.cpp @@ -24,12 +24,12 @@ #include <stdlib.h> #include <assert.h> -#include <qcolor.h> -#include <qfile.h> -#include <qglobal.h> -#include <qimage.h> -#include <qobject.h> -#include <qpalette.h> +#include <tqcolor.h> +#include <tqfile.h> +#include <tqglobal.h> +#include <tqimage.h> +#include <tqobject.h> +#include <tqpalette.h> #include <kcursor.h> #include <kdebug.h> @@ -43,8 +43,8 @@ const int ImlibWidget::ImlibOffset = 256; -ImlibWidget::ImlibWidget( ImData *_idata, QWidget *parent, const char *name ) : - QWidget( parent, name, WDestructiveClose ) +ImlibWidget::ImlibWidget( ImData *_idata, TQWidget *tqparent, const char *name ) : + TQWidget( tqparent, name, WDestructiveClose ) { idata = _idata; deleteImData = false; @@ -82,9 +82,9 @@ ImlibWidget::ImlibWidget( ImData *_idata, QWidget *parent, const char *name ) : } -ImlibWidget::ImlibWidget( ImData *_idata, ImlibData *_id, QWidget *parent, +ImlibWidget::ImlibWidget( ImData *_idata, ImlibData *_id, TQWidget *tqparent, const char *name ) - : QWidget( parent, name, WDestructiveClose ) + : TQWidget( tqparent, name, WDestructiveClose ) { id = _id; idata = _idata; @@ -104,7 +104,7 @@ void ImlibWidget::init() { int w = 1; // > 0 for XCreateWindow int h = 1; - myBackgroundColor = Qt::black; + myBackgroundColor = TQt::black; m_kuim = 0L; m_kuickFile = 0L; @@ -113,12 +113,12 @@ void ImlibWidget::init() setAutoRender( true ); - setPalette( QPalette( myBackgroundColor )); + setPalette( TQPalette( myBackgroundColor )); setBackgroundMode( PaletteBackground ); imageCache = new ImageCache( id, 4 ); // cache 4 images (FIXME?) - connect( imageCache, SIGNAL( sigBusy() ), SLOT( setBusyCursor() )); - connect( imageCache, SIGNAL( sigIdle() ), SLOT( restoreCursor() )); + connect( imageCache, TQT_SIGNAL( sigBusy() ), TQT_SLOT( setBusyCursor() )); + connect( imageCache, TQT_SIGNAL( sigIdle() ), TQT_SLOT( restoreCursor() )); win = XCreateSimpleWindow(x11Display(), winId(), 0,0,w,h,0,0,0); } @@ -206,7 +206,7 @@ bool ImlibWidget::cacheImage( const KURL& url ) if ( !file->download() ) { return false; } - connect( file, SIGNAL( downloaded( KuickFile * )), SLOT( cacheImage( KuickFile * )) ); + connect( file, TQT_SIGNAL( downloaded( KuickFile * )), TQT_SLOT( cacheImage( KuickFile * )) ); return true; // optimistic } } @@ -311,18 +311,16 @@ bool ImlibWidget::autoRotate( KuickImage *kuim ) if ( !metadatas.isValid() ) return false; - KFileMetaInfoItem metaitem = metadatas.item("Orientation"); + KFileMetaInfoItem metaitem = metadatas.item("Qt::Orientation"); if ( !metaitem.isValid() -#if QT_VERSION >= 0x030100 || metaitem.value().isNull() -#endif ) return false; switch ( metaitem.value().toInt() ) { - // Orientation: + // Qt::Orientation: // 1: normal // 2: flipped horizontally // 3: ROT 180 @@ -438,17 +436,17 @@ void ImlibWidget::setFlipMode( int mode ) } -void ImlibWidget::updateWidget( bool geometryUpdate ) +void ImlibWidget::updateWidget( bool tqgeometryUpdate ) { if ( !m_kuim ) return; -// if ( geometryUpdate ) +// if ( tqgeometryUpdate ) // XUnmapWindow( x11Display(), win );// remove the old image -> no flicker XSetWindowBackgroundPixmap( x11Display(), win, m_kuim->pixmap() ); - if ( geometryUpdate ) + if ( tqgeometryUpdate ) updateGeometry( m_kuim->width(), m_kuim->height() ); XClearWindow( x11Display(), win ); @@ -466,21 +464,21 @@ void ImlibWidget::updateGeometry( int w, int h ) } -void ImlibWidget::closeEvent( QCloseEvent *e ) +void ImlibWidget::closeEvent( TQCloseEvent *e ) { e->accept(); - QWidget::closeEvent( e ); + TQWidget::closeEvent( e ); } -void ImlibWidget::setBackgroundColor( const QColor& color ) +void ImlibWidget::setBackgroundColor( const TQColor& color ) { myBackgroundColor = color; - setPalette( QPalette( myBackgroundColor )); - repaint( false); // FIXME - false? necessary at all? + setPalette( TQPalette( myBackgroundColor )); + tqrepaint( false); // FIXME - false? necessary at all? } -const QColor& ImlibWidget::backgroundColor() const +const TQColor& ImlibWidget::backgroundColor() const { return myBackgroundColor; } @@ -510,30 +508,30 @@ void ImlibWidget::setBusyCursor() if ( ownCursor() ) m_oldCursor = cursor(); else - m_oldCursor = QCursor(); + m_oldCursor = TQCursor(); setCursor( KCursor::waitCursor() ); } void ImlibWidget::restoreCursor() { - if ( cursor().shape() == KCursor::waitCursor().shape() ) // only if nobody changed the cursor in the meantime! + if ( cursor().shape() == KCursor::waitCursor().tqshape() ) // only if nobody changed the cursor in the meantime! setCursor( m_oldCursor ); } -// Reparenting a widget in Qt in fact means destroying the old X window of the widget +// Retqparenting a widget in TQt in fact means destroying the old X window of the widget // and creating a new one. And since the X window used for the Imlib image is a child // of this widget's X window, destroying this widget's X window would mean also // destroying the Imlib image X window. Therefore it needs to be temporarily reparented // away and reparented back to the new X window. -// Reparenting may happen e.g. when doing the old-style (non-NETWM) fullscreen changes. -void ImlibWidget::reparent( QWidget* parent, WFlags f, const QPoint& p, bool showIt ) +// Retqparenting may happen e.g. when doing the old-style (non-NETWM) fullscreen changes. +void ImlibWidget::reparent( TQWidget* tqparent, WFlags f, const TQPoint& p, bool showIt ) { XWindowAttributes attr; XGetWindowAttributes( x11Display(), win, &attr ); XUnmapWindow( x11Display(), win ); XReparentWindow( x11Display(), win, attr.root, 0, 0 ); - QWidget::reparent( parent, f, p, showIt ); + TQWidget::reparent( tqparent, f, p, showIt ); XReparentWindow( x11Display(), win, winId(), attr.x, attr.y ); if( attr.map_state != IsUnmapped ) XMapWindow( x11Display(), win ); @@ -604,7 +602,7 @@ KuickImage * ImageCache::getKuimage( KuickFile * file, return 0L; KuickImage *kuim = 0L; - int index = fileList.findIndex( file ); + int index = fileList.tqfindIndex( file ); if ( index != -1 ) { if ( index == 0 ) kuim = kuickList.at( 0 ); @@ -630,7 +628,7 @@ KuickImage * ImageCache::getKuimage( KuickFile * file, // #endif ImlibImage *im = Imlib_load_image( myId, - QFile::encodeName( file->localFile() ).data() ); + TQFile::encodeName( file->localFile() ).data() ); // #ifndef NDEBUG // gettimeofday( &tms2, NULL ); @@ -641,7 +639,7 @@ KuickImage * ImageCache::getKuimage( KuickFile * file, slotIdle(); if ( !im ) { slotBusy(); - im = loadImageWithQt( file->localFile() ); + im = loadImageWithTQt( file->localFile() ); slotIdle(); if ( !im ) return 0L; @@ -649,8 +647,8 @@ KuickImage * ImageCache::getKuimage( KuickFile * file, Imlib_set_image_modifier( myId, im, &mod ); kuim = new KuickImage( file, im, myId ); - connect( kuim, SIGNAL( startRendering() ), SLOT( slotBusy() )); - connect( kuim, SIGNAL( stoppedRendering() ), SLOT( slotIdle() )); + connect( kuim, TQT_SIGNAL( startRendering() ), TQT_SLOT( slotBusy() )); + connect( kuim, TQT_SIGNAL( stoppedRendering() ), TQT_SLOT( slotIdle() )); kuickList.insert( 0, kuim ); fileList.prepend( file ); @@ -668,13 +666,13 @@ KuickImage * ImageCache::getKuimage( KuickFile * file, // Note: the returned image's filename will not be the real filename (which it usually // isn't anyway, according to Imlib's sources). -ImlibImage * ImageCache::loadImageWithQt( const QString& fileName ) const +ImlibImage * ImageCache::loadImageWithTQt( const TQString& fileName ) const { kdDebug() << "Trying to load " << fileName << " with KImageIO..." << endl; KImageIO::registerFormats(); - QImage image( fileName ); + TQImage image( fileName ); if ( image.isNull() ) return 0L; if ( image.depth() != 32 ) { @@ -695,12 +693,12 @@ ImlibImage * ImageCache::loadImageWithQt( const QString& fileName ) const int h = image.height(); for (int y = 0; y < h; y++) { - QRgb *scanLine = reinterpret_cast<QRgb *>( image.scanLine(y) ); + TQRgb *scanLine = reinterpret_cast<TQRgb *>( image.scanLine(y) ); for (int x = 0; x < w; x++) { - const QRgb& pixel = scanLine[x]; - *(newData++) = qRed(pixel); - *(newData++) = qGreen(pixel); - *(newData++) = qBlue(pixel); + const TQRgb& pixel = scanLine[x]; + *(newData++) = tqRed(pixel); + *(newData++) = tqGreen(pixel); + *(newData++) = tqBlue(pixel); } } diff --git a/kuickshow/src/imlibwidget.h b/kuickshow/src/imlibwidget.h index d4c1256..f39b3ce 100644 --- a/kuickshow/src/imlibwidget.h +++ b/kuickshow/src/imlibwidget.h @@ -1,7 +1,7 @@ /**************************************************************************** ** $Id: imlibwidget.h 524709 2006-03-31 00:03:44Z pfeiffer $ ** -** ImlibWidget: maps an Xlib window with Imlib's contents on a QWidget +** ImlibWidget: maps an Xlib window with Imlib's contents on a TQWidget ** ** Created : 98 ** @@ -12,17 +12,17 @@ #ifndef IMLIBWIDGET_H #define IMLIBWIDGET_H -#include <qvariant.h> +#include <tqvariant.h> -#include <qcursor.h> -#include <qevent.h> -#include <qptrlist.h> -#include <qtimer.h> -#include <qwidget.h> +#include <tqcursor.h> +#include <tqevent.h> +#include <tqptrlist.h> +#include <tqtimer.h> +#include <tqwidget.h> #include <kurl.h> -// #include those AFTER Qt-includes! +// #include those AFTER TQt-includes! #include <Imlib.h> #include <X11/Xlib.h> #include <X11/Xutil.h> @@ -34,9 +34,10 @@ class KuickFile; class KuickImage; -class ImageCache : public QObject +class ImageCache : public TQObject { Q_OBJECT + TQ_OBJECT public: ImageCache( ImlibData *id, int maxImages=1 ); @@ -48,12 +49,12 @@ public: KuickImage * getKuimage( KuickFile * file, ImlibColorModifier ); private: - ImlibImage * loadImageWithQt( const QString& filename ) const; + ImlibImage * loadImageWithTQt( const TQString& filename ) const; int myMaxImages; - QValueList<KuickFile*>fileList; - QPtrList<KuickImage> kuickList; - // QPtrList<ImlibImage> imList; + TQValueList<KuickFile*>fileList; + TQPtrList<KuickImage> kuickList; + // TQPtrList<ImlibImage> imList; ImlibData * myId; int idleCount; @@ -70,16 +71,17 @@ signals: // ------------------------------------------ -class QColor; +class TQColor; -class ImlibWidget : public QWidget +class ImlibWidget : public TQWidget { Q_OBJECT + TQ_OBJECT public: - ImlibWidget( ImData *_idata=0, QWidget *parent=0, const char *name=0 ); - ImlibWidget( ImData *_idata, ImlibData *id, QWidget *parent=0, + ImlibWidget( ImData *_idata=0, TQWidget *tqparent=0, const char *name=0 ); + ImlibWidget( ImData *_idata, ImlibData *id, TQWidget *tqparent=0, const char *name=0 ); virtual ~ImlibWidget(); @@ -108,8 +110,8 @@ public: bool isAutoRenderEnabled() const { return isAutoRendering; } void setMaxImageCache( int ); int maxImageCache() const { return myMaxImageCache; } - const QColor& backgroundColor() const; - void setBackgroundColor( const QColor& ); + const TQColor& backgroundColor() const; + void setBackgroundColor( const TQColor& ); /** * @return true if auto-rotation is not possible, e.g. because no metadata @@ -119,7 +121,7 @@ public: ImlibData* getImlibData() const { return id; } - virtual void reparent( QWidget* parent, WFlags f, const QPoint& p, bool showIt = FALSE ); + virtual void reparent( TQWidget* tqparent, WFlags f, const TQPoint& p, bool showIt = FALSE ); public slots: void rotate90(); @@ -136,17 +138,17 @@ protected: void showImage(); void setImageModifier(); void rotate( int ); - void updateWidget( bool geometryUpdate=true ); + void updateWidget( bool tqgeometryUpdate=true ); virtual void updateGeometry( int width, int height ); virtual void loaded( KuickImage * ); virtual bool canZoomTo( int newWidth, int newHeight ); virtual void rotated( KuickImage *kuim, int rotation ); - void closeEvent( QCloseEvent * ); + void closeEvent( TQCloseEvent * ); - inline void autoUpdate( bool geometryUpdate=false ) { + inline void autoUpdate( bool tqgeometryUpdate=false ) { if ( isAutoRendering ) - updateWidget( geometryUpdate ); + updateWidget( tqgeometryUpdate ); } bool stillResizing, deleteImData, deleteImlibData; @@ -160,7 +162,7 @@ protected: ImlibColorModifier mod; KuickFile *m_kuickFile; - QCursor m_oldCursor; + TQCursor m_oldCursor; static const int ImlibOffset; @@ -169,7 +171,7 @@ private: void init(); bool isAutoRendering; int myMaxImageCache; - QColor myBackgroundColor; + TQColor myBackgroundColor; protected slots: @@ -179,7 +181,7 @@ protected slots: signals: - void sigImageError( const KuickFile * file, const QString& ); + void sigImageError( const KuickFile * file, const TQString& ); }; diff --git a/kuickshow/src/kuick.cpp b/kuickshow/src/kuick.cpp index 43eadb5..24f1677 100644 --- a/kuickshow/src/kuick.cpp +++ b/kuickshow/src/kuick.cpp @@ -1,4 +1,4 @@ #include "kuick.h" Kuick * Kuick::s_self = 0L; -QSize Kuick::s_frameSize; +TQSize Kuick::s_frameSize; diff --git a/kuickshow/src/kuick.h b/kuickshow/src/kuick.h index bc86d5d..98289df 100644 --- a/kuickshow/src/kuick.h +++ b/kuickshow/src/kuick.h @@ -19,8 +19,8 @@ #ifndef KUICKGLOBALS_H #define KUICKGLOBALS_H -#include <qrect.h> -#include <qsize.h> +#include <tqrect.h> +#include <tqsize.h> #include <kwin.h> #include <kwinmodule.h> @@ -28,11 +28,11 @@ class Kuick { public: - static QRect workArea() { + static TQRect workArea() { return self()->winModule.workArea(); } - static QSize frameSize( WId win = 0L ) { + static TQSize frameSize( WId win = 0L ) { if ( win ) { KWin::WindowInfo info = KWin::windowInfo(win, NET::WMKDEFrameStrut | NET::WMGeometry); int wborder = info.frameGeometry().width() - info.geometry().width(); @@ -45,7 +45,7 @@ public: } if ( !s_frameSize.isValid() ) - return QSize( 0, 0 ); + return TQSize( 0, 0 ); return s_frameSize; } @@ -63,7 +63,7 @@ private: Kuick() {} static Kuick * s_self; - static QSize s_frameSize; + static TQSize s_frameSize; }; diff --git a/kuickshow/src/kuickconfigdlg.cpp b/kuickshow/src/kuickconfigdlg.cpp index 6ece888..3d981e1 100644 --- a/kuickshow/src/kuickconfigdlg.cpp +++ b/kuickshow/src/kuickconfigdlg.cpp @@ -22,8 +22,8 @@ #endif #include "kuickconfigdlg.h" -#include <qkeycode.h> -#include <qvbox.h> +#include <tqkeycode.h> +#include <tqvbox.h> #include <kaccel.h> #include <kconfig.h> @@ -38,14 +38,14 @@ #include "kuickdata.h" -KuickConfigDialog::KuickConfigDialog( KActionCollection *_coll, QWidget *parent, +KuickConfigDialog::KuickConfigDialog( KActionCollection *_coll, TQWidget *tqparent, const char *name, bool modal ) : KDialogBase( Tabbed, i18n("Configure"), Help | Default | Ok | Apply | Cancel, Ok, - parent, name, modal ) + tqparent, name, modal ) { coll = _coll; - QVBox *box = addVBoxPage( i18n("&General") ); + TQVBox *box = addVBoxPage( i18n("&General") ); generalWidget = new GeneralWidget( box, "general widget" ); box = addVBoxPage( i18n("&Modifications") ); @@ -64,7 +64,7 @@ KuickConfigDialog::KuickConfigDialog( KActionCollection *_coll, QWidget *parent, box = addVBoxPage( i18n("Bro&wser Shortcuts") ); browserKeyChooser = new KKeyChooser( coll, box ); - connect( this, SIGNAL( defaultClicked() ), SLOT( resetDefaults() )); + connect( this, TQT_SIGNAL( defaultClicked() ), TQT_SLOT( resetDefaults() )); } KuickConfigDialog::~KuickConfigDialog() diff --git a/kuickshow/src/kuickconfigdlg.h b/kuickshow/src/kuickconfigdlg.h index 884d91d..9d7657b 100644 --- a/kuickshow/src/kuickconfigdlg.h +++ b/kuickshow/src/kuickconfigdlg.h @@ -19,7 +19,7 @@ #ifndef KUICKCONFIGDLG_H #define KUICKCONFIGDLG_H -#include <qevent.h> +#include <tqevent.h> #include <kkeydialog.h> @@ -33,9 +33,10 @@ class ImageWindow; class KuickConfigDialog : public KDialogBase { Q_OBJECT + TQ_OBJECT public: - KuickConfigDialog( KActionCollection *coll, QWidget *parent=0, + KuickConfigDialog( KActionCollection *coll, TQWidget *tqparent=0, const char *name=0, bool modal=true); ~KuickConfigDialog(); diff --git a/kuickshow/src/kuickdata.cpp b/kuickshow/src/kuickdata.cpp index c6aa47c..528d1aa 100644 --- a/kuickshow/src/kuickdata.cpp +++ b/kuickshow/src/kuickdata.cpp @@ -18,7 +18,7 @@ #include <stdlib.h> -#include <qcolor.h> +#include <tqcolor.h> #include <kconfig.h> #include <kglobal.h> @@ -55,7 +55,7 @@ KuickData::KuickData() maxZoomFactor = 4.0; maxCachedImages = 4; - backgroundColor = Qt::black; + backgroundColor = TQt::black; startInLastDir = true; @@ -106,7 +106,7 @@ void KuickData::load() maxCachedImages = kc->readUnsignedNumEntry( "MaxCachedImages", def.maxCachedImages ); - backgroundColor = kc->readColorEntry( "BackgroundColor", &Qt::black ); + backgroundColor = kc->readColorEntry( "BackgroundColor", &TQt::black ); startInLastDir = kc->readBoolEntry( "StartInLastDir", true); diff --git a/kuickshow/src/kuickdata.h b/kuickshow/src/kuickdata.h index d05b3e9..e24d3bc 100644 --- a/kuickshow/src/kuickdata.h +++ b/kuickshow/src/kuickdata.h @@ -19,8 +19,8 @@ #ifndef KUICKDATA_H #define KUICKDATA_H -#include <qcolor.h> -#include <qstring.h> +#include <tqcolor.h> +#include <tqstring.h> #include "imdata.h" @@ -44,7 +44,7 @@ public: ImData *idata; - QString fileFilter; + TQString fileFilter; uint slideDelay; uint slideshowCycles; bool slideshowFullscreen :1; @@ -75,7 +75,7 @@ public: uint maxCachedImages; Rotation rotation; - QColor backgroundColor; + TQColor backgroundColor; }; diff --git a/kuickshow/src/kuickfile.cpp b/kuickshow/src/kuickfile.cpp index 1dd259d..648cf6a 100644 --- a/kuickshow/src/kuickfile.cpp +++ b/kuickshow/src/kuickfile.cpp @@ -1,4 +1,4 @@ -#include <qfile.h> +#include <tqfile.h> #include <kdebug.h> #include <kdeversion.h> @@ -13,7 +13,7 @@ #include "kuickfile.h" KuickFile::KuickFile(const KURL& url) - : QObject(), + : TQObject(), m_url( url ), m_job( 0L ), m_progress( 0L ), @@ -33,15 +33,15 @@ KuickFile::~KuickFile() delete m_job; if ( hasDownloaded() ) - QFile::remove( m_localFile ); + TQFile::remove( m_localFile ); } -QString KuickFile::localFile() const +TQString KuickFile::localFile() const { // Note: never call isAvailable() from here, directly or indirectly if ( isDownloading() ) - return QString::null; + return TQString(); return m_localFile; } @@ -61,17 +61,17 @@ bool KuickFile::download() return true; // reinitialize - m_localFile = QString::null; + m_localFile = TQString(); m_currentProgress = 0; - QString ext; - QString fileName = m_url.fileName(); - int extIndex = fileName.findRev('.'); + TQString ext; + TQString fileName = m_url.fileName(); + int extIndex = fileName.tqfindRev('.'); if ( extIndex > 0 ) ext = fileName.mid( extIndex + 1 ); - QString tempDir = FileCache::self()->tempDir(); + TQString tempDir = FileCache::self()->tempDir(); KTempFile tempFile( tempDir, ext ); tempFile.setAutoDelete( tempDir.isNull() ); // in case there is no proper tempdir, make sure to delete those files! if ( tempFile.status() != 0 ) @@ -86,15 +86,15 @@ bool KuickFile::download() m_job = KIO::file_copy( m_url, destURL, -1, true, false, false ); // handling progress ourselves m_job->setAutoErrorHandlingEnabled( true ); - connect( m_job, SIGNAL( result( KIO::Job * )), SLOT( slotResult( KIO::Job * ) )); - connect( m_job, SIGNAL( percent( KIO::Job *, unsigned long )), SLOT( slotProgress( KIO::Job *, unsigned long ) )); + connect( m_job, TQT_SIGNAL( result( KIO::Job * )), TQT_SLOT( slotResult( KIO::Job * ) )); + connect( m_job, TQT_SIGNAL( percent( KIO::Job *, unsigned long )), TQT_SLOT( slotProgress( KIO::Job *, unsigned long ) )); // TODO: generify background/foreground downloading? return m_job != 0L; } -KuickFile::DownloadStatus KuickFile::waitForDownload( QWidget *parent ) +KuickFile::DownloadtqStatus KuickFile::waitForDownload( TQWidget *tqparent ) { if ( isAvailable() ) return OK; @@ -104,10 +104,10 @@ KuickFile::DownloadStatus KuickFile::waitForDownload( QWidget *parent ) return ERROR; } - KProgressDialog *dialog = new KProgressDialog( parent ); + KProgressDialog *dialog = new KProgressDialog( tqparent ); dialog->setModal( true ); - dialog->setCaption( i18n("Downloading %1...").arg( m_url.fileName() ) ); - dialog->setLabel( i18n("Please wait while downloading\n%1").arg( m_url.prettyURL() )); + dialog->setCaption( i18n("Downloading %1...").tqarg( m_url.fileName() ) ); + dialog->setLabel( i18n("Please wait while downloading\n%1").tqarg( m_url.prettyURL() )); dialog->setAllowCancel( true ); dialog->setAutoClose( true ); @@ -150,9 +150,9 @@ void KuickFile::slotResult( KIO::Job *job ) if ( job->error() != KIO::ERR_USER_CANCELED ) kdWarning() << "ERROR: KuickFile::slotResult: " << job->errorString() << endl; - QString canceledFile = static_cast<KIO::FileCopyJob*>(job)->destURL().path(); - QFile::remove( canceledFile ); - m_progress->topLevelWidget()->hide(); + TQString canceledFile = static_cast<KIO::FileCopyJob*>(job)->destURL().path(); + TQFile::remove( canceledFile ); + m_progress->tqtopLevelWidget()->hide(); } else { m_localFile = static_cast<KIO::FileCopyJob*>(job)->destURL().path(); @@ -162,7 +162,7 @@ void KuickFile::slotResult( KIO::Job *job ) m_progress->setProgress( 100 ); #define BUGGY_VERSION KDE_MAKE_VERSION(3,5,2) if ( KDE::version() <= BUGGY_VERSION ) { - m_progress->topLevelWidget()->hide(); // ### workaround broken KProgressDialog + m_progress->tqtopLevelWidget()->hide(); // ### workaround broken KProgressDialog } } } diff --git a/kuickshow/src/kuickfile.h b/kuickshow/src/kuickfile.h index 957db6e..08fa455 100644 --- a/kuickshow/src/kuickfile.h +++ b/kuickshow/src/kuickfile.h @@ -10,8 +10,8 @@ #ifndef KUICKFILE_H #define KUICKFILE_H -#include <qobject.h> -#include <qstring.h> +#include <tqobject.h> +#include <tqstring.h> #include <kurl.h> #include <kprogress.h> @@ -21,12 +21,13 @@ namespace KIO { class FileCopyJob; } -class KuickFile : public QObject +class KuickFile : public TQObject { Q_OBJECT + TQ_OBJECT public: - enum DownloadStatus + enum DownloadtqStatus { OK = 1, CANCELED, @@ -43,7 +44,7 @@ public: const KURL& url() const { return m_url; } - QString localFile() const; + TQString localFile() const; bool download(); @@ -71,7 +72,7 @@ public: * immediately. * @return true when the download has finished or false when the user aborted the dialog */ - KuickFile::DownloadStatus waitForDownload( QWidget *parent ); + KuickFile::DownloadtqStatus waitForDownload( TQWidget *tqparent ); // bool needsDownload(); @@ -87,7 +88,7 @@ private slots: private: KURL m_url; - QString m_localFile; + TQString m_localFile; KIO::FileCopyJob *m_job; KProgress *m_progress; int m_currentProgress; diff --git a/kuickshow/src/kuickimage.cpp b/kuickshow/src/kuickimage.cpp index 29e5de1..894a036 100644 --- a/kuickshow/src/kuickimage.cpp +++ b/kuickshow/src/kuickimage.cpp @@ -1,7 +1,7 @@ #include "kuickimage.h" KuickImage::KuickImage( const KuickFile * file, ImlibImage *im, ImlibData *id) - : QObject( 0L, 0L ) + : TQObject( 0L, 0L ) { myFile = file; myOrigIm = 0L; @@ -82,7 +82,7 @@ void KuickImage::rotate( Rotation rot ) } else if ( rot == ROT_90 || rot == ROT_270 ) { - qSwap( myWidth, myHeight ); + tqSwap( myWidth, myHeight ); Imlib_rotate_image( myId, myIm, -1 ); if ( rot == ROT_90 ) // rotate 90 degrees @@ -178,7 +178,7 @@ void KuickImage::restoreOriginalSize() myIsDirty = true; if ( myRotation == ROT_90 || myRotation == ROT_270 ) - qSwap( myWidth, myHeight ); + tqSwap( myWidth, myHeight ); } void KuickImage::resize( int width, int height, KuickImage::ResizeMode mode ) @@ -212,9 +212,9 @@ bool KuickImage::smoothResize( int newWidth, int newHeight ) { // qDebug("-- smoothResize: %i x %i", newWidth, newHeight); - QImage *image = newQImage(); - // Note: QImage::ScaleMin seems to have a bug (off-by-one, sometimes results in width being 1 pixel too small) - QImage scaledImage = image->smoothScale(newWidth, newHeight, QImage::ScaleFree); + TQImage *image = newTQImage(); + // Note: TQ_ScaleMin seems to have a bug (off-by-one, sometimes results in width being 1 pixel too small) + TQImage scaledImage = image->smoothScale(newWidth, newHeight, TQ_ScaleFree); delete image; @@ -235,11 +235,11 @@ bool KuickImage::smoothResize( int newWidth, int newHeight ) return false; } -QImage * KuickImage::newQImage() const +TQImage * KuickImage::newTQImage() const { ImlibImage *im; -// qDebug("-- newQImage"); +// qDebug("-- newTQImage"); if ( myOrigIm != 0L && myRotation == ROT_0 && myFlipMode == FlipNone ) { @@ -255,9 +255,9 @@ QImage * KuickImage::newQImage() const int w = im->rgb_width; int h = im->rgb_height; - QImage *image = new QImage( w, h, 32 ); + TQImage *image = new TQImage( w, h, 32 ); uchar *rgb = im->rgb_data; - QRgb **destImageData = reinterpret_cast<QRgb**>( image->jumpTable() ); + TQRgb **destImageData = reinterpret_cast<TQRgb**>( image->jumpTable() ); int byteIndex = 0; @@ -275,14 +275,14 @@ QImage * KuickImage::newQImage() const uchar g = rgb[byteIndex++]; uchar b = rgb[byteIndex++]; - QRgb rgbPixel = qRgb( r, g, b ); + TQRgb rgbPixel = tqRgb( r, g, b ); destImageData[destLineIndex][destByteIndex++] = rgbPixel; } return image; } -ImlibImage * KuickImage::toImage( ImlibData *id, QImage& image ) +ImlibImage * KuickImage::toImage( ImlibData *id, TQImage& image ) { if ( image.isNull() ) return 0L; @@ -306,12 +306,12 @@ ImlibImage * KuickImage::toImage( ImlibData *id, QImage& image ) int h = image.height(); for (int y = 0; y < h; y++) { - QRgb *scanLine = reinterpret_cast<QRgb *>( image.scanLine(y) ); + TQRgb *scanLine = reinterpret_cast<TQRgb *>( image.scanLine(y) ); for (int x = 0; x < w; x++) { - const QRgb& pixel = scanLine[x]; - *(newData++) = qRed(pixel); - *(newData++) = qGreen(pixel); - *(newData++) = qBlue(pixel); + const TQRgb& pixel = scanLine[x]; + *(newData++) = tqRed(pixel); + *(newData++) = tqGreen(pixel); + *(newData++) = tqBlue(pixel); } } @@ -339,9 +339,9 @@ bool KuickImage::smoothResize( int newWidth, int newHeight ) // int w = myOrigWidth; //myViewport.width(); //int h = myOrigHeight; //myViewport.height(); - //QImage dst(w, h, myIm->depth(), myIm->numColors(), myIm->bitOrder()); + //TQImage dst(w, h, myIm->depth(), myIm->numColors(), myIm->bitOrder()); - //QRgb *scanline; + //TQRgb *scanline; int basis_ox, basis_oy, basis_xx, basis_yy; @@ -363,10 +363,10 @@ bool KuickImage::smoothResize( int newWidth, int newHeight ) int max_x2 = (myOrigWidth << 12); int max_y2 = (myOrigHeight << 12); -// QRgb background = idata->backgroundColor.rgb(); +// TQRgb background = idata->backgroundColor.rgb(); -// QRgb **imdata = (QRgb **) myIm->jumpTable(); -// QRgb *imdata = reinterpret_cast<QRgb*>( myIm->rgb_data ); +// TQRgb **imdata = (TQRgb **) myIm->jumpTable(); +// TQRgb *imdata = reinterpret_cast<TQRgb*>( myIm->rgb_data ); uchar *imdata = myIm->rgb_data; @@ -380,15 +380,15 @@ bool KuickImage::smoothResize( int newWidth, int newHeight ) // if ((y2 >= 0 && (y2 >> 12) < myIm->height()) || y >= h) // break; // -// scanline = (QRgb*) dst.scanLine(y); +// scanline = (TQRgb*) dst.scanLine(y); // for (int i = 0; i < w; i++) -// *(scanline++) = background; //qRgb(0,255,0); +// *(scanline++) = background; //tqRgb(0,255,0); // y++; // } for (; y < newHeight; y++) { -// scanline = (QRgb*) dst.scanLine(y); +// scanline = (TQRgb*) dst.scanLine(y); x2 = basis_ox; y2 = basis_oy + y * basis_yy; @@ -400,7 +400,7 @@ bool KuickImage::smoothResize( int newWidth, int newHeight ) // while ((x2 < 0 || (x2 >> 12) >= myIm->width()) && x < w) //fill the left of the target pixmap with the background color // { -// *(scanline++) = background; //qRgb(0,0,255); +// *(scanline++) = background; //tqRgb(0,0,255); // x2 += basis_xx; // x++; // } @@ -425,14 +425,14 @@ bool KuickImage::smoothResize( int newWidth, int newHeight ) unsigned int iwx = 0xfff - wx; unsigned int iwy = 0xfff - wy; - QRgb tl = 0, tr = 0, bl = 0, br = 0; + TQRgb tl = 0, tr = 0, bl = 0, br = 0; int ind = 0; ind = (left + top * myOrigWidth) * 3; tl = (imdata[ind] << 16); tl |= (imdata[ind + 1] << 8); tl |= (imdata[ind + 2] << 0); int bar = imdata[ind + 2] << 8; - bar = qBlue(bar); + bar = tqBlue(bar); ind = (right + top * myOrigWidth) * 3; tr = (imdata[ind] << 16); @@ -462,9 +462,9 @@ bool KuickImage::smoothResize( int newWidth, int newHeight ) br=getValidPixel(myIm, right, bottom, x, y); */ - unsigned int r = (unsigned int) (qRed(tl) * iwx * iwy + qRed(tr) * wx* iwy + qRed(bl) * iwx * wy + qRed(br) * wx * wy); // NB 12+12+8 == 32 - unsigned int g = (unsigned int) (qGreen(tl) * iwx * iwy + qGreen(tr) * wx * iwy + qGreen(bl) * iwx * wy + qGreen(br) * wx * wy); - unsigned int b = (unsigned int) (qBlue(tl) * iwx * iwy + qBlue(tr) * wx * iwy + qBlue(bl) * iwx * wy + qBlue(br) * wx * wy); + unsigned int r = (unsigned int) (tqRed(tl) * iwx * iwy + tqRed(tr) * wx* iwy + tqRed(bl) * iwx * wy + tqRed(br) * wx * wy); // NB 12+12+8 == 32 + unsigned int g = (unsigned int) (tqGreen(tl) * iwx * iwy + tqGreen(tr) * wx * iwy + tqGreen(bl) * iwx * wy + tqGreen(br) * wx * wy); + unsigned int b = (unsigned int) (tqBlue(tl) * iwx * iwy + tqBlue(tr) * wx * iwy + tqBlue(bl) * iwx * wy + tqBlue(br) * wx * wy); // ### endianness //we're actually off by one in 255 here! (254 instead of 255) @@ -474,7 +474,7 @@ bool KuickImage::smoothResize( int newWidth, int newHeight ) newImageData[(y * newWidth * 3) + (x * 3) + 0] = (r >> 24); newImageData[(y * newWidth * 3) + (x * 3) + 1] = (g >> 24); newImageData[(y * newWidth * 3) + (x * 3) + 2] = (b >> 24); -// *(scanline++) = qRgb(r >> 24, g >> 24, b >> 24); //we're actually off by one in 255 here +// *(scanline++) = tqRgb(r >> 24, g >> 24, b >> 24); //we're actually off by one in 255 here x2 += basis_xx; @@ -488,7 +488,7 @@ bool KuickImage::smoothResize( int newWidth, int newHeight ) // while (x < w) //fill the right of each scanline with the background colour // { -// *(scanline++) = background; //qRgb(255,0,0); +// *(scanline++) = background; //tqRgb(255,0,0); // x++; // } } @@ -500,9 +500,9 @@ bool KuickImage::smoothResize( int newWidth, int newHeight ) // if (y >= h) // break; // -// scanline = (QRgb*) dst.scanLine(y); +// scanline = (TQRgb*) dst.scanLine(y); // for (int i = 0; i < w; i++) -// *(scanline++) = background; //qRgb(255,255,0); +// *(scanline++) = background; //tqRgb(255,255,0); // y++; // } diff --git a/kuickshow/src/kuickimage.h b/kuickshow/src/kuickimage.h index 745facf..a1875e1 100644 --- a/kuickshow/src/kuickimage.h +++ b/kuickshow/src/kuickimage.h @@ -10,24 +10,25 @@ #ifndef KUICKIMAGE_H #define KUICKIMAGE_H -#include <qimage.h> -#include <qobject.h> +#include <tqimage.h> +#include <tqobject.h> #include <kurl.h> #include "kuickdata.h" #include "kuickfile.h" -// #include those AFTER Qt-includes! +// #include those AFTER TQt-includes! #include <Imlib.h> #include <X11/Xlib.h> #include <X11/Xutil.h> // #include <X11/extensions/shape.h> -class KuickImage : public QObject +class KuickImage : public TQObject { Q_OBJECT + TQ_OBJECT public: enum ResizeMode { FAST, SMOOTH }; @@ -49,7 +50,7 @@ public: ImlibImage * imlibImage() const { return myIm; } Pixmap& pixmap(); void renderPixmap(); -// const QString& filename() const { return myFilename;} +// const TQString& filename() const { return myFilename;} const KuickFile& file() const { return *myFile; } const KURL& url() const { return myFile->url(); } @@ -58,7 +59,7 @@ public: Rotation absRotation() const { return myRotation; } FlipMode flipMode() const { return myFlipMode; } - static ImlibImage * toImage( ImlibData *id, QImage& image ); + static ImlibImage * toImage( ImlibData *id, TQImage& image ); private: void fastResize( int newWidth, int newHeight ); @@ -66,7 +67,7 @@ private: /** * Note: caller must delete it! */ - QImage * newQImage() const; + TQImage * newTQImage() const; const KuickFile * myFile; diff --git a/kuickshow/src/kuickshow.cpp b/kuickshow/src/kuickshow.cpp index 7e8718f..d793b84 100644 --- a/kuickshow/src/kuickshow.cpp +++ b/kuickshow/src/kuickshow.cpp @@ -19,14 +19,14 @@ #include <stdio.h> #include <assert.h> -#include <qdir.h> -#include <qdesktopwidget.h> -#include <qdialog.h> -#include <qglobal.h> -#include <qkeycode.h> -#include <qlayout.h> -#include <qsize.h> -#include <qstring.h> +#include <tqdir.h> +#include <tqdesktopwidget.h> +#include <tqdialog.h> +#include <tqglobal.h> +#include <tqkeycode.h> +#include <tqlayout.h> +#include <tqsize.h> +#include <tqstring.h> #include <kaboutdata.h> #include <kaccel.h> @@ -89,7 +89,7 @@ KuickData* kdata; static const int URL_ITEM = 0; static const int META_ITEM = 1; -QValueList<ImageWindow*> KuickShow::s_viewers; +TQValueList<ImageWindow*> KuickShow::s_viewers; KuickShow::KuickShow( const char *name ) : KMainWindow( 0L, name ), @@ -110,8 +110,8 @@ KuickShow::KuickShow( const char *name ) initImlib(); resize( 400, 500 ); - m_slideTimer = new QTimer( this ); - connect( m_slideTimer, SIGNAL( timeout() ), SLOT( nextSlide() )); + m_slideTimer = new TQTimer( this ); + connect( m_slideTimer, TQT_SIGNAL( timeout() ), TQT_SLOT( nextSlide() )); KConfig *kc = KGlobal::config(); @@ -124,7 +124,7 @@ KuickShow::KuickShow( const char *name ) // files to display // either a directory to display, an absolute path, a relative path, or a URL KURL startDir; - startDir.setPath( QDir::currentDirPath() + '/' ); + startDir.setPath( TQDir::currentDirPath() + '/' ); int numArgs = args->count(); if ( numArgs >= 10 ) @@ -133,7 +133,7 @@ KuickShow::KuickShow( const char *name ) if ( KMessageBox::warningYesNo( this, i18n("Do you really want to display this 1 image at the same time? This might be quite resource intensive and could overload your computer.<br>If you choose %1, only the first image will be shown.", - "Do you really want to display these %n images at the same time? This might be quite resource intensive and could overload your computer.<br>If you choose %1, only the first image will be shown.", numArgs).arg(KStdGuiItem::no().plainText()), + "Do you really want to display these %n images at the same time? This might be quite resource intensive and could overload your computer.<br>If you choose %1, only the first image will be shown.", numArgs).tqarg(KStdGuiItem::no().plainText()), i18n("Display Multiple Images?")) != KMessageBox::Yes ) { @@ -164,7 +164,7 @@ KuickShow::KuickShow( const char *name ) else if ( !url.isLocalFile() ) { KMimeType::Ptr mime = KMimeType::findByURL( url ); - QString name = mime->name(); + TQString name = mime->name(); if ( name == "application/octet-stream" ) // unknown -> stat() name = KIO::NetAccess::mimetype( url, this ); @@ -231,39 +231,39 @@ void KuickShow::initGUI( const KURL& startDir ) redirectDeleteAndTrashActions(coll); - connect( fileWidget, SIGNAL( fileSelected( const KFileItem * ) ), - this, SLOT( slotSelected( const KFileItem * ) )); + connect( fileWidget, TQT_SIGNAL( fileSelected( const KFileItem * ) ), + TQT_TQOBJECT(this), TQT_SLOT( slotSelected( const KFileItem * ) )); - connect( fileWidget, SIGNAL( fileHighlighted( const KFileItem * )), - this, SLOT( slotHighlighted( const KFileItem * ) )); + connect( fileWidget, TQT_SIGNAL( fileHighlighted( const KFileItem * )), + TQT_TQOBJECT(this), TQT_SLOT( slotHighlighted( const KFileItem * ) )); - connect( fileWidget, SIGNAL( urlEntered( const KURL& )), - this, SLOT( dirSelected( const KURL& )) ); + connect( fileWidget, TQT_SIGNAL( urlEntered( const KURL& )), + TQT_TQOBJECT(this), TQT_SLOT( dirSelected( const KURL& )) ); fileWidget->setAcceptDrops(true); - connect( fileWidget, SIGNAL( dropped( const KFileItem *, QDropEvent *, const KURL::List & )), - this, SLOT( slotDropped( const KFileItem *, QDropEvent *, const KURL::List &)) ); + connect( fileWidget, TQT_SIGNAL( dropped( const KFileItem *, TQDropEvent *, const KURL::List & )), + TQT_TQOBJECT(this), TQT_SLOT( slotDropped( const KFileItem *, TQDropEvent *, const KURL::List &)) ); // setup actions - KAction *open = KStdAction::open( this, SLOT( slotOpenURL() ), + KAction *open = KStdAction::open( TQT_TQOBJECT(this), TQT_SLOT( slotOpenURL() ), coll, "openURL" ); - KAction *print = KStdAction::print( this, SLOT( slotPrint() ), + KAction *print = KStdAction::print( TQT_TQOBJECT(this), TQT_SLOT( slotPrint() ), coll, "kuick_print" ); print->setText( i18n("Print Image...") ); - KAction *configure = new KAction( i18n("Configure %1...").arg( KGlobal::instance()->aboutData()->programName() ), "configure", + KAction *configure = new KAction( i18n("Configure %1...").tqarg( KGlobal::instance()->aboutData()->programName() ), "configure", KShortcut(), - this, SLOT( configuration() ), + TQT_TQOBJECT(this), TQT_SLOT( configuration() ), coll, "kuick_configure" ); KAction *slide = new KAction( i18n("Start Slideshow" ), "ksslide", KShortcut( Key_F2 ), - this, SLOT( startSlideShow() ), + TQT_TQOBJECT(this), TQT_SLOT( startSlideShow() ), coll, "kuick_slideshow" ); KAction *about = new KAction( i18n( "About KuickShow" ), "about", KShortcut(), - this, SLOT( about() ), coll, "about" ); + TQT_TQOBJECT(this), TQT_SLOT( about() ), coll, "about" ); oneWindowAction = new KToggleAction( i18n("Open Only One Image Window"), "window_new", @@ -272,29 +272,29 @@ void KuickShow::initGUI( const KURL& startDir ) m_toggleBrowserAction = new KToggleAction( i18n("Show File Browser"), KShortcut( Key_Space ), coll, "toggleBrowser" ); m_toggleBrowserAction->setCheckedState(i18n("Hide File Browser")); - connect( m_toggleBrowserAction, SIGNAL( toggled( bool ) ), - SLOT( toggleBrowser() )); + connect( m_toggleBrowserAction, TQT_SIGNAL( toggled( bool ) ), + TQT_SLOT( toggleBrowser() )); KAction *showInOther = new KAction( i18n("Show Image"), KShortcut(), - this, SLOT( slotShowInOtherWindow() ), + TQT_TQOBJECT(this), TQT_SLOT( slotShowInOtherWindow() ), coll, "kuick_showInOtherWindow" ); KAction *showInSame = new KAction( i18n("Show Image in Active Window"), KShortcut(), - this, SLOT( slotShowInSameWindow() ), + TQT_TQOBJECT(this), TQT_SLOT( slotShowInSameWindow() ), coll, "kuick_showInSameWindow" ); KAction *showFullscreen = new KAction( i18n("Show Image in Fullscreen Mode"), - KShortcut(), this, SLOT( slotShowFullscreen() ), + KShortcut(), TQT_TQOBJECT(this), TQT_SLOT( slotShowFullscreen() ), coll, "kuick_showFullscreen" ); - KAction *quit = KStdAction::quit( this, SLOT(slotQuit()), coll, "quit"); + KAction *quit = KStdAction::quit( TQT_TQOBJECT(this), TQT_SLOT(slotQuit()), coll, "quit"); - // remove QString::null parameter -- ellis - coll->readShortcutSettings( QString::null ); + // remove TQString() parameter -- ellis + coll->readShortcutSettings( TQString() ); m_accel = coll->accel(); // menubar KMenuBar *mBar = menuBar(); - QPopupMenu *fileMenu = new QPopupMenu( mBar, "file" ); + TQPopupMenu *fileMenu = new TQPopupMenu( mBar, "file" ); open->plug( fileMenu ); showInOther->plug( fileMenu ); showInSame->plug( fileMenu ); @@ -305,7 +305,7 @@ void KuickShow::initGUI( const KURL& startDir ) fileMenu->insertSeparator(); quit->plug( fileMenu ); - QPopupMenu *editMenu = new QPopupMenu( mBar, "edit" ); + TQPopupMenu *editMenu = new TQPopupMenu( mBar, "edit" ); coll->action("mkdir")->plug( editMenu ); coll->action("delete")->plug( editMenu ); editMenu->insertSeparator(); @@ -316,10 +316,10 @@ void KuickShow::initGUI( const KURL& startDir ) // from the main contextmenu KActionMenu *sortingMenu = static_cast<KActionMenu*>( coll->action("sorting menu")); KActionMenu *mainActionMenu = static_cast<KActionMenu*>( coll->action("popupMenu")); - QPopupMenu *mainPopup = mainActionMenu->popupMenu(); + TQPopupMenu *mainPopup = mainActionMenu->popupMenu(); int sortingIndex = mainPopup->indexOf( sortingMenu->itemId( 0 ) ); int separatorId = mainPopup->idAt( sortingIndex + 1 ); - QMenuItem *separatorItem = mainPopup->findItem( separatorId ); + TQMenuItem *separatorItem = mainPopup->tqfindItem( separatorId ); if ( separatorItem && separatorItem->isSeparator() ) mainPopup->removeItem( separatorId ); mainActionMenu->remove( sortingMenu ); @@ -330,7 +330,7 @@ void KuickShow::initGUI( const KURL& startDir ) sortingMenu->plug( viewActionMenu->popupMenu(), 0 ); // on top of the menu - QPopupMenu *settingsMenu = new QPopupMenu( mBar, "settings" ); + TQPopupMenu *settingsMenu = new TQPopupMenu( mBar, "settings" ); configure->plug( settingsMenu ); mBar->insertItem( i18n("&File"), fileMenu ); @@ -363,14 +363,14 @@ void KuickShow::initGUI( const KURL& startDir ) tBar->insertSeparator(); about->plug( tBar ); - QPopupMenu *help = helpMenu( QString::null, false ); + TQPopupMenu *help = helpMenu( TQString(), false ); mBar->insertItem( KStdGuiItem::help().text() , help ); KStatusBar* sBar = statusBar(); sBar->insertItem( " ", URL_ITEM, 10 ); sBar->insertItem( " ", META_ITEM, 2 ); - sBar->setItemAlignment(URL_ITEM, QLabel::AlignVCenter | QLabel::AlignLeft); + sBar->setItemAlignment(URL_ITEM, TQLabel::AlignVCenter | TQLabel::AlignLeft); fileWidget->setFocus(); @@ -394,10 +394,10 @@ void KuickShow::initGUI( const KURL& startDir ) addressToolBar->insertWidget( ID_ADDRESSBAR, 1, cmbPath); addressToolBar->setItemAutoSized( ID_ADDRESSBAR ); - connect( cmbPath, SIGNAL( urlActivated( const KURL& )), - this, SLOT( slotSetURL( const KURL& ))); - connect( cmbPath, SIGNAL( returnPressed()), - this, SLOT( slotURLComboReturnPressed())); + connect( cmbPath, TQT_SIGNAL( urlActivated( const KURL& )), + TQT_TQOBJECT(this), TQT_SLOT( slotSetURL( const KURL& ))); + connect( cmbPath, TQT_SIGNAL( returnPressed()), + TQT_TQOBJECT(this), TQT_SLOT( slotURLComboReturnPressed())); fileWidget->initActions(); @@ -422,14 +422,14 @@ void KuickShow::redirectDeleteAndTrashActions(KActionCollection *coll) if (action) { action->disconnect(fileWidget); - connect(action, SIGNAL(activated()), this, SLOT(slotDeleteCurrentImage())); + connect(action, TQT_SIGNAL(activated()), TQT_TQOBJECT(this), TQT_SLOT(slotDeleteCurrentImage())); } action = coll->action("trash"); if (action) { action->disconnect(fileWidget); - connect(action, SIGNAL(activated()), this, SLOT(slotTrashCurrentImage())); + connect(action, TQT_SIGNAL(activated()), TQT_TQOBJECT(this), TQT_SLOT(slotTrashCurrentImage())); } } @@ -478,7 +478,7 @@ void KuickShow::slotHighlighted( const KFileItem *fi ) statusBar()->changeItem( item->getStatusBarInfo(), URL_ITEM ); bool image = FileWidget::isImage( fi ); - QString meta; + TQString meta; if ( image ) { KFileMetaInfo info = item->metaInfo(); @@ -488,7 +488,7 @@ void KuickShow::slotHighlighted( const KFileItem *fi ) KFileMetaInfoGroup group = info.group( "Technical" ); if ( group.isValid() ) { - QString bpp = group.item( "BitDepth" ).string(); + TQString bpp = group.item( "BitDepth" ).string(); if ( !bpp.isEmpty() ) meta.append( ", " ).append( bpp ); } @@ -537,22 +537,22 @@ bool KuickShow::showImage( const KFileItem *fi, m_viewer->setFullscreen( fullscreen ); s_viewers.append( m_viewer ); - connect( m_viewer, SIGNAL( destroyed() ), SLOT( viewerDeleted() )); - connect( m_viewer, SIGNAL( sigFocusWindow( ImageWindow *) ), - this, SLOT( slotSetActiveViewer( ImageWindow * ) )); - connect( m_viewer, SIGNAL( sigImageError(const KuickFile *, const QString& ) ), - this, SLOT( messageCantLoadImage(const KuickFile *, const QString &) )); - connect( m_viewer, SIGNAL( requestImage( ImageWindow *, int )), - this, SLOT( slotAdvanceImage( ImageWindow *, int ))); - connect( m_viewer, SIGNAL( pauseSlideShowSignal() ), - this, SLOT( pauseSlideShow() ) ); - connect( m_viewer, SIGNAL (deleteImage (ImageWindow *)), - this, SLOT (slotDeleteCurrentImage (ImageWindow *))); - connect( m_viewer, SIGNAL (trashImage (ImageWindow *)), - this, SLOT (slotTrashCurrentImage (ImageWindow *))); + connect( m_viewer, TQT_SIGNAL( destroyed() ), TQT_SLOT( viewerDeleted() )); + connect( m_viewer, TQT_SIGNAL( sigFocusWindow( ImageWindow *) ), + TQT_TQOBJECT(this), TQT_SLOT( slotSetActiveViewer( ImageWindow * ) )); + connect( m_viewer, TQT_SIGNAL( sigImageError(const KuickFile *, const TQString& ) ), + TQT_TQOBJECT(this), TQT_SLOT( messageCantLoadImage(const KuickFile *, const TQString &) )); + connect( m_viewer, TQT_SIGNAL( requestImage( ImageWindow *, int )), + TQT_TQOBJECT(this), TQT_SLOT( slotAdvanceImage( ImageWindow *, int ))); + connect( m_viewer, TQT_SIGNAL( pauseSlideShowSignal() ), + TQT_TQOBJECT(this), TQT_SLOT( pauseSlideShow() ) ); + connect( m_viewer, TQT_SIGNAL (deleteImage (ImageWindow *)), + TQT_TQOBJECT(this), TQT_SLOT (slotDeleteCurrentImage (ImageWindow *))); + connect( m_viewer, TQT_SIGNAL (trashImage (ImageWindow *)), + TQT_TQOBJECT(this), TQT_SLOT (slotTrashCurrentImage (ImageWindow *))); if ( s_viewers.count() == 1 && moveToTopLeft ) { // we have to move to 0x0 before showing _and_ - // after showing, otherwise we get some bogus geometry() + // after showing, otherwise we get some bogus tqgeometry() m_viewer->move( Kuick::workArea().topLeft() ); } @@ -568,7 +568,7 @@ bool KuickShow::showImage( const KFileItem *fi, ImageWindow *safeViewer = m_viewer; // file->waitForDownload( this ); -// QString filename; +// TQString filename; // KIO::NetAccess::download(fi->url(), filename, this); if ( !safeViewer->showNextImage( fi->url() ) ) { @@ -631,7 +631,7 @@ void KuickShow::slotTrashCurrentImage(ImageWindow *viewer) performTrashCurrentImage(viewer); } -void KuickShow::performDeleteCurrentImage(QWidget *parent) +void KuickShow::performDeleteCurrentImage(TQWidget *tqparent) { assert(fileWidget != 0L); @@ -640,8 +640,8 @@ void KuickShow::performDeleteCurrentImage(QWidget *parent) list.append (item); if (KMessageBox::warningContinueCancel( - parent, - i18n("<qt>Do you really want to delete\n <b>'%1'</b>?</qt>").arg(item->url().pathOrURL()), + tqparent, + i18n("<qt>Do you really want to delete\n <b>'%1'</b>?</qt>").tqarg(item->url().pathOrURL()), i18n("Delete File"), KStdGuiItem::del(), "Kuick_delete_current_image") @@ -654,7 +654,7 @@ void KuickShow::performDeleteCurrentImage(QWidget *parent) fileWidget->del(list, false, false); } -void KuickShow::performTrashCurrentImage(QWidget *parent) +void KuickShow::performTrashCurrentImage(TQWidget *tqparent) { assert(fileWidget != 0L); @@ -665,8 +665,8 @@ void KuickShow::performTrashCurrentImage(QWidget *parent) list.append (item); if (KMessageBox::warningContinueCancel( - parent, - i18n("<qt>Do you really want to trash\n <b>'%1'</b>?</qt>").arg(item->url().pathOrURL()), + tqparent, + i18n("<qt>Do you really want to trash\n <b>'%1'</b>?</qt>").tqarg(item->url().pathOrURL()), i18n("Trash File"), KGuiItem(i18n("to trash", "&Trash"),"edittrash"), "Kuick_trash_current_image") @@ -676,7 +676,7 @@ void KuickShow::performTrashCurrentImage(QWidget *parent) } tryShowNextImage(); - fileWidget->trash(list, parent, false, false); + fileWidget->trash(list, tqparent, false, false); } void KuickShow::tryShowNextImage() @@ -698,7 +698,7 @@ void KuickShow::tryShowNextImage() if (!haveBrowser()) { // ### when simply calling toggleBrowser(), this main window is completely messed up - QTimer::singleShot(0, this, SLOT(toggleBrowser())); + TQTimer::singleShot(0, TQT_TQOBJECT(this), TQT_SLOT(toggleBrowser())); } m_viewer->deleteLater(); } @@ -805,7 +805,7 @@ void KuickShow::slotShowFullscreen() showImage( fileWidget->getCurrentItem( false ), false, true ); } -void KuickShow::slotDropped( const KFileItem *, QDropEvent *, const KURL::List &urls) +void KuickShow::slotDropped( const KFileItem *, TQDropEvent *, const KURL::List &urls) { KURL::List::ConstIterator it = urls.begin(); for ( ; it != urls.end(); ++it ) @@ -855,7 +855,7 @@ void KuickShow::slotAdvanceImage( ImageWindow *view, int steps ) } if ( FileWidget::isImage( item ) ) { -// QString filename; +// TQString filename; // KIO::NetAccess::download(item->url(), filename, this); view->showNextImage( item->url() ); if (m_slideTimer->isActive() && kdata->slideDelay) @@ -869,7 +869,7 @@ void KuickShow::slotAdvanceImage( ImageWindow *view, int steps ) } } -bool KuickShow::eventFilter( QObject *o, QEvent *e ) +bool KuickShow::eventFilter( TQObject *o, TQEvent *e ) { if ( m_delayedRepeatItem ) // we probably need to install an eventFilter over { @@ -878,9 +878,9 @@ bool KuickShow::eventFilter( QObject *o, QEvent *e ) bool ret = false; int eventType = e->type(); - QKeyEvent *k = 0L; - if ( eventType == QEvent::KeyPress ) - k = static_cast<QKeyEvent *>( e ); + TQKeyEvent *k = 0L; + if ( eventType == TQEvent::KeyPress ) + k = TQT_TQKEYEVENT( e ); if ( k ) { if ( KStdAccel::quit().contains( KKey( k ) ) ) { @@ -903,11 +903,11 @@ bool KuickShow::eventFilter( QObject *o, QEvent *e ) // switching images, causing enter- and leaveevents for this // ImageWindow, leading to the cursor being unhidden. So we simply // don't pass those events to KCursor to prevent that. - if ( eventType != QEvent::Leave && eventType != QEvent::Enter ) + if ( eventType != TQEvent::Leave && eventType != TQEvent::Enter ) KCursor::autoHideEventFilter( o, e ); m_viewer = window; - QString img; + TQString img; KFileItem *item = 0L; // the image to be shown KFileItem *item_next = 0L; // the image to be cached @@ -925,7 +925,7 @@ bool KuickShow::eventFilter( QObject *o, QEvent *e ) if ( key != Key_Escape && key != Key_Shift && key != Key_Alt ) { KuickFile *file = m_viewer->currentFile(); -// QFileInfo fi( m_viewer->filename() ); +// TQFileInfo fi( m_viewer->filename() ); // start.setPath( fi.dirPath( true ) ); initGUI( file->url().upURL() ); @@ -952,7 +952,7 @@ bool KuickShow::eventFilter( QObject *o, QEvent *e ) if ( fileWidget->dirLister()->rootItem() ) { fileWidget->setCurrentItem( file->url().fileName() ); - QTimer::singleShot( 0, this, SLOT( slotReplayEvent())); + TQTimer::singleShot( 0, TQT_TQOBJECT(this), TQT_SLOT( slotReplayEvent())); } else // finished, but no root-item -- probably an error, kill repeat-item! { @@ -962,8 +962,8 @@ bool KuickShow::eventFilter( QObject *o, QEvent *e ) else // not finished yet { fileWidget->setInitialItem( file->url().fileName() ); - connect( fileWidget, SIGNAL( finished() ), - SLOT( slotReplayEvent() )); + connect( fileWidget, TQT_SIGNAL( finished() ), + TQT_SLOT( slotReplayEvent() )); } return true; @@ -1018,7 +1018,7 @@ bool KuickShow::eventFilter( QObject *o, QEvent *e ) if ( FileWidget::isImage( item ) ) { -// QString filename; +// TQString filename; // KIO::NetAccess::download(item->url(), filename, this); m_viewer->showNextImage( item->url() ); @@ -1034,17 +1034,17 @@ bool KuickShow::eventFilter( QObject *o, QEvent *e ) // doubleclick closes image window // and shows browser when last window closed via doubleclick - else if ( eventType == QEvent::MouseButtonDblClick ) + else if ( eventType == TQEvent::MouseButtonDblClick ) { - QMouseEvent *ev = static_cast<QMouseEvent*>( e ); - if ( ev->button() == LeftButton ) + TQMouseEvent *ev = TQT_TQMOUSEEVENT( e ); + if ( ev->button() == Qt::LeftButton ) { if ( s_viewers.count() == 1 ) { if ( !fileWidget ) { // KURL start; -// QFileInfo fi( window->filename() ); +// TQFileInfo fi( window->filename() ); // start.setPath( fi.dirPath( true ) ); initGUI( window->currentFile()->url().fileName() ); } @@ -1072,8 +1072,8 @@ void KuickShow::configuration() { if ( !m_accel ) { KURL start; - start.setPath( QDir::homeDirPath() ); - initGUI( KURL::fromPathOrURL( QDir::homeDirPath() ) ); + start.setPath( TQDir::homeDirPath() ); + initGUI( KURL::fromPathOrURL( TQDir::homeDirPath() ) ); } dialog = new KuickConfigDialog( fileWidget->actionCollection(), 0L, @@ -1081,12 +1081,12 @@ void KuickShow::configuration() dialog->resize( 540, 510 ); dialog->setIcon( kapp->miniIcon() ); - connect( dialog, SIGNAL( okClicked() ), - this, SLOT( slotConfigApplied() ) ); - connect( dialog, SIGNAL( applyClicked() ), - this, SLOT( slotConfigApplied() ) ); - connect( dialog, SIGNAL( finished() ), - this, SLOT( slotConfigClosed() ) ); + connect( dialog, TQT_SIGNAL( okClicked() ), + TQT_TQOBJECT(this), TQT_SLOT( slotConfigApplied() ) ); + connect( dialog, TQT_SIGNAL( applyClicked() ), + TQT_TQOBJECT(this), TQT_SLOT( slotConfigApplied() ) ); + connect( dialog, TQT_SIGNAL( finished() ), + TQT_TQOBJECT(this), TQT_SLOT( slotConfigClosed() ) ); fileWidget->actionCollection()->action( "kuick_configure" )->setEnabled( false ); dialog->show(); @@ -1101,7 +1101,7 @@ void KuickShow::slotConfigApplied() kdata->save(); ImageWindow *viewer; - QValueListIterator<ImageWindow*> it = s_viewers.begin(); + TQValueListIterator<ImageWindow*> it = s_viewers.begin(); while ( it != s_viewers.end() ) { viewer = *it; viewer->updateActions(); @@ -1129,12 +1129,12 @@ void KuickShow::about() KDialog::centerOnScreen( aboutWidget ); #else // Not fixed because it must be dead code now. - QDesktopWidget *desktop = QApplication::desktop(); + TQDesktopWidget *desktop = TQApplication::desktop(); int screen = desktop->screenNumber( aboutWidget ); if ( screen == -1 ) screen = desktop->primaryScreen(); - QRect r = desktop->screenGeometry( screen ); + TQRect r = desktop->screenGeometry( screen ); aboutWidget->move( r.center().x() - aboutWidget->width()/2, r.center().y() - aboutWidget->height()/2 ); #endif @@ -1146,15 +1146,15 @@ void KuickShow::about() void KuickShow::readProperties( KConfig *kc ) { assert( fileWidget ); // from SM, we should always have initGUI on startup - QString dir = kc->readPathEntry( "CurrentDirectory" ); + TQString dir = kc->readPathEntry( "CurrentDirectory" ); if ( !dir.isEmpty() ) { fileWidget->setURL( KURL::fromPathOrURL( dir ), true ); fileWidget->clearHistory(); } const KURL& listedURL = fileWidget->url(); - QStringList images = kc->readPathListEntry( "Images shown" ); - QStringList::Iterator it; + TQStringList images = kc->readPathListEntry( "Images shown" ); + TQStringList::Iterator it; bool hasCurrentURL = false; for ( it = images.begin(); it != images.end(); ++it ) { @@ -1179,8 +1179,8 @@ void KuickShow::saveProperties( KConfig *kc ) if (fileWidget) kc->writePathEntry( "CurrentDirectory", fileWidget->url().url() ); - QStringList urls; - QValueListIterator<ImageWindow*> it; + TQStringList urls; + TQValueListIterator<ImageWindow*> it; for ( it = s_viewers.begin(); it != s_viewers.end(); ++it ) { const KURL& url = (*it)->currentFile()->url(); @@ -1212,7 +1212,7 @@ void KuickShow::saveSettings() } -void KuickShow::messageCantLoadImage( const KuickFile *, const QString& message ) +void KuickShow::messageCantLoadImage( const KuickFile *, const TQString& message ) { m_viewer->clearFocus(); KMessageBox::information( m_viewer, message, i18n("Error"), "kuick_cant_load_image" ); @@ -1229,7 +1229,7 @@ void KuickShow::initImlib() initImlibParams( idata, &par ); qWarning("*** KuickShow: Whoops, can't initialize imlib, trying my own palettefile now."); - QString paletteFile = locate( "data", "kuickshow/im_palette.pal" ); + TQString paletteFile = locate( "data", "kuickshow/im_palette.pal" ); // ### - does the qstrdup() cure the segfault in imlib eventually? char *file = qstrdup( paletteFile.local8Bit() ); par.palettefile = file; @@ -1240,7 +1240,7 @@ void KuickShow::initImlib() id = Imlib_init_with_params( x11Display(), &par ); if ( !id ) { - QString tmp = i18n("Unable to initialize \"Imlib\".\n" + TQString tmp = i18n("Unable to initialize \"Imlib\".\n" "Start kuickshow from the command line " "and look for error messages.\n" "The program will now quit."); @@ -1281,9 +1281,9 @@ bool KuickShow::haveBrowser() const return fileWidget && fileWidget->isVisible(); } -void KuickShow::delayedRepeatEvent( ImageWindow *w, QKeyEvent *e ) +void KuickShow::delayedRepeatEvent( ImageWindow *w, TQKeyEvent *e ) { - m_delayedRepeatItem = new DelayedRepeatEvent( w, new QKeyEvent( *e ) ); + m_delayedRepeatItem = new DelayedRepeatEvent( w, new TQKeyEvent( *e ) ); } void KuickShow::abortDelayedEvent() @@ -1294,19 +1294,19 @@ void KuickShow::abortDelayedEvent() void KuickShow::slotReplayEvent() { - disconnect( fileWidget, SIGNAL( finished() ), - this, SLOT( slotReplayEvent() )); + disconnect( fileWidget, TQT_SIGNAL( finished() ), + TQT_TQOBJECT(this), TQT_SLOT( slotReplayEvent() )); DelayedRepeatEvent *e = m_delayedRepeatItem; m_delayedRepeatItem = 0L; // otherwise, eventFilter aborts - eventFilter( e->viewer, e->event ); + eventFilter( TQT_TQOBJECT(e->viewer), TQT_TQEVENT(e->event) ); delete e; - // ### WORKAROUND for QIconView bug in Qt <= 3.0.3 at least + // ### WORKAROUND for TQIconView bug in TQt <= 3.0.3 at least if ( fileWidget && fileWidget->view() ) { - QWidget *widget = fileWidget->view()->widget(); - if ( widget->inherits( "QIconView" ) || widget->child(0, "QIconView" ) ){ + TQWidget *widget = fileWidget->view()->widget(); + if ( widget->inherits( TQICONVIEW_OBJECT_NAME_STRING ) || widget->child(0, TQICONVIEW_OBJECT_NAME_STRING ) ){ fileWidget->setSorting( fileWidget->sorting() ); } } @@ -1315,12 +1315,12 @@ void KuickShow::slotReplayEvent() void KuickShow::replayAdvance(DelayedRepeatEvent *event) { - // ### WORKAROUND for QIconView bug in Qt <= 3.0.3 at least + // ### WORKAROUND for TQIconView bug in TQt <= 3.0.3 at least // Sigh. According to qt-bugs, they won't fix this bug ever. So you can't - // rely on sorting to be correct before the QIconView has been show()n. + // rely on sorting to be correct before the TQIconView has been show()n. if ( fileWidget && fileWidget->view() ) { - QWidget *widget = fileWidget->view()->widget(); - if ( widget->inherits( "QIconView" ) || widget->child(0, "QIconView" ) ){ + TQWidget *widget = fileWidget->view()->widget(); + if ( widget->inherits( TQICONVIEW_OBJECT_NAME_STRING ) || widget->child(0, TQICONVIEW_OBJECT_NAME_STRING ) ){ fileWidget->setSorting( fileWidget->sorting() ); } } @@ -1337,7 +1337,7 @@ void KuickShow::delayAction(DelayedRepeatEvent *event) m_delayedRepeatItem = event; KURL url = event->viewer->currentFile()->url(); -// QFileInfo fi( event->viewer->filename() ); +// TQFileInfo fi( event->viewer->filename() ); // start.setPath( fi.dirPath( true ) ); initGUI( url.upURL() ); @@ -1346,13 +1346,13 @@ void KuickShow::delayAction(DelayedRepeatEvent *event) fileWidget->dirLister()->rootItem() ) { fileWidget->setCurrentItem( url.fileName() ); - QTimer::singleShot( 0, this, SLOT( doReplay())); + TQTimer::singleShot( 0, TQT_TQOBJECT(this), TQT_SLOT( doReplay())); } else { fileWidget->setInitialItem( url.fileName() ); - connect( fileWidget, SIGNAL( finished() ), - SLOT( doReplay() )); + connect( fileWidget, TQT_SIGNAL( finished() ), + TQT_SLOT( doReplay() )); } } @@ -1361,16 +1361,16 @@ void KuickShow::doReplay() if (!m_delayedRepeatItem) return; - disconnect( fileWidget, SIGNAL( finished() ), - this, SLOT( doReplay() )); + disconnect( fileWidget, TQT_SIGNAL( finished() ), + TQT_TQOBJECT(this), TQT_SLOT( doReplay() )); switch (m_delayedRepeatItem->action) { case DelayedRepeatEvent::DeleteCurrentFile: - performDeleteCurrentImage((QWidget *) m_delayedRepeatItem->data); + performDeleteCurrentImage((TQWidget *) m_delayedRepeatItem->data); break; case DelayedRepeatEvent::TrashCurrentFile: - performTrashCurrentImage((QWidget *) m_delayedRepeatItem->data); + performTrashCurrentImage((TQWidget *) m_delayedRepeatItem->data); break; case DelayedRepeatEvent::AdvanceViewer: replayAdvance(m_delayedRepeatItem); @@ -1401,11 +1401,11 @@ void KuickShow::toggleBrowser() void KuickShow::slotOpenURL() { - KFileDialog dlg(QString::null, kdata->fileFilter, this, "filedialog", true); + KFileDialog dlg(TQString(), kdata->fileFilter, this, "filedialog", true); dlg.setMode( KFile::Files | KFile::Directory ); dlg.setCaption( i18n("Select Files or Folder to Open") ); - if ( dlg.exec() == QDialog::Accepted ) + if ( dlg.exec() == TQDialog::Accepted ) { KURL::List urls = dlg.selectedURLs(); KURL::List::ConstIterator it = urls.begin(); @@ -1422,9 +1422,9 @@ void KuickShow::slotOpenURL() void KuickShow::deleteAllViewers() { - QValueListIterator<ImageWindow*> it = s_viewers.begin(); + TQValueListIterator<ImageWindow*> it = s_viewers.begin(); for ( ; it != s_viewers.end(); ++it ) { - (*it)->disconnect( SIGNAL( destroyed() ), this, SLOT( viewerDeleted() )); + (*it)->disconnect( TQT_SIGNAL( destroyed() ), TQT_TQOBJECT(this), TQT_SLOT( viewerDeleted() )); (*it)->close( true ); } diff --git a/kuickshow/src/kuickshow.h b/kuickshow/src/kuickshow.h index d6239b6..f45027d 100644 --- a/kuickshow/src/kuickshow.h +++ b/kuickshow/src/kuickshow.h @@ -19,10 +19,10 @@ #ifndef KUICKSHOW_H #define KUICKSHOW_H -#include <qevent.h> -#include <qguardedptr.h> -#include <qstring.h> -#include <qvaluelist.h> +#include <tqevent.h> +#include <tqguardedptr.h> +#include <tqstring.h> +#include <tqvaluelist.h> #include <kfileitem.h> #include <kmainwindow.h> @@ -50,7 +50,7 @@ class KuickFile; class DelayedRepeatEvent { public: - DelayedRepeatEvent( ImageWindow *view, QKeyEvent *ev ) { + DelayedRepeatEvent( ImageWindow *view, TQKeyEvent *ev ) { viewer = view; event = ev; } @@ -73,7 +73,7 @@ public: }; ImageWindow *viewer; - QKeyEvent *event; + TQKeyEvent *event; int action; void *data; }; @@ -82,13 +82,14 @@ public: class KuickShow : public KMainWindow { Q_OBJECT + TQ_OBJECT public: KuickShow( const char *name=0 ); ~KuickShow(); virtual void show(); - static QValueList<ImageWindow*> s_viewers; + static TQValueList<ImageWindow*> s_viewers; // overridden to make KDCOPActionProxy work -- all our actions are not // in the mainwindow's collection, but in the filewidget's. @@ -106,7 +107,7 @@ private slots: void slotPrint(); void slotConfigApplied(); void slotConfigClosed(); - void messageCantLoadImage( const KuickFile * file, const QString& message); + void messageCantLoadImage( const KuickFile * file, const TQString& message); bool showImage(const KFileItem *, bool newWindow = false, bool fullscreen = false, bool moveToTopLeft = true ); void showFileItem( ImageWindow *, const KFileItem * ); @@ -120,7 +121,7 @@ private slots: void nextSlide(); void nextSlide( KFileItem *item ); void viewerDeleted(); - void slotDropped( const KFileItem *, QDropEvent *, const KURL::List &); + void slotDropped( const KFileItem *, TQDropEvent *, const KURL::List &); void slotSetActiveViewer( ImageWindow *i ) { m_viewer = i; } void slotAdvanceImage( ImageWindow *, int steps ); @@ -132,7 +133,7 @@ private slots: void slotOpenURL(); void slotSetURL( const KURL& ); void slotURLComboReturnPressed(); -// void invalidateImages( const KFileItemList& items ); +// void tqinvalidateImages( const KFileItemList& items ); void slotDeleteCurrentImage(ImageWindow *viewer); void slotTrashCurrentImage(ImageWindow *viewer); void slotDeleteCurrentImage(); @@ -142,12 +143,12 @@ private slots: private: void initGUI( const KURL& startDir ); - bool eventFilter( QObject *, QEvent * ); + bool eventFilter( TQObject *, TQEvent * ); void initImlib(); void saveProperties( KConfig * ); void saveSettings(); bool haveBrowser() const; - void delayedRepeatEvent( ImageWindow *, QKeyEvent * ); + void delayedRepeatEvent( ImageWindow *, TQKeyEvent * ); void abortDelayedEvent(); void deleteAllViewers(); void redirectDeleteAndTrashActions(KActionCollection *coll); @@ -155,8 +156,8 @@ private: void delayAction(DelayedRepeatEvent *event); void replayAdvance(DelayedRepeatEvent *event); - void performDeleteCurrentImage(QWidget *parent); - void performTrashCurrentImage(QWidget *parent); + void performDeleteCurrentImage(TQWidget *tqparent); + void performTrashCurrentImage(TQWidget *tqparent); uint viewItem, renameItem, deleteItem, printItem; uint m_slideshowCycle; @@ -169,10 +170,10 @@ private: KToggleAction *oneWindowAction; KAccel *m_accel; DelayedRepeatEvent *m_delayedRepeatItem; - QTimer *m_slideTimer; + TQTimer *m_slideTimer; bool m_slideShowStopped; KToggleAction *m_toggleBrowserAction; - QGuardedPtr<AboutWidget> aboutWidget; + TQGuardedPtr<AboutWidget> aboutWidget; }; #endif diff --git a/kuickshow/src/kurlwidget.cpp b/kuickshow/src/kurlwidget.cpp index 0a23fa3..3d23106 100644 --- a/kuickshow/src/kurlwidget.cpp +++ b/kuickshow/src/kurlwidget.cpp @@ -16,18 +16,18 @@ Boston, MA 02110-1301, USA. */ -#include <qtooltip.h> +#include <tqtooltip.h> #include <kurl.h> #include <krun.h> #include "kurlwidget.h" -KURLWidget::KURLWidget(const QString& text, QWidget *parent, const char *name) - : KURLLabel( parent, name ) +KURLWidget::KURLWidget(const TQString& text, TQWidget *tqparent, const char *name) + : KURLLabel( tqparent, name ) { setText( text ); - connect( this, SIGNAL( leftClickedURL() ), SLOT( run() )); + connect( this, TQT_SIGNAL( leftClickedURL() ), TQT_SLOT( run() )); setUseTips( true ); } diff --git a/kuickshow/src/kurlwidget.h b/kuickshow/src/kurlwidget.h index 2f35e00..cb02bf7 100644 --- a/kuickshow/src/kurlwidget.h +++ b/kuickshow/src/kurlwidget.h @@ -24,9 +24,10 @@ class KURLWidget : public KURLLabel { Q_OBJECT + TQ_OBJECT public: - KURLWidget( const QString& text, QWidget *, const char *name=0 ); + KURLWidget( const TQString& text, TQWidget *, const char *name=0 ); protected slots: virtual void run(); diff --git a/kuickshow/src/main.cpp b/kuickshow/src/main.cpp index dfb462f..41fcbac 100644 --- a/kuickshow/src/main.cpp +++ b/kuickshow/src/main.cpp @@ -16,7 +16,7 @@ Boston, MA 02110-1301, USA. */ -#include <qstring.h> +#include <tqstring.h> #include <kaboutdata.h> #include <kapplication.h> diff --git a/kuickshow/src/mainwidget.cpp b/kuickshow/src/mainwidget.cpp index caa6700..b9e6357 100644 --- a/kuickshow/src/mainwidget.cpp +++ b/kuickshow/src/mainwidget.cpp @@ -21,10 +21,10 @@ #include "mainwidget.h" -MainWidget::MainWidget( QString startDir, QWidget *parent, - const char *name ) : QWidget ( parent, name ) +MainWidget::MainWidget( TQString startDir, TQWidget *tqparent, + const char *name ) : TQWidget ( tqparent, name ) { - box = new FileView( startDir, true, (QDir::Dirs | QDir::Files), + box = new FileView( startDir, true, (TQDir::Dirs | TQDir::Files), this, "fileview" ); } @@ -35,8 +35,8 @@ MainWidget::~MainWidget() } -// for now, no layout managers -void MainWidget::resizeEvent( QResizeEvent * ) +// for now, no tqlayout managers +void MainWidget::resizeEvent( TQResizeEvent * ) { box->resize( width(), height() ); } diff --git a/kuickshow/src/mainwidget.h b/kuickshow/src/mainwidget.h index 36285dd..875fbce 100644 --- a/kuickshow/src/mainwidget.h +++ b/kuickshow/src/mainwidget.h @@ -19,24 +19,25 @@ #ifndef MAINWIDGET_H #define MAINWIDGET_H -#include <qevent.h> -#include <qstring.h> -#include <qwidget.h> +#include <tqevent.h> +#include <tqstring.h> +#include <tqwidget.h> class FileView; -class MainWidget : public QWidget +class MainWidget : public TQWidget { Q_OBJECT + TQ_OBJECT public: - MainWidget( QString, QWidget *parent, const char *name=0L); + MainWidget( TQString, TQWidget *tqparent, const char *name=0L); ~MainWidget(); FileView* getFileBox() { return box; } protected: - virtual void resizeEvent( QResizeEvent * ); + virtual void resizeEvent( TQResizeEvent * ); private: FileView *box; diff --git a/kuickshow/src/printing.cpp b/kuickshow/src/printing.cpp index be57ca7..b2a4de6 100644 --- a/kuickshow/src/printing.cpp +++ b/kuickshow/src/printing.cpp @@ -16,19 +16,19 @@ Boston, MA 02110-1301, USA. */ -#include <qcheckbox.h> -#include <qfont.h> -#include <qfontmetrics.h> -#include <qgrid.h> -#include <qhbox.h> -#include <qlayout.h> -#include <qimage.h> +#include <tqcheckbox.h> +#include <tqfont.h> +#include <tqfontmetrics.h> +#include <tqgrid.h> +#include <tqhbox.h> +#include <tqlayout.h> +#include <tqimage.h> #include <kimageeffect.h> -#include <qpaintdevicemetrics.h> -#include <qpainter.h> -#include <qradiobutton.h> -#include <qvbuttongroup.h> -#include <qcolor.h> +#include <tqpaintdevicemetrics.h> +#include <tqpainter.h> +#include <tqradiobutton.h> +#include <tqvbuttongroup.h> +#include <tqcolor.h> #include <kcombobox.h> #include <kdialog.h> @@ -43,23 +43,23 @@ #include "printing.h" #include "version.h" -bool Printing::printImage( ImageWindow& imageWin, QWidget *parent ) +bool Printing::printImage( ImageWindow& imageWin, TQWidget *tqparent ) { - QString imageURL = imageWin.url().prettyURL(); + TQString imageURL = imageWin.url().prettyURL(); KPrinter printer; printer.setDocName( imageURL ); printer.setCreator( "KuickShow-" KUICKSHOWVERSION ); - KPrinter::addDialogPage( new KuickPrintDialogPage( parent, "kuick page")); + KPrinter::addDialogPage( new KuickPrintDialogPage( tqparent, "kuick page")); - if ( printer.setup( parent, i18n("Print %1").arg(printer.docName().section('/', -1)) ) ) + if ( printer.setup( tqparent, i18n("Print %1").tqarg(printer.docName().section('/', -1)) ) ) { - KTempFile tmpFile( QString::null, ".png" ); + KTempFile tmpFile( TQString(), ".png" ); if ( tmpFile.status() == 0 ) { tmpFile.setAutoDelete( true ); if ( imageWin.saveImage( tmpFile.name(), true ) ) - return printImageWithQt( tmpFile.name(), printer, + return printImageWithTQt( tmpFile.name(), printer, imageURL ); } @@ -69,27 +69,27 @@ bool Printing::printImage( ImageWindow& imageWin, QWidget *parent ) return true; // user aborted } -bool Printing::printImageWithQt( const QString& filename, KPrinter& printer, - const QString& originalFileName ) +bool Printing::printImageWithTQt( const TQString& filename, KPrinter& printer, + const TQString& originalFileName ) { - QImage image( filename ); + TQImage image( filename ); if ( image.isNull() ) { kdWarning() << "Can't load image: " << filename << " for printing.\n"; return false; } - QPainter p; + TQPainter p; p.begin( &printer ); - QPaintDeviceMetrics metrics( &printer ); + TQPaintDeviceMetrics metrics( &printer ); p.setFont( KGlobalSettings::generalFont() ); - QFontMetrics fm = p.fontMetrics(); + TQFontMetrics fm = p.fontMetrics(); int w = metrics.width(); int h = metrics.height(); - QString t = "true"; - QString f = "false"; + TQString t = "true"; + TQString f = "false"; // Black & white print? if ( printer.option( "app-kuickshow-blackwhite" ) != f) { @@ -107,9 +107,9 @@ bool Printing::printImageWithQt( const QString& filename, KPrinter& printer, // shrink image to pagesize, if necessary // bool shrinkToFit = (printer.option( "app-kuickshow-shrinkToFit" ) != f); - QSize imagesize = image.size(); + TQSize imagesize = image.size(); if ( shrinkToFit && (image.width() > w || image.height() > h) ) { - imagesize.scale( w, h, QSize::ScaleMin ); + imagesize.tqscale( w, h, TQSize::ScaleMin ); } @@ -117,38 +117,38 @@ bool Printing::printImageWithQt( const QString& filename, KPrinter& printer, // align image // bool ok = false; - int alignment = printer.option("app-kuickshow-alignment").toInt( &ok ); + int tqalignment = printer.option("app-kuickshow-tqalignment").toInt( &ok ); if ( !ok ) - alignment = Qt::AlignCenter; // default + tqalignment = TQt::AlignCenter; // default int x = 0; int y = 0; // ### need a GUI for this in KuickPrintDialogPage! - // x - alignment - if ( alignment & Qt::AlignHCenter ) + // x - tqalignment + if ( tqalignment & TQt::AlignHCenter ) x = (w - imagesize.width())/2; - else if ( alignment & Qt::AlignLeft ) + else if ( tqalignment & TQt::AlignLeft ) x = 0; - else if ( alignment & Qt::AlignRight ) + else if ( tqalignment & TQt::AlignRight ) x = w - imagesize.width(); - // y - alignment - if ( alignment & Qt::AlignVCenter ) + // y - tqalignment + if ( tqalignment & TQt::AlignVCenter ) y = (h - imagesize.height())/2; - else if ( alignment & Qt::AlignTop ) + else if ( tqalignment & TQt::AlignTop ) y = 0; - else if ( alignment & Qt::AlignBottom ) + else if ( tqalignment & TQt::AlignBottom ) y = h - imagesize.height(); // // perform the actual drawing // - p.drawImage( QRect( x, y, imagesize.width(), imagesize.height()), image ); + p.drawImage( TQRect( x, y, imagesize.width(), imagesize.height()), image ); if ( printFilename ) { - QString fname = minimizeString( originalFileName, fm, w ); + TQString fname = minimizeString( originalFileName, fm, w ); if ( !fname.isEmpty() ) { int fw = fm.width( fname ); @@ -163,11 +163,11 @@ bool Printing::printImageWithQt( const QString& filename, KPrinter& printer, return true; } -QString Printing::minimizeString( QString text, const QFontMetrics& +TQString Printing::minimizeString( TQString text, const TQFontMetrics& metrics, int maxWidth ) { if ( text.length() <= 5 ) - return QString::null; // no sense to cut that tiny little string + return TQString(); // no sense to cut that tiny little string bool changed = false; while ( metrics.width( text ) > maxWidth ) @@ -181,9 +181,9 @@ QString Printing::minimizeString( QString text, const QFontMetrics& { int mid = text.length() / 2; if ( mid <= 5 ) // sanity check - return QString::null; + return TQString(); - text.replace( mid - 1, 3, "..." ); + text.tqreplace( mid - 1, 3, "..." ); } return text; @@ -194,42 +194,42 @@ QString Printing::minimizeString( QString text, const QFontMetrics& /////////////////////////////////////////////////////////////////// -KuickPrintDialogPage::KuickPrintDialogPage( QWidget *parent, const char *name ) - : KPrintDialogPage( parent, name ) +KuickPrintDialogPage::KuickPrintDialogPage( TQWidget *tqparent, const char *name ) + : KPrintDialogPage( tqparent, name ) { setTitle( i18n("Image Settings") ); - QVBoxLayout *layout = new QVBoxLayout( this ); - layout->setMargin( KDialog::marginHint() ); - layout->setSpacing( KDialog::spacingHint() ); + TQVBoxLayout *tqlayout = new TQVBoxLayout( this ); + tqlayout->setMargin( KDialog::marginHint() ); + tqlayout->setSpacing( KDialog::spacingHint() ); - m_addFileName = new QCheckBox( i18n("Print fi&lename below image"), this); + m_addFileName = new TQCheckBox( i18n("Print fi&lename below image"), this); m_addFileName->setChecked( true ); - layout->addWidget( m_addFileName ); + tqlayout->addWidget( m_addFileName ); - m_blackwhite = new QCheckBox ( i18n("Print image in &black and white"), this); + m_blackwhite = new TQCheckBox ( i18n("Print image in &black and white"), this); m_blackwhite->setChecked( false ); - layout->addWidget (m_blackwhite ); + tqlayout->addWidget (m_blackwhite ); - QVButtonGroup *group = new QVButtonGroup( i18n("Scaling"), this ); + TQVButtonGroup *group = new TQVButtonGroup( i18n("Scaling"), this ); group->setRadioButtonExclusive( true ); - layout->addWidget( group ); - // m_shrinkToFit = new QRadioButton( i18n("Shrink image to &fit, if necessary"), group ); - m_shrinkToFit = new QCheckBox( i18n("Shrink image to &fit, if necessary"), group ); + tqlayout->addWidget( group ); + // m_shrinkToFit = new TQRadioButton( i18n("Shrink image to &fit, if necessary"), group ); + m_shrinkToFit = new TQCheckBox( i18n("Shrink image to &fit, if necessary"), group ); m_shrinkToFit->setChecked( true ); - QWidget *widget = new QWidget( group ); - QGridLayout *grid = new QGridLayout( widget, 3, 3 ); + TQWidget *widget = new TQWidget( group ); + TQGridLayout *grid = new TQGridLayout( widget, 3, 3 ); grid->addColSpacing( 0, 30 ); grid->setColStretch( 0, 0 ); grid->setColStretch( 1, 1 ); grid->setColStretch( 2, 10 ); - m_scale = new QRadioButton( i18n("Print e&xact size: "), widget ); + m_scale = new TQRadioButton( i18n("Print e&xact size: "), widget ); m_scale->setEnabled( false ); // ### grid->addMultiCellWidget( m_scale, 0, 0, 0, 1 ); group->insert( m_scale ); - connect( m_scale, SIGNAL( toggled( bool )), SLOT( toggleScaling( bool ))); + connect( m_scale, TQT_SIGNAL( toggled( bool )), TQT_SLOT( toggleScaling( bool ))); m_units = new KComboBox( false, widget, "unit combobox" ); grid->addWidget( m_units, 0, 2, AlignLeft ); @@ -252,26 +252,26 @@ KuickPrintDialogPage::~KuickPrintDialogPage() { } -void KuickPrintDialogPage::getOptions( QMap<QString,QString>& opts, +void KuickPrintDialogPage::getOptions( TQMap<TQString,TQString>& opts, bool /*incldef*/ ) { - QString t = "true"; - QString f = "false"; + TQString t = "true"; + TQString f = "false"; -// ### opts["app-kuickshow-alignment"] = ; +// ### opts["app-kuickshow-tqalignment"] = ; opts["app-kuickshow-printFilename"] = m_addFileName->isChecked() ? t : f; opts["app-kuickshow-blackwhite"] = m_blackwhite->isChecked() ? t : f; opts["app-kuickshow-shrinkToFit"] = m_shrinkToFit->isChecked() ? t : f; opts["app-kuickshow-scale"] = m_scale->isChecked() ? t : f; opts["app-kuickshow-scale-unit"] = m_units->currentText(); - opts["app-kuickshow-scale-width-pixels"] = QString::number( scaleWidth() ); - opts["app-kuickshow-scale-height-pixels"] = QString::number( scaleHeight() ); + opts["app-kuickshow-scale-width-pixels"] = TQString::number( scaleWidth() ); + opts["app-kuickshow-scale-height-pixels"] = TQString::number( scaleHeight() ); } -void KuickPrintDialogPage::setOptions( const QMap<QString,QString>& opts ) +void KuickPrintDialogPage::setOptions( const TQMap<TQString,TQString>& opts ) { - QString t = "true"; - QString f = "false"; + TQString t = "true"; + TQString f = "false"; m_addFileName->setChecked( opts["app-kuickshow-printFilename"] != f ); // This sound strange, but if I copy the code on the line above, the checkbox diff --git a/kuickshow/src/printing.h b/kuickshow/src/printing.h index eb679f7..f58f05d 100644 --- a/kuickshow/src/printing.h +++ b/kuickshow/src/printing.h @@ -19,13 +19,13 @@ #ifndef PRINTING_H #define PRINTING_H -#include <qfontmetrics.h> -#include <qstring.h> +#include <tqfontmetrics.h> +#include <tqstring.h> #include <kdeprint/kprintdialogpage.h> -class QCheckBox; -class QRadioButton; +class TQCheckBox; +class TQRadioButton; class KComboBox; class KPrinter; class KIntNumInput; @@ -36,13 +36,13 @@ class ImageWindow; class Printing { public: - static bool printImage( ImageWindow& imageWin, QWidget *parent = 0L); - static bool printImageWithQt( const QString& filename, KPrinter& printer, - const QString& originalFileName ); + static bool printImage( ImageWindow& imageWin, TQWidget *tqparent = 0L); + static bool printImageWithTQt( const TQString& filename, KPrinter& printer, + const TQString& originalFileName ); private: static void addConfigPages(); - static QString minimizeString( QString text, const QFontMetrics& metrics, + static TQString minimizeString( TQString text, const TQFontMetrics& metrics, int maxWidth ); }; @@ -50,13 +50,14 @@ private: class KuickPrintDialogPage : public KPrintDialogPage { Q_OBJECT + TQ_OBJECT public: - KuickPrintDialogPage( QWidget *parent = 0L, const char *name = 0 ); + KuickPrintDialogPage( TQWidget *tqparent = 0L, const char *name = 0 ); ~KuickPrintDialogPage(); - virtual void getOptions(QMap<QString,QString>& opts, bool incldef = false); - virtual void setOptions(const QMap<QString,QString>& opts); + virtual void getOptions(TQMap<TQString,TQString>& opts, bool incldef = false); + virtual void setOptions(const TQMap<TQString,TQString>& opts); private slots: void toggleScaling( bool enable ); @@ -72,13 +73,13 @@ private: int fromUnitToPixels( float val ) const; float pixelsToUnit( int pixels ) const; - QCheckBox *m_shrinkToFit; - QRadioButton *m_scale; + TQCheckBox *m_shrinkToFit; + TQRadioButton *m_scale; KIntNumInput *m_width; KIntNumInput *m_height; KComboBox *m_units; - QCheckBox *m_addFileName; - QCheckBox *m_blackwhite; + TQCheckBox *m_addFileName; + TQCheckBox *m_blackwhite; }; diff --git a/kuickshow/src/slideshowwidget.cpp b/kuickshow/src/slideshowwidget.cpp index 447b996..a35f159 100644 --- a/kuickshow/src/slideshowwidget.cpp +++ b/kuickshow/src/slideshowwidget.cpp @@ -16,8 +16,8 @@ Boston, MA 02110-1301, USA. */ -#include <qcheckbox.h> -#include <qlayout.h> +#include <tqcheckbox.h> +#include <tqlayout.h> #include <kdialog.h> #include <klocale.h> @@ -26,16 +26,16 @@ #include "slideshowwidget.h" -SlideShowWidget::SlideShowWidget( QWidget *parent, const char *name ) - : QWidget( parent, name ) +SlideShowWidget::SlideShowWidget( TQWidget *tqparent, const char *name ) + : TQWidget( tqparent, name ) { // setTitle( i18n("Slideshow") ); - QVBoxLayout *layout = new QVBoxLayout( this ); - layout->setSpacing( KDialog::spacingHint() ); + TQVBoxLayout *tqlayout = new TQVBoxLayout( this ); + tqlayout->setSpacing( KDialog::spacingHint() ); - m_fullScreen = new QCheckBox( i18n("Switch to &full-screen"), this ); - m_startWithCurrent = new QCheckBox( i18n("S&tart with current image"), this); + m_fullScreen = new TQCheckBox( i18n("Switch to &full-screen"), this ); + m_startWithCurrent = new TQCheckBox( i18n("S&tart with current image"), this); m_delayTime = new KIntNumInput( this, "delay time" ); m_delayTime->setLabel( i18n("De&lay between slides:") ); @@ -48,11 +48,11 @@ SlideShowWidget::SlideShowWidget( QWidget *parent, const char *name ) m_cycles->setSpecialValueText( i18n("infinite") ); m_cycles->setRange( 0, 500 ); - layout->addWidget( m_fullScreen ); - layout->addWidget( m_startWithCurrent ); - layout->addWidget( m_delayTime ); - layout->addWidget( m_cycles ); - layout->addStretch( 1 ); + tqlayout->addWidget( m_fullScreen ); + tqlayout->addWidget( m_startWithCurrent ); + tqlayout->addWidget( m_delayTime ); + tqlayout->addWidget( m_cycles ); + tqlayout->addStretch( 1 ); loadSettings( *kdata ); } diff --git a/kuickshow/src/slideshowwidget.h b/kuickshow/src/slideshowwidget.h index c651103..4408b20 100644 --- a/kuickshow/src/slideshowwidget.h +++ b/kuickshow/src/slideshowwidget.h @@ -21,14 +21,15 @@ #include "kuickdata.h" -class QCheckBox; +class TQCheckBox; class KIntNumInput; -class SlideShowWidget : public QWidget +class SlideShowWidget : public TQWidget { Q_OBJECT + TQ_OBJECT public: - SlideShowWidget( QWidget *parent, const char *name ); + SlideShowWidget( TQWidget *tqparent, const char *name ); ~SlideShowWidget(); virtual void loadSettings( const KuickData& data ); @@ -37,8 +38,8 @@ public: private: KIntNumInput *m_delayTime; KIntNumInput *m_cycles; - QCheckBox *m_fullScreen; - QCheckBox *m_startWithCurrent; + TQCheckBox *m_fullScreen; + TQCheckBox *m_startWithCurrent; }; #endif // SLIDESHOWWIDGET_H |