diff --git a/hecl-gui/quazip/CMakeLists.txt b/hecl-gui/quazip/CMakeLists.txt index f72dacf09..2d632df7e 100644 --- a/hecl-gui/quazip/CMakeLists.txt +++ b/hecl-gui/quazip/CMakeLists.txt @@ -1,15 +1,64 @@ -project (QuaZip) -cmake_minimum_required(VERSION 2.8) - -find_package(Qt5Core) -find_package(ZLIB) - -include_directories(${Qt5Core_INCLUDE_DIRS}) - -# All build libraries are moved to this directory -set(LIBRARY_OUTPUT_PATH ${CMAKE_BINARY_DIR}) - -set(LIB_SUFFIX "" CACHE STRING "Define suffix of directory name (32/64)") -set(LIB_DESTINATION "${CMAKE_INSTALL_PREFIX}/lib${LIB_SUFFIX}" CACHE STRING "Library directory name" FORCE) - -add_subdirectory(quazip) +cmake_minimum_required(VERSION 2.6) +project(QuaZip) + +# CMP0042: Explicitly acknowledge MACOSX_RPATH +# (introduced in CMake 2.8.12, enabled by default in CMake 3.0, +# and producing a warning when unset since 3.7.1) +cmake_policy(SET CMP0042 NEW) + +option(BUILD_WITH_QT4 "Build QuaZip with Qt4 no matter if Qt5 was found" OFF) + +if(NOT BUILD_WITH_QT4) + # try Qt5 first, and prefer that if found + find_package(Qt5Core QUIET) +endif() + +if(Qt5Core_FOUND) + set(CMAKE_CXX_STANDARD 11) + set(QTCORE_LIBRARIES ${Qt5Core_LIBRARIES}) + set(QUAZIP_LIB_VERSION_SUFFIX 5) + # if there is no QT_ROOT, try to deduce it from Qt QtCore include + if("${QT_ROOT}" STREQUAL "") + set(QT_ROOT ${QT_QTCORE_INCLUDE_DIR}/../..) + endif() + include_directories(${Qt5Core_INCLUDE_DIRS}) + + macro(qt_wrap_cpp) + qt5_wrap_cpp(${ARGN}) + endmacro() +else() + set(qt_min_version "4.5.0") + find_package(Qt4 REQUIRED) + set(QT_USE_QTGUI false) + include(${QT_USE_FILE}) + include_directories(${QT_INCLUDES}) + set(QTCORE_LIBRARIES ${QT_QTCORE_LIBRARY}) + + macro(qt_wrap_cpp) + qt4_wrap_cpp(${ARGN}) + endmacro() +endif() + +# Use system zlib on unix and Qt ZLIB on Windows +if(UNIX OR MINGW) + find_package(ZLIB REQUIRED) +else() + set(ZLIB_INCLUDE_DIRS "${QT_ROOT}/src/3rdparty/zlib" CACHE STRING "Path to ZLIB headers of Qt") + set(ZLIB_LIBRARIES "") + if(NOT EXISTS "${ZLIB_INCLUDE_DIRS}/zlib.h") + message("Please specify a valid zlib include dir") + endif() +endif() + +# All build libraries are moved to this directory +set(LIBRARY_OUTPUT_PATH ${CMAKE_BINARY_DIR}) + +set(LIB_SUFFIX "" CACHE STRING "Define suffix of directory name (32/64)") +set(LIB_DESTINATION "${CMAKE_INSTALL_PREFIX}/lib${LIB_SUFFIX}" CACHE STRING "Library directory name" FORCE) +set(INSTALL_PKGCONFIG_DIR "${CMAKE_INSTALL_PREFIX}/lib${LIB_SUFFIX}/pkgconfig" CACHE STRING "Installation directory for pkgconfig (.pc) files" FORCE) +set(QUAZIP_LIB_TARGET_NAME quazip${QUAZIP_LIB_VERSION_SUFFIX} CACHE + INTERNAL "Target name of libquazip" FORCE) + +add_subdirectory(quazip) + +install(FILES QuaZipConfig.cmake DESTINATION ${LIB_DESTINATION}/cmake/QuaZip${QUAZIP_LIB_VERSION_SUFFIX} RENAME QuaZip${QUAZIP_LIB_VERSION_SUFFIX}Config.cmake) diff --git a/hecl-gui/quazip/COPYING b/hecl-gui/quazip/COPYING index 8904ea404..e5e2603e6 100644 --- a/hecl-gui/quazip/COPYING +++ b/hecl-gui/quazip/COPYING @@ -1,458 +1,474 @@ - GNU LESSER GENERAL PUBLIC LICENSE - Version 2.1, February 1999 - - Copyright (C) 1991, 1999 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. - -[This is the first released version of the Lesser GPL. It also counts - as the successor of the GNU Library Public License, version 2, hence - the version number 2.1.] - - Preamble - - The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -Licenses are intended to guarantee your freedom to share and change -free software--to make sure the software is free for all its users. - - This license, the Lesser General Public License, applies to some -specially designated software packages--typically libraries--of the -Free Software Foundation and other authors who decide to use it. You -can use it too, but we suggest you first think carefully about whether -this license or the ordinary General Public License is the better -strategy to use in any particular case, based on the explanations below. - - When we speak of free software, we are referring to freedom of use, -not price. Our General Public Licenses are designed to make sure that -you have the freedom to distribute copies of free software (and charge -for this service if you wish); that you receive source code or can get -it if you want it; that you can change the software and use pieces of -it in new free programs; and that you are informed that you can do -these things. - - To protect your rights, we need to make restrictions that forbid -distributors to deny you these rights or to ask you to surrender these -rights. These restrictions translate to certain responsibilities for -you if you distribute copies of the library or if you modify it. - - For example, if you distribute copies of the library, whether gratis -or for a fee, you must give the recipients all the rights that we gave -you. You must make sure that they, too, receive or can get the source -code. If you link other code with the library, you must provide -complete object files to the recipients, so that they can relink them -with the library after making changes to the library and recompiling -it. And you must show them these terms so they know their rights. - - We protect your rights with a two-step method: (1) we copyright the -library, and (2) we offer you this license, which gives you legal -permission to copy, distribute and/or modify the library. - - To protect each distributor, we want to make it very clear that -there is no warranty for the free library. Also, if the library is -modified by someone else and passed on, the recipients should know -that what they have is not the original version, so that the original -author's reputation will not be affected by problems that might be -introduced by others. - - Finally, software patents pose a constant threat to the existence of -any free program. We wish to make sure that a company cannot -effectively restrict the users of a free program by obtaining a -restrictive license from a patent holder. Therefore, we insist that -any patent license obtained for a version of the library must be -consistent with the full freedom of use specified in this license. - - Most GNU software, including some libraries, is covered by the -ordinary GNU General Public License. This license, the GNU Lesser -General Public License, applies to certain designated libraries, and -is quite different from the ordinary General Public License. We use -this license for certain libraries in order to permit linking those -libraries into non-free programs. - - When a program is linked with a library, whether statically or using -a shared library, the combination of the two is legally speaking a -combined work, a derivative of the original library. The ordinary -General Public License therefore permits such linking only if the -entire combination fits its criteria of freedom. The Lesser General -Public License permits more lax criteria for linking other code with -the library. - - We call this license the "Lesser" General Public License because it -does Less to protect the user's freedom than the ordinary General -Public License. It also provides other free software developers Less -of an advantage over competing non-free programs. These disadvantages -are the reason we use the ordinary General Public License for many -libraries. However, the Lesser license provides advantages in certain -special circumstances. - - For example, on rare occasions, there may be a special need to -encourage the widest possible use of a certain library, so that it becomes -a de-facto standard. To achieve this, non-free programs must be -allowed to use the library. A more frequent case is that a free -library does the same job as widely used non-free libraries. In this -case, there is little to gain by limiting the free library to free -software only, so we use the Lesser General Public License. - - In other cases, permission to use a particular library in non-free -programs enables a greater number of people to use a large body of -free software. For example, permission to use the GNU C Library in -non-free programs enables many more people to use the whole GNU -operating system, as well as its variant, the GNU/Linux operating -system. - - Although the Lesser General Public License is Less protective of the -users' freedom, it does ensure that the user of a program that is -linked with the Library has the freedom and the wherewithal to run -that program using a modified version of the Library. - - The precise terms and conditions for copying, distribution and -modification follow. Pay close attention to the difference between a -"work based on the library" and a "work that uses the library". The -former contains code derived from the library, whereas the latter must -be combined with the library in order to run. - - GNU LESSER GENERAL PUBLIC LICENSE - TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - - 0. This License Agreement applies to any software library or other -program which contains a notice placed by the copyright holder or -other authorized party saying it may be distributed under the terms of -this Lesser General Public License (also called "this License"). -Each licensee is addressed as "you". - - A "library" means a collection of software functions and/or data -prepared so as to be conveniently linked with application programs -(which use some of those functions and data) to form executables. - - The "Library", below, refers to any such software library or work -which has been distributed under these terms. A "work based on the -Library" means either the Library or any derivative work under -copyright law: that is to say, a work containing the Library or a -portion of it, either verbatim or with modifications and/or translated -straightforwardly into another language. (Hereinafter, translation is -included without limitation in the term "modification".) - - "Source code" for a work means the preferred form of the work for -making modifications to it. For a library, complete source code means -all the source code for all modules it contains, plus any associated -interface definition files, plus the scripts used to control compilation -and installation of the library. - - Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running a program using the Library is not restricted, and output from -such a program is covered only if its contents constitute a work based -on the Library (independent of the use of the Library in a tool for -writing it). Whether that is true depends on what the Library does -and what the program that uses the Library does. - - 1. You may copy and distribute verbatim copies of the Library's -complete source code as you receive it, in any medium, provided that -you conspicuously and appropriately publish on each copy an -appropriate copyright notice and disclaimer of warranty; keep intact -all the notices that refer to this License and to the absence of any -warranty; and distribute a copy of this License along with the -Library. - - You may charge a fee for the physical act of transferring a copy, -and you may at your option offer warranty protection in exchange for a -fee. - - 2. You may modify your copy or copies of the Library or any portion -of it, thus forming a work based on the Library, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - - a) The modified work must itself be a software library. - - b) You must cause the files modified to carry prominent notices - stating that you changed the files and the date of any change. - - c) You must cause the whole of the work to be licensed at no - charge to all third parties under the terms of this License. - - d) If a facility in the modified Library refers to a function or a - table of data to be supplied by an application program that uses - the facility, other than as an argument passed when the facility - is invoked, then you must make a good faith effort to ensure that, - in the event an application does not supply such function or - table, the facility still operates, and performs whatever part of - its purpose remains meaningful. - - (For example, a function in a library to compute square roots has - a purpose that is entirely well-defined independent of the - application. Therefore, Subsection 2d requires that any - application-supplied function or table used by this function must - be optional: if the application does not supply it, the square - root function must still compute square roots.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Library, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Library, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote -it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Library. - -In addition, mere aggregation of another work not based on the Library -with the Library (or with a work based on the Library) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - - 3. You may opt to apply the terms of the ordinary GNU General Public -License instead of this License to a given copy of the Library. To do -this, you must alter all the notices that refer to this License, so -that they refer to the ordinary GNU General Public License, version 2, -instead of to this License. (If a newer version than version 2 of the -ordinary GNU General Public License has appeared, then you can specify -that version instead if you wish.) Do not make any other change in -these notices. - - Once this change is made in a given copy, it is irreversible for -that copy, so the ordinary GNU General Public License applies to all -subsequent copies and derivative works made from that copy. - - This option is useful when you wish to copy part of the code of -the Library into a program that is not a library. - - 4. You may copy and distribute the Library (or a portion or -derivative of it, under Section 2) in object code or executable form -under the terms of Sections 1 and 2 above provided that you accompany -it with the complete corresponding machine-readable source code, which -must be distributed under the terms of Sections 1 and 2 above on a -medium customarily used for software interchange. - - If distribution of object code is made by offering access to copy -from a designated place, then offering equivalent access to copy the -source code from the same place satisfies the requirement to -distribute the source code, even though third parties are not -compelled to copy the source along with the object code. - - 5. A program that contains no derivative of any portion of the -Library, but is designed to work with the Library by being compiled or -linked with it, is called a "work that uses the Library". Such a -work, in isolation, is not a derivative work of the Library, and -therefore falls outside the scope of this License. - - However, linking a "work that uses the Library" with the Library -creates an executable that is a derivative of the Library (because it -contains portions of the Library), rather than a "work that uses the -library". The executable is therefore covered by this License. -Section 6 states terms for distribution of such executables. - - When a "work that uses the Library" uses material from a header file -that is part of the Library, the object code for the work may be a -derivative work of the Library even though the source code is not. -Whether this is true is especially significant if the work can be -linked without the Library, or if the work is itself a library. The -threshold for this to be true is not precisely defined by law. - - If such an object file uses only numerical parameters, data -structure layouts and accessors, and small macros and small inline -functions (ten lines or less in length), then the use of the object -file is unrestricted, regardless of whether it is legally a derivative -work. (Executables containing this object code plus portions of the -Library will still fall under Section 6.) - - Otherwise, if the work is a derivative of the Library, you may -distribute the object code for the work under the terms of Section 6. -Any executables containing that work also fall under Section 6, -whether or not they are linked directly with the Library itself. - - 6. As an exception to the Sections above, you may also combine or -link a "work that uses the Library" with the Library to produce a -work containing portions of the Library, and distribute that work -under terms of your choice, provided that the terms permit -modification of the work for the customer's own use and reverse -engineering for debugging such modifications. - - You must give prominent notice with each copy of the work that the -Library is used in it and that the Library and its use are covered by -this License. You must supply a copy of this License. If the work -during execution displays copyright notices, you must include the -copyright notice for the Library among them, as well as a reference -directing the user to the copy of this License. Also, you must do one -of these things: - - a) Accompany the work with the complete corresponding - machine-readable source code for the Library including whatever - changes were used in the work (which must be distributed under - Sections 1 and 2 above); and, if the work is an executable linked - with the Library, with the complete machine-readable "work that - uses the Library", as object code and/or source code, so that the - user can modify the Library and then relink to produce a modified - executable containing the modified Library. (It is understood - that the user who changes the contents of definitions files in the - Library will not necessarily be able to recompile the application - to use the modified definitions.) - - b) Use a suitable shared library mechanism for linking with the - Library. A suitable mechanism is one that (1) uses at run time a - copy of the library already present on the user's computer system, - rather than copying library functions into the executable, and (2) - will operate properly with a modified version of the library, if - the user installs one, as long as the modified version is - interface-compatible with the version that the work was made with. - - c) Accompany the work with a written offer, valid for at - least three years, to give the same user the materials - specified in Subsection 6a, above, for a charge no more - than the cost of performing this distribution. - - d) If distribution of the work is made by offering access to copy - from a designated place, offer equivalent access to copy the above - specified materials from the same place. - - e) Verify that the user has already received a copy of these - materials or that you have already sent this user a copy. - - For an executable, the required form of the "work that uses the -Library" must include any data and utility programs needed for -reproducing the executable from it. However, as a special exception, -the materials to be distributed need not include anything that is -normally distributed (in either source or binary form) with the major -components (compiler, kernel, and so on) of the operating system on -which the executable runs, unless that component itself accompanies -the executable. - - It may happen that this requirement contradicts the license -restrictions of other proprietary libraries that do not normally -accompany the operating system. Such a contradiction means you cannot -use both them and the Library together in an executable that you -distribute. - - 7. You may place library facilities that are a work based on the -Library side-by-side in a single library together with other library -facilities not covered by this License, and distribute such a combined -library, provided that the separate distribution of the work based on -the Library and of the other library facilities is otherwise -permitted, and provided that you do these two things: - - a) Accompany the combined library with a copy of the same work - based on the Library, uncombined with any other library - facilities. This must be distributed under the terms of the - Sections above. - - b) Give prominent notice with the combined library of the fact - that part of it is a work based on the Library, and explaining - where to find the accompanying uncombined form of the same work. - - 8. You may not copy, modify, sublicense, link with, or distribute -the Library except as expressly provided under this License. Any -attempt otherwise to copy, modify, sublicense, link with, or -distribute the Library is void, and will automatically terminate your -rights under this License. However, parties who have received copies, -or rights, from you under this License will not have their licenses -terminated so long as such parties remain in full compliance. - - 9. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Library or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Library (or any work based on the -Library), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Library or works based on it. - - 10. Each time you redistribute the Library (or any work based on the -Library), the recipient automatically receives a license from the -original licensor to copy, distribute, link with or modify the Library -subject to these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties with -this License. - - 11. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Library at all. For example, if a patent -license would not permit royalty-free redistribution of the Library by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Library. - -If any portion of this section is held invalid or unenforceable under any -particular circumstance, the balance of the section is intended to apply, -and the section as a whole is intended to apply in other circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - - 12. If the distribution and/or use of the Library is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Library under this License may add -an explicit geographical distribution limitation excluding those countries, -so that distribution is permitted only in or among countries not thus -excluded. In such case, this License incorporates the limitation as if -written in the body of this License. - - 13. The Free Software Foundation may publish revised and/or new -versions of the Lesser General Public License from time to time. -Such new versions will be similar in spirit to the present version, -but may differ in detail to address new problems or concerns. - -Each version is given a distinguishing version number. If the Library -specifies a version number of this License which applies to it and -"any later version", you have the option of following the terms and -conditions either of that version or of any later version published by -the Free Software Foundation. If the Library does not specify a -license version number, you may choose any version ever published by -the Free Software Foundation. - - 14. If you wish to incorporate parts of the Library into other free -programs whose distribution conditions are incompatible with these, -write to the author to ask for permission. For software which is -copyrighted by the Free Software Foundation, write to the Free -Software Foundation; we sometimes make exceptions for this. Our -decision will be guided by the two goals of preserving the free status -of all derivatives of our free software and of promoting the sharing -and reuse of software generally. - - NO WARRANTY - - 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO -WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. -EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR -OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY -KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE -IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE -LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME -THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN -WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY -AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU -FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR -CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE -LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING -RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A -FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF -SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH -DAMAGES. - - END OF TERMS AND CONDITIONS +The QuaZIP library is licensed under the GNU Lesser General Public +License V2.1 plus a static linking exception. + +STATIC LINKING EXCEPTION + +The copyright holders give you permission to link this library with +independent modules to produce an executable, regardless of the license +terms of these independent modules, and to copy and distribute the +resulting executable under terms of your choice, provided that you also +meet, for each linked independent module, the terms and conditions of +the license of that module. An independent module is a module which is +not derived from or based on this library. If you modify this library, +you must extend this exception to your version of the library. + +The text of the GNU Lesser General Public License V2.1 follows. + + GNU LESSER GENERAL PUBLIC LICENSE + Version 2.1, February 1999 + + Copyright (C) 1991, 1999 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. + +[This is the first released version of the Lesser GPL. It also counts + as the successor of the GNU Library Public License, version 2, hence + the version number 2.1.] + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +Licenses are intended to guarantee your freedom to share and change +free software--to make sure the software is free for all its users. + + This license, the Lesser General Public License, applies to some +specially designated software packages--typically libraries--of the +Free Software Foundation and other authors who decide to use it. You +can use it too, but we suggest you first think carefully about whether +this license or the ordinary General Public License is the better +strategy to use in any particular case, based on the explanations below. + + When we speak of free software, we are referring to freedom of use, +not price. Our General Public Licenses are designed to make sure that +you have the freedom to distribute copies of free software (and charge +for this service if you wish); that you receive source code or can get +it if you want it; that you can change the software and use pieces of +it in new free programs; and that you are informed that you can do +these things. + + To protect your rights, we need to make restrictions that forbid +distributors to deny you these rights or to ask you to surrender these +rights. These restrictions translate to certain responsibilities for +you if you distribute copies of the library or if you modify it. + + For example, if you distribute copies of the library, whether gratis +or for a fee, you must give the recipients all the rights that we gave +you. You must make sure that they, too, receive or can get the source +code. If you link other code with the library, you must provide +complete object files to the recipients, so that they can relink them +with the library after making changes to the library and recompiling +it. And you must show them these terms so they know their rights. + + We protect your rights with a two-step method: (1) we copyright the +library, and (2) we offer you this license, which gives you legal +permission to copy, distribute and/or modify the library. + + To protect each distributor, we want to make it very clear that +there is no warranty for the free library. Also, if the library is +modified by someone else and passed on, the recipients should know +that what they have is not the original version, so that the original +author's reputation will not be affected by problems that might be +introduced by others. + + Finally, software patents pose a constant threat to the existence of +any free program. We wish to make sure that a company cannot +effectively restrict the users of a free program by obtaining a +restrictive license from a patent holder. Therefore, we insist that +any patent license obtained for a version of the library must be +consistent with the full freedom of use specified in this license. + + Most GNU software, including some libraries, is covered by the +ordinary GNU General Public License. This license, the GNU Lesser +General Public License, applies to certain designated libraries, and +is quite different from the ordinary General Public License. We use +this license for certain libraries in order to permit linking those +libraries into non-free programs. + + When a program is linked with a library, whether statically or using +a shared library, the combination of the two is legally speaking a +combined work, a derivative of the original library. The ordinary +General Public License therefore permits such linking only if the +entire combination fits its criteria of freedom. The Lesser General +Public License permits more lax criteria for linking other code with +the library. + + We call this license the "Lesser" General Public License because it +does Less to protect the user's freedom than the ordinary General +Public License. It also provides other free software developers Less +of an advantage over competing non-free programs. These disadvantages +are the reason we use the ordinary General Public License for many +libraries. However, the Lesser license provides advantages in certain +special circumstances. + + For example, on rare occasions, there may be a special need to +encourage the widest possible use of a certain library, so that it becomes +a de-facto standard. To achieve this, non-free programs must be +allowed to use the library. A more frequent case is that a free +library does the same job as widely used non-free libraries. In this +case, there is little to gain by limiting the free library to free +software only, so we use the Lesser General Public License. + + In other cases, permission to use a particular library in non-free +programs enables a greater number of people to use a large body of +free software. For example, permission to use the GNU C Library in +non-free programs enables many more people to use the whole GNU +operating system, as well as its variant, the GNU/Linux operating +system. + + Although the Lesser General Public License is Less protective of the +users' freedom, it does ensure that the user of a program that is +linked with the Library has the freedom and the wherewithal to run +that program using a modified version of the Library. + + The precise terms and conditions for copying, distribution and +modification follow. Pay close attention to the difference between a +"work based on the library" and a "work that uses the library". The +former contains code derived from the library, whereas the latter must +be combined with the library in order to run. + + GNU LESSER GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License Agreement applies to any software library or other +program which contains a notice placed by the copyright holder or +other authorized party saying it may be distributed under the terms of +this Lesser General Public License (also called "this License"). +Each licensee is addressed as "you". + + A "library" means a collection of software functions and/or data +prepared so as to be conveniently linked with application programs +(which use some of those functions and data) to form executables. + + The "Library", below, refers to any such software library or work +which has been distributed under these terms. A "work based on the +Library" means either the Library or any derivative work under +copyright law: that is to say, a work containing the Library or a +portion of it, either verbatim or with modifications and/or translated +straightforwardly into another language. (Hereinafter, translation is +included without limitation in the term "modification".) + + "Source code" for a work means the preferred form of the work for +making modifications to it. For a library, complete source code means +all the source code for all modules it contains, plus any associated +interface definition files, plus the scripts used to control compilation +and installation of the library. + + Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running a program using the Library is not restricted, and output from +such a program is covered only if its contents constitute a work based +on the Library (independent of the use of the Library in a tool for +writing it). Whether that is true depends on what the Library does +and what the program that uses the Library does. + + 1. You may copy and distribute verbatim copies of the Library's +complete source code as you receive it, in any medium, provided that +you conspicuously and appropriately publish on each copy an +appropriate copyright notice and disclaimer of warranty; keep intact +all the notices that refer to this License and to the absence of any +warranty; and distribute a copy of this License along with the +Library. + + You may charge a fee for the physical act of transferring a copy, +and you may at your option offer warranty protection in exchange for a +fee. + + 2. You may modify your copy or copies of the Library or any portion +of it, thus forming a work based on the Library, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) The modified work must itself be a software library. + + b) You must cause the files modified to carry prominent notices + stating that you changed the files and the date of any change. + + c) You must cause the whole of the work to be licensed at no + charge to all third parties under the terms of this License. + + d) If a facility in the modified Library refers to a function or a + table of data to be supplied by an application program that uses + the facility, other than as an argument passed when the facility + is invoked, then you must make a good faith effort to ensure that, + in the event an application does not supply such function or + table, the facility still operates, and performs whatever part of + its purpose remains meaningful. + + (For example, a function in a library to compute square roots has + a purpose that is entirely well-defined independent of the + application. Therefore, Subsection 2d requires that any + application-supplied function or table used by this function must + be optional: if the application does not supply it, the square + root function must still compute square roots.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Library, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Library, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote +it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Library. + +In addition, mere aggregation of another work not based on the Library +with the Library (or with a work based on the Library) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may opt to apply the terms of the ordinary GNU General Public +License instead of this License to a given copy of the Library. To do +this, you must alter all the notices that refer to this License, so +that they refer to the ordinary GNU General Public License, version 2, +instead of to this License. (If a newer version than version 2 of the +ordinary GNU General Public License has appeared, then you can specify +that version instead if you wish.) Do not make any other change in +these notices. + + Once this change is made in a given copy, it is irreversible for +that copy, so the ordinary GNU General Public License applies to all +subsequent copies and derivative works made from that copy. + + This option is useful when you wish to copy part of the code of +the Library into a program that is not a library. + + 4. You may copy and distribute the Library (or a portion or +derivative of it, under Section 2) in object code or executable form +under the terms of Sections 1 and 2 above provided that you accompany +it with the complete corresponding machine-readable source code, which +must be distributed under the terms of Sections 1 and 2 above on a +medium customarily used for software interchange. + + If distribution of object code is made by offering access to copy +from a designated place, then offering equivalent access to copy the +source code from the same place satisfies the requirement to +distribute the source code, even though third parties are not +compelled to copy the source along with the object code. + + 5. A program that contains no derivative of any portion of the +Library, but is designed to work with the Library by being compiled or +linked with it, is called a "work that uses the Library". Such a +work, in isolation, is not a derivative work of the Library, and +therefore falls outside the scope of this License. + + However, linking a "work that uses the Library" with the Library +creates an executable that is a derivative of the Library (because it +contains portions of the Library), rather than a "work that uses the +library". The executable is therefore covered by this License. +Section 6 states terms for distribution of such executables. + + When a "work that uses the Library" uses material from a header file +that is part of the Library, the object code for the work may be a +derivative work of the Library even though the source code is not. +Whether this is true is especially significant if the work can be +linked without the Library, or if the work is itself a library. The +threshold for this to be true is not precisely defined by law. + + If such an object file uses only numerical parameters, data +structure layouts and accessors, and small macros and small inline +functions (ten lines or less in length), then the use of the object +file is unrestricted, regardless of whether it is legally a derivative +work. (Executables containing this object code plus portions of the +Library will still fall under Section 6.) + + Otherwise, if the work is a derivative of the Library, you may +distribute the object code for the work under the terms of Section 6. +Any executables containing that work also fall under Section 6, +whether or not they are linked directly with the Library itself. + + 6. As an exception to the Sections above, you may also combine or +link a "work that uses the Library" with the Library to produce a +work containing portions of the Library, and distribute that work +under terms of your choice, provided that the terms permit +modification of the work for the customer's own use and reverse +engineering for debugging such modifications. + + You must give prominent notice with each copy of the work that the +Library is used in it and that the Library and its use are covered by +this License. You must supply a copy of this License. If the work +during execution displays copyright notices, you must include the +copyright notice for the Library among them, as well as a reference +directing the user to the copy of this License. Also, you must do one +of these things: + + a) Accompany the work with the complete corresponding + machine-readable source code for the Library including whatever + changes were used in the work (which must be distributed under + Sections 1 and 2 above); and, if the work is an executable linked + with the Library, with the complete machine-readable "work that + uses the Library", as object code and/or source code, so that the + user can modify the Library and then relink to produce a modified + executable containing the modified Library. (It is understood + that the user who changes the contents of definitions files in the + Library will not necessarily be able to recompile the application + to use the modified definitions.) + + b) Use a suitable shared library mechanism for linking with the + Library. A suitable mechanism is one that (1) uses at run time a + copy of the library already present on the user's computer system, + rather than copying library functions into the executable, and (2) + will operate properly with a modified version of the library, if + the user installs one, as long as the modified version is + interface-compatible with the version that the work was made with. + + c) Accompany the work with a written offer, valid for at + least three years, to give the same user the materials + specified in Subsection 6a, above, for a charge no more + than the cost of performing this distribution. + + d) If distribution of the work is made by offering access to copy + from a designated place, offer equivalent access to copy the above + specified materials from the same place. + + e) Verify that the user has already received a copy of these + materials or that you have already sent this user a copy. + + For an executable, the required form of the "work that uses the +Library" must include any data and utility programs needed for +reproducing the executable from it. However, as a special exception, +the materials to be distributed need not include anything that is +normally distributed (in either source or binary form) with the major +components (compiler, kernel, and so on) of the operating system on +which the executable runs, unless that component itself accompanies +the executable. + + It may happen that this requirement contradicts the license +restrictions of other proprietary libraries that do not normally +accompany the operating system. Such a contradiction means you cannot +use both them and the Library together in an executable that you +distribute. + + 7. You may place library facilities that are a work based on the +Library side-by-side in a single library together with other library +facilities not covered by this License, and distribute such a combined +library, provided that the separate distribution of the work based on +the Library and of the other library facilities is otherwise +permitted, and provided that you do these two things: + + a) Accompany the combined library with a copy of the same work + based on the Library, uncombined with any other library + facilities. This must be distributed under the terms of the + Sections above. + + b) Give prominent notice with the combined library of the fact + that part of it is a work based on the Library, and explaining + where to find the accompanying uncombined form of the same work. + + 8. You may not copy, modify, sublicense, link with, or distribute +the Library except as expressly provided under this License. Any +attempt otherwise to copy, modify, sublicense, link with, or +distribute the Library is void, and will automatically terminate your +rights under this License. However, parties who have received copies, +or rights, from you under this License will not have their licenses +terminated so long as such parties remain in full compliance. + + 9. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Library or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Library (or any work based on the +Library), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Library or works based on it. + + 10. Each time you redistribute the Library (or any work based on the +Library), the recipient automatically receives a license from the +original licensor to copy, distribute, link with or modify the Library +subject to these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties with +this License. + + 11. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Library at all. For example, if a patent +license would not permit royalty-free redistribution of the Library by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Library. + +If any portion of this section is held invalid or unenforceable under any +particular circumstance, the balance of the section is intended to apply, +and the section as a whole is intended to apply in other circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 12. If the distribution and/or use of the Library is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Library under this License may add +an explicit geographical distribution limitation excluding those countries, +so that distribution is permitted only in or among countries not thus +excluded. In such case, this License incorporates the limitation as if +written in the body of this License. + + 13. The Free Software Foundation may publish revised and/or new +versions of the Lesser General Public License from time to time. +Such new versions will be similar in spirit to the present version, +but may differ in detail to address new problems or concerns. + +Each version is given a distinguishing version number. If the Library +specifies a version number of this License which applies to it and +"any later version", you have the option of following the terms and +conditions either of that version or of any later version published by +the Free Software Foundation. If the Library does not specify a +license version number, you may choose any version ever published by +the Free Software Foundation. + + 14. If you wish to incorporate parts of the Library into other free +programs whose distribution conditions are incompatible with these, +write to the author to ask for permission. For software which is +copyrighted by the Free Software Foundation, write to the Free +Software Foundation; we sometimes make exceptions for this. Our +decision will be guided by the two goals of preserving the free status +of all derivatives of our free software and of promoting the sharing +and reuse of software generally. + + NO WARRANTY + + 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO +WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. +EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR +OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY +KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE +LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME +THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN +WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY +AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU +FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR +CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE +LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING +RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A +FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF +SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH +DAMAGES. + + END OF TERMS AND CONDITIONS diff --git a/hecl-gui/quazip/Doxyfile b/hecl-gui/quazip/Doxyfile deleted file mode 100644 index f956740f9..000000000 --- a/hecl-gui/quazip/Doxyfile +++ /dev/null @@ -1,1722 +0,0 @@ -# Doxyfile 1.7.4 - -# This file describes the settings to be used by the documentation system -# doxygen (www.doxygen.org) for a project. -# -# All text after a hash (#) is considered a comment and will be ignored. -# The format is: -# TAG = value [value, ...] -# For lists items can also be appended using: -# TAG += value [value, ...] -# Values that contain spaces should be placed between quotes (" "). - -#--------------------------------------------------------------------------- -# Project related configuration options -#--------------------------------------------------------------------------- - -# This tag specifies the encoding used for all characters in the config file -# that follow. The default is UTF-8 which is also the encoding used for all -# text before the first occurrence of this tag. Doxygen uses libiconv (or the -# iconv built into libc) for the transcoding. See -# http://www.gnu.org/software/libiconv for the list of possible encodings. - -DOXYFILE_ENCODING = UTF-8 - -# The PROJECT_NAME tag is a single word (or a sequence of words surrounded -# by quotes) that should identify the project. - -PROJECT_NAME = QuaZIP - -# The PROJECT_NUMBER tag can be used to enter a project or revision number. -# This could be handy for archiving the generated documentation or -# if some version control system is used. - -PROJECT_NUMBER = quazip-0-6-2 - -# Using the PROJECT_BRIEF tag one can provide an optional one line description -# for a project that appears at the top of each page and should give viewer -# a quick idea about the purpose of the project. Keep the description short. - -PROJECT_BRIEF = - -# With the PROJECT_LOGO tag one can specify an logo or icon that is -# included in the documentation. The maximum height of the logo should not -# exceed 55 pixels and the maximum width should not exceed 200 pixels. -# Doxygen will copy the logo to the output directory. - -PROJECT_LOGO = - -# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) -# base path where the generated documentation will be put. -# If a relative path is entered, it will be relative to the location -# where doxygen was started. If left blank the current directory will be used. - -OUTPUT_DIRECTORY = doc - -# If the CREATE_SUBDIRS tag is set to YES, then doxygen will create -# 4096 sub-directories (in 2 levels) under the output directory of each output -# format and will distribute the generated files over these directories. -# Enabling this option can be useful when feeding doxygen a huge amount of -# source files, where putting all generated files in the same directory would -# otherwise cause performance problems for the file system. - -CREATE_SUBDIRS = NO - -# The OUTPUT_LANGUAGE tag is used to specify the language in which all -# documentation generated by doxygen is written. Doxygen will use this -# information to generate all constant output in the proper language. -# The default language is English, other supported languages are: -# Afrikaans, Arabic, Brazilian, Catalan, Chinese, Chinese-Traditional, -# Croatian, Czech, Danish, Dutch, Esperanto, Farsi, Finnish, French, German, -# Greek, Hungarian, Italian, Japanese, Japanese-en (Japanese with English -# messages), Korean, Korean-en, Lithuanian, Norwegian, Macedonian, Persian, -# Polish, Portuguese, Romanian, Russian, Serbian, Serbian-Cyrillic, Slovak, -# Slovene, Spanish, Swedish, Ukrainian, and Vietnamese. - -OUTPUT_LANGUAGE = English - -# If the BRIEF_MEMBER_DESC tag is set to YES (the default) Doxygen will -# include brief member descriptions after the members that are listed in -# the file and class documentation (similar to JavaDoc). -# Set to NO to disable this. - -BRIEF_MEMBER_DESC = YES - -# If the REPEAT_BRIEF tag is set to YES (the default) Doxygen will prepend -# the brief description of a member or function before the detailed description. -# Note: if both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the -# brief descriptions will be completely suppressed. - -REPEAT_BRIEF = YES - -# This tag implements a quasi-intelligent brief description abbreviator -# that is used to form the text in various listings. Each string -# in this list, if found as the leading text of the brief description, will be -# stripped from the text and the result after processing the whole list, is -# used as the annotated text. Otherwise, the brief description is used as-is. -# If left blank, the following values are used ("$name" is automatically -# replaced with the name of the entity): "The $name class" "The $name widget" -# "The $name file" "is" "provides" "specifies" "contains" -# "represents" "a" "an" "the" - -ABBREVIATE_BRIEF = - -# If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then -# Doxygen will generate a detailed section even if there is only a brief -# description. - -ALWAYS_DETAILED_SEC = NO - -# If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all -# inherited members of a class in the documentation of that class as if those -# members were ordinary class members. Constructors, destructors and assignment -# operators of the base classes will not be shown. - -INLINE_INHERITED_MEMB = NO - -# If the FULL_PATH_NAMES tag is set to YES then Doxygen will prepend the full -# path before files name in the file list and in the header files. If set -# to NO the shortest path that makes the file name unique will be used. - -FULL_PATH_NAMES = YES - -# If the FULL_PATH_NAMES tag is set to YES then the STRIP_FROM_PATH tag -# can be used to strip a user-defined part of the path. Stripping is -# only done if one of the specified strings matches the left-hand part of -# the path. The tag can be used to show relative paths in the file list. -# If left blank the directory from which doxygen is run is used as the -# path to strip. - -STRIP_FROM_PATH = - -# The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of -# the path mentioned in the documentation of a class, which tells -# the reader which header file to include in order to use a class. -# If left blank only the name of the header file containing the class -# definition is used. Otherwise one should specify the include paths that -# are normally passed to the compiler using the -I flag. - -STRIP_FROM_INC_PATH = - -# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter -# (but less readable) file names. This can be useful if your file system -# doesn't support long names like on DOS, Mac, or CD-ROM. - -SHORT_NAMES = NO - -# If the JAVADOC_AUTOBRIEF tag is set to YES then Doxygen -# will interpret the first line (until the first dot) of a JavaDoc-style -# comment as the brief description. If set to NO, the JavaDoc -# comments will behave just like regular Qt-style comments -# (thus requiring an explicit @brief command for a brief description.) - -JAVADOC_AUTOBRIEF = NO - -# If the QT_AUTOBRIEF tag is set to YES then Doxygen will -# interpret the first line (until the first dot) of a Qt-style -# comment as the brief description. If set to NO, the comments -# will behave just like regular Qt-style comments (thus requiring -# an explicit \brief command for a brief description.) - -QT_AUTOBRIEF = NO - -# The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make Doxygen -# treat a multi-line C++ special comment block (i.e. a block of //! or /// -# comments) as a brief description. This used to be the default behaviour. -# The new default is to treat a multi-line C++ comment block as a detailed -# description. Set this tag to YES if you prefer the old behaviour instead. - -MULTILINE_CPP_IS_BRIEF = NO - -# If the INHERIT_DOCS tag is set to YES (the default) then an undocumented -# member inherits the documentation from any documented member that it -# re-implements. - -INHERIT_DOCS = YES - -# If the SEPARATE_MEMBER_PAGES tag is set to YES, then doxygen will produce -# a new page for each member. If set to NO, the documentation of a member will -# be part of the file/class/namespace that contains it. - -SEPARATE_MEMBER_PAGES = NO - -# The TAB_SIZE tag can be used to set the number of spaces in a tab. -# Doxygen uses this value to replace tabs by spaces in code fragments. - -TAB_SIZE = 8 - -# This tag can be used to specify a number of aliases that acts -# as commands in the documentation. An alias has the form "name=value". -# For example adding "sideeffect=\par Side Effects:\n" will allow you to -# put the command \sideeffect (or @sideeffect) in the documentation, which -# will result in a user-defined paragraph with heading "Side Effects:". -# You can put \n's in the value part of an alias to insert newlines. - -ALIASES = - -# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C -# sources only. Doxygen will then generate output that is more tailored for C. -# For instance, some of the names that are used will be different. The list -# of all members will be omitted, etc. - -OPTIMIZE_OUTPUT_FOR_C = NO - -# Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java -# sources only. Doxygen will then generate output that is more tailored for -# Java. For instance, namespaces will be presented as packages, qualified -# scopes will look different, etc. - -OPTIMIZE_OUTPUT_JAVA = NO - -# Set the OPTIMIZE_FOR_FORTRAN tag to YES if your project consists of Fortran -# sources only. Doxygen will then generate output that is more tailored for -# Fortran. - -OPTIMIZE_FOR_FORTRAN = NO - -# Set the OPTIMIZE_OUTPUT_VHDL tag to YES if your project consists of VHDL -# sources. Doxygen will then generate output that is tailored for -# VHDL. - -OPTIMIZE_OUTPUT_VHDL = NO - -# Doxygen selects the parser to use depending on the extension of the files it -# parses. With this tag you can assign which parser to use for a given extension. -# Doxygen has a built-in mapping, but you can override or extend it using this -# tag. The format is ext=language, where ext is a file extension, and language -# is one of the parsers supported by doxygen: IDL, Java, Javascript, CSharp, C, -# C++, D, PHP, Objective-C, Python, Fortran, VHDL, C, C++. For instance to make -# doxygen treat .inc files as Fortran files (default is PHP), and .f files as C -# (default is Fortran), use: inc=Fortran f=C. Note that for custom extensions -# you also need to set FILE_PATTERNS otherwise the files are not read by doxygen. - -EXTENSION_MAPPING = - -# If you use STL classes (i.e. std::string, std::vector, etc.) but do not want -# to include (a tag file for) the STL sources as input, then you should -# set this tag to YES in order to let doxygen match functions declarations and -# definitions whose arguments contain STL classes (e.g. func(std::string); v.s. -# func(std::string) {}). This also makes the inheritance and collaboration -# diagrams that involve STL classes more complete and accurate. - -BUILTIN_STL_SUPPORT = NO - -# If you use Microsoft's C++/CLI language, you should set this option to YES to -# enable parsing support. - -CPP_CLI_SUPPORT = NO - -# Set the SIP_SUPPORT tag to YES if your project consists of sip sources only. -# Doxygen will parse them like normal C++ but will assume all classes use public -# instead of private inheritance when no explicit protection keyword is present. - -SIP_SUPPORT = NO - -# For Microsoft's IDL there are propget and propput attributes to indicate getter -# and setter methods for a property. Setting this option to YES (the default) -# will make doxygen replace the get and set methods by a property in the -# documentation. This will only work if the methods are indeed getting or -# setting a simple type. If this is not the case, or you want to show the -# methods anyway, you should set this option to NO. - -IDL_PROPERTY_SUPPORT = YES - -# If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC -# tag is set to YES, then doxygen will reuse the documentation of the first -# member in the group (if any) for the other members of the group. By default -# all members of a group must be documented explicitly. - -DISTRIBUTE_GROUP_DOC = NO - -# Set the SUBGROUPING tag to YES (the default) to allow class member groups of -# the same type (for instance a group of public functions) to be put as a -# subgroup of that type (e.g. under the Public Functions section). Set it to -# NO to prevent subgrouping. Alternatively, this can be done per class using -# the \nosubgrouping command. - -SUBGROUPING = YES - -# When the INLINE_GROUPED_CLASSES tag is set to YES, classes, structs and -# unions are shown inside the group in which they are included (e.g. using -# @ingroup) instead of on a separate page (for HTML and Man pages) or -# section (for LaTeX and RTF). - -INLINE_GROUPED_CLASSES = NO - -# When TYPEDEF_HIDES_STRUCT is enabled, a typedef of a struct, union, or enum -# is documented as struct, union, or enum with the name of the typedef. So -# typedef struct TypeS {} TypeT, will appear in the documentation as a struct -# with name TypeT. When disabled the typedef will appear as a member of a file, -# namespace, or class. And the struct will be named TypeS. This can typically -# be useful for C code in case the coding convention dictates that all compound -# types are typedef'ed and only the typedef is referenced, never the tag name. - -TYPEDEF_HIDES_STRUCT = NO - -# The SYMBOL_CACHE_SIZE determines the size of the internal cache use to -# determine which symbols to keep in memory and which to flush to disk. -# When the cache is full, less often used symbols will be written to disk. -# For small to medium size projects (<1000 input files) the default value is -# probably good enough. For larger projects a too small cache size can cause -# doxygen to be busy swapping symbols to and from disk most of the time -# causing a significant performance penalty. -# If the system has enough physical memory increasing the cache will improve the -# performance by keeping more symbols in memory. Note that the value works on -# a logarithmic scale so increasing the size by one will roughly double the -# memory usage. The cache size is given by this formula: -# 2^(16+SYMBOL_CACHE_SIZE). The valid range is 0..9, the default is 0, -# corresponding to a cache size of 2^16 = 65536 symbols - -SYMBOL_CACHE_SIZE = 0 - -#--------------------------------------------------------------------------- -# Build related configuration options -#--------------------------------------------------------------------------- - -# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in -# documentation are documented, even if no documentation was available. -# Private class members and static file members will be hidden unless -# the EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES - -EXTRACT_ALL = NO - -# If the EXTRACT_PRIVATE tag is set to YES all private members of a class -# will be included in the documentation. - -EXTRACT_PRIVATE = NO - -# If the EXTRACT_STATIC tag is set to YES all static members of a file -# will be included in the documentation. - -EXTRACT_STATIC = NO - -# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs) -# defined locally in source files will be included in the documentation. -# If set to NO only classes defined in header files are included. - -EXTRACT_LOCAL_CLASSES = YES - -# This flag is only useful for Objective-C code. When set to YES local -# methods, which are defined in the implementation section but not in -# the interface are included in the documentation. -# If set to NO (the default) only methods in the interface are included. - -EXTRACT_LOCAL_METHODS = NO - -# If this flag is set to YES, the members of anonymous namespaces will be -# extracted and appear in the documentation as a namespace called -# 'anonymous_namespace{file}', where file will be replaced with the base -# name of the file that contains the anonymous namespace. By default -# anonymous namespaces are hidden. - -EXTRACT_ANON_NSPACES = NO - -# If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all -# undocumented members of documented classes, files or namespaces. -# If set to NO (the default) these members will be included in the -# various overviews, but no documentation section is generated. -# This option has no effect if EXTRACT_ALL is enabled. - -HIDE_UNDOC_MEMBERS = NO - -# If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all -# undocumented classes that are normally visible in the class hierarchy. -# If set to NO (the default) these classes will be included in the various -# overviews. This option has no effect if EXTRACT_ALL is enabled. - -HIDE_UNDOC_CLASSES = NO - -# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, Doxygen will hide all -# friend (class|struct|union) declarations. -# If set to NO (the default) these declarations will be included in the -# documentation. - -HIDE_FRIEND_COMPOUNDS = NO - -# If the HIDE_IN_BODY_DOCS tag is set to YES, Doxygen will hide any -# documentation blocks found inside the body of a function. -# If set to NO (the default) these blocks will be appended to the -# function's detailed documentation block. - -HIDE_IN_BODY_DOCS = NO - -# The INTERNAL_DOCS tag determines if documentation -# that is typed after a \internal command is included. If the tag is set -# to NO (the default) then the documentation will be excluded. -# Set it to YES to include the internal documentation. - -INTERNAL_DOCS = NO - -# If the CASE_SENSE_NAMES tag is set to NO then Doxygen will only generate -# file names in lower-case letters. If set to YES upper-case letters are also -# allowed. This is useful if you have classes or files whose names only differ -# in case and if your file system supports case sensitive file names. Windows -# and Mac users are advised to set this option to NO. - -CASE_SENSE_NAMES = YES - -# If the HIDE_SCOPE_NAMES tag is set to NO (the default) then Doxygen -# will show members with their full class and namespace scopes in the -# documentation. If set to YES the scope will be hidden. - -HIDE_SCOPE_NAMES = NO - -# If the SHOW_INCLUDE_FILES tag is set to YES (the default) then Doxygen -# will put a list of the files that are included by a file in the documentation -# of that file. - -SHOW_INCLUDE_FILES = YES - -# If the FORCE_LOCAL_INCLUDES tag is set to YES then Doxygen -# will list include files with double quotes in the documentation -# rather than with sharp brackets. - -FORCE_LOCAL_INCLUDES = NO - -# If the INLINE_INFO tag is set to YES (the default) then a tag [inline] -# is inserted in the documentation for inline members. - -INLINE_INFO = YES - -# If the SORT_MEMBER_DOCS tag is set to YES (the default) then doxygen -# will sort the (detailed) documentation of file and class members -# alphabetically by member name. If set to NO the members will appear in -# declaration order. - -SORT_MEMBER_DOCS = NO - -# If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the -# brief documentation of file, namespace and class members alphabetically -# by member name. If set to NO (the default) the members will appear in -# declaration order. - -SORT_BRIEF_DOCS = NO - -# If the SORT_MEMBERS_CTORS_1ST tag is set to YES then doxygen -# will sort the (brief and detailed) documentation of class members so that -# constructors and destructors are listed first. If set to NO (the default) -# the constructors will appear in the respective orders defined by -# SORT_MEMBER_DOCS and SORT_BRIEF_DOCS. -# This tag will be ignored for brief docs if SORT_BRIEF_DOCS is set to NO -# and ignored for detailed docs if SORT_MEMBER_DOCS is set to NO. - -SORT_MEMBERS_CTORS_1ST = NO - -# If the SORT_GROUP_NAMES tag is set to YES then doxygen will sort the -# hierarchy of group names into alphabetical order. If set to NO (the default) -# the group names will appear in their defined order. - -SORT_GROUP_NAMES = NO - -# If the SORT_BY_SCOPE_NAME tag is set to YES, the class list will be -# sorted by fully-qualified names, including namespaces. If set to -# NO (the default), the class list will be sorted only by class name, -# not including the namespace part. -# Note: This option is not very useful if HIDE_SCOPE_NAMES is set to YES. -# Note: This option applies only to the class list, not to the -# alphabetical list. - -SORT_BY_SCOPE_NAME = NO - -# If the STRICT_PROTO_MATCHING option is enabled and doxygen fails to -# do proper type resolution of all parameters of a function it will reject a -# match between the prototype and the implementation of a member function even -# if there is only one candidate or it is obvious which candidate to choose -# by doing a simple string match. By disabling STRICT_PROTO_MATCHING doxygen -# will still accept a match between prototype and implementation in such cases. - -STRICT_PROTO_MATCHING = NO - -# The GENERATE_TODOLIST tag can be used to enable (YES) or -# disable (NO) the todo list. This list is created by putting \todo -# commands in the documentation. - -GENERATE_TODOLIST = YES - -# The GENERATE_TESTLIST tag can be used to enable (YES) or -# disable (NO) the test list. This list is created by putting \test -# commands in the documentation. - -GENERATE_TESTLIST = YES - -# The GENERATE_BUGLIST tag can be used to enable (YES) or -# disable (NO) the bug list. This list is created by putting \bug -# commands in the documentation. - -GENERATE_BUGLIST = YES - -# The GENERATE_DEPRECATEDLIST tag can be used to enable (YES) or -# disable (NO) the deprecated list. This list is created by putting -# \deprecated commands in the documentation. - -GENERATE_DEPRECATEDLIST= YES - -# The ENABLED_SECTIONS tag can be used to enable conditional -# documentation sections, marked by \if sectionname ... \endif. - -ENABLED_SECTIONS = - -# The MAX_INITIALIZER_LINES tag determines the maximum number of lines -# the initial value of a variable or macro consists of for it to appear in -# the documentation. If the initializer consists of more lines than specified -# here it will be hidden. Use a value of 0 to hide initializers completely. -# The appearance of the initializer of individual variables and macros in the -# documentation can be controlled using \showinitializer or \hideinitializer -# command in the documentation regardless of this setting. - -MAX_INITIALIZER_LINES = 30 - -# Set the SHOW_USED_FILES tag to NO to disable the list of files generated -# at the bottom of the documentation of classes and structs. If set to YES the -# list will mention the files that were used to generate the documentation. - -SHOW_USED_FILES = YES - -# If the sources in your project are distributed over multiple directories -# then setting the SHOW_DIRECTORIES tag to YES will show the directory hierarchy -# in the documentation. The default is NO. - -SHOW_DIRECTORIES = YES - -# Set the SHOW_FILES tag to NO to disable the generation of the Files page. -# This will remove the Files entry from the Quick Index and from the -# Folder Tree View (if specified). The default is YES. - -SHOW_FILES = YES - -# Set the SHOW_NAMESPACES tag to NO to disable the generation of the -# Namespaces page. -# This will remove the Namespaces entry from the Quick Index -# and from the Folder Tree View (if specified). The default is YES. - -SHOW_NAMESPACES = YES - -# The FILE_VERSION_FILTER tag can be used to specify a program or script that -# doxygen should invoke to get the current version for each file (typically from -# the version control system). Doxygen will invoke the program by executing (via -# popen()) the command , where is the value of -# the FILE_VERSION_FILTER tag, and is the name of an input file -# provided by doxygen. Whatever the program writes to standard output -# is used as the file version. See the manual for examples. - -FILE_VERSION_FILTER = - -# The LAYOUT_FILE tag can be used to specify a layout file which will be parsed -# by doxygen. The layout file controls the global structure of the generated -# output files in an output format independent way. The create the layout file -# that represents doxygen's defaults, run doxygen with the -l option. -# You can optionally specify a file name after the option, if omitted -# DoxygenLayout.xml will be used as the name of the layout file. - -LAYOUT_FILE = - -#--------------------------------------------------------------------------- -# configuration options related to warning and progress messages -#--------------------------------------------------------------------------- - -# The QUIET tag can be used to turn on/off the messages that are generated -# by doxygen. Possible values are YES and NO. If left blank NO is used. - -QUIET = NO - -# The WARNINGS tag can be used to turn on/off the warning messages that are -# generated by doxygen. Possible values are YES and NO. If left blank -# NO is used. - -WARNINGS = YES - -# If WARN_IF_UNDOCUMENTED is set to YES, then doxygen will generate warnings -# for undocumented members. If EXTRACT_ALL is set to YES then this flag will -# automatically be disabled. - -WARN_IF_UNDOCUMENTED = YES - -# If WARN_IF_DOC_ERROR is set to YES, doxygen will generate warnings for -# potential errors in the documentation, such as not documenting some -# parameters in a documented function, or documenting parameters that -# don't exist or using markup commands wrongly. - -WARN_IF_DOC_ERROR = YES - -# The WARN_NO_PARAMDOC option can be enabled to get warnings for -# functions that are documented, but have no documentation for their parameters -# or return value. If set to NO (the default) doxygen will only warn about -# wrong or incomplete parameter documentation, but not about the absence of -# documentation. - -WARN_NO_PARAMDOC = NO - -# The WARN_FORMAT tag determines the format of the warning messages that -# doxygen can produce. The string should contain the $file, $line, and $text -# tags, which will be replaced by the file and line number from which the -# warning originated and the warning text. Optionally the format may contain -# $version, which will be replaced by the version of the file (if it could -# be obtained via FILE_VERSION_FILTER) - -WARN_FORMAT = "$file:$line: $text" - -# The WARN_LOGFILE tag can be used to specify a file to which warning -# and error messages should be written. If left blank the output is written -# to stderr. - -WARN_LOGFILE = - -#--------------------------------------------------------------------------- -# configuration options related to the input files -#--------------------------------------------------------------------------- - -# The INPUT tag can be used to specify the files and/or directories that contain -# documented source files. You may enter file names like "myfile.cpp" or -# directories like "/usr/src/myproject". Separate the files or directories -# with spaces. - -INPUT = - -# This tag can be used to specify the character encoding of the source files -# that doxygen parses. Internally doxygen uses the UTF-8 encoding, which is -# also the default input encoding. Doxygen uses libiconv (or the iconv built -# into libc) for the transcoding. See http://www.gnu.org/software/libiconv for -# the list of possible encodings. - -INPUT_ENCODING = UTF-8 - -# If the value of the INPUT tag contains directories, you can use the -# FILE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp -# and *.h) to filter out the source-files in the directories. If left -# blank the following patterns are tested: -# *.c *.cc *.cxx *.cpp *.c++ *.d *.java *.ii *.ixx *.ipp *.i++ *.inl *.h *.hh -# *.hxx *.hpp *.h++ *.idl *.odl *.cs *.php *.php3 *.inc *.m *.mm *.dox *.py -# *.f90 *.f *.for *.vhd *.vhdl - -FILE_PATTERNS = *.cpp \ - *.h \ - *.dox - -# The RECURSIVE tag can be used to turn specify whether or not subdirectories -# should be searched for input files as well. Possible values are YES and NO. -# If left blank NO is used. - -RECURSIVE = YES - -# The EXCLUDE tag can be used to specify files and/or directories that should -# excluded from the INPUT source files. This way you can easily exclude a -# subdirectory from a directory tree whose root is specified with the INPUT tag. - -EXCLUDE = quazip/unzip.h \ - quazip/zip.h \ - quazip/ioapi.h \ - quazip/crypt.h \ - qztest/ - -# The EXCLUDE_SYMLINKS tag can be used select whether or not files or -# directories that are symbolic links (a Unix file system feature) are excluded -# from the input. - -EXCLUDE_SYMLINKS = NO - -# If the value of the INPUT tag contains directories, you can use the -# EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude -# certain files from those directories. Note that the wildcards are matched -# against the file with absolute path, so to exclude all test directories -# for example use the pattern */test/* - -EXCLUDE_PATTERNS = */.moc/* */release/* */debug/* */moc_*.cpp - -# The EXCLUDE_SYMBOLS tag can be used to specify one or more symbol names -# (namespaces, classes, functions, etc.) that should be excluded from the -# output. The symbol name can be a fully qualified name, a word, or if the -# wildcard * is used, a substring. Examples: ANamespace, AClass, -# AClass::ANamespace, ANamespace::*Test - -EXCLUDE_SYMBOLS = - -# The EXAMPLE_PATH tag can be used to specify one or more files or -# directories that contain example code fragments that are included (see -# the \include command). - -EXAMPLE_PATH = - -# If the value of the EXAMPLE_PATH tag contains directories, you can use the -# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp -# and *.h) to filter out the source-files in the directories. If left -# blank all files are included. - -EXAMPLE_PATTERNS = - -# If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be -# searched for input files to be used with the \include or \dontinclude -# commands irrespective of the value of the RECURSIVE tag. -# Possible values are YES and NO. If left blank NO is used. - -EXAMPLE_RECURSIVE = NO - -# The IMAGE_PATH tag can be used to specify one or more files or -# directories that contain image that are included in the documentation (see -# the \image command). - -IMAGE_PATH = - -# The INPUT_FILTER tag can be used to specify a program that doxygen should -# invoke to filter for each input file. Doxygen will invoke the filter program -# by executing (via popen()) the command , where -# is the value of the INPUT_FILTER tag, and is the name of an -# input file. Doxygen will then use the output that the filter program writes -# to standard output. -# If FILTER_PATTERNS is specified, this tag will be -# ignored. - -INPUT_FILTER = - -# The FILTER_PATTERNS tag can be used to specify filters on a per file pattern -# basis. -# Doxygen will compare the file name with each pattern and apply the -# filter if there is a match. -# The filters are a list of the form: -# pattern=filter (like *.cpp=my_cpp_filter). See INPUT_FILTER for further -# info on how filters are used. If FILTER_PATTERNS is empty or if -# non of the patterns match the file name, INPUT_FILTER is applied. - -FILTER_PATTERNS = - -# If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using -# INPUT_FILTER) will be used to filter the input files when producing source -# files to browse (i.e. when SOURCE_BROWSER is set to YES). - -FILTER_SOURCE_FILES = NO - -# The FILTER_SOURCE_PATTERNS tag can be used to specify source filters per file -# pattern. A pattern will override the setting for FILTER_PATTERN (if any) -# and it is also possible to disable source filtering for a specific pattern -# using *.ext= (so without naming a filter). This option only has effect when -# FILTER_SOURCE_FILES is enabled. - -FILTER_SOURCE_PATTERNS = - -#--------------------------------------------------------------------------- -# configuration options related to source browsing -#--------------------------------------------------------------------------- - -# If the SOURCE_BROWSER tag is set to YES then a list of source files will -# be generated. Documented entities will be cross-referenced with these sources. -# Note: To get rid of all source code in the generated output, make sure also -# VERBATIM_HEADERS is set to NO. - -SOURCE_BROWSER = NO - -# Setting the INLINE_SOURCES tag to YES will include the body -# of functions and classes directly in the documentation. - -INLINE_SOURCES = NO - -# Setting the STRIP_CODE_COMMENTS tag to YES (the default) will instruct -# doxygen to hide any special comment blocks from generated source code -# fragments. Normal C and C++ comments will always remain visible. - -STRIP_CODE_COMMENTS = YES - -# If the REFERENCED_BY_RELATION tag is set to YES -# then for each documented function all documented -# functions referencing it will be listed. - -REFERENCED_BY_RELATION = YES - -# If the REFERENCES_RELATION tag is set to YES -# then for each documented function all documented entities -# called/used by that function will be listed. - -REFERENCES_RELATION = YES - -# If the REFERENCES_LINK_SOURCE tag is set to YES (the default) -# and SOURCE_BROWSER tag is set to YES, then the hyperlinks from -# functions in REFERENCES_RELATION and REFERENCED_BY_RELATION lists will -# link to the source code. -# Otherwise they will link to the documentation. - -REFERENCES_LINK_SOURCE = YES - -# If the USE_HTAGS tag is set to YES then the references to source code -# will point to the HTML generated by the htags(1) tool instead of doxygen -# built-in source browser. The htags tool is part of GNU's global source -# tagging system (see http://www.gnu.org/software/global/global.html). You -# will need version 4.8.6 or higher. - -USE_HTAGS = NO - -# If the VERBATIM_HEADERS tag is set to YES (the default) then Doxygen -# will generate a verbatim copy of the header file for each class for -# which an include is specified. Set to NO to disable this. - -VERBATIM_HEADERS = YES - -#--------------------------------------------------------------------------- -# configuration options related to the alphabetical class index -#--------------------------------------------------------------------------- - -# If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index -# of all compounds will be generated. Enable this if the project -# contains a lot of classes, structs, unions or interfaces. - -ALPHABETICAL_INDEX = NO - -# If the alphabetical index is enabled (see ALPHABETICAL_INDEX) then -# the COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns -# in which this list will be split (can be a number in the range [1..20]) - -COLS_IN_ALPHA_INDEX = 5 - -# In case all classes in a project start with a common prefix, all -# classes will be put under the same header in the alphabetical index. -# The IGNORE_PREFIX tag can be used to specify one or more prefixes that -# should be ignored while generating the index headers. - -IGNORE_PREFIX = - -#--------------------------------------------------------------------------- -# configuration options related to the HTML output -#--------------------------------------------------------------------------- - -# If the GENERATE_HTML tag is set to YES (the default) Doxygen will -# generate HTML output. - -GENERATE_HTML = YES - -# The HTML_OUTPUT tag is used to specify where the HTML docs will be put. -# If a relative path is entered the value of OUTPUT_DIRECTORY will be -# put in front of it. If left blank `html' will be used as the default path. - -HTML_OUTPUT = html - -# The HTML_FILE_EXTENSION tag can be used to specify the file extension for -# each generated HTML page (for example: .htm,.php,.asp). If it is left blank -# doxygen will generate files with .html extension. - -HTML_FILE_EXTENSION = .html - -# The HTML_HEADER tag can be used to specify a personal HTML header for -# each generated HTML page. If it is left blank doxygen will generate a -# standard header. Note that when using a custom header you are responsible -# for the proper inclusion of any scripts and style sheets that doxygen -# needs, which is dependent on the configuration options used. -# It is adviced to generate a default header using "doxygen -w html -# header.html footer.html stylesheet.css YourConfigFile" and then modify -# that header. Note that the header is subject to change so you typically -# have to redo this when upgrading to a newer version of doxygen or when changing the value of configuration settings such as GENERATE_TREEVIEW! - -HTML_HEADER = - -# The HTML_FOOTER tag can be used to specify a personal HTML footer for -# each generated HTML page. If it is left blank doxygen will generate a -# standard footer. - -HTML_FOOTER = - -# The HTML_STYLESHEET tag can be used to specify a user-defined cascading -# style sheet that is used by each HTML page. It can be used to -# fine-tune the look of the HTML output. If the tag is left blank doxygen -# will generate a default style sheet. Note that doxygen will try to copy -# the style sheet file to the HTML output directory, so don't put your own -# stylesheet in the HTML output directory as well, or it will be erased! - -HTML_STYLESHEET = - -# The HTML_EXTRA_FILES tag can be used to specify one or more extra images or -# other source files which should be copied to the HTML output directory. Note -# that these files will be copied to the base HTML output directory. Use the -# $relpath$ marker in the HTML_HEADER and/or HTML_FOOTER files to load these -# files. In the HTML_STYLESHEET file, use the file name only. Also note that -# the files will be copied as-is; there are no commands or markers available. - -HTML_EXTRA_FILES = - -# The HTML_COLORSTYLE_HUE tag controls the color of the HTML output. -# Doxygen will adjust the colors in the stylesheet and background images -# according to this color. Hue is specified as an angle on a colorwheel, -# see http://en.wikipedia.org/wiki/Hue for more information. -# For instance the value 0 represents red, 60 is yellow, 120 is green, -# 180 is cyan, 240 is blue, 300 purple, and 360 is red again. -# The allowed range is 0 to 359. - -HTML_COLORSTYLE_HUE = 220 - -# The HTML_COLORSTYLE_SAT tag controls the purity (or saturation) of -# the colors in the HTML output. For a value of 0 the output will use -# grayscales only. A value of 255 will produce the most vivid colors. - -HTML_COLORSTYLE_SAT = 100 - -# The HTML_COLORSTYLE_GAMMA tag controls the gamma correction applied to -# the luminance component of the colors in the HTML output. Values below -# 100 gradually make the output lighter, whereas values above 100 make -# the output darker. The value divided by 100 is the actual gamma applied, -# so 80 represents a gamma of 0.8, The value 220 represents a gamma of 2.2, -# and 100 does not change the gamma. - -HTML_COLORSTYLE_GAMMA = 80 - -# If the HTML_TIMESTAMP tag is set to YES then the footer of each generated HTML -# page will contain the date and time when the page was generated. Setting -# this to NO can help when comparing the output of multiple runs. - -HTML_TIMESTAMP = YES - -# If the HTML_ALIGN_MEMBERS tag is set to YES, the members of classes, -# files or namespaces will be aligned in HTML using tables. If set to -# NO a bullet list will be used. - -HTML_ALIGN_MEMBERS = YES - -# If the HTML_DYNAMIC_SECTIONS tag is set to YES then the generated HTML -# documentation will contain sections that can be hidden and shown after the -# page has loaded. For this to work a browser that supports -# JavaScript and DHTML is required (for instance Mozilla 1.0+, Firefox -# Netscape 6.0+, Internet explorer 5.0+, Konqueror, or Safari). - -HTML_DYNAMIC_SECTIONS = NO - -# If the GENERATE_DOCSET tag is set to YES, additional index files -# will be generated that can be used as input for Apple's Xcode 3 -# integrated development environment, introduced with OSX 10.5 (Leopard). -# To create a documentation set, doxygen will generate a Makefile in the -# HTML output directory. Running make will produce the docset in that -# directory and running "make install" will install the docset in -# ~/Library/Developer/Shared/Documentation/DocSets so that Xcode will find -# it at startup. -# See http://developer.apple.com/tools/creatingdocsetswithdoxygen.html -# for more information. - -GENERATE_DOCSET = NO - -# When GENERATE_DOCSET tag is set to YES, this tag determines the name of the -# feed. A documentation feed provides an umbrella under which multiple -# documentation sets from a single provider (such as a company or product suite) -# can be grouped. - -DOCSET_FEEDNAME = "Doxygen generated docs" - -# When GENERATE_DOCSET tag is set to YES, this tag specifies a string that -# should uniquely identify the documentation set bundle. This should be a -# reverse domain-name style string, e.g. com.mycompany.MyDocSet. Doxygen -# will append .docset to the name. - -DOCSET_BUNDLE_ID = org.doxygen.Project - -# When GENERATE_PUBLISHER_ID tag specifies a string that should uniquely identify -# the documentation publisher. This should be a reverse domain-name style -# string, e.g. com.mycompany.MyDocSet.documentation. - -DOCSET_PUBLISHER_ID = org.doxygen.Publisher - -# The GENERATE_PUBLISHER_NAME tag identifies the documentation publisher. - -DOCSET_PUBLISHER_NAME = Publisher - -# If the GENERATE_HTMLHELP tag is set to YES, additional index files -# will be generated that can be used as input for tools like the -# Microsoft HTML help workshop to generate a compiled HTML help file (.chm) -# of the generated HTML documentation. - -GENERATE_HTMLHELP = NO - -# If the GENERATE_HTMLHELP tag is set to YES, the CHM_FILE tag can -# be used to specify the file name of the resulting .chm file. You -# can add a path in front of the file if the result should not be -# written to the html output directory. - -CHM_FILE = - -# If the GENERATE_HTMLHELP tag is set to YES, the HHC_LOCATION tag can -# be used to specify the location (absolute path including file name) of -# the HTML help compiler (hhc.exe). If non-empty doxygen will try to run -# the HTML help compiler on the generated index.hhp. - -HHC_LOCATION = - -# If the GENERATE_HTMLHELP tag is set to YES, the GENERATE_CHI flag -# controls if a separate .chi index file is generated (YES) or that -# it should be included in the master .chm file (NO). - -GENERATE_CHI = NO - -# If the GENERATE_HTMLHELP tag is set to YES, the CHM_INDEX_ENCODING -# is used to encode HtmlHelp index (hhk), content (hhc) and project file -# content. - -CHM_INDEX_ENCODING = - -# If the GENERATE_HTMLHELP tag is set to YES, the BINARY_TOC flag -# controls whether a binary table of contents is generated (YES) or a -# normal table of contents (NO) in the .chm file. - -BINARY_TOC = NO - -# The TOC_EXPAND flag can be set to YES to add extra items for group members -# to the contents of the HTML help documentation and to the tree view. - -TOC_EXPAND = NO - -# If the GENERATE_QHP tag is set to YES and both QHP_NAMESPACE and -# QHP_VIRTUAL_FOLDER are set, an additional index file will be generated -# that can be used as input for Qt's qhelpgenerator to generate a -# Qt Compressed Help (.qch) of the generated HTML documentation. - -GENERATE_QHP = NO - -# If the QHG_LOCATION tag is specified, the QCH_FILE tag can -# be used to specify the file name of the resulting .qch file. -# The path specified is relative to the HTML output folder. - -QCH_FILE = - -# The QHP_NAMESPACE tag specifies the namespace to use when generating -# Qt Help Project output. For more information please see -# http://doc.trolltech.com/qthelpproject.html#namespace - -QHP_NAMESPACE = org.doxygen.Project - -# The QHP_VIRTUAL_FOLDER tag specifies the namespace to use when generating -# Qt Help Project output. For more information please see -# http://doc.trolltech.com/qthelpproject.html#virtual-folders - -QHP_VIRTUAL_FOLDER = doc - -# If QHP_CUST_FILTER_NAME is set, it specifies the name of a custom filter to -# add. For more information please see -# http://doc.trolltech.com/qthelpproject.html#custom-filters - -QHP_CUST_FILTER_NAME = - -# The QHP_CUST_FILT_ATTRS tag specifies the list of the attributes of the -# custom filter to add. For more information please see -# -# Qt Help Project / Custom Filters. - -QHP_CUST_FILTER_ATTRS = - -# The QHP_SECT_FILTER_ATTRS tag specifies the list of the attributes this -# project's -# filter section matches. -# -# Qt Help Project / Filter Attributes. - -QHP_SECT_FILTER_ATTRS = - -# If the GENERATE_QHP tag is set to YES, the QHG_LOCATION tag can -# be used to specify the location of Qt's qhelpgenerator. -# If non-empty doxygen will try to run qhelpgenerator on the generated -# .qhp file. - -QHG_LOCATION = - -# If the GENERATE_ECLIPSEHELP tag is set to YES, additional index files -# will be generated, which together with the HTML files, form an Eclipse help -# plugin. To install this plugin and make it available under the help contents -# menu in Eclipse, the contents of the directory containing the HTML and XML -# files needs to be copied into the plugins directory of eclipse. The name of -# the directory within the plugins directory should be the same as -# the ECLIPSE_DOC_ID value. After copying Eclipse needs to be restarted before -# the help appears. - -GENERATE_ECLIPSEHELP = NO - -# A unique identifier for the eclipse help plugin. When installing the plugin -# the directory name containing the HTML and XML files should also have -# this name. - -ECLIPSE_DOC_ID = org.doxygen.Project - -# The DISABLE_INDEX tag can be used to turn on/off the condensed index at -# top of each HTML page. The value NO (the default) enables the index and -# the value YES disables it. - -DISABLE_INDEX = NO - -# The ENUM_VALUES_PER_LINE tag can be used to set the number of enum values -# (range [0,1..20]) that doxygen will group on one line in the generated HTML -# documentation. Note that a value of 0 will completely suppress the enum -# values from appearing in the overview section. - -ENUM_VALUES_PER_LINE = 4 - -# The GENERATE_TREEVIEW tag is used to specify whether a tree-like index -# structure should be generated to display hierarchical information. -# If the tag value is set to YES, a side panel will be generated -# containing a tree-like index structure (just like the one that -# is generated for HTML Help). For this to work a browser that supports -# JavaScript, DHTML, CSS and frames is required (i.e. any modern browser). -# Windows users are probably better off using the HTML help feature. - -GENERATE_TREEVIEW = NO - -# By enabling USE_INLINE_TREES, doxygen will generate the Groups, Directories, -# and Class Hierarchy pages using a tree view instead of an ordered list. - -USE_INLINE_TREES = NO - -# If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be -# used to set the initial width (in pixels) of the frame in which the tree -# is shown. - -TREEVIEW_WIDTH = 250 - -# When the EXT_LINKS_IN_WINDOW option is set to YES doxygen will open -# links to external symbols imported via tag files in a separate window. - -EXT_LINKS_IN_WINDOW = NO - -# Use this tag to change the font size of Latex formulas included -# as images in the HTML documentation. The default is 10. Note that -# when you change the font size after a successful doxygen run you need -# to manually remove any form_*.png images from the HTML output directory -# to force them to be regenerated. - -FORMULA_FONTSIZE = 10 - -# Use the FORMULA_TRANPARENT tag to determine whether or not the images -# generated for formulas are transparent PNGs. Transparent PNGs are -# not supported properly for IE 6.0, but are supported on all modern browsers. -# Note that when changing this option you need to delete any form_*.png files -# in the HTML output before the changes have effect. - -FORMULA_TRANSPARENT = YES - -# Enable the USE_MATHJAX option to render LaTeX formulas using MathJax -# (see http://www.mathjax.org) which uses client side Javascript for the -# rendering instead of using prerendered bitmaps. Use this if you do not -# have LaTeX installed or if you want to formulas look prettier in the HTML -# output. When enabled you also need to install MathJax separately and -# configure the path to it using the MATHJAX_RELPATH option. - -USE_MATHJAX = NO - -# When MathJax is enabled you need to specify the location relative to the -# HTML output directory using the MATHJAX_RELPATH option. The destination -# directory should contain the MathJax.js script. For instance, if the mathjax -# directory is located at the same level as the HTML output directory, then -# MATHJAX_RELPATH should be ../mathjax. The default value points to the -# mathjax.org site, so you can quickly see the result without installing -# MathJax, but it is strongly recommended to install a local copy of MathJax -# before deployment. - -MATHJAX_RELPATH = http://www.mathjax.org/mathjax - -# When the SEARCHENGINE tag is enabled doxygen will generate a search box -# for the HTML output. The underlying search engine uses javascript -# and DHTML and should work on any modern browser. Note that when using -# HTML help (GENERATE_HTMLHELP), Qt help (GENERATE_QHP), or docsets -# (GENERATE_DOCSET) there is already a search function so this one should -# typically be disabled. For large projects the javascript based search engine -# can be slow, then enabling SERVER_BASED_SEARCH may provide a better solution. - -SEARCHENGINE = NO - -# When the SERVER_BASED_SEARCH tag is enabled the search engine will be -# implemented using a PHP enabled web server instead of at the web client -# using Javascript. Doxygen will generate the search PHP script and index -# file to put on the web server. The advantage of the server -# based approach is that it scales better to large projects and allows -# full text search. The disadvantages are that it is more difficult to setup -# and does not have live searching capabilities. - -SERVER_BASED_SEARCH = NO - -#--------------------------------------------------------------------------- -# configuration options related to the LaTeX output -#--------------------------------------------------------------------------- - -# If the GENERATE_LATEX tag is set to YES (the default) Doxygen will -# generate Latex output. - -GENERATE_LATEX = YES - -# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. -# If a relative path is entered the value of OUTPUT_DIRECTORY will be -# put in front of it. If left blank `latex' will be used as the default path. - -LATEX_OUTPUT = latex - -# The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be -# invoked. If left blank `latex' will be used as the default command name. -# Note that when enabling USE_PDFLATEX this option is only used for -# generating bitmaps for formulas in the HTML output, but not in the -# Makefile that is written to the output directory. - -LATEX_CMD_NAME = latex - -# The MAKEINDEX_CMD_NAME tag can be used to specify the command name to -# generate index for LaTeX. If left blank `makeindex' will be used as the -# default command name. - -MAKEINDEX_CMD_NAME = makeindex - -# If the COMPACT_LATEX tag is set to YES Doxygen generates more compact -# LaTeX documents. This may be useful for small projects and may help to -# save some trees in general. - -COMPACT_LATEX = NO - -# The PAPER_TYPE tag can be used to set the paper type that is used -# by the printer. Possible values are: a4, letter, legal and -# executive. If left blank a4wide will be used. - -PAPER_TYPE = a4wide - -# The EXTRA_PACKAGES tag can be to specify one or more names of LaTeX -# packages that should be included in the LaTeX output. - -EXTRA_PACKAGES = - -# The LATEX_HEADER tag can be used to specify a personal LaTeX header for -# the generated latex document. The header should contain everything until -# the first chapter. If it is left blank doxygen will generate a -# standard header. Notice: only use this tag if you know what you are doing! - -LATEX_HEADER = - -# The LATEX_FOOTER tag can be used to specify a personal LaTeX footer for -# the generated latex document. The footer should contain everything after -# the last chapter. If it is left blank doxygen will generate a -# standard footer. Notice: only use this tag if you know what you are doing! - -LATEX_FOOTER = - -# If the PDF_HYPERLINKS tag is set to YES, the LaTeX that is generated -# is prepared for conversion to pdf (using ps2pdf). The pdf file will -# contain links (just like the HTML output) instead of page references -# This makes the output suitable for online browsing using a pdf viewer. - -PDF_HYPERLINKS = NO - -# If the USE_PDFLATEX tag is set to YES, pdflatex will be used instead of -# plain latex in the generated Makefile. Set this option to YES to get a -# higher quality PDF documentation. - -USE_PDFLATEX = NO - -# If the LATEX_BATCHMODE tag is set to YES, doxygen will add the \\batchmode. -# command to the generated LaTeX files. This will instruct LaTeX to keep -# running if errors occur, instead of asking the user for help. -# This option is also used when generating formulas in HTML. - -LATEX_BATCHMODE = NO - -# If LATEX_HIDE_INDICES is set to YES then doxygen will not -# include the index chapters (such as File Index, Compound Index, etc.) -# in the output. - -LATEX_HIDE_INDICES = NO - -# If LATEX_SOURCE_CODE is set to YES then doxygen will include -# source code with syntax highlighting in the LaTeX output. -# Note that which sources are shown also depends on other settings -# such as SOURCE_BROWSER. - -LATEX_SOURCE_CODE = NO - -#--------------------------------------------------------------------------- -# configuration options related to the RTF output -#--------------------------------------------------------------------------- - -# If the GENERATE_RTF tag is set to YES Doxygen will generate RTF output -# The RTF output is optimized for Word 97 and may not look very pretty with -# other RTF readers or editors. - -GENERATE_RTF = NO - -# The RTF_OUTPUT tag is used to specify where the RTF docs will be put. -# If a relative path is entered the value of OUTPUT_DIRECTORY will be -# put in front of it. If left blank `rtf' will be used as the default path. - -RTF_OUTPUT = rtf - -# If the COMPACT_RTF tag is set to YES Doxygen generates more compact -# RTF documents. This may be useful for small projects and may help to -# save some trees in general. - -COMPACT_RTF = NO - -# If the RTF_HYPERLINKS tag is set to YES, the RTF that is generated -# will contain hyperlink fields. The RTF file will -# contain links (just like the HTML output) instead of page references. -# This makes the output suitable for online browsing using WORD or other -# programs which support those fields. -# Note: wordpad (write) and others do not support links. - -RTF_HYPERLINKS = NO - -# Load stylesheet definitions from file. Syntax is similar to doxygen's -# config file, i.e. a series of assignments. You only have to provide -# replacements, missing definitions are set to their default value. - -RTF_STYLESHEET_FILE = - -# Set optional variables used in the generation of an rtf document. -# Syntax is similar to doxygen's config file. - -RTF_EXTENSIONS_FILE = - -#--------------------------------------------------------------------------- -# configuration options related to the man page output -#--------------------------------------------------------------------------- - -# If the GENERATE_MAN tag is set to YES (the default) Doxygen will -# generate man pages - -GENERATE_MAN = NO - -# The MAN_OUTPUT tag is used to specify where the man pages will be put. -# If a relative path is entered the value of OUTPUT_DIRECTORY will be -# put in front of it. If left blank `man' will be used as the default path. - -MAN_OUTPUT = man - -# The MAN_EXTENSION tag determines the extension that is added to -# the generated man pages (default is the subroutine's section .3) - -MAN_EXTENSION = .3 - -# If the MAN_LINKS tag is set to YES and Doxygen generates man output, -# then it will generate one additional man file for each entity -# documented in the real man page(s). These additional files -# only source the real man page, but without them the man command -# would be unable to find the correct page. The default is NO. - -MAN_LINKS = NO - -#--------------------------------------------------------------------------- -# configuration options related to the XML output -#--------------------------------------------------------------------------- - -# If the GENERATE_XML tag is set to YES Doxygen will -# generate an XML file that captures the structure of -# the code including all documentation. - -GENERATE_XML = NO - -# The XML_OUTPUT tag is used to specify where the XML pages will be put. -# If a relative path is entered the value of OUTPUT_DIRECTORY will be -# put in front of it. If left blank `xml' will be used as the default path. - -XML_OUTPUT = xml - -# The XML_SCHEMA tag can be used to specify an XML schema, -# which can be used by a validating XML parser to check the -# syntax of the XML files. - -XML_SCHEMA = - -# The XML_DTD tag can be used to specify an XML DTD, -# which can be used by a validating XML parser to check the -# syntax of the XML files. - -XML_DTD = - -# If the XML_PROGRAMLISTING tag is set to YES Doxygen will -# dump the program listings (including syntax highlighting -# and cross-referencing information) to the XML output. Note that -# enabling this will significantly increase the size of the XML output. - -XML_PROGRAMLISTING = YES - -#--------------------------------------------------------------------------- -# configuration options for the AutoGen Definitions output -#--------------------------------------------------------------------------- - -# If the GENERATE_AUTOGEN_DEF tag is set to YES Doxygen will -# generate an AutoGen Definitions (see autogen.sf.net) file -# that captures the structure of the code including all -# documentation. Note that this feature is still experimental -# and incomplete at the moment. - -GENERATE_AUTOGEN_DEF = NO - -#--------------------------------------------------------------------------- -# configuration options related to the Perl module output -#--------------------------------------------------------------------------- - -# If the GENERATE_PERLMOD tag is set to YES Doxygen will -# generate a Perl module file that captures the structure of -# the code including all documentation. Note that this -# feature is still experimental and incomplete at the -# moment. - -GENERATE_PERLMOD = NO - -# If the PERLMOD_LATEX tag is set to YES Doxygen will generate -# the necessary Makefile rules, Perl scripts and LaTeX code to be able -# to generate PDF and DVI output from the Perl module output. - -PERLMOD_LATEX = NO - -# If the PERLMOD_PRETTY tag is set to YES the Perl module output will be -# nicely formatted so it can be parsed by a human reader. -# This is useful -# if you want to understand what is going on. -# On the other hand, if this -# tag is set to NO the size of the Perl module output will be much smaller -# and Perl will parse it just the same. - -PERLMOD_PRETTY = YES - -# The names of the make variables in the generated doxyrules.make file -# are prefixed with the string contained in PERLMOD_MAKEVAR_PREFIX. -# This is useful so different doxyrules.make files included by the same -# Makefile don't overwrite each other's variables. - -PERLMOD_MAKEVAR_PREFIX = - -#--------------------------------------------------------------------------- -# Configuration options related to the preprocessor -#--------------------------------------------------------------------------- - -# If the ENABLE_PREPROCESSING tag is set to YES (the default) Doxygen will -# evaluate all C-preprocessor directives found in the sources and include -# files. - -ENABLE_PREPROCESSING = YES - -# If the MACRO_EXPANSION tag is set to YES Doxygen will expand all macro -# names in the source code. If set to NO (the default) only conditional -# compilation will be performed. Macro expansion can be done in a controlled -# way by setting EXPAND_ONLY_PREDEF to YES. - -MACRO_EXPANSION = NO - -# If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES -# then the macro expansion is limited to the macros specified with the -# PREDEFINED and EXPAND_AS_DEFINED tags. - -EXPAND_ONLY_PREDEF = NO - -# If the SEARCH_INCLUDES tag is set to YES (the default) the includes files -# pointed to by INCLUDE_PATH will be searched when a #include is found. - -SEARCH_INCLUDES = YES - -# The INCLUDE_PATH tag can be used to specify one or more directories that -# contain include files that are not input files but should be processed by -# the preprocessor. - -INCLUDE_PATH = - -# You can use the INCLUDE_FILE_PATTERNS tag to specify one or more wildcard -# patterns (like *.h and *.hpp) to filter out the header-files in the -# directories. If left blank, the patterns specified with FILE_PATTERNS will -# be used. - -INCLUDE_FILE_PATTERNS = - -# The PREDEFINED tag can be used to specify one or more macro names that -# are defined before the preprocessor is started (similar to the -D option of -# gcc). The argument of the tag is a list of macros of the form: name -# or name=definition (no spaces). If the definition and the = are -# omitted =1 is assumed. To prevent a macro definition from being -# undefined via #undef or recursively expanded use the := operator -# instead of the = operator. - -PREDEFINED = - -# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then -# this tag can be used to specify a list of macro names that should be expanded. -# The macro definition that is found in the sources will be used. -# Use the PREDEFINED tag if you want to use a different macro definition that -# overrules the definition found in the source code. - -EXPAND_AS_DEFINED = - -# If the SKIP_FUNCTION_MACROS tag is set to YES (the default) then -# doxygen's preprocessor will remove all references to function-like macros -# that are alone on a line, have an all uppercase name, and do not end with a -# semicolon, because these will confuse the parser if not removed. - -SKIP_FUNCTION_MACROS = YES - -#--------------------------------------------------------------------------- -# Configuration::additions related to external references -#--------------------------------------------------------------------------- - -# The TAGFILES option can be used to specify one or more tagfiles. -# Optionally an initial location of the external documentation -# can be added for each tagfile. The format of a tag file without -# this location is as follows: -# -# TAGFILES = file1 file2 ... -# Adding location for the tag files is done as follows: -# -# TAGFILES = file1=loc1 "file2 = loc2" ... -# where "loc1" and "loc2" can be relative or absolute paths or -# URLs. If a location is present for each tag, the installdox tool -# does not have to be run to correct the links. -# Note that each tag file must have a unique name -# (where the name does NOT include the path) -# If a tag file is not located in the directory in which doxygen -# is run, you must also specify the path to the tagfile here. - -TAGFILES = - -# When a file name is specified after GENERATE_TAGFILE, doxygen will create -# a tag file that is based on the input files it reads. - -GENERATE_TAGFILE = - -# If the ALLEXTERNALS tag is set to YES all external classes will be listed -# in the class index. If set to NO only the inherited external classes -# will be listed. - -ALLEXTERNALS = NO - -# If the EXTERNAL_GROUPS tag is set to YES all external groups will be listed -# in the modules index. If set to NO, only the current project's groups will -# be listed. - -EXTERNAL_GROUPS = YES - -# The PERL_PATH should be the absolute path and name of the perl script -# interpreter (i.e. the result of `which perl'). - -PERL_PATH = /usr/bin/perl - -#--------------------------------------------------------------------------- -# Configuration options related to the dot tool -#--------------------------------------------------------------------------- - -# If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will -# generate a inheritance diagram (in HTML, RTF and LaTeX) for classes with base -# or super classes. Setting the tag to NO turns the diagrams off. Note that -# this option also works with HAVE_DOT disabled, but it is recommended to -# install and use dot, since it yields more powerful graphs. - -CLASS_DIAGRAMS = YES - -# You can define message sequence charts within doxygen comments using the \msc -# command. Doxygen will then run the mscgen tool (see -# http://www.mcternan.me.uk/mscgen/) to produce the chart and insert it in the -# documentation. The MSCGEN_PATH tag allows you to specify the directory where -# the mscgen tool resides. If left empty the tool is assumed to be found in the -# default search path. - -MSCGEN_PATH = - -# If set to YES, the inheritance and collaboration graphs will hide -# inheritance and usage relations if the target is undocumented -# or is not a class. - -HIDE_UNDOC_RELATIONS = YES - -# If you set the HAVE_DOT tag to YES then doxygen will assume the dot tool is -# available from the path. This tool is part of Graphviz, a graph visualization -# toolkit from AT&T and Lucent Bell Labs. The other options in this section -# have no effect if this option is set to NO (the default) - -HAVE_DOT = YES - -# The DOT_NUM_THREADS specifies the number of dot invocations doxygen is -# allowed to run in parallel. When set to 0 (the default) doxygen will -# base this on the number of processors available in the system. You can set it -# explicitly to a value larger than 0 to get control over the balance -# between CPU load and processing speed. - -DOT_NUM_THREADS = 0 - -# By default doxygen will write a font called Helvetica to the output -# directory and reference it in all dot files that doxygen generates. -# When you want a differently looking font you can specify the font name -# using DOT_FONTNAME. You need to make sure dot is able to find the font, -# which can be done by putting it in a standard location or by setting the -# DOTFONTPATH environment variable or by setting DOT_FONTPATH to the directory -# containing the font. - -DOT_FONTNAME = Helvetica - -# The DOT_FONTSIZE tag can be used to set the size of the font of dot graphs. -# The default size is 10pt. - -DOT_FONTSIZE = 10 - -# By default doxygen will tell dot to use the output directory to look for the -# FreeSans.ttf font (which doxygen will put there itself). If you specify a -# different font using DOT_FONTNAME you can set the path where dot -# can find it using this tag. - -DOT_FONTPATH = - -# If the CLASS_GRAPH and HAVE_DOT tags are set to YES then doxygen -# will generate a graph for each documented class showing the direct and -# indirect inheritance relations. Setting this tag to YES will force the -# the CLASS_DIAGRAMS tag to NO. - -CLASS_GRAPH = YES - -# If the COLLABORATION_GRAPH and HAVE_DOT tags are set to YES then doxygen -# will generate a graph for each documented class showing the direct and -# indirect implementation dependencies (inheritance, containment, and -# class references variables) of the class with other documented classes. - -COLLABORATION_GRAPH = YES - -# If the GROUP_GRAPHS and HAVE_DOT tags are set to YES then doxygen -# will generate a graph for groups, showing the direct groups dependencies - -GROUP_GRAPHS = YES - -# If the UML_LOOK tag is set to YES doxygen will generate inheritance and -# collaboration diagrams in a style similar to the OMG's Unified Modeling -# Language. - -UML_LOOK = NO - -# If set to YES, the inheritance and collaboration graphs will show the -# relations between templates and their instances. - -TEMPLATE_RELATIONS = NO - -# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDE_GRAPH, and HAVE_DOT -# tags are set to YES then doxygen will generate a graph for each documented -# file showing the direct and indirect include dependencies of the file with -# other documented files. - -INCLUDE_GRAPH = YES - -# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDED_BY_GRAPH, and -# HAVE_DOT tags are set to YES then doxygen will generate a graph for each -# documented header file showing the documented files that directly or -# indirectly include this file. - -INCLUDED_BY_GRAPH = YES - -# If the CALL_GRAPH and HAVE_DOT options are set to YES then -# doxygen will generate a call dependency graph for every global function -# or class method. Note that enabling this option will significantly increase -# the time of a run. So in most cases it will be better to enable call graphs -# for selected functions only using the \callgraph command. - -CALL_GRAPH = NO - -# If the CALLER_GRAPH and HAVE_DOT tags are set to YES then -# doxygen will generate a caller dependency graph for every global function -# or class method. Note that enabling this option will significantly increase -# the time of a run. So in most cases it will be better to enable caller -# graphs for selected functions only using the \callergraph command. - -CALLER_GRAPH = NO - -# If the GRAPHICAL_HIERARCHY and HAVE_DOT tags are set to YES then doxygen -# will generate a graphical hierarchy of all classes instead of a textual one. - -GRAPHICAL_HIERARCHY = YES - -# If the DIRECTORY_GRAPH, SHOW_DIRECTORIES and HAVE_DOT tags are set to YES -# then doxygen will show the dependencies a directory has on other directories -# in a graphical way. The dependency relations are determined by the #include -# relations between the files in the directories. - -DIRECTORY_GRAPH = YES - -# The DOT_IMAGE_FORMAT tag can be used to set the image format of the images -# generated by dot. Possible values are svg, png, jpg, or gif. -# If left blank png will be used. - -DOT_IMAGE_FORMAT = png - -# The tag DOT_PATH can be used to specify the path where the dot tool can be -# found. If left blank, it is assumed the dot tool can be found in the path. - -DOT_PATH = - -# The DOTFILE_DIRS tag can be used to specify one or more directories that -# contain dot files that are included in the documentation (see the -# \dotfile command). - -DOTFILE_DIRS = - -# The MSCFILE_DIRS tag can be used to specify one or more directories that -# contain msc files that are included in the documentation (see the -# \mscfile command). - -MSCFILE_DIRS = - -# The DOT_GRAPH_MAX_NODES tag can be used to set the maximum number of -# nodes that will be shown in the graph. If the number of nodes in a graph -# becomes larger than this value, doxygen will truncate the graph, which is -# visualized by representing a node as a red box. Note that doxygen if the -# number of direct children of the root node in a graph is already larger than -# DOT_GRAPH_MAX_NODES then the graph will not be shown at all. Also note -# that the size of a graph can be further restricted by MAX_DOT_GRAPH_DEPTH. - -DOT_GRAPH_MAX_NODES = 50 - -# The MAX_DOT_GRAPH_DEPTH tag can be used to set the maximum depth of the -# graphs generated by dot. A depth value of 3 means that only nodes reachable -# from the root by following a path via at most 3 edges will be shown. Nodes -# that lay further from the root node will be omitted. Note that setting this -# option to 1 or 2 may greatly reduce the computation time needed for large -# code bases. Also note that the size of a graph can be further restricted by -# DOT_GRAPH_MAX_NODES. Using a depth of 0 means no depth restriction. - -MAX_DOT_GRAPH_DEPTH = 0 - -# Set the DOT_TRANSPARENT tag to YES to generate images with a transparent -# background. This is disabled by default, because dot on Windows does not -# seem to support this out of the box. Warning: Depending on the platform used, -# enabling this option may lead to badly anti-aliased labels on the edges of -# a graph (i.e. they become hard to read). - -DOT_TRANSPARENT = NO - -# Set the DOT_MULTI_TARGETS tag to YES allow dot to generate multiple output -# files in one run (i.e. multiple -o and -T options on the command line). This -# makes dot run faster, but since only newer versions of dot (>1.8.10) -# support this, this feature is disabled by default. - -DOT_MULTI_TARGETS = NO - -# If the GENERATE_LEGEND tag is set to YES (the default) Doxygen will -# generate a legend page explaining the meaning of the various boxes and -# arrows in the dot generated graphs. - -GENERATE_LEGEND = YES - -# If the DOT_CLEANUP tag is set to YES (the default) Doxygen will -# remove the intermediate dot files that are used to generate -# the various graphs. - -DOT_CLEANUP = YES diff --git a/hecl-gui/quazip/NEWS.txt b/hecl-gui/quazip/NEWS.txt index 99dfa9f94..26026ffd8 100644 --- a/hecl-gui/quazip/NEWS.txt +++ b/hecl-gui/quazip/NEWS.txt @@ -1,143 +1,186 @@ -QuaZIP changes - -* 2014-02-09 0.6.2 - * QuaZipNewInfo / QuaZipFileInfo64 now provide API to access/set - NTFS time stamps - useful even on non-NTFS systems if you - need more precise dates and times than default ones. - * QuaZipNewInfo may now be initialized from QuaZipFileInfo64. - * No more crashes when using QSaveFile as QIODevice for ZIP. - * The new QuaZip::setAutoClose() method allows to leave the - QIODevice open when you close the QuaZip instance. - * qztest now depends on quazip, no longer breaking the build. - -* 2014-01-26 0.6.1 - * Improved zip64 support. - * A LOT more tests thanks to g++ --coverage / lcov. - * JlCompress extraction methods now create files with default - permissions if they are zero in the original archive. - * Some QuaZipDir fixes (thanks to the new tests). - -* 2014-01-22 0.6 - * Minizip updated to 1.1 (with all the necessary modifications - re-done), and that means that... - * the long-awaited zip64 support is now available! - * A few rather minor fixes. - -* 2014-01-19 0.5.2 - * Some minor bug fixes. - * API to access file permissions subfield of the external - attributes. - * MS VS 2012 Express support. - * API to set the default codec used to encode/decode file names - (mainly for use by various wrappers such as JlCompress, when - you don't have direct access to the underlying QuaZip instance). - -* 2013-03-02 0.5.1 - * Lots of QuaZipDir fixes, thanks to all bug reporters. - * Full Qt Creator support. - * MS VS 2010 Express support. - * Qt5 support (didn't need any source code changes anyway). - * Lots of minor bug fixes. - -* 2012-09-07 0.5 - * Added run_moc.bat files for building under Windows in case Qt - integration is not available (e. g. VS 2008 Express). - * Added the QuaZipDir class to simplify ZIP navigation in terms - of directories. - * Added the QuaGzipFile class for working with GZIP archives. It - was added as a bonus since it has nothing to do with the main - purpose of the library. It probably won't get any major - improvements, although minor bug fixes are possible. - * Added the QuaZIODevice class for working with zlib - compression. It has nothing to do with the ZIP format, and - therefore the same notice as for the QuaGzipFile applies. - * The global comment is no longer erased when adding files to - an archive. - * Many bug fixes. - -* 2012-01-14 0.4.4 - * Fixed isSequential() test that was causing open() failures on - Unix. - * Fixed sub-directory compressing in JlCompress. - * Added MS VS 2008 solution, compatible with the binary Qt - distribution (tested on MS VS 2008 Express, had to run MOC - manually due to the lack of plugin in Express). - * Fixed extracting directories in JlCompress. - * Fixed JlCompress.h includes in the test suite, which used - lowercase names thus breaking on case-sensitive systems. - * Implemented missing QuaZipFile::getZip() that was only - declared. - * Fixed reopening closed files. - * Fixed possible memory leak in case of open error. - -* 2011-09-09 0.4.3 - * New test suite using QTestLib. - * Fixed bytesAvailable(), pos() and atEnd(). - * Added ZIP v1.0 support and disabling data descriptor for - compatibility with some older software. - * Fixed DLL export/import issues for some symbols. - * Added QUAZIP_STATIC macro for compiling as a static library or - directly including the source. - * Added getFileNameList() and getFileInfoList() convenience - functions. - * Added some buffering to JlCompress to improve performance. - -* 2011-08-10 0.4.2 - * Cmake patch (thanks to Bernhard Rosenkraenzer). - * Symbian patch (thanks to Hamish Willee). - * Documented the multiple files limitation of QuaZipFile. - * Fixed relative paths handling in JlCompress. - * Fixed linking to MinGW zlib. - -* 2011-05-26 0.4.1 - * License statement updated to avoid confusion. GPL license - removed for the very same reason. - * Parts of original package are now clearly marked as modified, - just as their license requires. - -* 2011-05-23 0.4 - * QuaZip and QuaZipFile classes now use the Pimpl idiom. This - means that future releases will probably be binary compatible - with this one, but it also means that this one is binary - incompatible with the old ones. - * IO API has been rewritten using QIODevice instead of standard - C library. Among other things it means that QuaZip now supports - files up to 4 GB in size instead of 2 GB. - * Added QuaZip methods allowing access to ZIP files represented - by any seekable QIODevice implementation (QBuffer is a good - example). - -* 2010-07-23 0.3 - * Fixed getComment() for global comments. - * Added some useful classes for calculating checksums (thanks to - Adam Walczak). - * Added some utility classes for working with whole directories - (thanks to Roberto Pompermaier). It would be nice if someone - documents these in English, though. - * Probably fixed some problems with passwords (thanks to Vasiliy - Sorokin). I didn't test it, though. - -* 2008-09-17 0.2.3 - * Fixed license notices in sources. - -* SVN - * Fixed a small bug in QuaZipFile::atEnd(). - -* 2007-01-16 0.2.2 - * Added LGPL as alternative license. - * Added FAQ documentation page. - -* 2006-03-21 0.2.1 - * Fixed setCommentCodec() bug. - * Fixed bug that set month 1-12 instead of 0-11, as specified in - zip.h. - * Added workaround for Qt's bug that caused wrong timestamps. - * Few documentation fixes and cosmetic changes. - -* 2005-07-08 0.2 - * Write support. - * Extended QuaZipFile API, including size(), *pos() functions. - * Support for comments encoding/decoding. - -* 2005-07-01 0.1 - * Initial version. +QuaZIP changes + +* 2019-05-27 0.8.1 + * CMake regression fix + +* 2019-05-23 0.8 + * Support for UTF-8 in file names and comments (Denis Zavorotnyy) + * get/setOsCode(), get/setDefaultOsCode() + * Fixed Z_STREAM_END handling in QuaZioDevice + +* 2018-06-13 0.7.6 + * Fixed the Zip Slip vulnerability in JlCompress + * Renamed crypt.h to minizip_crypt.h to avoid conflicts + +* 2018-05-20 0.7.5 + * Fixed target_link_libraries call in CMakeLists + * Worked around a Qt 4.6 bug (QTBUG-15421) screwing up hidden + files handling in JlCompress::compressDir() + * Removed Q_FOREACH uses to avoid conflicts (SF patch #32) + +* 2017-02-05 0.7.4 + * Static analysis patch from Intel Deutschland GmbH + * Replaced UNUSED with QUAZIP_UNUSED to avoid name clashes + * Minor bug fixes + +* 2017-02-05 0.7.3 + * Symlink handling + * Static linking exception for LGPL + * Minor bug fixes + +* 2016-03-29 0.7.2 + * New JlCompress methods (QIODevice*-based API by Lukasz Kwiecinski) + * Implemented QuaZioDevice::atEnd() and bytesAvailable()--these might + break ABI, but pretty unlikely. + +* 2015-01-07 0.7.1 + * Fixed licensing issues (bug #45). + * Added the convenience method QuaZipFileInfo::isEncrypted(). + +* 2014-07-24 0.7 + * It is now possible to write ZIP files to sequential devices + like sockets (only in mdCreate mode, so no self-extract, sorry). + * A few zip64 fixes. + * Several bug fixes and portability improvements. + +* 2014-02-09 0.6.2 + * QuaZipNewInfo / QuaZipFileInfo64 now provide API to access/set + NTFS time stamps - useful even on non-NTFS systems if you + need more precise dates and times than default ones. + * QuaZipNewInfo may now be initialized from QuaZipFileInfo64. + * No more crashes when using QSaveFile as QIODevice for ZIP. + * The new QuaZip::setAutoClose() method allows to leave the + QIODevice open when you close the QuaZip instance. + * qztest now depends on quazip, no longer breaking the build. + +* 2014-01-26 0.6.1 + * Improved zip64 support. + * A LOT more tests thanks to g++ --coverage / lcov. + * JlCompress extraction methods now create files with default + permissions if they are zero in the original archive. + * Some QuaZipDir fixes (thanks to the new tests). + +* 2014-01-22 0.6 + * Minizip updated to 1.1 (with all the necessary modifications + re-done), and that means that... + * the long-awaited zip64 support is now available! + * A few rather minor fixes. + +* 2014-01-19 0.5.2 + * Some minor bug fixes. + * API to access file permissions subfield of the external + attributes. + * MS VS 2012 Express support. + * API to set the default codec used to encode/decode file names + (mainly for use by various wrappers such as JlCompress, when + you don't have direct access to the underlying QuaZip instance). + +* 2013-03-02 0.5.1 + * Lots of QuaZipDir fixes, thanks to all bug reporters. + * Full Qt Creator support. + * MS VS 2010 Express support. + * Qt5 support (didn't need any source code changes anyway). + * Lots of minor bug fixes. + +* 2012-09-07 0.5 + * Added run_moc.bat files for building under Windows in case Qt + integration is not available (e. g. VS 2008 Express). + * Added the QuaZipDir class to simplify ZIP navigation in terms + of directories. + * Added the QuaGzipFile class for working with GZIP archives. It + was added as a bonus since it has nothing to do with the main + purpose of the library. It probably won't get any major + improvements, although minor bug fixes are possible. + * Added the QuaZIODevice class for working with zlib + compression. It has nothing to do with the ZIP format, and + therefore the same notice as for the QuaGzipFile applies. + * The global comment is no longer erased when adding files to + an archive. + * Many bug fixes. + +* 2012-01-14 0.4.4 + * Fixed isSequential() test that was causing open() failures on + Unix. + * Fixed sub-directory compressing in JlCompress. + * Added MS VS 2008 solution, compatible with the binary Qt + distribution (tested on MS VS 2008 Express, had to run MOC + manually due to the lack of plugin in Express). + * Fixed extracting directories in JlCompress. + * Fixed JlCompress.h includes in the test suite, which used + lowercase names thus breaking on case-sensitive systems. + * Implemented missing QuaZipFile::getZip() that was only + declared. + * Fixed reopening closed files. + * Fixed possible memory leak in case of open error. + +* 2011-09-09 0.4.3 + * New test suite using QTestLib. + * Fixed bytesAvailable(), pos() and atEnd(). + * Added ZIP v1.0 support and disabling data descriptor for + compatibility with some older software. + * Fixed DLL export/import issues for some symbols. + * Added QUAZIP_STATIC macro for compiling as a static library or + directly including the source. + * Added getFileNameList() and getFileInfoList() convenience + functions. + * Added some buffering to JlCompress to improve performance. + +* 2011-08-10 0.4.2 + * Cmake patch (thanks to Bernhard Rosenkraenzer). + * Symbian patch (thanks to Hamish Willee). + * Documented the multiple files limitation of QuaZipFile. + * Fixed relative paths handling in JlCompress. + * Fixed linking to MinGW zlib. + +* 2011-05-26 0.4.1 + * License statement updated to avoid confusion. GPL license + removed for the very same reason. + * Parts of original package are now clearly marked as modified, + just as their license requires. + +* 2011-05-23 0.4 + * QuaZip and QuaZipFile classes now use the Pimpl idiom. This + means that future releases will probably be binary compatible + with this one, but it also means that this one is binary + incompatible with the old ones. + * IO API has been rewritten using QIODevice instead of standard + C library. Among other things it means that QuaZip now supports + files up to 4 GB in size instead of 2 GB. + * Added QuaZip methods allowing access to ZIP files represented + by any seekable QIODevice implementation (QBuffer is a good + example). + +* 2010-07-23 0.3 + * Fixed getComment() for global comments. + * Added some useful classes for calculating checksums (thanks to + Adam Walczak). + * Added some utility classes for working with whole directories + (thanks to Roberto Pompermaier). It would be nice if someone + documents these in English, though. + * Probably fixed some problems with passwords (thanks to Vasiliy + Sorokin). I didn't test it, though. + +* 2008-09-17 0.2.3 + * Fixed license notices in sources. + +* SVN + * Fixed a small bug in QuaZipFile::atEnd(). + +* 2007-01-16 0.2.2 + * Added LGPL as alternative license. + * Added FAQ documentation page. + +* 2006-03-21 0.2.1 + * Fixed setCommentCodec() bug. + * Fixed bug that set month 1-12 instead of 0-11, as specified in + zip.h. + * Added workaround for Qt's bug that caused wrong timestamps. + * Few documentation fixes and cosmetic changes. + +* 2005-07-08 0.2 + * Write support. + * Extended QuaZipFile API, including size(), *pos() functions. + * Support for comments encoding/decoding. + +* 2005-07-01 0.1 + * Initial version. diff --git a/hecl-gui/quazip/README.md b/hecl-gui/quazip/README.md new file mode 100644 index 000000000..6761aed9a --- /dev/null +++ b/hecl-gui/quazip/README.md @@ -0,0 +1,20 @@ +QuaZIP is the C++ wrapper for Gilles Vollant's ZIP/UNZIP package +(AKA Minizip) using Trolltech's Qt library. + +If you need to write files to a ZIP archive or read files from one +using QIODevice API, QuaZIP is exactly the kind of tool you need. + +See [the documentation](https://stachenov.github.io/quazip/) for details. + +Want to report a bug or ask for a feature? Open an [issue](https://github.com/stachenov/quazip/issues). + +Want to fix a bug or implement a new feature? See [CONTRIBUTING.md](CONTRIBUTING.md). + +Copyright notice: + +Copyright (C) 2005-2018 Sergey A. Tachenov + +Distributed under LGPL, full details in the COPYING file. + +Original ZIP package is copyrighted by Gilles Vollant, see +quazip/(un)zip.h files for details, but basically it's the zlib license. diff --git a/hecl-gui/quazip/README.mdown b/hecl-gui/quazip/README.mdown deleted file mode 100644 index 30befd6cb..000000000 --- a/hecl-gui/quazip/README.mdown +++ /dev/null @@ -1,52 +0,0 @@ -

NOT MAINTAINED!! Use https://github.com/stachenov/quazip by the original author instead.

- -

QuaZIP is the C++ wrapper for Gilles Vollant's ZIP/UNZIP package -(AKA minizip) using the Qt framework.

- -

Dependencies:

-
    -
  1. zlib
  2. -
  3. Qt 5
  4. -
- -

Building:

- -Building QuaZIP is super simple. Just open the terminal on your Mac/Linux -or Command Prompt on Windows and type the following: -``` -$ mkdir build && cd build -$ cmake .. -DCMAKE_BUILD_TYPE=(Debug|Release) -DCMAKE_INSTALL_PREFIX=/path/to/install/QuaZIP -``` -
Notes for building on Windows:
-We recommend you not to install QuaZIP in "Program Files" on Windows. We also recommend to use -the NMake Makefiles generator if you are compiling with Visual Studio. - -

Documentation:

- -

See doc/html or, if you do not have a browser, quazip/*.h and -quazip/doc/* files for the more detailed documentation.

- -

Copyright notice:

- -``` -Copyright (C) 2005-2012 Sergey A. Tachenov - -This program is free software; you can redistribute it and/or modify it -under the terms of the GNU Lesser General Public License as published by -the Free Software Foundation; either version 2 of the License, or (at -your option) any later version. - -This program is distributed in the hope that it will be useful, but -WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser -General Public License for more details. - -You should have received a copy of the GNU Lesser General Public License -along with this program; if not, write to the Free Software Foundation, -Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - -See COPYING file for the full LGPL text. - -Original ZIP package is copyrighted by Gilles Vollant, see -quazip/(un)zip.h files for details, basically it's zlib license. -``` diff --git a/hecl-gui/quazip/doc/html/JlCompress_8h_source.html b/hecl-gui/quazip/doc/html/JlCompress_8h_source.html deleted file mode 100644 index 685bfd1e4..000000000 --- a/hecl-gui/quazip/doc/html/JlCompress_8h_source.html +++ /dev/null @@ -1,122 +0,0 @@ - - - - -QuaZIP: quazip/JlCompress.h Source File - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - -
-
-
-
JlCompress.h
-
-
-
00001 #ifndef JLCOMPRESSFOLDER_H_
-00002 #define JLCOMPRESSFOLDER_H_
-00003 
-00004 /*
-00005 Copyright (C) 2010 Roberto Pompermaier
-00006 Copyright (C) 2005-2014 Sergey A. Tachenov
-00007 
-00008 This file is part of QuaZIP.
-00009 
-00010 QuaZIP is free software: you can redistribute it and/or modify
-00011 it under the terms of the GNU Lesser General Public License as published by
-00012 the Free Software Foundation, either version 3 of the License, or
-00013 (at your option) any later version.
-00014 
-00015 QuaZIP is distributed in the hope that it will be useful,
-00016 but WITHOUT ANY WARRANTY; without even the implied warranty of
-00017 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-00018 GNU Lesser General Public License for more details.
-00019 
-00020 You should have received a copy of the GNU Lesser General Public License
-00021 along with QuaZIP.  If not, see <http://www.gnu.org/licenses/>.
-00022 
-00023 See COPYING file for the full LGPL text.
-00024 
-00025 Original ZIP package is copyrighted by Gilles Vollant and contributors,
-00026 see quazip/(un)zip.h files for details. Basically it's the zlib license.
-00027 */
-00028 
-00029 #include "quazip.h"
-00030 #include "quazipfile.h"
-00031 #include "quazipfileinfo.h"
-00032 #include <QString>
-00033 #include <QDir>
-00034 #include <QFileInfo>
-00035 #include <QFile>
-00036 
-00038 
-00042 class QUAZIP_EXPORT JlCompress {
-00043 private:
-00045 
-00051     static bool compressFile(QuaZip* zip, QString fileName, QString fileDest);
-00053 
-00062     static bool compressSubDir(QuaZip* parentZip, QString dir, QString parentDir, bool recursive = true);
-00064 
-00070     static bool extractFile(QuaZip* zip, QString fileName, QString fileDest);
-00072 
-00076     static bool removeFile(QStringList listFile);
-00077 
-00078 public:
-00080 
-00085     static bool compressFile(QString fileCompressed, QString file);
-00087 
-00092     static bool compressFiles(QString fileCompressed, QStringList files);
-00094 
-00101     static bool compressDir(QString fileCompressed, QString dir = QString(), bool recursive = true);
-00102 
-00103 public:
-00105 
-00112     static QString extractFile(QString fileCompressed, QString fileName, QString fileDest = QString());
-00114 
-00121     static QStringList extractFiles(QString fileCompressed, QStringList files, QString dir = QString());
-00123 
-00129     static QStringList extractDir(QString fileCompressed, QString dir = QString());
-00131 
-00136     static QStringList getFileList(QString fileCompressed);
-00137 };
-00138 
-00139 #endif /* JLCOMPRESSFOLDER_H_ */
-
- - - - diff --git a/hecl-gui/quazip/doc/html/annotated.html b/hecl-gui/quazip/doc/html/annotated.html deleted file mode 100644 index c8185e02f..000000000 --- a/hecl-gui/quazip/doc/html/annotated.html +++ /dev/null @@ -1,66 +0,0 @@ - - - - -QuaZIP: Class List - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
-
-
Class List
-
-
-
Here are the classes, structs, unions and interfaces with brief descriptions:
- - - - - - - - - - - - - - -
JlCompressUtility class for typical operations
QuaAdler32Adler32 checksum
QuaChecksum32Checksum interface
QuaCrc32CRC32 checksum
QuaGzipFileGZIP file
QuaZIODeviceA class to compress/decompress QIODevice
QuaZipZIP archive
QuaZipDirProvides ZIP archive navigation
QuaZipFileA file inside ZIP archive
QuaZipFileInfoInformation about a file inside archive
QuaZipFileInfo64Information about a file inside archive (with zip64 support)
QuaZipFilePrivateThe implementation class for QuaZip
QuaZipNewInfoInformation about a file to be created
QuaZipPrivateAll the internal stuff for the QuaZip class
-
- - - diff --git a/hecl-gui/quazip/doc/html/bc_s.png b/hecl-gui/quazip/doc/html/bc_s.png deleted file mode 100644 index 51ba0066d..000000000 Binary files a/hecl-gui/quazip/doc/html/bc_s.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/classJlCompress-members.html b/hecl-gui/quazip/doc/html/classJlCompress-members.html deleted file mode 100644 index c64ac70ca..000000000 --- a/hecl-gui/quazip/doc/html/classJlCompress-members.html +++ /dev/null @@ -1,58 +0,0 @@ - - - - -QuaZIP: Member List - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
-
-
JlCompress Member List
-
-
-This is the complete list of members for JlCompress, including all inherited members. - - - - - - - -
compressDir(QString fileCompressed, QString dir=QString(), bool recursive=true)JlCompress [static]
compressFile(QString fileCompressed, QString file)JlCompress [static]
compressFiles(QString fileCompressed, QStringList files)JlCompress [static]
extractDir(QString fileCompressed, QString dir=QString())JlCompress [static]
extractFile(QString fileCompressed, QString fileName, QString fileDest=QString())JlCompress [static]
extractFiles(QString fileCompressed, QStringList files, QString dir=QString())JlCompress [static]
getFileList(QString fileCompressed)JlCompress [static]
- - - diff --git a/hecl-gui/quazip/doc/html/classJlCompress.html b/hecl-gui/quazip/doc/html/classJlCompress.html deleted file mode 100644 index 20d13e662..000000000 --- a/hecl-gui/quazip/doc/html/classJlCompress.html +++ /dev/null @@ -1,376 +0,0 @@ - - - - -QuaZIP: JlCompress Class Reference - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
- -
-
JlCompress Class Reference
-
-
- -

Utility class for typical operations. - More...

- -

#include <JlCompress.h>

- -

List of all members.

- - - - - - - - - - - - - - - - -

-Static Public Member Functions

static bool compressFile (QString fileCompressed, QString file)
 Compress a single file.
static bool compressFiles (QString fileCompressed, QStringList files)
 Compress a list of files.
static bool compressDir (QString fileCompressed, QString dir=QString(), bool recursive=true)
 Compress a whole directory.
static QString extractFile (QString fileCompressed, QString fileName, QString fileDest=QString())
 Extract a single file.
static QStringList extractFiles (QString fileCompressed, QStringList files, QString dir=QString())
 Extract a list of files.
static QStringList extractDir (QString fileCompressed, QString dir=QString())
 Extract a whole archive.
static QStringList getFileList (QString fileCompressed)
 Get the file list.
-

Detailed Description

-

Utility class for typical operations.

-

This class contains a number of useful static functions to perform simple operations, such as mass ZIP packing or extraction.

-

Member Function Documentation

- -
-
- - - - - - - - - - - - - - - - - - -
bool JlCompress::compressFile (QString fileCompressed,
QString file 
) [static]
-
-
- -

Compress a single file.

-
Parameters:
- - - -
fileCompressedThe name of the archive.
fileThe file to compress.
-
-
-
Returns:
true if success, false otherwise.
-

OK Comprime il file fileName nel file fileCompressed. Se la funzione fallisce restituisce false e cancella il file che si e tentato di creare.

-

La funzione fallisce se: * non si riesce ad aprire l'oggetto zip; * la compressione del file fallisce; * non si riesce a chiudere l'oggetto zip;

- -

References QuaZip::close(), QuaZip::getZipError(), QuaZip::mdCreate, and QuaZip::open().

- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
bool JlCompress::compressFiles (QString fileCompressed,
QStringList files 
) [static]
-
-
- -

Compress a list of files.

-
Parameters:
- - - -
fileCompressedThe name of the archive.
filesThe file list to compress.
-
-
-
Returns:
true if success, false otherwise.
-

OK Comprime i file specificati in files nel file fileCompressed. Se la funzione fallisce restituisce false e cancella il file che si e tentato di creare.

-

La funzione fallisce se: * non si riesce ad aprire l'oggetto zip; * la compressione di un file fallisce; * non si riesce a chiudere l'oggetto zip;

- -

References QuaZip::close(), QuaZip::getZipError(), QuaZip::mdCreate, and QuaZip::open().

- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
bool JlCompress::compressDir (QString fileCompressed,
QString dir = QString(),
bool recursive = true 
) [static]
-
-
- -

Compress a whole directory.

-
Parameters:
- - - - -
fileCompressedThe name of the archive.
dirThe directory to compress.
recursiveWhether to pack the subdirectories as well, or just regular files.
-
-
-
Returns:
true if success, false otherwise.
-

OK Comprime la cartella dir nel file fileCompressed, se recursive e true allora comprime anche le sotto cartelle. Se la funzione fallisce restituisce false e cancella il file che si e tentato di creare.

-

La funzione fallisce se: * non si riesce ad aprire l'oggetto zip; * la compressione di un file fallisce; * non si riesce a chiudere l'oggetto zip;

- -

References QuaZip::close(), QuaZip::getZipError(), QuaZip::mdCreate, and QuaZip::open().

- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
QString JlCompress::extractFile (QString fileCompressed,
QString fileName,
QString fileDest = QString() 
) [static]
-
-
- -

Extract a single file.

-
Parameters:
- - - - -
fileCompressedThe name of the archive.
fileNameThe file to extract.
fileDestThe destination file, assumed to be identical to file if left empty.
-
-
-
Returns:
The list of the full paths of the files extracted, empty on failure.
-

OK Estrae il file fileName, contenuto nel file fileCompressed, con il nome fileDest. Se fileDest = "" allora il file viene estratto con lo stesso nome con cui e stato compresso. Se la funzione fallisce cancella il file che si e tentato di estrarre. Restituisce il nome assoluto del file estratto.

-

La funzione fallisce se: * non si riesce ad aprire l'oggetto zip; * l'estrazione del file fallisce; * non si riesce a chiudere l'oggetto zip;

- -

References QuaZip::close(), QuaZip::getZipError(), QuaZip::mdUnzip, and QuaZip::open().

- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
QStringList JlCompress::extractFiles (QString fileCompressed,
QStringList files,
QString dir = QString() 
) [static]
-
-
- -

Extract a list of files.

-
Parameters:
- - - - -
fileCompressedThe name of the archive.
filesThe file list to extract.
dirThe directory to put the files to, the current directory if left empty.
-
-
-
Returns:
The list of the full paths of the files extracted, empty on failure.
-

OK Estrae i file specificati in files, contenuti nel file fileCompressed, nella cartella dir. La struttura a cartelle del file compresso viene rispettata. Se dir = "" allora il file viene estratto nella cartella corrente. Se la funzione fallisce cancella i file che si e tentato di estrarre. Restituisce i nomi assoluti dei file estratti.

-

La funzione fallisce se: * non si riesce ad aprire l'oggetto zip; * l'estrazione di un file fallisce; * non si riesce a chiudere l'oggetto zip;

- -

References QuaZip::close(), QuaZip::getZipError(), QuaZip::mdUnzip, and QuaZip::open().

- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
QStringList JlCompress::extractDir (QString fileCompressed,
QString dir = QString() 
) [static]
-
-
- -

Extract a whole archive.

-
Parameters:
- - - -
fileCompressedThe name of the archive.
dirThe directory to extract to, the current directory if left empty.
-
-
-
Returns:
The list of the full paths of the files extracted, empty on failure.
-

OK Estrae il file fileCompressed nella cartella dir. Se dir = "" allora il file viene estratto nella cartella corrente. Se la funzione fallisce cancella i file che si e tentato di estrarre. Restituisce i nomi assoluti dei file estratti.

-

La funzione fallisce se: * non si riesce ad aprire l'oggetto zip; * la compressione di un file fallisce; * non si riesce a chiudere l'oggetto zip;

- -

References QuaZip::close(), QuaZip::getCurrentFileName(), QuaZip::getZipError(), QuaZip::goToFirstFile(), QuaZip::goToNextFile(), QuaZip::mdUnzip, and QuaZip::open().

- -
-
- -
-
- - - - - - - - -
QStringList JlCompress::getFileList (QString fileCompressed) [static]
-
-
- -

Get the file list.

-
Returns:
The list of the files in the archive, or, more precisely, the list of the entries, including both files and directories if they are present separately.
-

OK Restituisce la lista dei file resenti nel file compresso fileCompressed. Se la funzione fallisce, restituisce un elenco vuoto.

-

La funzione fallisce se: * non si riesce ad aprire l'oggetto zip; * la richiesta di informazioni di un file fallisce; * non si riesce a chiudere l'oggetto zip;

- -

References QuaZip::close(), QuaZip::getCurrentFileInfo(), QuaZip::getZipError(), QuaZip::goToFirstFile(), QuaZip::goToNextFile(), QuaZip::mdUnzip, QuaZipFileInfo64::name, and QuaZip::open().

- -
-
-
The documentation for this class was generated from the following files: -
- - - diff --git a/hecl-gui/quazip/doc/html/classQuaAdler32-members.html b/hecl-gui/quazip/doc/html/classQuaAdler32-members.html deleted file mode 100644 index d5f1749a0..000000000 --- a/hecl-gui/quazip/doc/html/classQuaAdler32-members.html +++ /dev/null @@ -1,56 +0,0 @@ - - - - -QuaZIP: Member List - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
-
-
QuaAdler32 Member List
-
-
-This is the complete list of members for QuaAdler32, including all inherited members. - - - - - -
calculate(const QByteArray &data)QuaAdler32 [virtual]
QuaAdler32() (defined in QuaAdler32)QuaAdler32
reset()QuaAdler32 [virtual]
update(const QByteArray &buf)QuaAdler32 [virtual]
value()QuaAdler32 [virtual]
- - - diff --git a/hecl-gui/quazip/doc/html/classQuaAdler32.html b/hecl-gui/quazip/doc/html/classQuaAdler32.html deleted file mode 100644 index c6e1e7890..000000000 --- a/hecl-gui/quazip/doc/html/classQuaAdler32.html +++ /dev/null @@ -1,161 +0,0 @@ - - - - -QuaZIP: QuaAdler32 Class Reference - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
- -
-
QuaAdler32 Class Reference
-
-
- -

Adler32 checksum. - More...

- -

#include <quazip/quaadler32.h>

-
-Inheritance diagram for QuaAdler32:
-
-
Inheritance graph
- - -
[legend]
-
-Collaboration diagram for QuaAdler32:
-
-
Collaboration graph
- - -
[legend]
- -

List of all members.

- - - - - - - - - - -

-Public Member Functions

quint32 calculate (const QByteArray &data)
 Calculates the checksum for data.
-void reset ()
 Resets the calculation on a checksun for a stream.
void update (const QByteArray &buf)
 Updates the calculated checksum for the stream.
quint32 value ()
 Value of the checksum calculated for the stream passed throw update().
-

Detailed Description

-

Adler32 checksum.

-

This class wrappers the adler32 function with the QuaChecksum32 interface. See QuaChecksum32 for more info.

-

Member Function Documentation

- -
-
- - - - - - - - -
quint32 QuaAdler32::calculate (const QByteArray & data) [virtual]
-
-
- -

Calculates the checksum for data.

-

data source data

-
Returns:
data checksum
-

This function has no efect on the value returned by value().

- -

Implements QuaChecksum32.

- -
-
- -
-
- - - - - - - - -
void QuaAdler32::update (const QByteArray & buf) [virtual]
-
-
- -

Updates the calculated checksum for the stream.

-

buf next portion of data from the stream

- -

Implements QuaChecksum32.

- -
-
- -
-
- - - - - - - -
quint32 QuaAdler32::value () [virtual]
-
-
- -

Value of the checksum calculated for the stream passed throw update().

-
Returns:
checksum
- -

Implements QuaChecksum32.

- -
-
-
The documentation for this class was generated from the following files: -
- - - diff --git a/hecl-gui/quazip/doc/html/classQuaAdler32__coll__graph.map b/hecl-gui/quazip/doc/html/classQuaAdler32__coll__graph.map deleted file mode 100644 index 6aef7a7d7..000000000 --- a/hecl-gui/quazip/doc/html/classQuaAdler32__coll__graph.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/hecl-gui/quazip/doc/html/classQuaAdler32__coll__graph.md5 b/hecl-gui/quazip/doc/html/classQuaAdler32__coll__graph.md5 deleted file mode 100644 index 3e34b51d9..000000000 --- a/hecl-gui/quazip/doc/html/classQuaAdler32__coll__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -f6aef7d7bad2a6a2c0f29520e9cdb67f \ No newline at end of file diff --git a/hecl-gui/quazip/doc/html/classQuaAdler32__coll__graph.png b/hecl-gui/quazip/doc/html/classQuaAdler32__coll__graph.png deleted file mode 100644 index 70f8b85ec..000000000 Binary files a/hecl-gui/quazip/doc/html/classQuaAdler32__coll__graph.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/classQuaAdler32__inherit__graph.map b/hecl-gui/quazip/doc/html/classQuaAdler32__inherit__graph.map deleted file mode 100644 index 6aef7a7d7..000000000 --- a/hecl-gui/quazip/doc/html/classQuaAdler32__inherit__graph.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/hecl-gui/quazip/doc/html/classQuaAdler32__inherit__graph.md5 b/hecl-gui/quazip/doc/html/classQuaAdler32__inherit__graph.md5 deleted file mode 100644 index 3e34b51d9..000000000 --- a/hecl-gui/quazip/doc/html/classQuaAdler32__inherit__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -f6aef7d7bad2a6a2c0f29520e9cdb67f \ No newline at end of file diff --git a/hecl-gui/quazip/doc/html/classQuaAdler32__inherit__graph.png b/hecl-gui/quazip/doc/html/classQuaAdler32__inherit__graph.png deleted file mode 100644 index 70f8b85ec..000000000 Binary files a/hecl-gui/quazip/doc/html/classQuaAdler32__inherit__graph.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/classQuaChecksum32-members.html b/hecl-gui/quazip/doc/html/classQuaChecksum32-members.html deleted file mode 100644 index 3795b779c..000000000 --- a/hecl-gui/quazip/doc/html/classQuaChecksum32-members.html +++ /dev/null @@ -1,55 +0,0 @@ - - - - -QuaZIP: Member List - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
-
-
QuaChecksum32 Member List
-
-
-This is the complete list of members for QuaChecksum32, including all inherited members. - - - - -
calculate(const QByteArray &data)=0QuaChecksum32 [pure virtual]
reset()=0QuaChecksum32 [pure virtual]
update(const QByteArray &buf)=0QuaChecksum32 [pure virtual]
value()=0QuaChecksum32 [pure virtual]
- - - diff --git a/hecl-gui/quazip/doc/html/classQuaChecksum32.html b/hecl-gui/quazip/doc/html/classQuaChecksum32.html deleted file mode 100644 index 132dffe22..000000000 --- a/hecl-gui/quazip/doc/html/classQuaChecksum32.html +++ /dev/null @@ -1,164 +0,0 @@ - - - - -QuaZIP: QuaChecksum32 Class Reference - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
- -
-
QuaChecksum32 Class Reference
-
-
- -

Checksum interface. - More...

- -

#include <quazip/quachecksum32.h>

-
-Inheritance diagram for QuaChecksum32:
-
-
Inheritance graph
- - -
[legend]
- -

List of all members.

- - - - - - - - - - -

-Public Member Functions

virtual quint32 calculate (const QByteArray &data)=0
 Calculates the checksum for data.
-virtual void reset ()=0
 Resets the calculation on a checksun for a stream.
virtual void update (const QByteArray &buf)=0
 Updates the calculated checksum for the stream.
virtual quint32 value ()=0
 Value of the checksum calculated for the stream passed throw update().
-

Detailed Description

-

Checksum interface.

-

This is an interface for 32 bit checksums. Classes implementing this interface can calcunate a certin checksum in a single step:

-
 QChecksum32 *crc32 = new QuaCrc32(); 
- rasoult = crc32->calculate(data);
-

or by streaming the data:

-
 QChecksum32 *crc32 = new QuaCrc32(); 
- while(!fileA.atEnd())
-     crc32->update(fileA.read(bufSize));
- resoultA = crc32->value();
- crc32->reset();
- while(!fileB.atEnd())
-     crc32->update(fileB.read(bufSize));
- resoultB = crc32->value();
-

Member Function Documentation

- -
-
- - - - - - - - -
virtual quint32 QuaChecksum32::calculate (const QByteArray & data) [pure virtual]
-
-
- -

Calculates the checksum for data.

-

data source data

-
Returns:
data checksum
-

This function has no efect on the value returned by value().

- -

Implemented in QuaAdler32, and QuaCrc32.

- -
-
- -
-
- - - - - - - - -
virtual void QuaChecksum32::update (const QByteArray & buf) [pure virtual]
-
-
- -

Updates the calculated checksum for the stream.

-

buf next portion of data from the stream

- -

Implemented in QuaAdler32, and QuaCrc32.

- -
-
- -
-
- - - - - - - -
virtual quint32 QuaChecksum32::value () [pure virtual]
-
-
- -

Value of the checksum calculated for the stream passed throw update().

-
Returns:
checksum
- -

Implemented in QuaAdler32, and QuaCrc32.

- -
-
-
The documentation for this class was generated from the following file: -
- - - diff --git a/hecl-gui/quazip/doc/html/classQuaChecksum32__inherit__graph.map b/hecl-gui/quazip/doc/html/classQuaChecksum32__inherit__graph.map deleted file mode 100644 index b2387233c..000000000 --- a/hecl-gui/quazip/doc/html/classQuaChecksum32__inherit__graph.map +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/hecl-gui/quazip/doc/html/classQuaChecksum32__inherit__graph.md5 b/hecl-gui/quazip/doc/html/classQuaChecksum32__inherit__graph.md5 deleted file mode 100644 index 6dde40897..000000000 --- a/hecl-gui/quazip/doc/html/classQuaChecksum32__inherit__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -84ec9abb25cc3d010952b190062cd40b \ No newline at end of file diff --git a/hecl-gui/quazip/doc/html/classQuaChecksum32__inherit__graph.png b/hecl-gui/quazip/doc/html/classQuaChecksum32__inherit__graph.png deleted file mode 100644 index 4fc18c12f..000000000 Binary files a/hecl-gui/quazip/doc/html/classQuaChecksum32__inherit__graph.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/classQuaCrc32-members.html b/hecl-gui/quazip/doc/html/classQuaCrc32-members.html deleted file mode 100644 index 51ec6999c..000000000 --- a/hecl-gui/quazip/doc/html/classQuaCrc32-members.html +++ /dev/null @@ -1,56 +0,0 @@ - - - - -QuaZIP: Member List - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
-
-
QuaCrc32 Member List
-
-
-This is the complete list of members for QuaCrc32, including all inherited members. - - - - - -
calculate(const QByteArray &data)QuaCrc32 [virtual]
QuaCrc32() (defined in QuaCrc32)QuaCrc32
reset()QuaCrc32 [virtual]
update(const QByteArray &buf)QuaCrc32 [virtual]
value()QuaCrc32 [virtual]
- - - diff --git a/hecl-gui/quazip/doc/html/classQuaCrc32.html b/hecl-gui/quazip/doc/html/classQuaCrc32.html deleted file mode 100644 index ebbee0f63..000000000 --- a/hecl-gui/quazip/doc/html/classQuaCrc32.html +++ /dev/null @@ -1,161 +0,0 @@ - - - - -QuaZIP: QuaCrc32 Class Reference - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
- -
-
QuaCrc32 Class Reference
-
-
- -

CRC32 checksum. - More...

- -

#include <quazip/quacrc32.h>

-
-Inheritance diagram for QuaCrc32:
-
-
Inheritance graph
- - -
[legend]
-
-Collaboration diagram for QuaCrc32:
-
-
Collaboration graph
- - -
[legend]
- -

List of all members.

- - - - - - - - - - -

-Public Member Functions

quint32 calculate (const QByteArray &data)
 Calculates the checksum for data.
-void reset ()
 Resets the calculation on a checksun for a stream.
void update (const QByteArray &buf)
 Updates the calculated checksum for the stream.
quint32 value ()
 Value of the checksum calculated for the stream passed throw update().
-

Detailed Description

-

CRC32 checksum.

-

This class wrappers the crc32 function with the QuaChecksum32 interface. See QuaChecksum32 for more info.

-

Member Function Documentation

- -
-
- - - - - - - - -
quint32 QuaCrc32::calculate (const QByteArray & data) [virtual]
-
-
- -

Calculates the checksum for data.

-

data source data

-
Returns:
data checksum
-

This function has no efect on the value returned by value().

- -

Implements QuaChecksum32.

- -
-
- -
-
- - - - - - - - -
void QuaCrc32::update (const QByteArray & buf) [virtual]
-
-
- -

Updates the calculated checksum for the stream.

-

buf next portion of data from the stream

- -

Implements QuaChecksum32.

- -
-
- -
-
- - - - - - - -
quint32 QuaCrc32::value () [virtual]
-
-
- -

Value of the checksum calculated for the stream passed throw update().

-
Returns:
checksum
- -

Implements QuaChecksum32.

- -
-
-
The documentation for this class was generated from the following files: -
- - - diff --git a/hecl-gui/quazip/doc/html/classQuaCrc32__coll__graph.map b/hecl-gui/quazip/doc/html/classQuaCrc32__coll__graph.map deleted file mode 100644 index 6aef7a7d7..000000000 --- a/hecl-gui/quazip/doc/html/classQuaCrc32__coll__graph.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/hecl-gui/quazip/doc/html/classQuaCrc32__coll__graph.md5 b/hecl-gui/quazip/doc/html/classQuaCrc32__coll__graph.md5 deleted file mode 100644 index eefdbcd2b..000000000 --- a/hecl-gui/quazip/doc/html/classQuaCrc32__coll__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -c5893d01f9e8b7b19610a8cce32f67e4 \ No newline at end of file diff --git a/hecl-gui/quazip/doc/html/classQuaCrc32__coll__graph.png b/hecl-gui/quazip/doc/html/classQuaCrc32__coll__graph.png deleted file mode 100644 index 7e01eeb0e..000000000 Binary files a/hecl-gui/quazip/doc/html/classQuaCrc32__coll__graph.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/classQuaCrc32__inherit__graph.map b/hecl-gui/quazip/doc/html/classQuaCrc32__inherit__graph.map deleted file mode 100644 index 6aef7a7d7..000000000 --- a/hecl-gui/quazip/doc/html/classQuaCrc32__inherit__graph.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/hecl-gui/quazip/doc/html/classQuaCrc32__inherit__graph.md5 b/hecl-gui/quazip/doc/html/classQuaCrc32__inherit__graph.md5 deleted file mode 100644 index eefdbcd2b..000000000 --- a/hecl-gui/quazip/doc/html/classQuaCrc32__inherit__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -c5893d01f9e8b7b19610a8cce32f67e4 \ No newline at end of file diff --git a/hecl-gui/quazip/doc/html/classQuaCrc32__inherit__graph.png b/hecl-gui/quazip/doc/html/classQuaCrc32__inherit__graph.png deleted file mode 100644 index 7e01eeb0e..000000000 Binary files a/hecl-gui/quazip/doc/html/classQuaCrc32__inherit__graph.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/classQuaGzipFile-members.html b/hecl-gui/quazip/doc/html/classQuaGzipFile-members.html deleted file mode 100644 index 25355755a..000000000 --- a/hecl-gui/quazip/doc/html/classQuaGzipFile-members.html +++ /dev/null @@ -1,64 +0,0 @@ - - - - -QuaZIP: Member List - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
-
-
QuaGzipFile Member List
-
-
-This is the complete list of members for QuaGzipFile, including all inherited members. - - - - - - - - - - - - - -
close()QuaGzipFile [virtual]
flush()QuaGzipFile [virtual]
getFileName() const QuaGzipFile
isSequential() const QuaGzipFile [virtual]
open(QIODevice::OpenMode mode)QuaGzipFile [virtual]
open(int fd, QIODevice::OpenMode mode)QuaGzipFile [virtual]
QuaGzipFile()QuaGzipFile
QuaGzipFile(QObject *parent)QuaGzipFile
QuaGzipFile(const QString &fileName, QObject *parent=NULL)QuaGzipFile
readData(char *data, qint64 maxSize)QuaGzipFile [protected, virtual]
setFileName(const QString &fileName)QuaGzipFile
writeData(const char *data, qint64 maxSize)QuaGzipFile [protected, virtual]
~QuaGzipFile()QuaGzipFile [virtual]
- - - diff --git a/hecl-gui/quazip/doc/html/classQuaGzipFile.html b/hecl-gui/quazip/doc/html/classQuaGzipFile.html deleted file mode 100644 index db6a735c7..000000000 --- a/hecl-gui/quazip/doc/html/classQuaGzipFile.html +++ /dev/null @@ -1,292 +0,0 @@ - - - - -QuaZIP: QuaGzipFile Class Reference - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
- -
-
QuaGzipFile Class Reference
-
-
- -

GZIP file. - More...

- -

#include <quagzipfile.h>

- -

List of all members.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

 QuaGzipFile ()
 Empty constructor.
 QuaGzipFile (QObject *parent)
 Empty constructor with a parent.
 QuaGzipFile (const QString &fileName, QObject *parent=NULL)
 Constructor.
-virtual ~QuaGzipFile ()
 Destructor.
-void setFileName (const QString &fileName)
 Sets the name of the GZIP file to be opened.
-QString getFileName () const
 Returns the name of the GZIP file.
virtual bool isSequential () const
 Returns true.
virtual bool open (QIODevice::OpenMode mode)
 Opens the file.
virtual bool open (int fd, QIODevice::OpenMode mode)
 Opens the file.
virtual bool flush ()
 Flushes data to file.
-virtual void close ()
 Closes the file.

-Protected Member Functions

-virtual qint64 readData (char *data, qint64 maxSize)
 Implementation of QIODevice::readData().
-virtual qint64 writeData (const char *data, qint64 maxSize)
 Implementation of QIODevice::writeData().
-

Detailed Description

-

GZIP file.

-

This class is a wrapper around GZIP file access functions in zlib. Unlike QuaZip classes, it doesn't allow reading from a GZIP file opened as QIODevice, for example, if your GZIP file is in QBuffer. It only provides QIODevice access to a GZIP file contents, but the GZIP file itself must be identified by its name on disk or by descriptor id.

-

Constructor & Destructor Documentation

- -
-
- - - - - - - -
QuaGzipFile::QuaGzipFile ()
-
-
- -

Empty constructor.

-

Must call setFileName() before trying to open.

- -
-
- -
-
- - - - - - - - -
QuaGzipFile::QuaGzipFile (QObject * parent)
-
-
- -

Empty constructor with a parent.

-

Must call setFileName() before trying to open.

-
Parameters:
- - -
parentThe parent object, as per QObject logic.
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
QuaGzipFile::QuaGzipFile (const QString & fileName,
QObject * parent = NULL 
)
-
-
- -

Constructor.

-
Parameters:
- - - -
fileNameThe name of the GZIP file.
parentThe parent object, as per QObject logic.
-
-
- -
-
-

Member Function Documentation

- -
-
- - - - - - - -
bool QuaGzipFile::isSequential () const [virtual]
-
-
- -

Returns true.

-

Strictly speaking, zlib supports seeking for GZIP files, but it is poorly implemented, because there is no way to implement it properly. For reading, seeking backwards is very slow, and for writing, it is downright impossible. Therefore, QuaGzipFile does not support seeking at all.

- -
-
- -
-
- - - - - - - - -
bool QuaGzipFile::open (QIODevice::OpenMode mode) [virtual]
-
-
- -

Opens the file.

-
Parameters:
- - -
modeCan be either QIODevice::Write or QIODevice::Read. ReadWrite and Append aren't supported.
-
-
- -

Referenced by open().

- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
bool QuaGzipFile::open (int fd,
QIODevice::OpenMode mode 
) [virtual]
-
-
- -

Opens the file.

-

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

-
Parameters:
- - - -
fdThe file descriptor to read/write the GZIP file from/to.
modeCan be either QIODevice::Write or QIODevice::Read. ReadWrite and Append aren't supported.
-
-
- -

References open().

- -
-
- -
-
- - - - - - - -
bool QuaGzipFile::flush () [virtual]
-
-
- -

Flushes data to file.

-

The data is written using Z_SYNC_FLUSH mode. Doesn't make any sense when reading.

- -
-
-
The documentation for this class was generated from the following files: -
- - - diff --git a/hecl-gui/quazip/doc/html/classQuaZIODevice-members.html b/hecl-gui/quazip/doc/html/classQuaZIODevice-members.html deleted file mode 100644 index 5996de77e..000000000 --- a/hecl-gui/quazip/doc/html/classQuaZIODevice-members.html +++ /dev/null @@ -1,60 +0,0 @@ - - - - -QuaZIP: Member List - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
-
-
QuaZIODevice Member List
-
-
-This is the complete list of members for QuaZIODevice, including all inherited members. - - - - - - - - - -
close()QuaZIODevice [virtual]
flush()QuaZIODevice [virtual]
getIoDevice() const QuaZIODevice
isSequential() const QuaZIODevice [virtual]
open(QIODevice::OpenMode mode)QuaZIODevice [virtual]
QuaZIODevice(QIODevice *io, QObject *parent=NULL)QuaZIODevice
readData(char *data, qint64 maxSize)QuaZIODevice [protected, virtual]
writeData(const char *data, qint64 maxSize)QuaZIODevice [protected, virtual]
~QuaZIODevice()QuaZIODevice
- - - diff --git a/hecl-gui/quazip/doc/html/classQuaZIODevice.html b/hecl-gui/quazip/doc/html/classQuaZIODevice.html deleted file mode 100644 index 1341e777c..000000000 --- a/hecl-gui/quazip/doc/html/classQuaZIODevice.html +++ /dev/null @@ -1,209 +0,0 @@ - - - - -QuaZIP: QuaZIODevice Class Reference - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
- -
-
QuaZIODevice Class Reference
-
-
- -

A class to compress/decompress QIODevice. - More...

- -

#include <quaziodevice.h>

- -

List of all members.

- - - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

 QuaZIODevice (QIODevice *io, QObject *parent=NULL)
 Constructor.
~QuaZIODevice ()
 Destructor.
virtual bool flush ()
 Flushes data waiting to be written.
virtual bool open (QIODevice::OpenMode mode)
 Opens the device.
virtual void close ()
 Closes this device, but not the underlying one.
-QIODevice * getIoDevice () const
 Returns the underlying device.
-virtual bool isSequential () const
 Returns true.

-Protected Member Functions

-virtual qint64 readData (char *data, qint64 maxSize)
 Implementation of QIODevice::readData().
-virtual qint64 writeData (const char *data, qint64 maxSize)
 Implementation of QIODevice::writeData().
-

Detailed Description

-

A class to compress/decompress QIODevice.

-

This class can be used to compress any data written to QIODevice or decompress it back. Compressing data sent over a QTcpSocket is a good example.

-

Constructor & Destructor Documentation

- -
-
- - - - - - - - - - - - - - - - - - -
QuaZIODevice::QuaZIODevice (QIODevice * io,
QObject * parent = NULL 
)
-
-
- -

Constructor.

-
Parameters:
- - - -
ioThe QIODevice to read/write.
parentThe parent object, as per QObject logic.
-
-
- -
-
-

Member Function Documentation

- -
-
- - - - - - - -
bool QuaZIODevice::flush () [virtual]
-
-
- -

Flushes data waiting to be written.

-

Unfortunately, as QIODevice doesn't support flush() by itself, the only thing this method does is write the compressed data into the device using Z_SYNC_FLUSH mode. If you need the compressed data to actually be flushed from the buffer of the underlying QIODevice, you need to call its flush() method as well, providing it supports it (like QTcpSocket does). Example:

-
    QuaZIODevice dev(&sock);
-    dev.open(QIODevice::Write);
-    dev.write(yourDataGoesHere);
-    dev.flush();
-    sock->flush(); // this actually sends data to network
-

This may change in the future versions of QuaZIP by implementing an ugly hack: trying to cast the QIODevice using qobject_cast to known flush()-supporting subclasses, and calling flush if the resulting pointer is not zero.

- -

Referenced by close().

- -
-
- -
-
- - - - - - - - -
bool QuaZIODevice::open (QIODevice::OpenMode mode) [virtual]
-
-
- -

Opens the device.

-
Parameters:
- - -
modeNeither QIODevice::ReadWrite nor QIODevice::Append are not supported.
-
-
- -
-
- -
-
- - - - - - - -
void QuaZIODevice::close () [virtual]
-
-
- -

Closes this device, but not the underlying one.

-

The underlying QIODevice is not closed in case you want to write something else to it.

- -

References flush().

- -

Referenced by ~QuaZIODevice().

- -
-
-
The documentation for this class was generated from the following files: -
- - - diff --git a/hecl-gui/quazip/doc/html/classQuaZip-members.html b/hecl-gui/quazip/doc/html/classQuaZip-members.html deleted file mode 100644 index 016679407..000000000 --- a/hecl-gui/quazip/doc/html/classQuaZip-members.html +++ /dev/null @@ -1,107 +0,0 @@ - - - - -QuaZIP: Member List - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
-
-
QuaZip Member List
-
-
-This is the complete list of members for QuaZip, including all inherited members. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
CaseSensitivity enum nameQuaZip
close()QuaZip
Constants enum nameQuaZip
convertCaseSensitivity(CaseSensitivity cs)QuaZip [static]
csDefault enum valueQuaZip
csInsensitive enum valueQuaZip
csSensitive enum valueQuaZip
getComment() const QuaZip
getCommentCodec() const QuaZip
getCurrentFileInfo(QuaZipFileInfo *info) const QuaZip
getCurrentFileInfo(QuaZipFileInfo64 *info) const QuaZip
getCurrentFileName() const QuaZip
getEntriesCount() const QuaZip
getFileInfoList() const QuaZip
getFileInfoList64() const QuaZip
getFileNameCodec() const QuaZip
getFileNameList() const QuaZip
getIoDevice() const QuaZip
getMode() const QuaZip
getUnzFile()QuaZip
getZipError() const QuaZip
getZipFile()QuaZip
getZipName() const QuaZip
goToFirstFile()QuaZip
goToNextFile()QuaZip
hasCurrentFile() const QuaZip
isAutoClose() const QuaZip
isDataDescriptorWritingEnabled() const QuaZip
isOpen() const QuaZip
isZip64Enabled() const QuaZip
MAX_FILE_NAME_LENGTH enum valueQuaZip
mdAdd enum valueQuaZip
mdAppend enum valueQuaZip
mdCreate enum valueQuaZip
mdNotOpen enum valueQuaZip
mdUnzip enum valueQuaZip
Mode enum nameQuaZip
open(Mode mode, zlib_filefunc_def *ioApi=NULL)QuaZip
QuaZip()QuaZip
QuaZip(const QString &zipName)QuaZip
QuaZip(QIODevice *ioDevice)QuaZip
QuaZipPrivate (defined in QuaZip)QuaZip [friend]
setAutoClose(bool autoClose) const QuaZip
setComment(const QString &comment)QuaZip
setCommentCodec(QTextCodec *commentCodec)QuaZip
setCommentCodec(const char *commentCodecName)QuaZip
setCurrentFile(const QString &fileName, CaseSensitivity cs=csDefault)QuaZip
setDataDescriptorWritingEnabled(bool enabled)QuaZip
setDefaultFileNameCodec(QTextCodec *codec)QuaZip [static]
setDefaultFileNameCodec(const char *codecName)QuaZip [static]
setFileNameCodec(QTextCodec *fileNameCodec)QuaZip
setFileNameCodec(const char *fileNameCodecName)QuaZip
setIoDevice(QIODevice *ioDevice)QuaZip
setZip64Enabled(bool zip64)QuaZip
setZipName(const QString &zipName)QuaZip
~QuaZip()QuaZip
- - - diff --git a/hecl-gui/quazip/doc/html/classQuaZip.html b/hecl-gui/quazip/doc/html/classQuaZip.html deleted file mode 100644 index 4ed2248ab..000000000 --- a/hecl-gui/quazip/doc/html/classQuaZip.html +++ /dev/null @@ -1,1168 +0,0 @@ - - - - -QuaZIP: QuaZip Class Reference - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
- -
- -

ZIP archive. - More...

- -

#include <quazip/quazip.h>

-
-Collaboration diagram for QuaZip:
-
-
Collaboration graph
- - -
[legend]
- -

List of all members.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Public Types

enum  Constants { MAX_FILE_NAME_LENGTH = 256 - }
 Useful constants. More...
enum  Mode {
-  mdNotOpen, -mdUnzip, -mdCreate, -mdAppend, -
-  mdAdd -
- }
 Open mode of the ZIP file. More...
enum  CaseSensitivity { csDefault = 0, -csSensitive = 1, -csInsensitive = 2 - }
 Case sensitivity for the file names. More...

-Public Member Functions

 QuaZip ()
 Constructs QuaZip object.
QuaZip (const QString &zipName)
 Constructs QuaZip object associated with ZIP file zipName.
 QuaZip (QIODevice *ioDevice)
 Constructs QuaZip object associated with ZIP file represented by ioDevice.
 ~QuaZip ()
 Destroys QuaZip object.
bool open (Mode mode, zlib_filefunc_def *ioApi=NULL)
 Opens ZIP file.
void close ()
 Closes ZIP file.
void setFileNameCodec (QTextCodec *fileNameCodec)
 Sets the codec used to encode/decode file names inside archive.
void setFileNameCodec (const char *fileNameCodecName)
 Sets the codec used to encode/decode file names inside archive.
-QTextCodec * getFileNameCodec () const
 Returns the codec used to encode/decode comments inside archive.
void setCommentCodec (QTextCodec *commentCodec)
 Sets the codec used to encode/decode comments inside archive.
void setCommentCodec (const char *commentCodecName)
 Sets the codec used to encode/decode comments inside archive.
-QTextCodec * getCommentCodec () const
 Returns the codec used to encode/decode comments inside archive.
QString getZipName () const
 Returns the name of the ZIP file.
void setZipName (const QString &zipName)
 Sets the name of the ZIP file.
QIODevice * getIoDevice () const
 Returns the device representing this ZIP file.
void setIoDevice (QIODevice *ioDevice)
 Sets the device representing the ZIP file.
-Mode getMode () const
 Returns the mode in which ZIP file was opened.
-bool isOpen () const
 Returns true if ZIP file is open, false otherwise.
int getZipError () const
 Returns the error code of the last operation.
int getEntriesCount () const
 Returns number of the entries in the ZIP central directory.
-QString getComment () const
 Returns global comment in the ZIP file.
void setComment (const QString &comment)
 Sets the global comment in the ZIP file.
bool goToFirstFile ()
 Sets the current file to the first file in the archive.
bool goToNextFile ()
 Sets the current file to the next file in the archive.
bool setCurrentFile (const QString &fileName, CaseSensitivity cs=csDefault)
 Sets current file by its name.
-bool hasCurrentFile () const
 Returns true if the current file has been set.
bool getCurrentFileInfo (QuaZipFileInfo *info) const
 Retrieves information about the current file.
bool getCurrentFileInfo (QuaZipFileInfo64 *info) const
 Retrieves information about the current file.
QString getCurrentFileName () const
 Returns the current file name.
unzFile getUnzFile ()
 Returns unzFile handle.
zipFile getZipFile ()
 Returns zipFile handle.
void setDataDescriptorWritingEnabled (bool enabled)
 Changes the data descriptor writing mode.
bool isDataDescriptorWritingEnabled () const
 Returns the data descriptor default writing mode.
QStringList getFileNameList () const
 Returns a list of files inside the archive.
QList< QuaZipFileInfogetFileInfoList () const
 Returns information list about all files inside the archive.
QList< QuaZipFileInfo64getFileInfoList64 () const
 Returns information list about all files inside the archive.
void setZip64Enabled (bool zip64)
 Enables the zip64 mode.
bool isZip64Enabled () const
 Returns whether the zip64 mode is enabled.
bool isAutoClose () const
 Returns the auto-close flag.
void setAutoClose (bool autoClose) const
 Sets or unsets the auto-close flag.

-Static Public Member Functions

static Qt::CaseSensitivity convertCaseSensitivity (CaseSensitivity cs)
 Returns the actual case sensitivity for the specified QuaZIP one.
static void setDefaultFileNameCodec (QTextCodec *codec)
 Sets the default file name codec to use.
static void setDefaultFileNameCodec (const char *codecName)

-Friends

-class QuaZipPrivate
-

Detailed Description

-

ZIP archive.

-

This class implements basic interface to the ZIP archive. It can be used to read table contents of the ZIP archive and retreiving information about the files inside it.

-

You can also use this class to open files inside archive by passing pointer to the instance of this class to the constructor of the QuaZipFile class. But see QuaZipFile::QuaZipFile(QuaZip*, QObject*) for the possible pitfalls.

-

This class is indended to provide interface to the ZIP subpackage of the ZIP/UNZIP package as well as to the UNZIP subpackage. But currently it supports only UNZIP.

-

The use of this class is simple - just create instance using constructor, then set ZIP archive file name using setFile() function (if you did not passed the name to the constructor), then open() and then use different functions to work with it! Well, if you are paranoid, you may also wish to call close before destructing the instance, to check for errors on close.

-

You may also use getUnzFile() and getZipFile() functions to get the ZIP archive handle and use it with ZIP/UNZIP package API directly.

-

This class supports localized file names inside ZIP archive, but you have to set up proper codec with setCodec() function. By default, locale codec will be used, which is probably ok for UNIX systems, but will almost certainly fail with ZIP archives created in Windows. This is because Windows ZIP programs have strange habit of using DOS encoding for file names in ZIP archives. For example, ZIP archive with cyrillic names created in Windows will have file names in IBM866 encoding instead of WINDOWS-1251. I think that calling one function is not much trouble, but for true platform independency it would be nice to have some mechanism for file name encoding auto detection using locale information. Does anyone know a good way to do it?

-

Member Enumeration Documentation

- -
-
- - - - -
enum QuaZip::Constants
-
-
- -

Useful constants.

-
Enumerator:
- -
MAX_FILE_NAME_LENGTH  -

Maximum file name length. Taken from UNZ_MAXFILENAMEINZIP constant in unzip.c.

-
-
-
- -
-
- -
-
- - - - -
enum QuaZip::Mode
-
-
- -

Open mode of the ZIP file.

-
Enumerator:
- - - - - -
mdNotOpen  -

ZIP file is not open. This is the initial mode.

-
mdUnzip  -

ZIP file is open for reading files inside it.

-
mdCreate  -

ZIP file was created with open() call.

-
mdAppend  -

ZIP file was opened in append mode. This refers to APPEND_STATUS_CREATEAFTER mode in ZIP/UNZIP package and means that zip is appended to some existing file what is useful when that file contains self-extractor code. This is obviously not what you whant to use to add files to the existing ZIP archive.

-
mdAdd  -

ZIP file was opened for adding files in the archive.

-
-
-
- -
-
- -
-
- - - - -
enum QuaZip::CaseSensitivity
-
-
- -

Case sensitivity for the file names.

-

This is what you specify when accessing files in the archive. Works perfectly fine with any characters thanks to Qt's great unicode support. This is different from ZIP/UNZIP API, where only US-ASCII characters was supported.

-
Enumerator:
- - - -
csDefault  -

Default for platform. Case sensitive for UNIX, not for Windows.

-
csSensitive  -

Case sensitive.

-
csInsensitive  -

Case insensitive.

-
-
-
- -
-
-

Constructor & Destructor Documentation

- -
-
- - - - - - - -
QuaZip::QuaZip ()
-
-
- -

Constructs QuaZip object.

-

Call setName() before opening constructed object.

- -
-
- -
-
- - - - - - - - -
QuaZip::QuaZip (QIODevice * ioDevice)
-
-
- -

Constructs QuaZip object associated with ZIP file represented by ioDevice.

-

The IO device must be seekable, otherwise an error will occur when opening.

- -
-
- -
-
- - - - - - - -
QuaZip::~QuaZip ()
-
-
- -

Destroys QuaZip object.

-

Calls close() if necessary.

- -

References close(), and isOpen().

- -
-
-

Member Function Documentation

- -
-
- - - - - - - - -
Qt::CaseSensitivity QuaZip::convertCaseSensitivity (QuaZip::CaseSensitivity cs) [static]
-
-
- -

Returns the actual case sensitivity for the specified QuaZIP one.

-
Parameters:
- - -
csThe value to convert.
-
-
-
Returns:
If CaseSensitivity::csDefault, then returns the default file name case sensitivity for the platform. Otherwise, just returns the appropriate value from the Qt::CaseSensitivity enum.
- -

References csDefault, and csSensitive.

- -

Referenced by QuaZipDir::exists(), and setCurrentFile().

- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
bool QuaZip::open (Mode mode,
zlib_filefunc_def * ioApi = NULL 
)
-
-
- -

Opens ZIP file.

-

Argument mode specifies open mode of the ZIP archive. See Mode for details. Note that there is zipOpen2() function in the ZIP/UNZIP API which accepts globalcomment argument, but it does not use it anywhere, so this open() function does not have this argument. See setComment() if you need to set global comment.

-

If the ZIP file is accessed via explicitly set QIODevice, then this device is opened in the necessary mode. If the device was already opened by some other means, then QuaZIP checks if the open mode is compatible to the mode needed for the requested operation. If necessary, seeking is performed to position the device properly.

-
Returns:
true if successful, false otherwise.
-
Note:
ZIP/UNZIP API open calls do not return error code - they just return NULL indicating an error. But to make things easier, quazip.h header defines additional error code UNZ_ERROROPEN and getZipError() will return it if the open call of the ZIP/UNZIP API returns NULL.
-

Argument ioApi specifies IO function set for ZIP/UNZIP package to use. See unzip.h, zip.h and ioapi.h for details. Note that IO API for QuaZip is different from the original package. The file path argument was changed to be of type voidpf, and QuaZip passes a QIODevice pointer there. This QIODevice is either set explicitly via setIoDevice() or the QuaZip(QIODevice*) constructor, or it is created internally when opening the archive by its file name. The default API (qioapi.cpp) just delegates everything to the QIODevice API. Not only this allows to use a QIODevice instead of file name, but also has a nice side effect of raising the file size limit from 2G to 4G (in non-zip64 archives).

-
Note:
If the zip64 support is needed, the ioApi argument must be NULL because due to the backwards compatibility issues it can be used to provide a 32-bit API only.
-

In short: just forget about the ioApi argument and you'll be fine.

- -

References isOpen(), mdAdd, mdAppend, mdCreate, mdUnzip, QuaZipPrivate::unzFile_f, and QuaZipPrivate::zipFile_f.

- -

Referenced by JlCompress::compressDir(), JlCompress::compressFile(), JlCompress::compressFiles(), JlCompress::extractDir(), JlCompress::extractFile(), JlCompress::extractFiles(), JlCompress::getFileList(), and QuaZipFile::open().

- -
-
- -
-
- - - - - - - -
void QuaZip::close ()
-
-
- -

Closes ZIP file.

-

Call getZipError() to determine if the close was successful.

-

If the file was opened by name, then the underlying QIODevice is closed and deleted.

-

If the underlying QIODevice was set explicitly using setIoDevice() or the appropriate constructor, then it is closed if the auto-close flag is set (which it is by default). Call setAutoClose() to clear the auto-close flag if this behavior is undesirable.

-

Since Qt 5.1, the QSaveFile was introduced. It breaks the QIODevice API by making close() private and crashing the application if it is called from the base class where it is public. It is an excellent example of poor design that illustrates why you should never ever break an is-a relationship between the base class and a subclass. QuaZIP works around this bug by checking if the QIODevice is an instance of QSaveFile, using qobject_cast<>, and if it is, calls QSaveFile::commit() instead of close(). It is a really ugly hack, but at least it makes your programs work instead of crashing. Note that if the auto-close flag is cleared, then this is a non-issue, and commit() isn't called.

- -

References mdAdd, mdAppend, mdCreate, mdNotOpen, mdUnzip, QuaZipPrivate::unzFile_f, and QuaZipPrivate::zipFile_f.

- -

Referenced by QuaZipFile::close(), JlCompress::compressDir(), JlCompress::compressFile(), JlCompress::compressFiles(), JlCompress::extractDir(), JlCompress::extractFile(), JlCompress::extractFiles(), JlCompress::getFileList(), QuaZipFile::open(), and ~QuaZip().

- -
-
- -
-
- - - - - - - - -
void QuaZip::setFileNameCodec (QTextCodec * fileNameCodec)
-
-
- -

Sets the codec used to encode/decode file names inside archive.

-

This is necessary to access files in the ZIP archive created under Windows with non-latin characters in file names. For example, file names with cyrillic letters will be in IBM866 encoding.

- -
-
- -
-
- - - - - - - - -
void QuaZip::setFileNameCodec (const char * fileNameCodecName)
-
-
- -

Sets the codec used to encode/decode file names inside archive.

-

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. Equivalent to calling setFileNameCodec(QTextCodec::codecForName(codecName));

- -
-
- -
-
- - - - - - - - -
void QuaZip::setCommentCodec (QTextCodec * commentCodec)
-
-
- -

Sets the codec used to encode/decode comments inside archive.

-

This codec defaults to locale codec, which is probably ok.

- -
-
- -
-
- - - - - - - - -
void QuaZip::setCommentCodec (const char * commentCodecName)
-
-
- -

Sets the codec used to encode/decode comments inside archive.

-

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. Equivalent to calling setCommentCodec(QTextCodec::codecForName(codecName));

- -
-
- -
-
- - - - - - - -
QString QuaZip::getZipName () const
-
-
- -

Returns the name of the ZIP file.

-

Returns null string if no ZIP file name has been set, for example when the QuaZip instance is set up to use a QIODevice instead.

-
See also:
setZipName(), setIoDevice(), getIoDevice()
- -

Referenced by QuaZipFile::getZipName().

- -
-
- -
-
- - - - - - - - -
void QuaZip::setZipName (const QString & zipName)
-
-
- -

Sets the name of the ZIP file.

-

Does nothing if the ZIP file is open.

-

Does not reset error code returned by getZipError().

-
See also:
setIoDevice(), getIoDevice(), getZipName()
- -

References isOpen().

- -
-
- -
-
- - - - - - - -
QIODevice * QuaZip::getIoDevice () const
-
-
- -

Returns the device representing this ZIP file.

-

Returns null string if no device has been set explicitly, for example when opening a ZIP file by name.

-
See also:
setIoDevice(), getZipName(), setZipName()
- -
-
- -
-
- - - - - - - - -
void QuaZip::setIoDevice (QIODevice * ioDevice)
-
-
- -

Sets the device representing the ZIP file.

-

Does nothing if the ZIP file is open.

-

Does not reset error code returned by getZipError().

-
See also:
getIoDevice(), getZipName(), setZipName()
- -

References isOpen().

- -
-
- -
-
- - - - - - - -
int QuaZip::getZipError () const
-
-
- -

Returns the error code of the last operation.

-

Returns UNZ_OK if the last operation was successful.

-

Error code resets to UNZ_OK every time you call any function that accesses something inside ZIP archive, even if it is const (like getEntriesCount()). open() and close() calls reset error code too. See documentation for the specific functions for details on error detection.

- -

Referenced by QuaZipFile::close(), JlCompress::compressDir(), JlCompress::compressFile(), JlCompress::compressFiles(), JlCompress::extractDir(), JlCompress::extractFile(), JlCompress::extractFiles(), QuaZipFile::getActualFileName(), QuaZipFile::getFileInfo(), JlCompress::getFileList(), and QuaZipFile::open().

- -
-
- -
-
- - - - - - - -
int QuaZip::getEntriesCount () const
-
-
- -

Returns number of the entries in the ZIP central directory.

-

Returns negative error code in the case of error. The same error code will be returned by subsequent getZipError() call.

- -

References mdUnzip, and QuaZipPrivate::unzFile_f.

- -
-
- -
-
- - - - - - - - -
void QuaZip::setComment (const QString & comment)
-
-
- -

Sets the global comment in the ZIP file.

-

The comment will be written to the archive on close operation. QuaZip makes a distinction between a null QByteArray() comment and an empty "" comment in the QuaZip::mdAdd mode. A null comment is the default and it means "don't change the comment". An empty comment removes the original comment.

-
See also:
open()
- -
-
- -
-
- - - - - - - -
bool QuaZip::goToFirstFile ()
-
-
- -

Sets the current file to the first file in the archive.

-

Returns true on success, false otherwise. Call getZipError() to get the error code.

- -

References mdUnzip, and QuaZipPrivate::unzFile_f.

- -

Referenced by JlCompress::extractDir(), and JlCompress::getFileList().

- -
-
- -
-
- - - - - - - -
bool QuaZip::goToNextFile ()
-
-
- -

Sets the current file to the next file in the archive.

-

Returns true on success, false otherwise. Call getZipError() to determine if there was an error.

-

Should be used only in QuaZip::mdUnzip mode.

-
Note:
If the end of file was reached, getZipError() will return UNZ_OK instead of UNZ_END_OF_LIST_OF_FILE. This is to make things like this easier:
 for(bool more=zip.goToFirstFile(); more; more=zip.goToNextFile()) {
-   // do something
- }
- if(zip.getZipError()==UNZ_OK) {
-   // ok, there was no error
- }
-
- -

References mdUnzip, and QuaZipPrivate::unzFile_f.

- -

Referenced by JlCompress::extractDir(), JlCompress::getFileList(), and setCurrentFile().

- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
bool QuaZip::setCurrentFile (const QString & fileName,
CaseSensitivity cs = csDefault 
)
-
-
- -

Sets current file by its name.

-

Returns true if successful, false otherwise. Argument cs specifies case sensitivity of the file name. Call getZipError() in the case of a failure to get error code.

-

This is not a wrapper to unzLocateFile() function. That is because I had to implement locale-specific case-insensitive comparison.

-

Here are the differences from the original implementation:

-
    -
  • If the file was not found, error code is UNZ_OK, not UNZ_END_OF_LIST_OF_FILE (see also goToNextFile()).
  • -
  • If this function fails, it unsets the current file rather than resetting it back to what it was before the call.
  • -
-

If fileName is null string then this function unsets the current file and return true. Note that you should close the file first if it is open! See QuaZipFile::QuaZipFile(QuaZip*,QObject*) for the details.

-

Should be used only in QuaZip::mdUnzip mode.

-
See also:
setFileNameCodec(), CaseSensitivity
- -

References convertCaseSensitivity(), getCurrentFileName(), goToNextFile(), MAX_FILE_NAME_LENGTH, mdUnzip, and QuaZipPrivate::unzFile_f.

- -

Referenced by QuaZipFile::open().

- -
-
- -
-
- - - - - - - - -
bool QuaZip::getCurrentFileInfo (QuaZipFileInfoinfo) const
-
-
- -

Retrieves information about the current file.

-

Fills the structure pointed by info. Returns true on success, false otherwise. In the latter case structure pointed by info remains untouched. If there was an error, getZipError() returns error code.

-

Should be used only in QuaZip::mdUnzip mode.

-

Does nothing and returns false in any of the following cases.

-
    -
  • ZIP is not open;
  • -
  • ZIP does not have current file.
  • -
-

In both cases getZipError() returns UNZ_OK since there is no ZIP/UNZIP API call.

-

This overload doesn't support zip64, but will work OK on zip64 archives except that if one of the sizes (compressed or uncompressed) is greater than 0xFFFFFFFFu, it will be set to exactly 0xFFFFFFFFu.

-
See also:
getCurrentFileInfo(QuaZipFileInfo64* info)const
-
-QuaZipFileInfo64::toQuaZipFileInfo(QuaZipFileInfo&)const
- -

References QuaZipFileInfo64::toQuaZipFileInfo().

- -

Referenced by QuaZipFile::getFileInfo(), and JlCompress::getFileList().

- -
-
- -
-
- - - - - - - - -
bool QuaZip::getCurrentFileInfo (QuaZipFileInfo64info) const
-
-
- -

Retrieves information about the current file.

-

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. This function supports zip64. If the archive doesn't use zip64, it is completely equivalent to getCurrentFileInfo(QuaZipFileInfo* info) except for the argument type.

-
See also:
- -

References QuaZipFileInfo64::comment, QuaZipFileInfo64::compressedSize, QuaZipFileInfo64::crc, QuaZipFileInfo64::dateTime, QuaZipFileInfo64::diskNumberStart, QuaZipFileInfo64::externalAttr, QuaZipFileInfo64::extra, QuaZipFileInfo64::flags, hasCurrentFile(), QuaZipFileInfo64::internalAttr, isOpen(), mdUnzip, QuaZipFileInfo64::method, QuaZipFileInfo64::name, QuaZipFileInfo64::uncompressedSize, QuaZipPrivate::unzFile_f, QuaZipFileInfo64::versionCreated, and QuaZipFileInfo64::versionNeeded.

- -
-
- -
-
- - - - - - - -
QString QuaZip::getCurrentFileName () const
-
-
- -

Returns the current file name.

-

Equivalent to calling getCurrentFileInfo() and then getting name field of the QuaZipFileInfo structure, but faster and more convenient.

-

Should be used only in QuaZip::mdUnzip mode.

- -

References hasCurrentFile(), isOpen(), MAX_FILE_NAME_LENGTH, mdUnzip, and QuaZipPrivate::unzFile_f.

- -

Referenced by JlCompress::extractDir(), QuaZipFile::getActualFileName(), and setCurrentFile().

- -
-
- -
-
- - - - - - - -
unzFile QuaZip::getUnzFile ()
-
-
- -

Returns unzFile handle.

-

You can use this handle to directly call UNZIP part of the ZIP/UNZIP package functions (see unzip.h).

-
Warning:
When using the handle returned by this function, please keep in mind that QuaZip class is unable to detect any changes you make in the ZIP file state (e. g. changing current file, or closing the handle). So please do not do anything with this handle that is possible to do with the functions of this class. Or at least return the handle in the original state before calling some another function of this class (including implicit destructor calls and calls from the QuaZipFile objects that refer to this QuaZip instance!). So if you have changed the current file in the ZIP archive - then change it back or you may experience some strange behavior or even crashes.
- -

References QuaZipPrivate::unzFile_f.

- -

Referenced by QuaZipFile::atEnd(), QuaZipFile::close(), QuaZipFile::csize(), QuaZipFile::open(), QuaZipFile::pos(), QuaZipFile::readData(), and QuaZipFile::usize().

- -
-
- -
-
- - - - - - - -
zipFile QuaZip::getZipFile ()
-
-
- -

Returns zipFile handle.

-

You can use this handle to directly call ZIP part of the ZIP/UNZIP package functions (see zip.h). Warnings about the getUnzFile() function also apply to this function.

- -

References QuaZipPrivate::zipFile_f.

- -

Referenced by QuaZipFile::close(), QuaZipFile::open(), and QuaZipFile::writeData().

- -
-
- -
-
- - - - - - - - -
void QuaZip::setDataDescriptorWritingEnabled (bool enabled)
-
-
- -

Changes the data descriptor writing mode.

-

According to the ZIP format specification, a file inside archive may have a data descriptor immediately following the file data. This is reflected by a special flag in the local file header and in the central directory. By default, QuaZIP sets this flag and writes the data descriptor unless both method and level were set to 0, in which case it operates in 1.0-compatible mode and never writes data descriptors.

-

By setting this flag to false, it is possible to disable data descriptor writing, thus increasing compatibility with archive readers that don't understand this feature of the ZIP file format.

-

Setting this flag affects all the QuaZipFile instances that are opened after this flag is set.

-

The data descriptor writing mode is enabled by default.

-
Parameters:
- - -
enabledIf true, enable local descriptor writing, disable it otherwise.
-
-
-
See also:
QuaZipFile::setDataDescriptorWritingEnabled()
- -
-
- -
-
- - - - - - - -
bool QuaZip::isDataDescriptorWritingEnabled () const
-
-
- -

Returns the data descriptor default writing mode.

-
See also:
setDataDescriptorWritingEnabled()
- -

Referenced by QuaZipFile::open().

- -
-
- -
-
- - - - - - - -
QStringList QuaZip::getFileNameList () const
-
-
- -

Returns a list of files inside the archive.

-
Returns:
A list of file names or an empty list if there was an error or if the archive is empty (call getZipError() to figure out which).
-
See also:
getFileInfoList()
- -
-
- -
-
- - - - - - - -
QList< QuaZipFileInfo > QuaZip::getFileInfoList () const
-
-
- -

Returns information list about all files inside the archive.

-
Returns:
A list of QuaZipFileInfo objects or an empty list if there was an error or if the archive is empty (call getZipError() to figure out which).
-

This function doesn't support zip64, but will still work with zip64 archives, converting results using QuaZipFileInfo64::toQuaZipFileInfo(). If all file sizes are below 4 GB, it will work just fine.

-
See also:
getFileNameList()
-
-getFileInfoList64()
- -
-
- -
-
- - - - - - - -
QList< QuaZipFileInfo64 > QuaZip::getFileInfoList64 () const
-
-
- -

Returns information list about all files inside the archive.

-

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. This function supports zip64.

-
See also:
getFileNameList()
-
-getFileInfoList()
- -
-
- -
-
- - - - - - - - -
void QuaZip::setZip64Enabled (bool zip64)
-
-
- -

Enables the zip64 mode.

-
Parameters:
- - -
zip64If true, the zip64 mode is enabled, disabled otherwise.
-
-
-

Once this is enabled, all new files (until the mode is disabled again) will be created in the zip64 mode, thus enabling the ability to write files larger than 4 GB. By default, the zip64 mode is off due to compatibility reasons.

-

Note that this does not affect the ability to read zip64 archives in any way.

-
See also:
isZip64Enabled()
- -
-
- -
-
- - - - - - - -
bool QuaZip::isZip64Enabled () const
-
-
- -

Returns whether the zip64 mode is enabled.

-
Returns:
true if and only if the zip64 mode is enabled.
-
See also:
setZip64Enabled()
- -

Referenced by QuaZipFile::open().

- -
-
- -
-
- - - - - - - -
bool QuaZip::isAutoClose () const
-
-
- -

Returns the auto-close flag.

-
See also:
setAutoClose()
- -
-
- -
-
- - - - - - - - -
void QuaZip::setAutoClose (bool autoClose) const
-
-
- -

Sets or unsets the auto-close flag.

-

By default, QuaZIP opens the underlying QIODevice when open() is called, and closes it when close() is called. In some cases, when the device is set explicitly using setIoDevice(), it may be desirable to leave the device open. If the auto-close flag is unset using this method, then the device isn't closed automatically if it was set explicitly.

-

If it is needed to clear this flag, it is recommended to do so before opening the archive because otherwise QuaZIP may close the device during the open() call if an error is encountered after the device is opened.

-

If the device was not set explicitly, but rather the setZipName() or the appropriate constructor was used to set the ZIP file name instead, then the auto-close flag has no effect, and the internal device is closed nevertheless because there is no other way to close it.

-
See also:
isAutoClose()
-
-setIoDevice()
- -
-
- -
-
- - - - - - - - -
void QuaZip::setDefaultFileNameCodec (QTextCodec * codec) [static]
-
-
- -

Sets the default file name codec to use.

-

The default codec is used by the constructors, so calling this function won't affect the QuaZip instances already created at that moment.

-

The codec specified here can be overriden by calling setFileNameCodec(). If neither function is called, QTextCodec::codecForLocale() will be used to decode or encode file names. Use this function with caution if the application uses other libraries that depend on QuaZIP. Those libraries can either call this function by themselves, thus overriding your setting or can rely on the default encoding, thus failing mysteriously if you change it. For these reasons, it isn't recommended to use this function if you are developing a library, not an application. Instead, ask your library users to call it in case they need specific encoding.

-

In most cases, using setFileNameCodec() instead is the right choice. However, if you depend on third-party code that uses QuaZIP, then the reasons stated above can actually become a reason to use this function in case the third-party code in question fails because it doesn't understand the encoding you need and doesn't provide a way to specify it. This applies to the JlCompress class as well, as it was contributed and doesn't support explicit encoding parameters.

-

In short: use setFileNameCodec() when you can, resort to setDefaultFileNameCodec() when you don't have access to the QuaZip instance.

-
Parameters:
- - -
codecThe codec to use by default. If NULL, resets to default.
-
-
- -

Referenced by setDefaultFileNameCodec().

- -
-
- -
-
- - - - - - - - -
void QuaZip::setDefaultFileNameCodec (const char * codecName) [static]
-
-
-

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. Equivalent to calling setDefltFileNameCodec(QTextCodec::codecForName(codecName)).

- -

References setDefaultFileNameCodec().

- -
-
-
The documentation for this class was generated from the following files: -
- - - diff --git a/hecl-gui/quazip/doc/html/classQuaZipDir-members.html b/hecl-gui/quazip/doc/html/classQuaZipDir-members.html deleted file mode 100644 index 327842611..000000000 --- a/hecl-gui/quazip/doc/html/classQuaZipDir-members.html +++ /dev/null @@ -1,83 +0,0 @@ - - - - -QuaZIP: Member List - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
-
-
QuaZipDir Member List
-
-
-This is the complete list of members for QuaZipDir, including all inherited members. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
caseSensitivity() const QuaZipDir
cd(const QString &dirName)QuaZipDir
cdUp()QuaZipDir
count() const QuaZipDir
dirName() const QuaZipDir
entryInfoList(const QStringList &nameFilters, QDir::Filters filters=QDir::NoFilter, QDir::SortFlags sort=QDir::NoSort) const QuaZipDir
entryInfoList(QDir::Filters filters=QDir::NoFilter, QDir::SortFlags sort=QDir::NoSort) const QuaZipDir
entryInfoList64(const QStringList &nameFilters, QDir::Filters filters=QDir::NoFilter, QDir::SortFlags sort=QDir::NoSort) const QuaZipDir
entryInfoList64(QDir::Filters filters=QDir::NoFilter, QDir::SortFlags sort=QDir::NoSort) const QuaZipDir
entryList(const QStringList &nameFilters, QDir::Filters filters=QDir::NoFilter, QDir::SortFlags sort=QDir::NoSort) const QuaZipDir
entryList(QDir::Filters filters=QDir::NoFilter, QDir::SortFlags sort=QDir::NoSort) const QuaZipDir
exists(const QString &fileName) const QuaZipDir
exists() const QuaZipDir
filePath(const QString &fileName) const QuaZipDir
filter()QuaZipDir
isRoot() const QuaZipDir
nameFilters() const QuaZipDir
operator!=(const QuaZipDir &that)QuaZipDir [inline]
operator=(const QuaZipDir &that)QuaZipDir
operator==(const QuaZipDir &that)QuaZipDir
operator[](int pos) const QuaZipDir
path() const QuaZipDir
QuaZipDir(const QuaZipDir &that)QuaZipDir
QuaZipDir(QuaZip *zip, const QString &dir=QString())QuaZipDir
relativeFilePath(const QString &fileName) const QuaZipDir
setCaseSensitivity(QuaZip::CaseSensitivity caseSensitivity)QuaZipDir
setFilter(QDir::Filters filters)QuaZipDir
setNameFilters(const QStringList &nameFilters)QuaZipDir
setPath(const QString &path)QuaZipDir
setSorting(QDir::SortFlags sort)QuaZipDir
sorting() const QuaZipDir
~QuaZipDir()QuaZipDir
- - - diff --git a/hecl-gui/quazip/doc/html/classQuaZipDir.html b/hecl-gui/quazip/doc/html/classQuaZipDir.html deleted file mode 100644 index cb66f2d07..000000000 --- a/hecl-gui/quazip/doc/html/classQuaZipDir.html +++ /dev/null @@ -1,635 +0,0 @@ - - - - -QuaZIP: QuaZipDir Class Reference - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
- -
-
QuaZipDir Class Reference
-
-
- -

Provides ZIP archive navigation. - More...

- -

#include <quazipdir.h>

- -

List of all members.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

QuaZipDir (const QuaZipDir &that)
 The copy constructor.
 QuaZipDir (QuaZip *zip, const QString &dir=QString())
 Constructs a QuaZipDir instance pointing to the specified directory.
~QuaZipDir ()
 Destructor.
-bool operator== (const QuaZipDir &that)
 The assignment operator.
bool operator!= (const QuaZipDir &that)
 operator!=
QuaZipDiroperator= (const QuaZipDir &that)
 operator==
-QString operator[] (int pos) const
 Returns the name of the entry at the specified position.
-QuaZip::CaseSensitivity caseSensitivity () const
 Returns the current case sensitivity mode.
bool cd (const QString &dirName)
 Changes the 'current' directory.
-bool cdUp ()
 Goes up.
-uint count () const
 Returns the number of entries in the directory.
QString dirName () const
 Returns the current directory name.
QList< QuaZipFileInfoentryInfoList (const QStringList &nameFilters, QDir::Filters filters=QDir::NoFilter, QDir::SortFlags sort=QDir::NoSort) const
 Returns the list of the entries in the directory.
QList< QuaZipFileInfoentryInfoList (QDir::Filters filters=QDir::NoFilter, QDir::SortFlags sort=QDir::NoSort) const
 Returns the list of the entries in the directory.
QList< QuaZipFileInfo64entryInfoList64 (const QStringList &nameFilters, QDir::Filters filters=QDir::NoFilter, QDir::SortFlags sort=QDir::NoSort) const
 Returns the list of the entries in the directory with zip64 support.
QList< QuaZipFileInfo64entryInfoList64 (QDir::Filters filters=QDir::NoFilter, QDir::SortFlags sort=QDir::NoSort) const
 Returns the list of the entries in the directory with zip64 support.
QStringList entryList (const QStringList &nameFilters, QDir::Filters filters=QDir::NoFilter, QDir::SortFlags sort=QDir::NoSort) const
 Returns the list of the entry names in the directory.
QStringList entryList (QDir::Filters filters=QDir::NoFilter, QDir::SortFlags sort=QDir::NoSort) const
 Returns the list of the entry names in the directory.
bool exists (const QString &fileName) const
 Returns true if the entry with the specified name exists.
-bool exists () const
 Return true if the directory pointed by this QuaZipDir exists.
QString filePath (const QString &fileName) const
 Returns the full path to the specified file.
-QDir::Filters filter ()
 Returns the default filter.
bool isRoot () const
 Returns if the QuaZipDir points to the root of the archive.
-QStringList nameFilters () const
 Return the default name filter.
QString path () const
 Returns the path to the current dir.
QString relativeFilePath (const QString &fileName) const
 Returns the path to the specified file relative to the current dir.
-void setCaseSensitivity (QuaZip::CaseSensitivity caseSensitivity)
 Sets the default case sensitivity mode.
-void setFilter (QDir::Filters filters)
 Sets the default filter.
-void setNameFilters (const QStringList &nameFilters)
 Sets the default name filter.
void setPath (const QString &path)
 Goes to the specified path.
-void setSorting (QDir::SortFlags sort)
 Sets the default sorting mode.
-QDir::SortFlags sorting () const
 Returns the default sorting mode.
-

Detailed Description

-

Provides ZIP archive navigation.

-

This class is modelled after QDir, and is designed to provide similar features for ZIP archives.

-

The only significant difference from QDir is that the root path is not '/', but an empty string since that's how the file paths are stored in the archive. However, QuaZipDir understands the paths starting with '/'. It is important in a few places:

-
    -
  • In the cd() function.
  • -
  • In the constructor.
  • -
  • In the exists() function.
  • -
  • In the relativePath() function.
  • -
-

Note that since ZIP uses '/' on all platforms, the '\' separator is not supported.

-

Constructor & Destructor Documentation

- -
-
- - - - - - - - - - - - - - - - - - -
QuaZipDir::QuaZipDir (QuaZipzip,
const QString & dir = QString() 
)
-
-
- -

Constructs a QuaZipDir instance pointing to the specified directory.

-

If dir is not specified, points to the root of the archive. The same happens if the dir is "/".

- -
-
-

Member Function Documentation

- -
-
- - - - - - - - -
bool QuaZipDir::operator!= (const QuaZipDirthat) [inline]
-
-
- -

operator!=

-
Returns:
true if either this and that use different QuaZip instances or if they point to different directories.
- -
-
- -
-
- - - - - - - - -
QuaZipDir & QuaZipDir::operator= (const QuaZipDirthat)
-
-
- -

operator==

-
Returns:
true if both this and that use the same QuaZip instance and point to the same directory.
- -
-
- -
-
- - - - - - - - -
bool QuaZipDir::cd (const QString & dirName)
-
-
- -

Changes the 'current' directory.

-

If the path starts with '/', it is interpreted as an absolute path from the root of the archive. Otherwise, it is interpreted as a path relative to the current directory as was set by the previous cd() or the constructor.

-

Note that the subsequent path() call will not return a path starting with '/' in all cases.

- -

References cd(), dirName(), exists(), isRoot(), and path().

- -

Referenced by cd(), and cdUp().

- -
-
- -
-
- - - - - - - -
QString QuaZipDir::dirName () const
-
-
- -

Returns the current directory name.

-

The name doesn't include the path.

- -

Referenced by cd().

- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
QList< QuaZipFileInfo > QuaZipDir::entryInfoList (const QStringList & nameFilters,
QDir::Filters filters = QDir::NoFilter,
QDir::SortFlags sort = QDir::NoSort 
) const
-
-
- -

Returns the list of the entries in the directory.

-
Parameters:
- - - - -
nameFiltersThe list of file patterns to list, uses the same syntax as QDir.
filtersThe entry type filters, only Files and Dirs are accepted.
sortSorting mode.
-
-
- -

Referenced by entryInfoList().

- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
QList< QuaZipFileInfo > QuaZipDir::entryInfoList (QDir::Filters filters = QDir::NoFilter,
QDir::SortFlags sort = QDir::NoSort 
) const
-
-
- -

Returns the list of the entries in the directory.

-

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. The same as entryInfoList(QStringList(), filters, sort).

- -

References entryInfoList().

- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
QList< QuaZipFileInfo64 > QuaZipDir::entryInfoList64 (const QStringList & nameFilters,
QDir::Filters filters = QDir::NoFilter,
QDir::SortFlags sort = QDir::NoSort 
) const
-
-
- -

Returns the list of the entries in the directory with zip64 support.

-
Parameters:
- - - - -
nameFiltersThe list of file patterns to list, uses the same syntax as QDir.
filtersThe entry type filters, only Files and Dirs are accepted.
sortSorting mode.
-
-
- -

Referenced by entryInfoList64().

- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
QList< QuaZipFileInfo64 > QuaZipDir::entryInfoList64 (QDir::Filters filters = QDir::NoFilter,
QDir::SortFlags sort = QDir::NoSort 
) const
-
-
- -

Returns the list of the entries in the directory with zip64 support.

-

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. The same as entryInfoList64(QStringList(), filters, sort).

- -

References entryInfoList64().

- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
QStringList QuaZipDir::entryList (const QStringList & nameFilters,
QDir::Filters filters = QDir::NoFilter,
QDir::SortFlags sort = QDir::NoSort 
) const
-
-
- -

Returns the list of the entry names in the directory.

-

The same as entryInfoList(nameFilters, filters, sort), but only returns entry names.

- -

Referenced by count(), entryList(), exists(), and operator[]().

- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
QStringList QuaZipDir::entryList (QDir::Filters filters = QDir::NoFilter,
QDir::SortFlags sort = QDir::NoSort 
) const
-
-
- -

Returns the list of the entry names in the directory.

-

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. The same as entryList(QStringList(), filters, sort).

- -

References entryList().

- -
-
- -
-
- - - - - - - - -
bool QuaZipDir::exists (const QString & fileName) const
-
-
- -

Returns true if the entry with the specified name exists.

-

The ".." is considered to exist if the current directory is not root. The "." and "/" are considered to always exist. Paths starting with "/" are relative to the archive root, other paths are relative to the current dir.

- -

References QuaZip::convertCaseSensitivity(), entryList(), filePath(), and isRoot().

- -
-
- -
-
- - - - - - - - -
QString QuaZipDir::filePath (const QString & fileName) const
-
-
- -

Returns the full path to the specified file.

-

Doesn't check if the file actually exists.

- -

Referenced by exists().

- -
-
- -
-
- - - - - - - -
bool QuaZipDir::isRoot () const
-
-
- -

Returns if the QuaZipDir points to the root of the archive.

-

Not that the root path is the empty string, not '/'.

- -

Referenced by cd(), and exists().

- -
-
- -
-
- - - - - - - -
QString QuaZipDir::path () const
-
-
- -

Returns the path to the current dir.

-

The path never starts with '/', and the root path is an empty string.

- -

Referenced by cd(), and setPath().

- -
-
- -
-
- - - - - - - - -
QString QuaZipDir::relativeFilePath (const QString & fileName) const
-
-
- -

Returns the path to the specified file relative to the current dir.

-

This function is mostly useless, provided only for the sake of completeness.

-
Parameters:
- - -
fileNameThe path to the file, should start with "/" if relative to the archive root.
-
-
-
Returns:
Path relative to the current dir.
- -
-
- -
-
- - - - - - - - -
void QuaZipDir::setPath (const QString & path)
-
-
- -

Goes to the specified path.

-

The difference from cd() is that this function never checks if the path actually exists and doesn't use relative paths, so it's possible to go to the root directory with setPath("").

-

Note that this function still chops the trailing and/or leading '/' and treats a single '/' as the root path (path() will still return an empty string).

- -

References path().

- -
-
-
The documentation for this class was generated from the following files: -
- - - diff --git a/hecl-gui/quazip/doc/html/classQuaZipFile-members.html b/hecl-gui/quazip/doc/html/classQuaZipFile-members.html deleted file mode 100644 index 554e3b525..000000000 --- a/hecl-gui/quazip/doc/html/classQuaZipFile-members.html +++ /dev/null @@ -1,84 +0,0 @@ - - - - -QuaZIP: Member List - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
-
-
QuaZipFile Member List
-
-
-This is the complete list of members for QuaZipFile, including all inherited members. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
atEnd() const QuaZipFile [virtual]
bytesAvailable() const QuaZipFile [virtual]
close()QuaZipFile [virtual]
csize() const QuaZipFile
getActualFileName() const QuaZipFile
getCaseSensitivity() const QuaZipFile
getFileInfo(QuaZipFileInfo *info)QuaZipFile
getFileInfo(QuaZipFileInfo64 *info)QuaZipFile
getFileName() const QuaZipFile
getZip() const QuaZipFile
getZipError() const QuaZipFile
getZipName() const QuaZipFile
isRaw() const QuaZipFile
isSequential() const QuaZipFile [virtual]
open(OpenMode mode)QuaZipFile [virtual]
open(OpenMode mode, const char *password)QuaZipFile [inline]
open(OpenMode mode, int *method, int *level, bool raw, const char *password=NULL)QuaZipFile
open(OpenMode mode, const QuaZipNewInfo &info, const char *password=NULL, quint32 crc=0, int method=Z_DEFLATED, int level=Z_DEFAULT_COMPRESSION, bool raw=false, int windowBits=-MAX_WBITS, int memLevel=DEF_MEM_LEVEL, int strategy=Z_DEFAULT_STRATEGY)QuaZipFile
pos() const QuaZipFile [virtual]
QuaZipFile()QuaZipFile
QuaZipFile(QObject *parent)QuaZipFile
QuaZipFile(const QString &zipName, QObject *parent=NULL)QuaZipFile
QuaZipFile(const QString &zipName, const QString &fileName, QuaZip::CaseSensitivity cs=QuaZip::csDefault, QObject *parent=NULL)QuaZipFile
QuaZipFile(QuaZip *zip, QObject *parent=NULL)QuaZipFile
QuaZipFilePrivate (defined in QuaZipFile)QuaZipFile [friend]
readData(char *data, qint64 maxSize)QuaZipFile [protected]
setFileName(const QString &fileName, QuaZip::CaseSensitivity cs=QuaZip::csDefault)QuaZipFile
setZip(QuaZip *zip)QuaZipFile
setZipName(const QString &zipName)QuaZipFile
size() const QuaZipFile [virtual]
usize() const QuaZipFile
writeData(const char *data, qint64 maxSize)QuaZipFile [protected]
~QuaZipFile()QuaZipFile [virtual]
- - - diff --git a/hecl-gui/quazip/doc/html/classQuaZipFile.html b/hecl-gui/quazip/doc/html/classQuaZipFile.html deleted file mode 100644 index 21dae0ff1..000000000 --- a/hecl-gui/quazip/doc/html/classQuaZipFile.html +++ /dev/null @@ -1,959 +0,0 @@ - - - - -QuaZIP: QuaZipFile Class Reference - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
- -
-
QuaZipFile Class Reference
-
-
- -

A file inside ZIP archive. - More...

- -

#include <quazip/quazipfile.h>

-
-Collaboration diagram for QuaZipFile:
-
-
Collaboration graph
- - -
[legend]
- -

List of all members.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

 QuaZipFile ()
 Constructs a QuaZipFile instance.
 QuaZipFile (QObject *parent)
 Constructs a QuaZipFile instance.
 QuaZipFile (const QString &zipName, QObject *parent=NULL)
 Constructs a QuaZipFile instance.
 QuaZipFile (const QString &zipName, const QString &fileName, QuaZip::CaseSensitivity cs=QuaZip::csDefault, QObject *parent=NULL)
 Constructs a QuaZipFile instance.
 QuaZipFile (QuaZip *zip, QObject *parent=NULL)
 Constructs a QuaZipFile instance.
virtual ~QuaZipFile ()
 Destroys a QuaZipFile instance.
QString getZipName () const
 Returns the ZIP archive file name.
QuaZipgetZip () const
 Returns a pointer to the associated QuaZip object.
QString getFileName () const
 Returns file name.
QuaZip::CaseSensitivity getCaseSensitivity () const
 Returns case sensitivity of the file name.
QString getActualFileName () const
 Returns the actual file name in the archive.
void setZipName (const QString &zipName)
 Sets the ZIP archive file name.
bool isRaw () const
 Returns true if the file was opened in raw mode.
void setZip (QuaZip *zip)
 Binds to the existing QuaZip instance.
void setFileName (const QString &fileName, QuaZip::CaseSensitivity cs=QuaZip::csDefault)
 Sets the file name.
virtual bool open (OpenMode mode)
 Opens a file for reading.
bool open (OpenMode mode, const char *password)
 Opens a file for reading.
bool open (OpenMode mode, int *method, int *level, bool raw, const char *password=NULL)
 Opens a file for reading.
bool open (OpenMode mode, const QuaZipNewInfo &info, const char *password=NULL, quint32 crc=0, int method=Z_DEFLATED, int level=Z_DEFAULT_COMPRESSION, bool raw=false, int windowBits=-MAX_WBITS, int memLevel=DEF_MEM_LEVEL, int strategy=Z_DEFAULT_STRATEGY)
 Opens a file for writing.
-virtual bool isSequential () const
 Returns true, but beware!
virtual qint64 pos () const
 Returns current position in the file.
virtual bool atEnd () const
 Returns true if the end of file was reached.
virtual qint64 size () const
 Returns file size.
qint64 csize () const
 Returns compressed file size.
qint64 usize () const
 Returns uncompressed file size.
bool getFileInfo (QuaZipFileInfo *info)
 Gets information about current file.
bool getFileInfo (QuaZipFileInfo64 *info)
 Gets information about current file with zip64 support.
virtual void close ()
 Closes the file.
-int getZipError () const
 Returns the error code returned by the last ZIP/UNZIP API call.
-virtual qint64 bytesAvailable () const
 Returns the number of bytes available for reading.

-Protected Member Functions

-qint64 readData (char *data, qint64 maxSize)
 Implementation of the QIODevice::readData().
-qint64 writeData (const char *data, qint64 maxSize)
 Implementation of the QIODevice::writeData().

-Friends

-class QuaZipFilePrivate
-

Detailed Description

-

A file inside ZIP archive.

-

This is the most interesting class. Not only it provides C++ interface to the ZIP/UNZIP package, but also integrates it with Qt by subclassing QIODevice. This makes possible to access files inside ZIP archive using QTextStream or QDataStream, for example. Actually, this is the main purpose of the whole QuaZIP library.

-

You can either use existing QuaZip instance to create instance of this class or pass ZIP archive file name to this class, in which case it will create internal QuaZip object. See constructors' descriptions for details. Writing is only possible with the existing instance.

-

Note that due to the underlying library's limitation it is not possible to use multiple QuaZipFile instances to open several files in the same archive at the same time. If you need to write to multiple files in parallel, then you should write to temporary files first, then pack them all at once when you have finished writing. If you need to read multiple files inside the same archive in parallel, you should extract them all into a temporary directory first.

-

-Sequential or random-access?

-

At the first thought, QuaZipFile has fixed size, the start and the end and should be therefore considered random-access device. But there is one major obstacle to making it random-access: ZIP/UNZIP API does not support seek() operation and the only way to implement it is through reopening the file and re-reading to the required position, but this is prohibitively slow.

-

Therefore, QuaZipFile is considered to be a sequential device. This has advantage of availability of the ungetChar() operation (QIODevice does not implement it properly for non-sequential devices unless they support seek()). Disadvantage is a somewhat strange behaviour of the size() and pos() functions. This should be kept in mind while using this class.

-

Constructor & Destructor Documentation

- -
-
- - - - - - - -
QuaZipFile::QuaZipFile ()
-
-
- -

Constructs a QuaZipFile instance.

-

You should use setZipName() and setFileName() or setZip() before trying to call open() on the constructed object.

- -
-
- -
-
- - - - - - - - -
QuaZipFile::QuaZipFile (QObject * parent)
-
-
- -

Constructs a QuaZipFile instance.

-

parent argument specifies this object's parent object.

-

You should use setZipName() and setFileName() or setZip() before trying to call open() on the constructed object.

- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
QuaZipFile::QuaZipFile (const QString & zipName,
QObject * parent = NULL 
)
-
-
- -

Constructs a QuaZipFile instance.

-

parent argument specifies this object's parent object and zipName specifies ZIP archive file name.

-

You should use setFileName() before trying to call open() on the constructed object.

-

QuaZipFile constructed by this constructor can be used for read only access. Use QuaZipFile(QuaZip*,QObject*) for writing.

- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
QuaZipFile::QuaZipFile (const QString & zipName,
const QString & fileName,
QuaZip::CaseSensitivity cs = QuaZip::csDefault,
QObject * parent = NULL 
)
-
-
- -

Constructs a QuaZipFile instance.

-

parent argument specifies this object's parent object, zipName specifies ZIP archive file name and fileName and cs specify a name of the file to open inside archive.

-

QuaZipFile constructed by this constructor can be used for read only access. Use QuaZipFile(QuaZip*,QObject*) for writing.

-
See also:
QuaZip::setCurrentFile()
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
QuaZipFile::QuaZipFile (QuaZipzip,
QObject * parent = NULL 
)
-
-
- -

Constructs a QuaZipFile instance.

-

parent argument specifies this object's parent object.

-

zip is the pointer to the existing QuaZip object. This QuaZipFile object then can be used to read current file in the zip or to write to the file inside it.

-
Warning:
Using this constructor for reading current file can be tricky. Let's take the following example:
 QuaZip zip("archive.zip");
- zip.open(QuaZip::mdUnzip);
- zip.setCurrentFile("file-in-archive");
- QuaZipFile file(&zip);
- file.open(QIODevice::ReadOnly);
- // ok, now we can read from the file
- file.read(somewhere, some);
- zip.setCurrentFile("another-file-in-archive"); // oops...
- QuaZipFile anotherFile(&zip);
- anotherFile.open(QIODevice::ReadOnly);
- anotherFile.read(somewhere, some); // this is still ok...
- file.read(somewhere, some); // and this is NOT
-
So, what exactly happens here? When we change current file in the zip archive, file that references it becomes invalid (actually, as far as I understand ZIP/UNZIP sources, it becomes closed, but QuaZipFile has no means to detect it).
-

Summary: do not close zip object or change its current file as long as QuaZipFile is open. Even better - use another constructors which create internal QuaZip instances, one per object, and therefore do not cause unnecessary trouble. This constructor may be useful, though, if you already have a QuaZip instance and do not want to access several files at once. Good example:

-
 QuaZip zip("archive.zip");
- zip.open(QuaZip::mdUnzip);
- // first, we need some information about archive itself
- QByteArray comment=zip.getComment();
- // and now we are going to access files inside it
- QuaZipFile file(&zip);
- for(bool more=zip.goToFirstFile(); more; more=zip.goToNextFile()) {
-   file.open(QIODevice::ReadOnly);
-   // do something cool with file here
-   file.close(); // do not forget to close!
- }
- zip.close();
-
-
-
- -
-
- - - - - - - -
QuaZipFile::~QuaZipFile () [virtual]
-
-
- -

Destroys a QuaZipFile instance.

-

Closes file if open, destructs internal QuaZip object (if it exists and is internal, of course).

- -

References close().

- -
-
-

Member Function Documentation

- -
-
- - - - - - - -
QString QuaZipFile::getZipName () const
-
-
- -

Returns the ZIP archive file name.

-

If this object was created by passing QuaZip pointer to the constructor, this function will return that QuaZip's file name (or null string if that object does not have file name yet).

-

Otherwise, returns associated ZIP archive file name or null string if there are no name set yet.

-
See also:
setZipName() getFileName()
- -

References QuaZip::getZipName().

- -
-
- -
-
- - - - - - - -
QuaZip * QuaZipFile::getZip () const
-
-
- -

Returns a pointer to the associated QuaZip object.

-

Returns NULL if there is no associated QuaZip or it is internal (so you will not mess with it).

- -
-
- -
-
- - - - - - - -
QString QuaZipFile::getFileName () const
-
-
- -

Returns file name.

-

This function returns file name you passed to this object either by using QuaZipFile(const QString&,const QString&,QuaZip::CaseSensitivity,QObject*) or by calling setFileName(). Real name of the file may differ in case if you used case-insensitivity.

-

Returns null string if there is no file name set yet. This is the case when this QuaZipFile operates on the existing QuaZip object (constructor QuaZipFile(QuaZip*,QObject*) or setZip() was used).

-
See also:
getActualFileName
- -
-
- -
-
- - - - - - - -
QuaZip::CaseSensitivity QuaZipFile::getCaseSensitivity () const
-
-
- -

Returns case sensitivity of the file name.

-

This function returns case sensitivity argument you passed to this object either by using QuaZipFile(const QString&,const QString&,QuaZip::CaseSensitivity,QObject*) or by calling setFileName().

-

Returns unpredictable value if getFileName() returns null string (this is the case when you did not used setFileName() or constructor above).

-
See also:
getFileName
- -
-
- -
-
- - - - - - - -
QString QuaZipFile::getActualFileName () const
-
-
- -

Returns the actual file name in the archive.

-

This is not a ZIP archive file name, but a name of file inside archive. It is not necessary the same name that you have passed to the QuaZipFile(const QString&,const QString&,QuaZip::CaseSensitivity,QObject*), setFileName() or QuaZip::setCurrentFile() - this is the real file name inside archive, so it may differ in case if the file name search was case-insensitive.

-

Equivalent to calling getCurrentFileName() on the associated QuaZip object. Returns null string if there is no associated QuaZip object or if it does not have a current file yet. And this is the case if you called setFileName() but did not open the file yet. So this is perfectly fine:

-
 QuaZipFile file("somezip.zip");
- file.setFileName("somefile");
- QString name=file.getName(); // name=="somefile"
- QString actual=file.getActualFileName(); // actual is null string
- file.open(QIODevice::ReadOnly);
- QString actual=file.getActualFileName(); // actual can be "SoMeFiLe" on Windows
-
See also:
getZipName(), getFileName(), QuaZip::CaseSensitivity
- -

References QuaZip::getCurrentFileName(), and QuaZip::getZipError().

- -
-
- -
-
- - - - - - - - -
void QuaZipFile::setZipName (const QString & zipName)
-
-
- -

Sets the ZIP archive file name.

-

Automatically creates internal QuaZip object and destroys previously created internal QuaZip object, if any.

-

Will do nothing if this file is already open. You must close() it first.

- -
-
- -
-
- - - - - - - -
bool QuaZipFile::isRaw () const
-
-
- -

Returns true if the file was opened in raw mode.

-

If the file is not open, the returned value is undefined.

-
See also:
open(OpenMode,int*,int*,bool,const char*)
- -

Referenced by close().

- -
-
- -
-
- - - - - - - - -
void QuaZipFile::setZip (QuaZipzip)
-
-
- -

Binds to the existing QuaZip instance.

-

This function destroys internal QuaZip object, if any, and makes this QuaZipFile to use current file in the zip object for any further operations. See QuaZipFile(QuaZip*,QObject*) for the possible pitfalls.

-

Will do nothing if the file is currently open. You must close() it first.

- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
void QuaZipFile::setFileName (const QString & fileName,
QuaZip::CaseSensitivity cs = QuaZip::csDefault 
)
-
-
- -

Sets the file name.

-

Will do nothing if at least one of the following conditions is met:

-
    -
  • ZIP name has not been set yet (getZipName() returns null string).
  • -
  • This QuaZipFile is associated with external QuaZip. In this case you should call that QuaZip's setCurrentFile() function instead!
  • -
  • File is already open so setting the name is meaningless.
  • -
-
See also:
QuaZip::setCurrentFile
- -
-
- -
-
- - - - - - - - -
bool QuaZipFile::open (OpenMode mode) [virtual]
-
-
- -

Opens a file for reading.

-

Returns true on success, false otherwise. Call getZipError() to get error code.

-
Note:
Since ZIP/UNZIP API provides buffered reading only, QuaZipFile does not support unbuffered reading. So do not pass QIODevice::Unbuffered flag in mode, or open will fail.
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
bool QuaZipFile::open (OpenMode mode,
const char * password 
) [inline]
-
-
- -

Opens a file for reading.

-

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. Argument password specifies a password to decrypt the file. If it is NULL then this function behaves just like open(OpenMode).

- -

References open().

- -

Referenced by open().

- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
bool QuaZipFile::open (OpenMode mode,
int * method,
int * level,
bool raw,
const char * password = NULL 
)
-
-
- -

Opens a file for reading.

-

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. Argument password specifies a password to decrypt the file.

-

An integers pointed by method and level will receive codes of the compression method and level used. See unzip.h.

-

If raw is true then no decompression is performed.

-

method should not be NULL. level can be NULL if you don't want to know the compression level.

- -

References QuaZip::close(), QuaZip::getMode(), QuaZip::getUnzFile(), QuaZip::getZipError(), QuaZip::hasCurrentFile(), QuaZip::mdUnzip, QuaZip::open(), and QuaZip::setCurrentFile().

- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
bool QuaZipFile::open (OpenMode mode,
const QuaZipNewInfoinfo,
const char * password = NULL,
quint32 crc = 0,
int method = Z_DEFLATED,
int level = Z_DEFAULT_COMPRESSION,
bool raw = false,
int windowBits = -MAX_WBITS,
int memLevel = DEF_MEM_LEVEL,
int strategy = Z_DEFAULT_STRATEGY 
)
-
-
- -

Opens a file for writing.

-

info argument specifies information about file. It should at least specify a correct file name. Also, it is a good idea to specify correct timestamp (by default, current time will be used). See QuaZipNewInfo.

-

The password argument specifies the password for crypting. Pass NULL if you don't need any crypting. The crc argument was supposed to be used for crypting too, but then it turned out that it's false information, so you need to set it to 0 unless you want to use the raw mode (see below).

-

Arguments method and level specify compression method and level. The only method supported is Z_DEFLATED, but you may also specify 0 for no compression. If all of the files in the archive use both method 0 and either level 0 is explicitly specified or data descriptor writing is disabled with QuaZip::setDataDescriptorWritingEnabled(), then the resulting archive is supposed to be compatible with the 1.0 ZIP format version, should you need that. Except for this, level has no other effects with method 0.

-

If raw is true, no compression is performed. In this case, crc and uncompressedSize field of the info are required.

-

Arguments windowBits, memLevel, strategy provide zlib algorithms tuning. See deflateInit2() in zlib.

- -

References QuaZipNewInfo::comment, QuaZipNewInfo::dateTime, QuaZipNewInfo::externalAttr, QuaZipNewInfo::extraGlobal, QuaZipNewInfo::extraLocal, QuaZip::getCommentCodec(), QuaZip::getFileNameCodec(), QuaZip::getMode(), QuaZip::getZipFile(), QuaZipNewInfo::internalAttr, QuaZip::isDataDescriptorWritingEnabled(), QuaZip::isZip64Enabled(), QuaZip::mdAdd, QuaZip::mdAppend, QuaZip::mdCreate, QuaZipNewInfo::name, and QuaZipNewInfo::uncompressedSize.

- -
-
- -
-
- - - - - - - -
qint64 QuaZipFile::pos () const [virtual]
-
-
- -

Returns current position in the file.

-

Implementation of the QIODevice::pos(). When reading, this function is a wrapper to the ZIP/UNZIP unztell(), therefore it is unable to keep track of the ungetChar() calls (which is non-virtual and therefore is dangerous to reimplement). So if you are using ungetChar() feature of the QIODevice, this function reports incorrect value until you get back characters which you ungot.

-

When writing, pos() returns number of bytes already written (uncompressed unless you use raw mode).

-
Note:
Although QuaZipFile is a sequential device and therefore pos() should always return zero, it does not, because it would be misguiding. Keep this in mind.
-

This function returns -1 if the file or archive is not open.

-

Error code returned by getZipError() is not affected by this function call.

- -

References QuaZip::getUnzFile().

- -

Referenced by bytesAvailable().

- -
-
- -
-
- - - - - - - -
bool QuaZipFile::atEnd () const [virtual]
-
-
- -

Returns true if the end of file was reached.

-

This function returns false in the case of error. This means that you called this function on either not open file, or a file in the not open archive or even on a QuaZipFile instance that does not even have QuaZip instance associated. Do not do that because there is no means to determine whether false is returned because of error or because end of file was reached. Well, on the other side you may interpret false return value as "there is no file open to check for end of file and there is - no end of file therefore".

-

When writing, this function always returns true (because you are always writing to the end of file).

-

Error code returned by getZipError() is not affected by this function call.

- -

References bytesAvailable(), and QuaZip::getUnzFile().

- -
-
- -
-
- - - - - - - -
qint64 QuaZipFile::size () const [virtual]
-
-
- -

Returns file size.

-

This function returns csize() if the file is open for reading in raw mode, usize() if it is open for reading in normal mode and pos() if it is open for writing.

-

Returns -1 on error, call getZipError() to get error code.

-
Note:
This function returns file size despite that QuaZipFile is considered to be sequential device, for which size() should return bytesAvailable() instead. But its name would be very misguiding otherwise, so just keep in mind this inconsistence.
- -

References csize(), and usize().

- -

Referenced by bytesAvailable().

- -
-
- -
-
- - - - - - - -
qint64 QuaZipFile::csize () const
-
-
- -

Returns compressed file size.

-

Equivalent to calling getFileInfo() and then getting compressedSize field, but more convenient and faster.

-

File must be open for reading before calling this function.

-

Returns -1 on error, call getZipError() to get error code.

- -

References QuaZip::getMode(), QuaZip::getUnzFile(), and QuaZip::mdUnzip.

- -

Referenced by size().

- -
-
- -
-
- - - - - - - -
qint64 QuaZipFile::usize () const
-
-
- -

Returns uncompressed file size.

-

Equivalent to calling getFileInfo() and then getting uncompressedSize field, but more convenient and faster. See getFileInfo() for a warning.

-

File must be open for reading before calling this function.

-

Returns -1 on error, call getZipError() to get error code.

- -

References QuaZip::getMode(), QuaZip::getUnzFile(), and QuaZip::mdUnzip.

- -

Referenced by size().

- -
-
- -
-
- - - - - - - - -
bool QuaZipFile::getFileInfo (QuaZipFileInfoinfo)
-
-
- -

Gets information about current file.

-

This function does the same thing as calling QuaZip::getCurrentFileInfo() on the associated QuaZip object, but you can not call getCurrentFileInfo() if the associated QuaZip is internal (because you do not have access to it), while you still can call this function in that case.

-

File must be open for reading before calling this function.

-
Returns:
false in the case of an error.
-

This function doesn't support zip64, but will still work fine on zip64 archives if file sizes are below 4 GB, otherwise the values will be set as if converted using QuaZipFileInfo64::toQuaZipFileInfo().

-
See also:
getFileInfo(QuaZipFileInfo64*)
- -

References QuaZipFileInfo64::toQuaZipFileInfo().

- -
-
- -
-
- - - - - - - - -
bool QuaZipFile::getFileInfo (QuaZipFileInfo64info)
-
-
- -

Gets information about current file with zip64 support.

-

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

-
See also:
getFileInfo(QuaZipFileInfo*)
- -

References QuaZip::getCurrentFileInfo(), QuaZip::getMode(), QuaZip::getZipError(), and QuaZip::mdUnzip.

- -
-
- -
-
- - - - - - - -
void QuaZipFile::close () [virtual]
-
-
- -

Closes the file.

-

Call getZipError() to determine if the close was successful.

- -

References QuaZip::close(), QuaZip::getUnzFile(), QuaZip::getZipError(), QuaZip::getZipFile(), QuaZip::isOpen(), and isRaw().

- -

Referenced by ~QuaZipFile().

- -
-
-
The documentation for this class was generated from the following files: -
- - - diff --git a/hecl-gui/quazip/doc/html/classQuaZipFilePrivate-members.html b/hecl-gui/quazip/doc/html/classQuaZipFilePrivate-members.html deleted file mode 100644 index 1d2ca79e2..000000000 --- a/hecl-gui/quazip/doc/html/classQuaZipFilePrivate-members.html +++ /dev/null @@ -1,52 +0,0 @@ - - - - -QuaZIP: Member List - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
-
-
QuaZipFilePrivate Member List
-
-
-This is the complete list of members for QuaZipFilePrivate, including all inherited members. - -
QuaZipFile (defined in QuaZipFilePrivate)QuaZipFilePrivate [friend]
- - - diff --git a/hecl-gui/quazip/doc/html/classQuaZipFilePrivate.html b/hecl-gui/quazip/doc/html/classQuaZipFilePrivate.html deleted file mode 100644 index 32c8e8508..000000000 --- a/hecl-gui/quazip/doc/html/classQuaZipFilePrivate.html +++ /dev/null @@ -1,75 +0,0 @@ - - - - -QuaZIP: QuaZipFilePrivate Class Reference - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
- -
-
QuaZipFilePrivate Class Reference
-
-
- -

The implementation class for QuaZip. - More...

-
-Collaboration diagram for QuaZipFilePrivate:
-
-
Collaboration graph
- - -
[legend]
- -

List of all members.

- - - -

-Friends

-class QuaZipFile
-

Detailed Description

-

The implementation class for QuaZip.

-

The documentation for this class was generated from the following file:
    -
  • quazip/quazipfile.cpp
  • -
-
- - - diff --git a/hecl-gui/quazip/doc/html/classQuaZipFilePrivate__coll__graph.map b/hecl-gui/quazip/doc/html/classQuaZipFilePrivate__coll__graph.map deleted file mode 100644 index 079f87cca..000000000 --- a/hecl-gui/quazip/doc/html/classQuaZipFilePrivate__coll__graph.map +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/hecl-gui/quazip/doc/html/classQuaZipFilePrivate__coll__graph.md5 b/hecl-gui/quazip/doc/html/classQuaZipFilePrivate__coll__graph.md5 deleted file mode 100644 index 88803009a..000000000 --- a/hecl-gui/quazip/doc/html/classQuaZipFilePrivate__coll__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -8d67fd832bb90332fedcba49da020a67 \ No newline at end of file diff --git a/hecl-gui/quazip/doc/html/classQuaZipFilePrivate__coll__graph.png b/hecl-gui/quazip/doc/html/classQuaZipFilePrivate__coll__graph.png deleted file mode 100644 index abc750d27..000000000 Binary files a/hecl-gui/quazip/doc/html/classQuaZipFilePrivate__coll__graph.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/classQuaZipFile__coll__graph.map b/hecl-gui/quazip/doc/html/classQuaZipFile__coll__graph.map deleted file mode 100644 index 3c9d07fde..000000000 --- a/hecl-gui/quazip/doc/html/classQuaZipFile__coll__graph.map +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/hecl-gui/quazip/doc/html/classQuaZipFile__coll__graph.md5 b/hecl-gui/quazip/doc/html/classQuaZipFile__coll__graph.md5 deleted file mode 100644 index af6cbc02f..000000000 --- a/hecl-gui/quazip/doc/html/classQuaZipFile__coll__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -3cca548c6e61503dea7d82da54af1f8a \ No newline at end of file diff --git a/hecl-gui/quazip/doc/html/classQuaZipFile__coll__graph.png b/hecl-gui/quazip/doc/html/classQuaZipFile__coll__graph.png deleted file mode 100644 index b0778c343..000000000 Binary files a/hecl-gui/quazip/doc/html/classQuaZipFile__coll__graph.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/classQuaZipPrivate-members.html b/hecl-gui/quazip/doc/html/classQuaZipPrivate-members.html deleted file mode 100644 index b1c64ef3b..000000000 --- a/hecl-gui/quazip/doc/html/classQuaZipPrivate-members.html +++ /dev/null @@ -1,54 +0,0 @@ - - - - -QuaZIP: Member List - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
-
-
QuaZipPrivate Member List
-
-
-This is the complete list of members for QuaZipPrivate, including all inherited members. - - - -
QuaZip (defined in QuaZipPrivate)QuaZipPrivate [friend]
unzFile_fQuaZipPrivate
zipFile_fQuaZipPrivate
- - - diff --git a/hecl-gui/quazip/doc/html/classQuaZipPrivate.html b/hecl-gui/quazip/doc/html/classQuaZipPrivate.html deleted file mode 100644 index 7163e451b..000000000 --- a/hecl-gui/quazip/doc/html/classQuaZipPrivate.html +++ /dev/null @@ -1,75 +0,0 @@ - - - - -QuaZIP: QuaZipPrivate Class Reference - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
- -
-
QuaZipPrivate Class Reference
-
-
- -

All the internal stuff for the QuaZip class. - More...

-
-Collaboration diagram for QuaZipPrivate:
-
-
Collaboration graph
- - -
[legend]
- -

List of all members.

- - - -

-Friends

-class QuaZip
-

Detailed Description

-

All the internal stuff for the QuaZip class.

-

The documentation for this class was generated from the following file:
    -
  • quazip/quazip.cpp
  • -
-
- - - diff --git a/hecl-gui/quazip/doc/html/classQuaZipPrivate__coll__graph.map b/hecl-gui/quazip/doc/html/classQuaZipPrivate__coll__graph.map deleted file mode 100644 index d16ce7576..000000000 --- a/hecl-gui/quazip/doc/html/classQuaZipPrivate__coll__graph.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/hecl-gui/quazip/doc/html/classQuaZipPrivate__coll__graph.md5 b/hecl-gui/quazip/doc/html/classQuaZipPrivate__coll__graph.md5 deleted file mode 100644 index a9687896c..000000000 --- a/hecl-gui/quazip/doc/html/classQuaZipPrivate__coll__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -4dadbc94c10e818b6d044a538076a620 \ No newline at end of file diff --git a/hecl-gui/quazip/doc/html/classQuaZipPrivate__coll__graph.png b/hecl-gui/quazip/doc/html/classQuaZipPrivate__coll__graph.png deleted file mode 100644 index 5caab7717..000000000 Binary files a/hecl-gui/quazip/doc/html/classQuaZipPrivate__coll__graph.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/classQuaZip__coll__graph.map b/hecl-gui/quazip/doc/html/classQuaZip__coll__graph.map deleted file mode 100644 index 1456b6a82..000000000 --- a/hecl-gui/quazip/doc/html/classQuaZip__coll__graph.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/hecl-gui/quazip/doc/html/classQuaZip__coll__graph.md5 b/hecl-gui/quazip/doc/html/classQuaZip__coll__graph.md5 deleted file mode 100644 index 37a82d470..000000000 --- a/hecl-gui/quazip/doc/html/classQuaZip__coll__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -d04fc6b476641932472c86fd8096968c \ No newline at end of file diff --git a/hecl-gui/quazip/doc/html/classQuaZip__coll__graph.png b/hecl-gui/quazip/doc/html/classQuaZip__coll__graph.png deleted file mode 100644 index b1e92817b..000000000 Binary files a/hecl-gui/quazip/doc/html/classQuaZip__coll__graph.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/classes.html b/hecl-gui/quazip/doc/html/classes.html deleted file mode 100644 index a885daf3d..000000000 --- a/hecl-gui/quazip/doc/html/classes.html +++ /dev/null @@ -1,55 +0,0 @@ - - - - -QuaZIP: Class Index - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
-
-
Class Index
-
-
-
J | Q
- -
  J  
-
QuaChecksum32   QuaZIODevice   QuaZipFile   QuaZipFilePrivate   
JlCompress   QuaCrc32   QuaZip   QuaZipFileInfo   QuaZipNewInfo   
  Q  
-
QuaGzipFile   QuaZipDir   QuaZipFileInfo64   QuaZipPrivate   
QuaAdler32   
J | Q
-
- - - diff --git a/hecl-gui/quazip/doc/html/closed.png b/hecl-gui/quazip/doc/html/closed.png deleted file mode 100644 index b7d4bd9fe..000000000 Binary files a/hecl-gui/quazip/doc/html/closed.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/dir_63f4af0f6084a51244f9f3a16a2e698d.html b/hecl-gui/quazip/doc/html/dir_63f4af0f6084a51244f9f3a16a2e698d.html deleted file mode 100644 index f34f5b917..000000000 --- a/hecl-gui/quazip/doc/html/dir_63f4af0f6084a51244f9f3a16a2e698d.html +++ /dev/null @@ -1,82 +0,0 @@ - - - - -QuaZIP: quazip/ Directory Reference - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
-
-
quazip Directory Reference
-
-
-
-Directory dependency graph for quazip/:
-
-
quazip/
- - -
- - - - - - - - - - - - - - - - - - - - - - - - - -

-Files

file  JlCompress.cpp
file  JlCompress.h [code]
file  qioapi.cpp
file  quaadler32.cpp
file  quaadler32.h [code]
file  quachecksum32.h [code]
file  quacrc32.cpp
file  quacrc32.h [code]
file  quagzipfile.cpp
file  quagzipfile.h [code]
file  quaziodevice.cpp
file  quaziodevice.h [code]
file  quazip.cpp
file  quazip.h [code]
file  quazip_global.h [code]
file  quazipdir.cpp
file  quazipdir.h [code]
file  quazipfile.cpp
file  quazipfile.h [code]
file  quazipfileinfo.cpp
file  quazipfileinfo.h [code]
file  quazipnewinfo.cpp
file  quazipnewinfo.h [code]
-
- - - diff --git a/hecl-gui/quazip/doc/html/dir_63f4af0f6084a51244f9f3a16a2e698d_dep.map b/hecl-gui/quazip/doc/html/dir_63f4af0f6084a51244f9f3a16a2e698d_dep.map deleted file mode 100644 index 19022927a..000000000 --- a/hecl-gui/quazip/doc/html/dir_63f4af0f6084a51244f9f3a16a2e698d_dep.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/hecl-gui/quazip/doc/html/dir_63f4af0f6084a51244f9f3a16a2e698d_dep.md5 b/hecl-gui/quazip/doc/html/dir_63f4af0f6084a51244f9f3a16a2e698d_dep.md5 deleted file mode 100644 index 987fe35a4..000000000 --- a/hecl-gui/quazip/doc/html/dir_63f4af0f6084a51244f9f3a16a2e698d_dep.md5 +++ /dev/null @@ -1 +0,0 @@ -68fb1d4fbd418e78b1d377097ebdf8bb \ No newline at end of file diff --git a/hecl-gui/quazip/doc/html/dir_63f4af0f6084a51244f9f3a16a2e698d_dep.png b/hecl-gui/quazip/doc/html/dir_63f4af0f6084a51244f9f3a16a2e698d_dep.png deleted file mode 100644 index f936aee94..000000000 Binary files a/hecl-gui/quazip/doc/html/dir_63f4af0f6084a51244f9f3a16a2e698d_dep.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/dirs.html b/hecl-gui/quazip/doc/html/dirs.html deleted file mode 100644 index 0d0c3bb21..000000000 --- a/hecl-gui/quazip/doc/html/dirs.html +++ /dev/null @@ -1,46 +0,0 @@ - - - - -QuaZIP: Directories - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- -
-
-
-
Directories
-
-
-
This directory hierarchy is sorted roughly, but not completely, alphabetically:
-
- - - diff --git a/hecl-gui/quazip/doc/html/doxygen.css b/hecl-gui/quazip/doc/html/doxygen.css deleted file mode 100644 index 74445fe1f..000000000 --- a/hecl-gui/quazip/doc/html/doxygen.css +++ /dev/null @@ -1,835 +0,0 @@ -/* The standard CSS for doxygen */ - -body, table, div, p, dl { - font-family: Lucida Grande, Verdana, Geneva, Arial, sans-serif; - font-size: 12px; -} - -/* @group Heading Levels */ - -h1 { - font-size: 150%; -} - -.title { - font-size: 150%; - font-weight: bold; - margin: 10px 2px; -} - -h2 { - font-size: 120%; -} - -h3 { - font-size: 100%; -} - -dt { - font-weight: bold; -} - -div.multicol { - -moz-column-gap: 1em; - -webkit-column-gap: 1em; - -moz-column-count: 3; - -webkit-column-count: 3; -} - -p.startli, p.startdd, p.starttd { - margin-top: 2px; -} - -p.endli { - margin-bottom: 0px; -} - -p.enddd { - margin-bottom: 4px; -} - -p.endtd { - margin-bottom: 2px; -} - -/* @end */ - -caption { - font-weight: bold; -} - -span.legend { - font-size: 70%; - text-align: center; -} - -h3.version { - font-size: 90%; - text-align: center; -} - -div.qindex, div.navtab{ - background-color: #EBEFF6; - border: 1px solid #A3B4D7; - text-align: center; - margin: 2px; - padding: 2px; -} - -div.qindex, div.navpath { - width: 100%; - line-height: 140%; -} - -div.navtab { - margin-right: 15px; -} - -/* @group Link Styling */ - -a { - color: #3D578C; - font-weight: normal; - text-decoration: none; -} - -.contents a:visited { - color: #4665A2; -} - -a:hover { - text-decoration: underline; -} - -a.qindex { - font-weight: bold; -} - -a.qindexHL { - font-weight: bold; - background-color: #9CAFD4; - color: #ffffff; - border: 1px double #869DCA; -} - -.contents a.qindexHL:visited { - color: #ffffff; -} - -a.el { - font-weight: bold; -} - -a.elRef { -} - -a.code { - color: #4665A2; -} - -a.codeRef { - color: #4665A2; -} - -/* @end */ - -dl.el { - margin-left: -1cm; -} - -.fragment { - font-family: monospace, fixed; - font-size: 105%; -} - -pre.fragment { - border: 1px solid #C4CFE5; - background-color: #FBFCFD; - padding: 4px 6px; - margin: 4px 8px 4px 2px; - overflow: auto; - word-wrap: break-word; - font-size: 9pt; - line-height: 125%; -} - -div.ah { - background-color: black; - font-weight: bold; - color: #ffffff; - margin-bottom: 3px; - margin-top: 3px; - padding: 0.2em; - border: solid thin #333; - border-radius: 0.5em; - -webkit-border-radius: .5em; - -moz-border-radius: .5em; - box-shadow: 2px 2px 3px #999; - -webkit-box-shadow: 2px 2px 3px #999; - -moz-box-shadow: rgba(0, 0, 0, 0.15) 2px 2px 2px; - background-image: -webkit-gradient(linear, left top, left bottom, from(#eee), to(#000),color-stop(0.3, #444)); - background-image: -moz-linear-gradient(center top, #eee 0%, #444 40%, #000); -} - -div.groupHeader { - margin-left: 16px; - margin-top: 12px; - font-weight: bold; -} - -div.groupText { - margin-left: 16px; - font-style: italic; -} - -body { - background: white; - color: black; - margin: 0; -} - -div.contents { - margin-top: 10px; - margin-left: 10px; - margin-right: 5px; -} - -td.indexkey { - background-color: #EBEFF6; - font-weight: bold; - border: 1px solid #C4CFE5; - margin: 2px 0px 2px 0; - padding: 2px 10px; -} - -td.indexvalue { - background-color: #EBEFF6; - border: 1px solid #C4CFE5; - padding: 2px 10px; - margin: 2px 0px; -} - -tr.memlist { - background-color: #EEF1F7; -} - -p.formulaDsp { - text-align: center; -} - -img.formulaDsp { - -} - -img.formulaInl { - vertical-align: middle; -} - -div.center { - text-align: center; - margin-top: 0px; - margin-bottom: 0px; - padding: 0px; -} - -div.center img { - border: 0px; -} - -address.footer { - text-align: right; - padding-right: 12px; -} - -img.footer { - border: 0px; - vertical-align: middle; -} - -/* @group Code Colorization */ - -span.keyword { - color: #008000 -} - -span.keywordtype { - color: #604020 -} - -span.keywordflow { - color: #e08000 -} - -span.comment { - color: #800000 -} - -span.preprocessor { - color: #806020 -} - -span.stringliteral { - color: #002080 -} - -span.charliteral { - color: #008080 -} - -span.vhdldigit { - color: #ff00ff -} - -span.vhdlchar { - color: #000000 -} - -span.vhdlkeyword { - color: #700070 -} - -span.vhdllogic { - color: #ff0000 -} - -/* @end */ - -/* -.search { - color: #003399; - font-weight: bold; -} - -form.search { - margin-bottom: 0px; - margin-top: 0px; -} - -input.search { - font-size: 75%; - color: #000080; - font-weight: normal; - background-color: #e8eef2; -} -*/ - -td.tiny { - font-size: 75%; -} - -.dirtab { - padding: 4px; - border-collapse: collapse; - border: 1px solid #A3B4D7; -} - -th.dirtab { - background: #EBEFF6; - font-weight: bold; -} - -hr { - height: 0px; - border: none; - border-top: 1px solid #4A6AAA; -} - -hr.footer { - height: 1px; -} - -/* @group Member Descriptions */ - -table.memberdecls { - border-spacing: 0px; - padding: 0px; -} - -.mdescLeft, .mdescRight, -.memItemLeft, .memItemRight, -.memTemplItemLeft, .memTemplItemRight, .memTemplParams { - background-color: #F9FAFC; - border: none; - margin: 4px; - padding: 1px 0 0 8px; -} - -.mdescLeft, .mdescRight { - padding: 0px 8px 4px 8px; - color: #555; -} - -.memItemLeft, .memItemRight, .memTemplParams { - border-top: 1px solid #C4CFE5; -} - -.memItemLeft, .memTemplItemLeft { - white-space: nowrap; -} - -.memItemRight { - width: 100%; -} - -.memTemplParams { - color: #4665A2; - white-space: nowrap; -} - -/* @end */ - -/* @group Member Details */ - -/* Styles for detailed member documentation */ - -.memtemplate { - font-size: 80%; - color: #4665A2; - font-weight: normal; - margin-left: 9px; -} - -.memnav { - background-color: #EBEFF6; - border: 1px solid #A3B4D7; - text-align: center; - margin: 2px; - margin-right: 15px; - padding: 2px; -} - -.mempage { - width: 100%; -} - -.memitem { - padding: 0; - margin-bottom: 10px; - margin-right: 5px; -} - -.memname { - white-space: nowrap; - font-weight: bold; - margin-left: 6px; -} - -.memproto { - border-top: 1px solid #A8B8D9; - border-left: 1px solid #A8B8D9; - border-right: 1px solid #A8B8D9; - padding: 6px 0px 6px 0px; - color: #253555; - font-weight: bold; - text-shadow: 0px 1px 1px rgba(255, 255, 255, 0.9); - /* opera specific markup */ - box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); - border-top-right-radius: 8px; - border-top-left-radius: 8px; - /* firefox specific markup */ - -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px; - -moz-border-radius-topright: 8px; - -moz-border-radius-topleft: 8px; - /* webkit specific markup */ - -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); - -webkit-border-top-right-radius: 8px; - -webkit-border-top-left-radius: 8px; - background-image:url('nav_f.png'); - background-repeat:repeat-x; - background-color: #E2E8F2; - -} - -.memdoc { - border-bottom: 1px solid #A8B8D9; - border-left: 1px solid #A8B8D9; - border-right: 1px solid #A8B8D9; - padding: 2px 5px; - background-color: #FBFCFD; - border-top-width: 0; - /* opera specific markup */ - border-bottom-left-radius: 8px; - border-bottom-right-radius: 8px; - box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); - /* firefox specific markup */ - -moz-border-radius-bottomleft: 8px; - -moz-border-radius-bottomright: 8px; - -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px; - background-image: -moz-linear-gradient(center top, #FFFFFF 0%, #FFFFFF 60%, #F7F8FB 95%, #EEF1F7); - /* webkit specific markup */ - -webkit-border-bottom-left-radius: 8px; - -webkit-border-bottom-right-radius: 8px; - -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); - background-image: -webkit-gradient(linear,center top,center bottom,from(#FFFFFF), color-stop(0.6,#FFFFFF), color-stop(0.60,#FFFFFF), color-stop(0.95,#F7F8FB), to(#EEF1F7)); -} - -.paramkey { - text-align: right; -} - -.paramtype { - white-space: nowrap; -} - -.paramname { - color: #602020; - white-space: nowrap; -} -.paramname em { - font-style: normal; -} - -.params, .retval, .exception, .tparams { - border-spacing: 6px 2px; -} - -.params .paramname, .retval .paramname { - font-weight: bold; - vertical-align: top; -} - -.params .paramtype { - font-style: italic; - vertical-align: top; -} - -.params .paramdir { - font-family: "courier new",courier,monospace; - vertical-align: top; -} - - - - -/* @end */ - -/* @group Directory (tree) */ - -/* for the tree view */ - -.ftvtree { - font-family: sans-serif; - margin: 0px; -} - -/* these are for tree view when used as main index */ - -.directory { - font-size: 9pt; - font-weight: bold; - margin: 5px; -} - -.directory h3 { - margin: 0px; - margin-top: 1em; - font-size: 11pt; -} - -/* -The following two styles can be used to replace the root node title -with an image of your choice. Simply uncomment the next two styles, -specify the name of your image and be sure to set 'height' to the -proper pixel height of your image. -*/ - -/* -.directory h3.swap { - height: 61px; - background-repeat: no-repeat; - background-image: url("yourimage.gif"); -} -.directory h3.swap span { - display: none; -} -*/ - -.directory > h3 { - margin-top: 0; -} - -.directory p { - margin: 0px; - white-space: nowrap; -} - -.directory div { - display: none; - margin: 0px; -} - -.directory img { - vertical-align: -30%; -} - -/* these are for tree view when not used as main index */ - -.directory-alt { - font-size: 100%; - font-weight: bold; -} - -.directory-alt h3 { - margin: 0px; - margin-top: 1em; - font-size: 11pt; -} - -.directory-alt > h3 { - margin-top: 0; -} - -.directory-alt p { - margin: 0px; - white-space: nowrap; -} - -.directory-alt div { - display: none; - margin: 0px; -} - -.directory-alt img { - vertical-align: -30%; -} - -/* @end */ - -div.dynheader { - margin-top: 8px; -} - -address { - font-style: normal; - color: #2A3D61; -} - -table.doxtable { - border-collapse:collapse; -} - -table.doxtable td, table.doxtable th { - border: 1px solid #2D4068; - padding: 3px 7px 2px; -} - -table.doxtable th { - background-color: #374F7F; - color: #FFFFFF; - font-size: 110%; - padding-bottom: 4px; - padding-top: 5px; - text-align:left; -} - -.tabsearch { - top: 0px; - left: 10px; - height: 36px; - background-image: url('tab_b.png'); - z-index: 101; - overflow: hidden; - font-size: 13px; -} - -.navpath ul -{ - font-size: 11px; - background-image:url('tab_b.png'); - background-repeat:repeat-x; - height:30px; - line-height:30px; - color:#8AA0CC; - border:solid 1px #C2CDE4; - overflow:hidden; - margin:0px; - padding:0px; -} - -.navpath li -{ - list-style-type:none; - float:left; - padding-left:10px; - padding-right:15px; - background-image:url('bc_s.png'); - background-repeat:no-repeat; - background-position:right; - color:#364D7C; -} - -.navpath li.navelem a -{ - height:32px; - display:block; - text-decoration: none; - outline: none; -} - -.navpath li.navelem a:hover -{ - color:#6884BD; -} - -.navpath li.footer -{ - list-style-type:none; - float:right; - padding-left:10px; - padding-right:15px; - background-image:none; - background-repeat:no-repeat; - background-position:right; - color:#364D7C; - font-size: 8pt; -} - - -div.summary -{ - float: right; - font-size: 8pt; - padding-right: 5px; - width: 50%; - text-align: right; -} - -div.summary a -{ - white-space: nowrap; -} - -div.ingroups -{ - font-size: 8pt; - padding-left: 5px; - width: 50%; - text-align: left; -} - -div.ingroups a -{ - white-space: nowrap; -} - -div.header -{ - background-image:url('nav_h.png'); - background-repeat:repeat-x; - background-color: #F9FAFC; - margin: 0px; - border-bottom: 1px solid #C4CFE5; -} - -div.headertitle -{ - padding: 5px 5px 5px 10px; -} - -dl -{ - padding: 0 0 0 10px; -} - -dl.note, dl.warning, dl.attention, dl.pre, dl.post, dl.invariant, dl.deprecated, dl.todo, dl.test, dl.bug -{ - border-left:4px solid; - padding: 0 0 0 6px; -} - -dl.note -{ - border-color: #D0C000; -} - -dl.warning, dl.attention -{ - border-color: #FF0000; -} - -dl.pre, dl.post, dl.invariant -{ - border-color: #00D000; -} - -dl.deprecated -{ - border-color: #505050; -} - -dl.todo -{ - border-color: #00C0E0; -} - -dl.test -{ - border-color: #3030E0; -} - -dl.bug -{ - border-color: #C08050; -} - -#projectlogo -{ - text-align: center; - vertical-align: bottom; - border-collapse: separate; -} - -#projectlogo img -{ - border: 0px none; -} - -#projectname -{ - font: 300% Tahoma, Arial,sans-serif; - margin: 0px; - padding: 2px 0px; -} - -#projectbrief -{ - font: 120% Tahoma, Arial,sans-serif; - margin: 0px; - padding: 0px; -} - -#projectnumber -{ - font: 50% Tahoma, Arial,sans-serif; - margin: 0px; - padding: 0px; -} - -#titlearea -{ - padding: 0px; - margin: 0px; - width: 100%; - border-bottom: 1px solid #5373B4; -} - -.image -{ - text-align: center; -} - -.dotgraph -{ - text-align: center; -} - -.mscgraph -{ - text-align: center; -} - -.caption -{ - font-weight: bold; -} - diff --git a/hecl-gui/quazip/doc/html/doxygen.png b/hecl-gui/quazip/doc/html/doxygen.png deleted file mode 100644 index 635ed52fc..000000000 Binary files a/hecl-gui/quazip/doc/html/doxygen.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/faq.html b/hecl-gui/quazip/doc/html/faq.html deleted file mode 100644 index a9d7709ae..000000000 --- a/hecl-gui/quazip/doc/html/faq.html +++ /dev/null @@ -1,49 +0,0 @@ - - - - -QuaZIP: QuaZip FAQ - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- -
-
-
-
QuaZip FAQ
-
-
-

Q. Is there any way to use QuaZipFile in Qt where you are supposed to use normal (non-zipped) file, but not through QIODevice API?

-

A. Usually not. For example, if you are passing file name to some database driver (like SQLite), Qt usually just passes this name down to the 3rd-party library, which is usually does not know anything about QIODevice and therefore there is no way to pass QuaZipFile as normal file. However, if we are talking about some place where you pass file name, and then indirectly use QFile to open it, then it is a good idea to make overloaded method, which accepts a QIODevice pointer. Then you would be able to pass QuaZipFile as well as many other nice things such as QBuffer or QProcess.

-

Q. Can QuaZIP handle files larger than 4GB? What about zip64 standard?

-

A. Starting with version 0.6, QuaZIP uses Minizip 1.1 with zip64 support which should handle large files perfectly. The zip64 support in Minizip looks like it's not 100% conforming to the standard, but 3rd party tools seem to have no problem with the resulting archives.

-

Q. Can QuaZIP write archives to a sequential QIODevice like QTcpSocket?

-

A. Not yet. It is not supported by vanilla Minizip (the back-end QuaZIP uses), although theoretically possible according to the ZIP standard. It would require some Minizip modifications that would allow it to detect non-seekable I/O and produce necessary output structures. QuaZIP already writes data descriptor which is necessary for non-seekable I/O. The only thing that is apparently left is to make Minizip fill local headers with correct values and forget about seeking after closing the file.

-
- - - diff --git a/hecl-gui/quazip/doc/html/files.html b/hecl-gui/quazip/doc/html/files.html deleted file mode 100644 index 2c464cb52..000000000 --- a/hecl-gui/quazip/doc/html/files.html +++ /dev/null @@ -1,62 +0,0 @@ - - - - -QuaZIP: File List - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
-
-
File List
-
-
-
Here is a list of all documented files with brief descriptions:
- - - - - - - - - - - - -
quazip/JlCompress.h [code]
quazip/quaadler32.h [code]
quazip/quachecksum32.h [code]
quazip/quacrc32.h [code]
quazip/quagzipfile.h [code]
quazip/quaziodevice.h [code]
quazip/quazip.h [code]
quazip/quazip_global.h [code]
quazip/quazipdir.h [code]
quazip/quazipfile.h [code]
quazip/quazipfileinfo.h [code]
quazip/quazipnewinfo.h [code]
-
- - - diff --git a/hecl-gui/quazip/doc/html/functions.html b/hecl-gui/quazip/doc/html/functions.html deleted file mode 100644 index 4f1884ddb..000000000 --- a/hecl-gui/quazip/doc/html/functions.html +++ /dev/null @@ -1,88 +0,0 @@ - - - - -QuaZIP: Class Members - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-
Here is a list of all documented class members with links to the class documentation for each member:
- -

- a -

-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_0x62.html b/hecl-gui/quazip/doc/html/functions_0x62.html deleted file mode 100644 index f0d0f1c8e..000000000 --- a/hecl-gui/quazip/doc/html/functions_0x62.html +++ /dev/null @@ -1,88 +0,0 @@ - - - - -QuaZIP: Class Members - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-
Here is a list of all documented class members with links to the class documentation for each member:
- -

- b -

-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_0x63.html b/hecl-gui/quazip/doc/html/functions_0x63.html deleted file mode 100644 index e2946183c..000000000 --- a/hecl-gui/quazip/doc/html/functions_0x63.html +++ /dev/null @@ -1,151 +0,0 @@ - - - - -QuaZIP: Class Members - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-
Here is a list of all documented class members with links to the class documentation for each member:
- -

- c -

-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_0x64.html b/hecl-gui/quazip/doc/html/functions_0x64.html deleted file mode 100644 index 92118f5c6..000000000 --- a/hecl-gui/quazip/doc/html/functions_0x64.html +++ /dev/null @@ -1,97 +0,0 @@ - - - - -QuaZIP: Class Members - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-
Here is a list of all documented class members with links to the class documentation for each member:
- -

- d -

-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_0x65.html b/hecl-gui/quazip/doc/html/functions_0x65.html deleted file mode 100644 index 4f9fe68c1..000000000 --- a/hecl-gui/quazip/doc/html/functions_0x65.html +++ /dev/null @@ -1,121 +0,0 @@ - - - - -QuaZIP: Class Members - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-
Here is a list of all documented class members with links to the class documentation for each member:
- -

- e -

-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_0x66.html b/hecl-gui/quazip/doc/html/functions_0x66.html deleted file mode 100644 index bf354753c..000000000 --- a/hecl-gui/quazip/doc/html/functions_0x66.html +++ /dev/null @@ -1,99 +0,0 @@ - - - - -QuaZIP: Class Members - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-
Here is a list of all documented class members with links to the class documentation for each member:
- -

- f -

-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_0x67.html b/hecl-gui/quazip/doc/html/functions_0x67.html deleted file mode 100644 index 9cad087f2..000000000 --- a/hecl-gui/quazip/doc/html/functions_0x67.html +++ /dev/null @@ -1,171 +0,0 @@ - - - - -QuaZIP: Class Members - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-
Here is a list of all documented class members with links to the class documentation for each member:
- -

- g -

-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_0x68.html b/hecl-gui/quazip/doc/html/functions_0x68.html deleted file mode 100644 index 922f47711..000000000 --- a/hecl-gui/quazip/doc/html/functions_0x68.html +++ /dev/null @@ -1,88 +0,0 @@ - - - - -QuaZIP: Class Members - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-
Here is a list of all documented class members with links to the class documentation for each member:
- -

- h -

    -
  • hasCurrentFile() -: QuaZip -
  • -
-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_0x69.html b/hecl-gui/quazip/doc/html/functions_0x69.html deleted file mode 100644 index cfef39444..000000000 --- a/hecl-gui/quazip/doc/html/functions_0x69.html +++ /dev/null @@ -1,113 +0,0 @@ - - - - -QuaZIP: Class Members - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-
Here is a list of all documented class members with links to the class documentation for each member:
- -

- i -

-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_0x6d.html b/hecl-gui/quazip/doc/html/functions_0x6d.html deleted file mode 100644 index 84d046ac1..000000000 --- a/hecl-gui/quazip/doc/html/functions_0x6d.html +++ /dev/null @@ -1,110 +0,0 @@ - - - - -QuaZIP: Class Members - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-
Here is a list of all documented class members with links to the class documentation for each member:
- -

- m -

-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_0x6e.html b/hecl-gui/quazip/doc/html/functions_0x6e.html deleted file mode 100644 index e8115d476..000000000 --- a/hecl-gui/quazip/doc/html/functions_0x6e.html +++ /dev/null @@ -1,93 +0,0 @@ - - - - -QuaZIP: Class Members - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-
Here is a list of all documented class members with links to the class documentation for each member:
- -

- n -

-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_0x6f.html b/hecl-gui/quazip/doc/html/functions_0x6f.html deleted file mode 100644 index eba831b8e..000000000 --- a/hecl-gui/quazip/doc/html/functions_0x6f.html +++ /dev/null @@ -1,104 +0,0 @@ - - - - -QuaZIP: Class Members - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-
Here is a list of all documented class members with links to the class documentation for each member:
- -

- o -

-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_0x70.html b/hecl-gui/quazip/doc/html/functions_0x70.html deleted file mode 100644 index e489b9316..000000000 --- a/hecl-gui/quazip/doc/html/functions_0x70.html +++ /dev/null @@ -1,91 +0,0 @@ - - - - -QuaZIP: Class Members - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-
Here is a list of all documented class members with links to the class documentation for each member:
- -

- p -

-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_0x71.html b/hecl-gui/quazip/doc/html/functions_0x71.html deleted file mode 100644 index 8375a6f78..000000000 --- a/hecl-gui/quazip/doc/html/functions_0x71.html +++ /dev/null @@ -1,103 +0,0 @@ - - - - -QuaZIP: Class Members - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-
Here is a list of all documented class members with links to the class documentation for each member:
- -

- q -

-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_0x72.html b/hecl-gui/quazip/doc/html/functions_0x72.html deleted file mode 100644 index d1d94cabf..000000000 --- a/hecl-gui/quazip/doc/html/functions_0x72.html +++ /dev/null @@ -1,98 +0,0 @@ - - - - -QuaZIP: Class Members - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-
Here is a list of all documented class members with links to the class documentation for each member:
- -

- r -

-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_0x73.html b/hecl-gui/quazip/doc/html/functions_0x73.html deleted file mode 100644 index b7d086ca9..000000000 --- a/hecl-gui/quazip/doc/html/functions_0x73.html +++ /dev/null @@ -1,165 +0,0 @@ - - - - -QuaZIP: Class Members - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-
Here is a list of all documented class members with links to the class documentation for each member:
- -

- s -

-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_0x74.html b/hecl-gui/quazip/doc/html/functions_0x74.html deleted file mode 100644 index ff40d6e64..000000000 --- a/hecl-gui/quazip/doc/html/functions_0x74.html +++ /dev/null @@ -1,88 +0,0 @@ - - - - -QuaZIP: Class Members - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-
Here is a list of all documented class members with links to the class documentation for each member:
- -

- t -

-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_0x75.html b/hecl-gui/quazip/doc/html/functions_0x75.html deleted file mode 100644 index 58cab1cb8..000000000 --- a/hecl-gui/quazip/doc/html/functions_0x75.html +++ /dev/null @@ -1,101 +0,0 @@ - - - - -QuaZIP: Class Members - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-
Here is a list of all documented class members with links to the class documentation for each member:
- -

- u -

-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_0x76.html b/hecl-gui/quazip/doc/html/functions_0x76.html deleted file mode 100644 index 4a64845aa..000000000 --- a/hecl-gui/quazip/doc/html/functions_0x76.html +++ /dev/null @@ -1,98 +0,0 @@ - - - - -QuaZIP: Class Members - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-
Here is a list of all documented class members with links to the class documentation for each member:
- -

- v -

-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_0x77.html b/hecl-gui/quazip/doc/html/functions_0x77.html deleted file mode 100644 index 3ad3341bf..000000000 --- a/hecl-gui/quazip/doc/html/functions_0x77.html +++ /dev/null @@ -1,90 +0,0 @@ - - - - -QuaZIP: Class Members - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-
Here is a list of all documented class members with links to the class documentation for each member:
- -

- w -

-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_0x7a.html b/hecl-gui/quazip/doc/html/functions_0x7a.html deleted file mode 100644 index 2c7c1b404..000000000 --- a/hecl-gui/quazip/doc/html/functions_0x7a.html +++ /dev/null @@ -1,88 +0,0 @@ - - - - -QuaZIP: Class Members - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-
Here is a list of all documented class members with links to the class documentation for each member:
- -

- z -

-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_0x7e.html b/hecl-gui/quazip/doc/html/functions_0x7e.html deleted file mode 100644 index 5f103cb77..000000000 --- a/hecl-gui/quazip/doc/html/functions_0x7e.html +++ /dev/null @@ -1,100 +0,0 @@ - - - - -QuaZIP: Class Members - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-
Here is a list of all documented class members with links to the class documentation for each member:
- -

- ~ -

-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_enum.html b/hecl-gui/quazip/doc/html/functions_enum.html deleted file mode 100644 index 3c3b7c324..000000000 --- a/hecl-gui/quazip/doc/html/functions_enum.html +++ /dev/null @@ -1,66 +0,0 @@ - - - - -QuaZIP: Class Members - Enumerations - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - -
-
-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_eval.html b/hecl-gui/quazip/doc/html/functions_eval.html deleted file mode 100644 index 4b2999b38..000000000 --- a/hecl-gui/quazip/doc/html/functions_eval.html +++ /dev/null @@ -1,84 +0,0 @@ - - - - -QuaZIP: Class Members - Enumerator - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - -
-
-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_func.html b/hecl-gui/quazip/doc/html/functions_func.html deleted file mode 100644 index 78be91cf1..000000000 --- a/hecl-gui/quazip/doc/html/functions_func.html +++ /dev/null @@ -1,524 +0,0 @@ - - - - -QuaZIP: Class Members - Functions - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-  - -

- a -

- - -

- b -

- - -

- c -

- - -

- d -

- - -

- e -

- - -

- f -

- - -

- g -

- - -

- h -

    -
  • hasCurrentFile() -: QuaZip -
  • -
- - -

- i -

- - -

- n -

- - -

- o -

- - -

- p -

- - -

- q -

- - -

- r -

- - -

- s -

- - -

- t -

- - -

- u -

- - -

- v -

- - -

- w -

- - -

- ~ -

-
- - - diff --git a/hecl-gui/quazip/doc/html/functions_vars.html b/hecl-gui/quazip/doc/html/functions_vars.html deleted file mode 100644 index 2eca617dc..000000000 --- a/hecl-gui/quazip/doc/html/functions_vars.html +++ /dev/null @@ -1,183 +0,0 @@ - - - - -QuaZIP: Class Members - Variables - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - - -
-
-  - -

- c -

- - -

- d -

- - -

- e -

- - -

- f -

- - -

- i -

- - -

- m -

- - -

- n -

- - -

- u -

- - -

- v -

- - -

- z -

-
- - - diff --git a/hecl-gui/quazip/doc/html/graph_legend.html b/hecl-gui/quazip/doc/html/graph_legend.html deleted file mode 100644 index 248efee37..000000000 --- a/hecl-gui/quazip/doc/html/graph_legend.html +++ /dev/null @@ -1,107 +0,0 @@ - - - - -QuaZIP: Graph Legend - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- -
-
-
-
Graph Legend
-
-
-

This page explains how to interpret the graphs that are generated by doxygen.

-

Consider the following example:

-
/*! Invisible class because of truncation */
-class Invisible { };
-
-/*! Truncated class, inheritance relation is hidden */
-class Truncated : public Invisible { };
-
-/* Class not documented with doxygen comments */
-class Undocumented { };
-
-/*! Class that is inherited using public inheritance */
-class PublicBase : public Truncated { };
-
-/*! A template class */
-template<class T> class Templ { };
-
-/*! Class that is inherited using protected inheritance */
-class ProtectedBase { };
-
-/*! Class that is inherited using private inheritance */
-class PrivateBase { };
-
-/*! Class that is used by the Inherited class */
-class Used { };
-
-/*! Super class that inherits a number of other classes */
-class Inherited : public PublicBase,
-                  protected ProtectedBase,
-                  private PrivateBase,
-                  public Undocumented,
-                  public Templ<int>
-{
-  private:
-    Used *m_usedClass;
-};
-

This will result in the following graph:

-
-graph_legend.png -
-

The boxes in the above graph have the following meaning:

-
    -
  • -A filled gray box represents the struct or class for which the graph is generated.
  • -
  • -A box with a black border denotes a documented struct or class.
  • -
  • -A box with a grey border denotes an undocumented struct or class.
  • -
  • -A box with a red border denotes a documented struct or class forwhich not all inheritance/containment relations are shown. A graph is truncated if it does not fit within the specified boundaries.
  • -
-

The arrows have the following meaning:

-
    -
  • -A dark blue arrow is used to visualize a public inheritance relation between two classes.
  • -
  • -A dark green arrow is used for protected inheritance.
  • -
  • -A dark red arrow is used for private inheritance.
  • -
  • -A purple dashed arrow is used if a class is contained or used by another class. The arrow is labeled with the variable(s) through which the pointed class or struct is accessible.
  • -
  • -A yellow dashed arrow denotes a relation between a template instance and the template class it was instantiated from. The arrow is labeled with the template parameters of the instance.
  • -
-
- - - diff --git a/hecl-gui/quazip/doc/html/graph_legend.md5 b/hecl-gui/quazip/doc/html/graph_legend.md5 deleted file mode 100644 index 9d509f350..000000000 --- a/hecl-gui/quazip/doc/html/graph_legend.md5 +++ /dev/null @@ -1 +0,0 @@ -9fbb782f23f919c0064b8f454a56ede8 \ No newline at end of file diff --git a/hecl-gui/quazip/doc/html/graph_legend.png b/hecl-gui/quazip/doc/html/graph_legend.png deleted file mode 100644 index 3e9f9b16c..000000000 Binary files a/hecl-gui/quazip/doc/html/graph_legend.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/hierarchy.html b/hecl-gui/quazip/doc/html/hierarchy.html deleted file mode 100644 index e6e95c7ba..000000000 --- a/hecl-gui/quazip/doc/html/hierarchy.html +++ /dev/null @@ -1,70 +0,0 @@ - - - - -QuaZIP: Class Hierarchy - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
-
-
Class Hierarchy
-
- - - - diff --git a/hecl-gui/quazip/doc/html/index.html b/hecl-gui/quazip/doc/html/index.html deleted file mode 100644 index 16a9bffd9..000000000 --- a/hecl-gui/quazip/doc/html/index.html +++ /dev/null @@ -1,125 +0,0 @@ - - - - -QuaZIP: QuaZIP - Qt/C++ wrapper for ZIP/UNZIP package - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- -
-
-
-
QuaZIP - Qt/C++ wrapper for ZIP/UNZIP package
-
-
-
-Powered by SourceForge.net -

-Overview

-

QuaZIP is a simple C++ wrapper over Gilles Vollant's ZIP/UNZIP package that can be used to access ZIP archives. It uses the Qt toolkit.

-

If you do not know what Qt is, you have two options:

- -

The choice is yours, but if you are really interested in cross-platform (Windows/Linux/BSD/UNIX/Mac/Others) software development, I would definitely recommend you the latter ^_^

-

QuaZIP allows you to access files inside ZIP archives using QIODevice API, and - yes! - that means that you can also use QTextStream, QDataStream or whatever you would like to use on your zipped files.

-

QuaZIP provides complete abstraction of the ZIP/UNZIP API, for both reading from and writing to ZIP archives.

-

-Download QuaZIP

-

Downloads are available from QuaZIP project's page at SourceForge.net.

-

-Platforms supported

-

QuaZIP has been currently tested on the following platforms:

-
    -
  • linux-g++ (Ubuntu 11.10, Qt 4.7.4)
  • -
  • freebsd-g++ (Qt 4.0.0
  • -
  • hpux-acc (HP-UX 11.11)
  • -
  • hpux-g++ (HP-UX 11.11)
  • -
  • win32-g++ (MinGW)
  • -
  • win32-msvc2010 (MS VS 2010 Express, Qt 4.8.4)
  • -
  • win32-msvc2010 (Qt Creator, Qt 5.0.1)
  • -
  • win32-msvc2012 (Qt Creator, Qt 5.2.0)
  • -
  • some Symbian version, reportedly
  • -
-

No testing has been officially done on other systems. Of course, patches to make it work on any platform that it currently does not work on are always welcome!

-

-What is new in this version of QuaZIP?

-

See the NEWS.txt file supplied with the distribution.

-

-Requirements

-

Just zlib and Qt 4/5. Well, Qt 4 depends on zlib anyway, but you will need zlib headers to compile QuaZIP. With Qt5 sometimes you need the zlib library as well (on Windows, for example).

-

-Building, testing and installing

-
Note:
Instructions given in this section assume that you are using some UNIX dialect, but the build process should be very similar on win32-g++ platform too. On other platforms it's essentially the same process, maybe with some qmake adjustments not specific to QuaZIP itself.
-

To build the library, run:

-
-$ cd /wherever/quazip/source/is/quazip-x.y.z/quazip
-$ qmake [PREFIX=where-to-install]
-$ make
-

Make sure that you have Qt 4/5 installed with all required headers and utilities (that is, including the 'dev' or 'devel' package on Linux) and that you run qmake utility of the Qt 4, not some other version you may have already installed (you may need to type full path to qmake like /usr/local/qt4/bin/qmake).

-

To reconfigure (with another PREFIX, for example), just run qmake with appropriate arguments again.

-

If you need to specify additional include path or libraries, use qmake features (see qmake reference in the Qt documentation). For example:

-
-$ qmake LIBS+=-L/usr/local/zlib/lib INCLUDEPATH+=/usr/local/zlib/include
-

(note abscence of "-I" before the include path and the presence of "-L" before the lib path)

-

Also note that you may or may not need to define ZLIB_WINAPI (qmake DEFINES+=ZLIB_WINAPI) when linking to zlib on Windows, depending on how zlib was built (generally, if using zlibwapi.dll, this define is needed).

-

To install compiled library:

-
-$ make install
-

By default, QuaZIP compiles as a DLL/SO, but you have other options:

-
    -
  • Just copy appropriate source files to your project and use them, but you need to define QUAZIP_STATIC before including any QuaZIP headers (best done as a compiler option). This will save you from possible side effects of importing/exporting QuaZIP symbols.
  • -
  • Compile it as a static library using CONFIG += staticlib qmake option. QUAZIP_STATIC is defined automatically by qmake in this case.
  • -
-

Binary compatibility is guaranteed between minor releases starting with version 0.5, thanks to the Pimpl idiom. That is, the next binary incompatible version will be 1.x.

-

-Testing

-

To check if QuaZIP's basic features work OK on your platform, you may wish to compile the test suite provided in test directory:

-
-$ cd /wherever/quazip/source/is/quazip-x.y.z/qztest
-$ qmake
-$ make
-$ ./qztest
-

Note that the test suite looks for the quazip library in the "quazip" folder of the project ("../quazip"), but you may wish to use LIBS for some systems (Windows often puts the library in the separate "debug" or "release" directory). If you wish to use the quazip version that's already installed, provide the appropriate path.

-

On some systems you may need to set PATH, LD_LIBRARY_PATH or SHLIB_PATH to get "qztest" to actually run.

-

If everything went fine, the test suite should report a lot of PASS messages. If something goes wrong, it will provide details and a warning that some tests failed.

-

-Using

-

See usage page.

-

-Authors and contacts

-

This wrapper has been written by Sergey A. Tachenov, AKA Alqualos. This is my first open source project, so it may suck, but I did not find anything like that, so I just had no other choice but to write it.

-

If you have anything to say to me about QuaZIP library, feel free to do so (read the QuaZip FAQ first, though). I can not promise, though, that I fix all the bugs you report in, add any features you want, or respond to your critics, or respond to your feedback at all. I may be busy, I may be tired of working on QuaZIP, I may be even dead already (you never know...).

-

To report bugs or to post ideas about what should be done, use SourceForge.net's trackers. If you want to send me a private message, use my e-mail address stachenov@gmail.com.

-

Do not use e-mail to report bugs, please. Reporting bugs and problems with the SourceForge.net's bug report system has that advantage that it is visible to public, and I can always search for open tickets that were created long ago. It is highly unlikely that I will search my mail for that kind of stuff, so if a bug reported by mail isn't fixed immediately, it will likely be forgotten forever.

-

Copyright (C) 2005-2014 Sergey A. Tachenov and contributors

-
- - - diff --git a/hecl-gui/quazip/doc/html/inherit_graph_0.map b/hecl-gui/quazip/doc/html/inherit_graph_0.map deleted file mode 100644 index 628f8d939..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_0.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/hecl-gui/quazip/doc/html/inherit_graph_0.md5 b/hecl-gui/quazip/doc/html/inherit_graph_0.md5 deleted file mode 100644 index d192be4bd..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_0.md5 +++ /dev/null @@ -1 +0,0 @@ -87c0f0d7a3432462cbd094e7c615e18e \ No newline at end of file diff --git a/hecl-gui/quazip/doc/html/inherit_graph_0.png b/hecl-gui/quazip/doc/html/inherit_graph_0.png deleted file mode 100644 index cc96c9541..000000000 Binary files a/hecl-gui/quazip/doc/html/inherit_graph_0.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/inherit_graph_1.map b/hecl-gui/quazip/doc/html/inherit_graph_1.map deleted file mode 100644 index 423d2ed85..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_1.map +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/hecl-gui/quazip/doc/html/inherit_graph_1.md5 b/hecl-gui/quazip/doc/html/inherit_graph_1.md5 deleted file mode 100644 index 49b2a6185..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_1.md5 +++ /dev/null @@ -1 +0,0 @@ -521dc5609a23895b8a3757ffc576f343 \ No newline at end of file diff --git a/hecl-gui/quazip/doc/html/inherit_graph_1.png b/hecl-gui/quazip/doc/html/inherit_graph_1.png deleted file mode 100644 index b4aeb786b..000000000 Binary files a/hecl-gui/quazip/doc/html/inherit_graph_1.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/inherit_graph_10.map b/hecl-gui/quazip/doc/html/inherit_graph_10.map deleted file mode 100644 index 45faadd37..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_10.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/hecl-gui/quazip/doc/html/inherit_graph_10.md5 b/hecl-gui/quazip/doc/html/inherit_graph_10.md5 deleted file mode 100644 index 80f63f526..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_10.md5 +++ /dev/null @@ -1 +0,0 @@ -2fed9c540a17c647243104aeda47c683 \ No newline at end of file diff --git a/hecl-gui/quazip/doc/html/inherit_graph_10.png b/hecl-gui/quazip/doc/html/inherit_graph_10.png deleted file mode 100644 index 3d89b2fe5..000000000 Binary files a/hecl-gui/quazip/doc/html/inherit_graph_10.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/inherit_graph_11.map b/hecl-gui/quazip/doc/html/inherit_graph_11.map deleted file mode 100644 index 1f8549872..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_11.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/hecl-gui/quazip/doc/html/inherit_graph_11.md5 b/hecl-gui/quazip/doc/html/inherit_graph_11.md5 deleted file mode 100644 index 53013171a..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_11.md5 +++ /dev/null @@ -1 +0,0 @@ -8e1c8bc28a8271d22c62e3355c4d6457 \ No newline at end of file diff --git a/hecl-gui/quazip/doc/html/inherit_graph_11.png b/hecl-gui/quazip/doc/html/inherit_graph_11.png deleted file mode 100644 index f38d56a26..000000000 Binary files a/hecl-gui/quazip/doc/html/inherit_graph_11.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/inherit_graph_2.map b/hecl-gui/quazip/doc/html/inherit_graph_2.map deleted file mode 100644 index 2d4a7b7f8..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_2.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/hecl-gui/quazip/doc/html/inherit_graph_2.md5 b/hecl-gui/quazip/doc/html/inherit_graph_2.md5 deleted file mode 100644 index c6f5b3275..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_2.md5 +++ /dev/null @@ -1 +0,0 @@ -08d70385c6cb46b3e468c025be58be29 \ No newline at end of file diff --git a/hecl-gui/quazip/doc/html/inherit_graph_2.png b/hecl-gui/quazip/doc/html/inherit_graph_2.png deleted file mode 100644 index da509d6cf..000000000 Binary files a/hecl-gui/quazip/doc/html/inherit_graph_2.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/inherit_graph_3.map b/hecl-gui/quazip/doc/html/inherit_graph_3.map deleted file mode 100644 index 5f3dfabc6..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_3.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/hecl-gui/quazip/doc/html/inherit_graph_3.md5 b/hecl-gui/quazip/doc/html/inherit_graph_3.md5 deleted file mode 100644 index 7651521f6..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_3.md5 +++ /dev/null @@ -1 +0,0 @@ -b61cc9a124a015d73d6cbdf422313db4 \ No newline at end of file diff --git a/hecl-gui/quazip/doc/html/inherit_graph_3.png b/hecl-gui/quazip/doc/html/inherit_graph_3.png deleted file mode 100644 index 45d2fc8d2..000000000 Binary files a/hecl-gui/quazip/doc/html/inherit_graph_3.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/inherit_graph_4.map b/hecl-gui/quazip/doc/html/inherit_graph_4.map deleted file mode 100644 index 815ba965b..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_4.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/hecl-gui/quazip/doc/html/inherit_graph_4.md5 b/hecl-gui/quazip/doc/html/inherit_graph_4.md5 deleted file mode 100644 index 22214eea9..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_4.md5 +++ /dev/null @@ -1 +0,0 @@ -516630e9457f1fceabe81e76fdbf113d \ No newline at end of file diff --git a/hecl-gui/quazip/doc/html/inherit_graph_4.png b/hecl-gui/quazip/doc/html/inherit_graph_4.png deleted file mode 100644 index 75eab91cf..000000000 Binary files a/hecl-gui/quazip/doc/html/inherit_graph_4.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/inherit_graph_5.map b/hecl-gui/quazip/doc/html/inherit_graph_5.map deleted file mode 100644 index 89a82060f..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_5.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/hecl-gui/quazip/doc/html/inherit_graph_5.md5 b/hecl-gui/quazip/doc/html/inherit_graph_5.md5 deleted file mode 100644 index 92d597ecf..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_5.md5 +++ /dev/null @@ -1 +0,0 @@ -c70793a20c0ee967fcd21a549a42a789 \ No newline at end of file diff --git a/hecl-gui/quazip/doc/html/inherit_graph_5.png b/hecl-gui/quazip/doc/html/inherit_graph_5.png deleted file mode 100644 index 60a1497ae..000000000 Binary files a/hecl-gui/quazip/doc/html/inherit_graph_5.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/inherit_graph_6.map b/hecl-gui/quazip/doc/html/inherit_graph_6.map deleted file mode 100644 index fb84bfb90..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_6.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/hecl-gui/quazip/doc/html/inherit_graph_6.md5 b/hecl-gui/quazip/doc/html/inherit_graph_6.md5 deleted file mode 100644 index dc35309fd..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_6.md5 +++ /dev/null @@ -1 +0,0 @@ -a304fc926447a90879a7cd82c1947d0c \ No newline at end of file diff --git a/hecl-gui/quazip/doc/html/inherit_graph_6.png b/hecl-gui/quazip/doc/html/inherit_graph_6.png deleted file mode 100644 index 836b203bd..000000000 Binary files a/hecl-gui/quazip/doc/html/inherit_graph_6.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/inherit_graph_7.map b/hecl-gui/quazip/doc/html/inherit_graph_7.map deleted file mode 100644 index 06ea8e4e8..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_7.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/hecl-gui/quazip/doc/html/inherit_graph_7.md5 b/hecl-gui/quazip/doc/html/inherit_graph_7.md5 deleted file mode 100644 index d0b20e642..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_7.md5 +++ /dev/null @@ -1 +0,0 @@ -bb94f8389c69fe5653003491edaa81cb \ No newline at end of file diff --git a/hecl-gui/quazip/doc/html/inherit_graph_7.png b/hecl-gui/quazip/doc/html/inherit_graph_7.png deleted file mode 100644 index 639c9fa59..000000000 Binary files a/hecl-gui/quazip/doc/html/inherit_graph_7.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/inherit_graph_8.map b/hecl-gui/quazip/doc/html/inherit_graph_8.map deleted file mode 100644 index 0fd635784..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_8.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/hecl-gui/quazip/doc/html/inherit_graph_8.md5 b/hecl-gui/quazip/doc/html/inherit_graph_8.md5 deleted file mode 100644 index 7f32d5f6c..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_8.md5 +++ /dev/null @@ -1 +0,0 @@ -5bb5840bebb562b49d7b50f9856f62d8 \ No newline at end of file diff --git a/hecl-gui/quazip/doc/html/inherit_graph_8.png b/hecl-gui/quazip/doc/html/inherit_graph_8.png deleted file mode 100644 index 675db43dd..000000000 Binary files a/hecl-gui/quazip/doc/html/inherit_graph_8.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/inherit_graph_9.map b/hecl-gui/quazip/doc/html/inherit_graph_9.map deleted file mode 100644 index 00adcad34..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_9.map +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/hecl-gui/quazip/doc/html/inherit_graph_9.md5 b/hecl-gui/quazip/doc/html/inherit_graph_9.md5 deleted file mode 100644 index 199c8b51d..000000000 --- a/hecl-gui/quazip/doc/html/inherit_graph_9.md5 +++ /dev/null @@ -1 +0,0 @@ -bb506805d0a0a557d4ccbc22245703be \ No newline at end of file diff --git a/hecl-gui/quazip/doc/html/inherit_graph_9.png b/hecl-gui/quazip/doc/html/inherit_graph_9.png deleted file mode 100644 index 284895f64..000000000 Binary files a/hecl-gui/quazip/doc/html/inherit_graph_9.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/inherits.html b/hecl-gui/quazip/doc/html/inherits.html deleted file mode 100644 index a6e65b91b..000000000 --- a/hecl-gui/quazip/doc/html/inherits.html +++ /dev/null @@ -1,102 +0,0 @@ - - - - -QuaZIP: Class Hierarchy - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
-
-
Class Hierarchy
-
-
- - - - - - - - - - - - - -
- - -
- - -
- - -
- - -
- - -
- - -
- - -
- - -
- - -
- - -
- - -
- - -
-
- - - diff --git a/hecl-gui/quazip/doc/html/jquery.js b/hecl-gui/quazip/doc/html/jquery.js deleted file mode 100644 index c052173a8..000000000 --- a/hecl-gui/quazip/doc/html/jquery.js +++ /dev/null @@ -1,54 +0,0 @@ -/* - * jQuery JavaScript Library v1.3.2 - * http://jquery.com/ - * - * Copyright (c) 2009 John Resig - * Dual licensed under the MIT and GPL licenses. - * http://docs.jquery.com/License - * - * Date: 2009-02-19 17:34:21 -0500 (Thu, 19 Feb 2009) - * Revision: 6246 - */ -(function(){var l=this,g,y=l.jQuery,p=l.$,o=l.jQuery=l.$=function(E,F){return new o.fn.init(E,F)},D=/^[^<]*(<(.|\s)+>)[^>]*$|^#([\w-]+)$/,f=/^.[^:#\[\.,]*$/;o.fn=o.prototype={init:function(E,H){E=E||document;if(E.nodeType){this[0]=E;this.length=1;this.context=E;return this}if(typeof E==="string"){var G=D.exec(E);if(G&&(G[1]||!H)){if(G[1]){E=o.clean([G[1]],H)}else{var I=document.getElementById(G[3]);if(I&&I.id!=G[3]){return o().find(E)}var F=o(I||[]);F.context=document;F.selector=E;return F}}else{return o(H).find(E)}}else{if(o.isFunction(E)){return o(document).ready(E)}}if(E.selector&&E.context){this.selector=E.selector;this.context=E.context}return this.setArray(o.isArray(E)?E:o.makeArray(E))},selector:"",jquery:"1.3.2",size:function(){return this.length},get:function(E){return E===g?Array.prototype.slice.call(this):this[E]},pushStack:function(F,H,E){var G=o(F);G.prevObject=this;G.context=this.context;if(H==="find"){G.selector=this.selector+(this.selector?" ":"")+E}else{if(H){G.selector=this.selector+"."+H+"("+E+")"}}return G},setArray:function(E){this.length=0;Array.prototype.push.apply(this,E);return this},each:function(F,E){return o.each(this,F,E)},index:function(E){return o.inArray(E&&E.jquery?E[0]:E,this)},attr:function(F,H,G){var E=F;if(typeof F==="string"){if(H===g){return this[0]&&o[G||"attr"](this[0],F)}else{E={};E[F]=H}}return this.each(function(I){for(F in E){o.attr(G?this.style:this,F,o.prop(this,E[F],G,I,F))}})},css:function(E,F){if((E=="width"||E=="height")&&parseFloat(F)<0){F=g}return this.attr(E,F,"curCSS")},text:function(F){if(typeof F!=="object"&&F!=null){return this.empty().append((this[0]&&this[0].ownerDocument||document).createTextNode(F))}var E="";o.each(F||this,function(){o.each(this.childNodes,function(){if(this.nodeType!=8){E+=this.nodeType!=1?this.nodeValue:o.fn.text([this])}})});return E},wrapAll:function(E){if(this[0]){var F=o(E,this[0].ownerDocument).clone();if(this[0].parentNode){F.insertBefore(this[0])}F.map(function(){var G=this;while(G.firstChild){G=G.firstChild}return G}).append(this)}return this},wrapInner:function(E){return this.each(function(){o(this).contents().wrapAll(E)})},wrap:function(E){return this.each(function(){o(this).wrapAll(E)})},append:function(){return this.domManip(arguments,true,function(E){if(this.nodeType==1){this.appendChild(E)}})},prepend:function(){return this.domManip(arguments,true,function(E){if(this.nodeType==1){this.insertBefore(E,this.firstChild)}})},before:function(){return this.domManip(arguments,false,function(E){this.parentNode.insertBefore(E,this)})},after:function(){return this.domManip(arguments,false,function(E){this.parentNode.insertBefore(E,this.nextSibling)})},end:function(){return this.prevObject||o([])},push:[].push,sort:[].sort,splice:[].splice,find:function(E){if(this.length===1){var F=this.pushStack([],"find",E);F.length=0;o.find(E,this[0],F);return F}else{return this.pushStack(o.unique(o.map(this,function(G){return o.find(E,G)})),"find",E)}},clone:function(G){var E=this.map(function(){if(!o.support.noCloneEvent&&!o.isXMLDoc(this)){var I=this.outerHTML;if(!I){var J=this.ownerDocument.createElement("div");J.appendChild(this.cloneNode(true));I=J.innerHTML}return o.clean([I.replace(/ jQuery\d+="(?:\d+|null)"/g,"").replace(/^\s*/,"")])[0]}else{return this.cloneNode(true)}});if(G===true){var H=this.find("*").andSelf(),F=0;E.find("*").andSelf().each(function(){if(this.nodeName!==H[F].nodeName){return}var I=o.data(H[F],"events");for(var K in I){for(var J in I[K]){o.event.add(this,K,I[K][J],I[K][J].data)}}F++})}return E},filter:function(E){return this.pushStack(o.isFunction(E)&&o.grep(this,function(G,F){return E.call(G,F)})||o.multiFilter(E,o.grep(this,function(F){return F.nodeType===1})),"filter",E)},closest:function(E){var G=o.expr.match.POS.test(E)?o(E):null,F=0;return this.map(function(){var H=this;while(H&&H.ownerDocument){if(G?G.index(H)>-1:o(H).is(E)){o.data(H,"closest",F);return H}H=H.parentNode;F++}})},not:function(E){if(typeof E==="string"){if(f.test(E)){return this.pushStack(o.multiFilter(E,this,true),"not",E)}else{E=o.multiFilter(E,this)}}var F=E.length&&E[E.length-1]!==g&&!E.nodeType;return this.filter(function(){return F?o.inArray(this,E)<0:this!=E})},add:function(E){return this.pushStack(o.unique(o.merge(this.get(),typeof E==="string"?o(E):o.makeArray(E))))},is:function(E){return !!E&&o.multiFilter(E,this).length>0},hasClass:function(E){return !!E&&this.is("."+E)},val:function(K){if(K===g){var E=this[0];if(E){if(o.nodeName(E,"option")){return(E.attributes.value||{}).specified?E.value:E.text}if(o.nodeName(E,"select")){var I=E.selectedIndex,L=[],M=E.options,H=E.type=="select-one";if(I<0){return null}for(var F=H?I:0,J=H?I+1:M.length;F=0||o.inArray(this.name,K)>=0)}else{if(o.nodeName(this,"select")){var N=o.makeArray(K);o("option",this).each(function(){this.selected=(o.inArray(this.value,N)>=0||o.inArray(this.text,N)>=0)});if(!N.length){this.selectedIndex=-1}}else{this.value=K}}})},html:function(E){return E===g?(this[0]?this[0].innerHTML.replace(/ jQuery\d+="(?:\d+|null)"/g,""):null):this.empty().append(E)},replaceWith:function(E){return this.after(E).remove()},eq:function(E){return this.slice(E,+E+1)},slice:function(){return this.pushStack(Array.prototype.slice.apply(this,arguments),"slice",Array.prototype.slice.call(arguments).join(","))},map:function(E){return this.pushStack(o.map(this,function(G,F){return E.call(G,F,G)}))},andSelf:function(){return this.add(this.prevObject)},domManip:function(J,M,L){if(this[0]){var I=(this[0].ownerDocument||this[0]).createDocumentFragment(),F=o.clean(J,(this[0].ownerDocument||this[0]),I),H=I.firstChild;if(H){for(var G=0,E=this.length;G1||G>0?I.cloneNode(true):I)}}if(F){o.each(F,z)}}return this;function K(N,O){return M&&o.nodeName(N,"table")&&o.nodeName(O,"tr")?(N.getElementsByTagName("tbody")[0]||N.appendChild(N.ownerDocument.createElement("tbody"))):N}}};o.fn.init.prototype=o.fn;function z(E,F){if(F.src){o.ajax({url:F.src,async:false,dataType:"script"})}else{o.globalEval(F.text||F.textContent||F.innerHTML||"")}if(F.parentNode){F.parentNode.removeChild(F)}}function e(){return +new Date}o.extend=o.fn.extend=function(){var J=arguments[0]||{},H=1,I=arguments.length,E=false,G;if(typeof J==="boolean"){E=J;J=arguments[1]||{};H=2}if(typeof J!=="object"&&!o.isFunction(J)){J={}}if(I==H){J=this;--H}for(;H-1}},swap:function(H,G,I){var E={};for(var F in G){E[F]=H.style[F];H.style[F]=G[F]}I.call(H);for(var F in G){H.style[F]=E[F]}},css:function(H,F,J,E){if(F=="width"||F=="height"){var L,G={position:"absolute",visibility:"hidden",display:"block"},K=F=="width"?["Left","Right"]:["Top","Bottom"];function I(){L=F=="width"?H.offsetWidth:H.offsetHeight;if(E==="border"){return}o.each(K,function(){if(!E){L-=parseFloat(o.curCSS(H,"padding"+this,true))||0}if(E==="margin"){L+=parseFloat(o.curCSS(H,"margin"+this,true))||0}else{L-=parseFloat(o.curCSS(H,"border"+this+"Width",true))||0}})}if(H.offsetWidth!==0){I()}else{o.swap(H,G,I)}return Math.max(0,Math.round(L))}return o.curCSS(H,F,J)},curCSS:function(I,F,G){var L,E=I.style;if(F=="opacity"&&!o.support.opacity){L=o.attr(E,"opacity");return L==""?"1":L}if(F.match(/float/i)){F=w}if(!G&&E&&E[F]){L=E[F]}else{if(q.getComputedStyle){if(F.match(/float/i)){F="float"}F=F.replace(/([A-Z])/g,"-$1").toLowerCase();var M=q.getComputedStyle(I,null);if(M){L=M.getPropertyValue(F)}if(F=="opacity"&&L==""){L="1"}}else{if(I.currentStyle){var J=F.replace(/\-(\w)/g,function(N,O){return O.toUpperCase()});L=I.currentStyle[F]||I.currentStyle[J];if(!/^\d+(px)?$/i.test(L)&&/^\d/.test(L)){var H=E.left,K=I.runtimeStyle.left;I.runtimeStyle.left=I.currentStyle.left;E.left=L||0;L=E.pixelLeft+"px";E.left=H;I.runtimeStyle.left=K}}}}return L},clean:function(F,K,I){K=K||document;if(typeof K.createElement==="undefined"){K=K.ownerDocument||K[0]&&K[0].ownerDocument||document}if(!I&&F.length===1&&typeof F[0]==="string"){var H=/^<(\w+)\s*\/?>$/.exec(F[0]);if(H){return[K.createElement(H[1])]}}var G=[],E=[],L=K.createElement("div");o.each(F,function(P,S){if(typeof S==="number"){S+=""}if(!S){return}if(typeof S==="string"){S=S.replace(/(<(\w+)[^>]*?)\/>/g,function(U,V,T){return T.match(/^(abbr|br|col|img|input|link|meta|param|hr|area|embed)$/i)?U:V+">"});var O=S.replace(/^\s+/,"").substring(0,10).toLowerCase();var Q=!O.indexOf("",""]||!O.indexOf("",""]||O.match(/^<(thead|tbody|tfoot|colg|cap)/)&&[1,"","
"]||!O.indexOf("",""]||(!O.indexOf("",""]||!O.indexOf("",""]||!o.support.htmlSerialize&&[1,"div
","
"]||[0,"",""];L.innerHTML=Q[1]+S+Q[2];while(Q[0]--){L=L.lastChild}if(!o.support.tbody){var R=/"&&!R?L.childNodes:[];for(var M=N.length-1;M>=0;--M){if(o.nodeName(N[M],"tbody")&&!N[M].childNodes.length){N[M].parentNode.removeChild(N[M])}}}if(!o.support.leadingWhitespace&&/^\s/.test(S)){L.insertBefore(K.createTextNode(S.match(/^\s*/)[0]),L.firstChild)}S=o.makeArray(L.childNodes)}if(S.nodeType){G.push(S)}else{G=o.merge(G,S)}});if(I){for(var J=0;G[J];J++){if(o.nodeName(G[J],"script")&&(!G[J].type||G[J].type.toLowerCase()==="text/javascript")){E.push(G[J].parentNode?G[J].parentNode.removeChild(G[J]):G[J])}else{if(G[J].nodeType===1){G.splice.apply(G,[J+1,0].concat(o.makeArray(G[J].getElementsByTagName("script"))))}I.appendChild(G[J])}}return E}return G},attr:function(J,G,K){if(!J||J.nodeType==3||J.nodeType==8){return g}var H=!o.isXMLDoc(J),L=K!==g;G=H&&o.props[G]||G;if(J.tagName){var F=/href|src|style/.test(G);if(G=="selected"&&J.parentNode){J.parentNode.selectedIndex}if(G in J&&H&&!F){if(L){if(G=="type"&&o.nodeName(J,"input")&&J.parentNode){throw"type property can't be changed"}J[G]=K}if(o.nodeName(J,"form")&&J.getAttributeNode(G)){return J.getAttributeNode(G).nodeValue}if(G=="tabIndex"){var I=J.getAttributeNode("tabIndex");return I&&I.specified?I.value:J.nodeName.match(/(button|input|object|select|textarea)/i)?0:J.nodeName.match(/^(a|area)$/i)&&J.href?0:g}return J[G]}if(!o.support.style&&H&&G=="style"){return o.attr(J.style,"cssText",K)}if(L){J.setAttribute(G,""+K)}var E=!o.support.hrefNormalized&&H&&F?J.getAttribute(G,2):J.getAttribute(G);return E===null?g:E}if(!o.support.opacity&&G=="opacity"){if(L){J.zoom=1;J.filter=(J.filter||"").replace(/alpha\([^)]*\)/,"")+(parseInt(K)+""=="NaN"?"":"alpha(opacity="+K*100+")")}return J.filter&&J.filter.indexOf("opacity=")>=0?(parseFloat(J.filter.match(/opacity=([^)]*)/)[1])/100)+"":""}G=G.replace(/-([a-z])/ig,function(M,N){return N.toUpperCase()});if(L){J[G]=K}return J[G]},trim:function(E){return(E||"").replace(/^\s+|\s+$/g,"")},makeArray:function(G){var E=[];if(G!=null){var F=G.length;if(F==null||typeof G==="string"||o.isFunction(G)||G.setInterval){E[0]=G}else{while(F){E[--F]=G[F]}}}return E},inArray:function(G,H){for(var E=0,F=H.length;E0?this.clone(true):this).get();o.fn[F].apply(o(L[K]),I);J=J.concat(I)}return this.pushStack(J,E,G)}});o.each({removeAttr:function(E){o.attr(this,E,"");if(this.nodeType==1){this.removeAttribute(E)}},addClass:function(E){o.className.add(this,E)},removeClass:function(E){o.className.remove(this,E)},toggleClass:function(F,E){if(typeof E!=="boolean"){E=!o.className.has(this,F)}o.className[E?"add":"remove"](this,F)},remove:function(E){if(!E||o.filter(E,[this]).length){o("*",this).add([this]).each(function(){o.event.remove(this);o.removeData(this)});if(this.parentNode){this.parentNode.removeChild(this)}}},empty:function(){o(this).children().remove();while(this.firstChild){this.removeChild(this.firstChild)}}},function(E,F){o.fn[E]=function(){return this.each(F,arguments)}});function j(E,F){return E[0]&&parseInt(o.curCSS(E[0],F,true),10)||0}var h="jQuery"+e(),v=0,A={};o.extend({cache:{},data:function(F,E,G){F=F==l?A:F;var H=F[h];if(!H){H=F[h]=++v}if(E&&!o.cache[H]){o.cache[H]={}}if(G!==g){o.cache[H][E]=G}return E?o.cache[H][E]:H},removeData:function(F,E){F=F==l?A:F;var H=F[h];if(E){if(o.cache[H]){delete o.cache[H][E];E="";for(E in o.cache[H]){break}if(!E){o.removeData(F)}}}else{try{delete F[h]}catch(G){if(F.removeAttribute){F.removeAttribute(h)}}delete o.cache[H]}},queue:function(F,E,H){if(F){E=(E||"fx")+"queue";var G=o.data(F,E);if(!G||o.isArray(H)){G=o.data(F,E,o.makeArray(H))}else{if(H){G.push(H)}}}return G},dequeue:function(H,G){var E=o.queue(H,G),F=E.shift();if(!G||G==="fx"){F=E[0]}if(F!==g){F.call(H)}}});o.fn.extend({data:function(E,G){var H=E.split(".");H[1]=H[1]?"."+H[1]:"";if(G===g){var F=this.triggerHandler("getData"+H[1]+"!",[H[0]]);if(F===g&&this.length){F=o.data(this[0],E)}return F===g&&H[1]?this.data(H[0]):F}else{return this.trigger("setData"+H[1]+"!",[H[0],G]).each(function(){o.data(this,E,G)})}},removeData:function(E){return this.each(function(){o.removeData(this,E)})},queue:function(E,F){if(typeof E!=="string"){F=E;E="fx"}if(F===g){return o.queue(this[0],E)}return this.each(function(){var G=o.queue(this,E,F);if(E=="fx"&&G.length==1){G[0].call(this)}})},dequeue:function(E){return this.each(function(){o.dequeue(this,E)})}}); -/* - * Sizzle CSS Selector Engine - v0.9.3 - * Copyright 2009, The Dojo Foundation - * Released under the MIT, BSD, and GPL Licenses. - * More information: http://sizzlejs.com/ - */ -(function(){var R=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^[\]]*\]|['"][^'"]*['"]|[^[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?/g,L=0,H=Object.prototype.toString;var F=function(Y,U,ab,ac){ab=ab||[];U=U||document;if(U.nodeType!==1&&U.nodeType!==9){return[]}if(!Y||typeof Y!=="string"){return ab}var Z=[],W,af,ai,T,ad,V,X=true;R.lastIndex=0;while((W=R.exec(Y))!==null){Z.push(W[1]);if(W[2]){V=RegExp.rightContext;break}}if(Z.length>1&&M.exec(Y)){if(Z.length===2&&I.relative[Z[0]]){af=J(Z[0]+Z[1],U)}else{af=I.relative[Z[0]]?[U]:F(Z.shift(),U);while(Z.length){Y=Z.shift();if(I.relative[Y]){Y+=Z.shift()}af=J(Y,af)}}}else{var ae=ac?{expr:Z.pop(),set:E(ac)}:F.find(Z.pop(),Z.length===1&&U.parentNode?U.parentNode:U,Q(U));af=F.filter(ae.expr,ae.set);if(Z.length>0){ai=E(af)}else{X=false}while(Z.length){var ah=Z.pop(),ag=ah;if(!I.relative[ah]){ah=""}else{ag=Z.pop()}if(ag==null){ag=U}I.relative[ah](ai,ag,Q(U))}}if(!ai){ai=af}if(!ai){throw"Syntax error, unrecognized expression: "+(ah||Y)}if(H.call(ai)==="[object Array]"){if(!X){ab.push.apply(ab,ai)}else{if(U.nodeType===1){for(var aa=0;ai[aa]!=null;aa++){if(ai[aa]&&(ai[aa]===true||ai[aa].nodeType===1&&K(U,ai[aa]))){ab.push(af[aa])}}}else{for(var aa=0;ai[aa]!=null;aa++){if(ai[aa]&&ai[aa].nodeType===1){ab.push(af[aa])}}}}}else{E(ai,ab)}if(V){F(V,U,ab,ac);if(G){hasDuplicate=false;ab.sort(G);if(hasDuplicate){for(var aa=1;aa":function(Z,U,aa){var X=typeof U==="string";if(X&&!/\W/.test(U)){U=aa?U:U.toUpperCase();for(var V=0,T=Z.length;V=0)){if(!V){T.push(Y)}}else{if(V){U[X]=false}}}}return false},ID:function(T){return T[1].replace(/\\/g,"")},TAG:function(U,T){for(var V=0;T[V]===false;V++){}return T[V]&&Q(T[V])?U[1]:U[1].toUpperCase()},CHILD:function(T){if(T[1]=="nth"){var U=/(-?)(\d*)n((?:\+|-)?\d*)/.exec(T[2]=="even"&&"2n"||T[2]=="odd"&&"2n+1"||!/\D/.test(T[2])&&"0n+"+T[2]||T[2]);T[2]=(U[1]+(U[2]||1))-0;T[3]=U[3]-0}T[0]=L++;return T},ATTR:function(X,U,V,T,Y,Z){var W=X[1].replace(/\\/g,"");if(!Z&&I.attrMap[W]){X[1]=I.attrMap[W]}if(X[2]==="~="){X[4]=" "+X[4]+" "}return X},PSEUDO:function(X,U,V,T,Y){if(X[1]==="not"){if(X[3].match(R).length>1||/^\w/.test(X[3])){X[3]=F(X[3],null,null,U)}else{var W=F.filter(X[3],U,V,true^Y);if(!V){T.push.apply(T,W)}return false}}else{if(I.match.POS.test(X[0])||I.match.CHILD.test(X[0])){return true}}return X},POS:function(T){T.unshift(true);return T}},filters:{enabled:function(T){return T.disabled===false&&T.type!=="hidden"},disabled:function(T){return T.disabled===true},checked:function(T){return T.checked===true},selected:function(T){T.parentNode.selectedIndex;return T.selected===true},parent:function(T){return !!T.firstChild},empty:function(T){return !T.firstChild},has:function(V,U,T){return !!F(T[3],V).length},header:function(T){return/h\d/i.test(T.nodeName)},text:function(T){return"text"===T.type},radio:function(T){return"radio"===T.type},checkbox:function(T){return"checkbox"===T.type},file:function(T){return"file"===T.type},password:function(T){return"password"===T.type},submit:function(T){return"submit"===T.type},image:function(T){return"image"===T.type},reset:function(T){return"reset"===T.type},button:function(T){return"button"===T.type||T.nodeName.toUpperCase()==="BUTTON"},input:function(T){return/input|select|textarea|button/i.test(T.nodeName)}},setFilters:{first:function(U,T){return T===0},last:function(V,U,T,W){return U===W.length-1},even:function(U,T){return T%2===0},odd:function(U,T){return T%2===1},lt:function(V,U,T){return UT[3]-0},nth:function(V,U,T){return T[3]-0==U},eq:function(V,U,T){return T[3]-0==U}},filter:{PSEUDO:function(Z,V,W,aa){var U=V[1],X=I.filters[U];if(X){return X(Z,W,V,aa)}else{if(U==="contains"){return(Z.textContent||Z.innerText||"").indexOf(V[3])>=0}else{if(U==="not"){var Y=V[3];for(var W=0,T=Y.length;W=0)}}},ID:function(U,T){return U.nodeType===1&&U.getAttribute("id")===T},TAG:function(U,T){return(T==="*"&&U.nodeType===1)||U.nodeName===T},CLASS:function(U,T){return(" "+(U.className||U.getAttribute("class"))+" ").indexOf(T)>-1},ATTR:function(Y,W){var V=W[1],T=I.attrHandle[V]?I.attrHandle[V](Y):Y[V]!=null?Y[V]:Y.getAttribute(V),Z=T+"",X=W[2],U=W[4];return T==null?X==="!=":X==="="?Z===U:X==="*="?Z.indexOf(U)>=0:X==="~="?(" "+Z+" ").indexOf(U)>=0:!U?Z&&T!==false:X==="!="?Z!=U:X==="^="?Z.indexOf(U)===0:X==="$="?Z.substr(Z.length-U.length)===U:X==="|="?Z===U||Z.substr(0,U.length+1)===U+"-":false},POS:function(X,U,V,Y){var T=U[2],W=I.setFilters[T];if(W){return W(X,V,U,Y)}}}};var M=I.match.POS;for(var O in I.match){I.match[O]=RegExp(I.match[O].source+/(?![^\[]*\])(?![^\(]*\))/.source)}var E=function(U,T){U=Array.prototype.slice.call(U);if(T){T.push.apply(T,U);return T}return U};try{Array.prototype.slice.call(document.documentElement.childNodes)}catch(N){E=function(X,W){var U=W||[];if(H.call(X)==="[object Array]"){Array.prototype.push.apply(U,X)}else{if(typeof X.length==="number"){for(var V=0,T=X.length;V";var T=document.documentElement;T.insertBefore(U,T.firstChild);if(!!document.getElementById(V)){I.find.ID=function(X,Y,Z){if(typeof Y.getElementById!=="undefined"&&!Z){var W=Y.getElementById(X[1]);return W?W.id===X[1]||typeof W.getAttributeNode!=="undefined"&&W.getAttributeNode("id").nodeValue===X[1]?[W]:g:[]}};I.filter.ID=function(Y,W){var X=typeof Y.getAttributeNode!=="undefined"&&Y.getAttributeNode("id");return Y.nodeType===1&&X&&X.nodeValue===W}}T.removeChild(U)})();(function(){var T=document.createElement("div");T.appendChild(document.createComment(""));if(T.getElementsByTagName("*").length>0){I.find.TAG=function(U,Y){var X=Y.getElementsByTagName(U[1]);if(U[1]==="*"){var W=[];for(var V=0;X[V];V++){if(X[V].nodeType===1){W.push(X[V])}}X=W}return X}}T.innerHTML="";if(T.firstChild&&typeof T.firstChild.getAttribute!=="undefined"&&T.firstChild.getAttribute("href")!=="#"){I.attrHandle.href=function(U){return U.getAttribute("href",2)}}})();if(document.querySelectorAll){(function(){var T=F,U=document.createElement("div");U.innerHTML="

";if(U.querySelectorAll&&U.querySelectorAll(".TEST").length===0){return}F=function(Y,X,V,W){X=X||document;if(!W&&X.nodeType===9&&!Q(X)){try{return E(X.querySelectorAll(Y),V)}catch(Z){}}return T(Y,X,V,W)};F.find=T.find;F.filter=T.filter;F.selectors=T.selectors;F.matches=T.matches})()}if(document.getElementsByClassName&&document.documentElement.getElementsByClassName){(function(){var T=document.createElement("div");T.innerHTML="
";if(T.getElementsByClassName("e").length===0){return}T.lastChild.className="e";if(T.getElementsByClassName("e").length===1){return}I.order.splice(1,0,"CLASS");I.find.CLASS=function(U,V,W){if(typeof V.getElementsByClassName!=="undefined"&&!W){return V.getElementsByClassName(U[1])}}})()}function P(U,Z,Y,ad,aa,ac){var ab=U=="previousSibling"&&!ac;for(var W=0,V=ad.length;W0){X=T;break}}}T=T[U]}ad[W]=X}}}var K=document.compareDocumentPosition?function(U,T){return U.compareDocumentPosition(T)&16}:function(U,T){return U!==T&&(U.contains?U.contains(T):true)};var Q=function(T){return T.nodeType===9&&T.documentElement.nodeName!=="HTML"||!!T.ownerDocument&&Q(T.ownerDocument)};var J=function(T,aa){var W=[],X="",Y,V=aa.nodeType?[aa]:aa;while((Y=I.match.PSEUDO.exec(T))){X+=Y[0];T=T.replace(I.match.PSEUDO,"")}T=I.relative[T]?T+"*":T;for(var Z=0,U=V.length;Z0||T.offsetHeight>0};F.selectors.filters.animated=function(T){return o.grep(o.timers,function(U){return T===U.elem}).length};o.multiFilter=function(V,T,U){if(U){V=":not("+V+")"}return F.matches(V,T)};o.dir=function(V,U){var T=[],W=V[U];while(W&&W!=document){if(W.nodeType==1){T.push(W)}W=W[U]}return T};o.nth=function(X,T,V,W){T=T||1;var U=0;for(;X;X=X[V]){if(X.nodeType==1&&++U==T){break}}return X};o.sibling=function(V,U){var T=[];for(;V;V=V.nextSibling){if(V.nodeType==1&&V!=U){T.push(V)}}return T};return;l.Sizzle=F})();o.event={add:function(I,F,H,K){if(I.nodeType==3||I.nodeType==8){return}if(I.setInterval&&I!=l){I=l}if(!H.guid){H.guid=this.guid++}if(K!==g){var G=H;H=this.proxy(G);H.data=K}var E=o.data(I,"events")||o.data(I,"events",{}),J=o.data(I,"handle")||o.data(I,"handle",function(){return typeof o!=="undefined"&&!o.event.triggered?o.event.handle.apply(arguments.callee.elem,arguments):g});J.elem=I;o.each(F.split(/\s+/),function(M,N){var O=N.split(".");N=O.shift();H.type=O.slice().sort().join(".");var L=E[N];if(o.event.specialAll[N]){o.event.specialAll[N].setup.call(I,K,O)}if(!L){L=E[N]={};if(!o.event.special[N]||o.event.special[N].setup.call(I,K,O)===false){if(I.addEventListener){I.addEventListener(N,J,false)}else{if(I.attachEvent){I.attachEvent("on"+N,J)}}}}L[H.guid]=H;o.event.global[N]=true});I=null},guid:1,global:{},remove:function(K,H,J){if(K.nodeType==3||K.nodeType==8){return}var G=o.data(K,"events"),F,E;if(G){if(H===g||(typeof H==="string"&&H.charAt(0)==".")){for(var I in G){this.remove(K,I+(H||""))}}else{if(H.type){J=H.handler;H=H.type}o.each(H.split(/\s+/),function(M,O){var Q=O.split(".");O=Q.shift();var N=RegExp("(^|\\.)"+Q.slice().sort().join(".*\\.")+"(\\.|$)");if(G[O]){if(J){delete G[O][J.guid]}else{for(var P in G[O]){if(N.test(G[O][P].type)){delete G[O][P]}}}if(o.event.specialAll[O]){o.event.specialAll[O].teardown.call(K,Q)}for(F in G[O]){break}if(!F){if(!o.event.special[O]||o.event.special[O].teardown.call(K,Q)===false){if(K.removeEventListener){K.removeEventListener(O,o.data(K,"handle"),false)}else{if(K.detachEvent){K.detachEvent("on"+O,o.data(K,"handle"))}}}F=null;delete G[O]}}})}for(F in G){break}if(!F){var L=o.data(K,"handle");if(L){L.elem=null}o.removeData(K,"events");o.removeData(K,"handle")}}},trigger:function(I,K,H,E){var G=I.type||I;if(!E){I=typeof I==="object"?I[h]?I:o.extend(o.Event(G),I):o.Event(G);if(G.indexOf("!")>=0) -{I.type=G=G.slice(0,-1);I.exclusive=true}if(!H){I.stopPropagation();if(this.global[G]){o.each(o.cache,function(){if(this.events&&this.events[G]){o.event.trigger(I,K,this.handle.elem)}})}}if(!H||H.nodeType==3||H.nodeType==8){return g}I.result=g;I.target=H;K=o.makeArray(K);K.unshift(I)}I.currentTarget=H;var J=o.data(H,"handle");if(J){J.apply(H,K)}if((!H[G]||(o.nodeName(H,"a")&&G=="click"))&&H["on"+G]&&H["on"+G].apply(H,K)===false){I.result=false}if(!E&&H[G]&&!I.isDefaultPrevented()&&!(o.nodeName(H,"a")&&G=="click")){this.triggered=true;try{H[G]()}catch(L){}}this.triggered=false;if(!I.isPropagationStopped()){var F=H.parentNode||H.ownerDocument;if(F){o.event.trigger(I,K,F,true)}}},handle:function(K){var J,E;K=arguments[0]=o.event.fix(K||l.event);K.currentTarget=this;var L=K.type.split(".");K.type=L.shift();J=!L.length&&!K.exclusive;var I=RegExp("(^|\\.)"+L.slice().sort().join(".*\\.")+"(\\.|$)");E=(o.data(this,"events")||{})[K.type];for(var G in E){var H=E[G];if(J||I.test(H.type)){K.handler=H;K.data=H.data;var F=H.apply(this,arguments);if(F!==g){K.result=F;if(F===false){K.preventDefault();K.stopPropagation()}}if(K.isImmediatePropagationStopped()){break}}}},props:"altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode metaKey newValue originalTarget pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target toElement view wheelDelta which".split(" "),fix:function(H){if(H[h]){return H}var F=H;H=o.Event(F);for(var G=this.props.length,J;G;){J=this.props[--G];H[J]=F[J]}if(!H.target){H.target=H.srcElement||document}if(H.target.nodeType==3){H.target=H.target.parentNode}if(!H.relatedTarget&&H.fromElement){H.relatedTarget=H.fromElement==H.target?H.toElement:H.fromElement}if(H.pageX==null&&H.clientX!=null){var I=document.documentElement,E=document.body;H.pageX=H.clientX+(I&&I.scrollLeft||E&&E.scrollLeft||0)-(I.clientLeft||0);H.pageY=H.clientY+(I&&I.scrollTop||E&&E.scrollTop||0)-(I.clientTop||0)}if(!H.which&&((H.charCode||H.charCode===0)?H.charCode:H.keyCode)){H.which=H.charCode||H.keyCode}if(!H.metaKey&&H.ctrlKey){H.metaKey=H.ctrlKey}if(!H.which&&H.button){H.which=(H.button&1?1:(H.button&2?3:(H.button&4?2:0)))}return H},proxy:function(F,E){E=E||function(){return F.apply(this,arguments)};E.guid=F.guid=F.guid||E.guid||this.guid++;return E},special:{ready:{setup:B,teardown:function(){}}},specialAll:{live:{setup:function(E,F){o.event.add(this,F[0],c)},teardown:function(G){if(G.length){var E=0,F=RegExp("(^|\\.)"+G[0]+"(\\.|$)");o.each((o.data(this,"events").live||{}),function(){if(F.test(this.type)){E++}});if(E<1){o.event.remove(this,G[0],c)}}}}}};o.Event=function(E){if(!this.preventDefault){return new o.Event(E)}if(E&&E.type){this.originalEvent=E;this.type=E.type}else{this.type=E}this.timeStamp=e();this[h]=true};function k(){return false}function u(){return true}o.Event.prototype={preventDefault:function(){this.isDefaultPrevented=u;var E=this.originalEvent;if(!E){return}if(E.preventDefault){E.preventDefault()}E.returnValue=false},stopPropagation:function(){this.isPropagationStopped=u;var E=this.originalEvent;if(!E){return}if(E.stopPropagation){E.stopPropagation()}E.cancelBubble=true},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=u;this.stopPropagation()},isDefaultPrevented:k,isPropagationStopped:k,isImmediatePropagationStopped:k};var a=function(F){var E=F.relatedTarget;while(E&&E!=this){try{E=E.parentNode}catch(G){E=this}}if(E!=this){F.type=F.data;o.event.handle.apply(this,arguments)}};o.each({mouseover:"mouseenter",mouseout:"mouseleave"},function(F,E){o.event.special[E]={setup:function(){o.event.add(this,F,a,E)},teardown:function(){o.event.remove(this,F,a)}}});o.fn.extend({bind:function(F,G,E){return F=="unload"?this.one(F,G,E):this.each(function(){o.event.add(this,F,E||G,E&&G)})},one:function(G,H,F){var E=o.event.proxy(F||H,function(I){o(this).unbind(I,E);return(F||H).apply(this,arguments)});return this.each(function(){o.event.add(this,G,E,F&&H)})},unbind:function(F,E){return this.each(function(){o.event.remove(this,F,E)})},trigger:function(E,F){return this.each(function(){o.event.trigger(E,F,this)})},triggerHandler:function(E,G){if(this[0]){var F=o.Event(E);F.preventDefault();F.stopPropagation();o.event.trigger(F,G,this[0]);return F.result}},toggle:function(G){var E=arguments,F=1;while(F=0){var E=G.slice(I,G.length);G=G.slice(0,I)}var H="GET";if(J){if(o.isFunction(J)){K=J;J=null}else{if(typeof J==="object"){J=o.param(J);H="POST"}}}var F=this;o.ajax({url:G,type:H,dataType:"html",data:J,complete:function(M,L){if(L=="success"||L=="notmodified"){F.html(E?o("
").append(M.responseText.replace(//g,"")).find(E):M.responseText)}if(K){F.each(K,[M.responseText,L,M])}}});return this},serialize:function(){return o.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?o.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||/select|textarea/i.test(this.nodeName)||/text|hidden|password|search/i.test(this.type))}).map(function(E,F){var G=o(this).val();return G==null?null:o.isArray(G)?o.map(G,function(I,H){return{name:F.name,value:I}}):{name:F.name,value:G}}).get()}});o.each("ajaxStart,ajaxStop,ajaxComplete,ajaxError,ajaxSuccess,ajaxSend".split(","),function(E,F){o.fn[F]=function(G){return this.bind(F,G)}});var r=e();o.extend({get:function(E,G,H,F){if(o.isFunction(G)){H=G;G=null}return o.ajax({type:"GET",url:E,data:G,success:H,dataType:F})},getScript:function(E,F){return o.get(E,null,F,"script")},getJSON:function(E,F,G){return o.get(E,F,G,"json")},post:function(E,G,H,F){if(o.isFunction(G)){H=G;G={}}return o.ajax({type:"POST",url:E,data:G,success:H,dataType:F})},ajaxSetup:function(E){o.extend(o.ajaxSettings,E)},ajaxSettings:{url:location.href,global:true,type:"GET",contentType:"application/x-www-form-urlencoded",processData:true,async:true,xhr:function(){return l.ActiveXObject?new ActiveXObject("Microsoft.XMLHTTP"):new XMLHttpRequest()},accepts:{xml:"application/xml, text/xml",html:"text/html",script:"text/javascript, application/javascript",json:"application/json, text/javascript",text:"text/plain",_default:"*/*"}},lastModified:{},ajax:function(M){M=o.extend(true,M,o.extend(true,{},o.ajaxSettings,M));var W,F=/=\?(&|$)/g,R,V,G=M.type.toUpperCase();if(M.data&&M.processData&&typeof M.data!=="string"){M.data=o.param(M.data)}if(M.dataType=="jsonp"){if(G=="GET"){if(!M.url.match(F)){M.url+=(M.url.match(/\?/)?"&":"?")+(M.jsonp||"callback")+"=?"}}else{if(!M.data||!M.data.match(F)){M.data=(M.data?M.data+"&":"")+(M.jsonp||"callback")+"=?"}}M.dataType="json"}if(M.dataType=="json"&&(M.data&&M.data.match(F)||M.url.match(F))){W="jsonp"+r++;if(M.data){M.data=(M.data+"").replace(F,"="+W+"$1")}M.url=M.url.replace(F,"="+W+"$1");M.dataType="script";l[W]=function(X){V=X;I();L();l[W]=g;try{delete l[W]}catch(Y){}if(H){H.removeChild(T)}}}if(M.dataType=="script"&&M.cache==null){M.cache=false}if(M.cache===false&&G=="GET"){var E=e();var U=M.url.replace(/(\?|&)_=.*?(&|$)/,"$1_="+E+"$2");M.url=U+((U==M.url)?(M.url.match(/\?/)?"&":"?")+"_="+E:"")}if(M.data&&G=="GET"){M.url+=(M.url.match(/\?/)?"&":"?")+M.data;M.data=null}if(M.global&&!o.active++){o.event.trigger("ajaxStart")}var Q=/^(\w+:)?\/\/([^\/?#]+)/.exec(M.url);if(M.dataType=="script"&&G=="GET"&&Q&&(Q[1]&&Q[1]!=location.protocol||Q[2]!=location.host)){var H=document.getElementsByTagName("head")[0];var T=document.createElement("script");T.src=M.url;if(M.scriptCharset){T.charset=M.scriptCharset}if(!W){var O=false;T.onload=T.onreadystatechange=function(){if(!O&&(!this.readyState||this.readyState=="loaded"||this.readyState=="complete")){O=true;I();L();T.onload=T.onreadystatechange=null;H.removeChild(T)}}}H.appendChild(T);return g}var K=false;var J=M.xhr();if(M.username){J.open(G,M.url,M.async,M.username,M.password)}else{J.open(G,M.url,M.async)}try{if(M.data){J.setRequestHeader("Content-Type",M.contentType)}if(M.ifModified){J.setRequestHeader("If-Modified-Since",o.lastModified[M.url]||"Thu, 01 Jan 1970 00:00:00 GMT")}J.setRequestHeader("X-Requested-With","XMLHttpRequest");J.setRequestHeader("Accept",M.dataType&&M.accepts[M.dataType]?M.accepts[M.dataType]+", */*":M.accepts._default)}catch(S){}if(M.beforeSend&&M.beforeSend(J,M)===false){if(M.global&&!--o.active){o.event.trigger("ajaxStop")}J.abort();return false}if(M.global){o.event.trigger("ajaxSend",[J,M])}var N=function(X){if(J.readyState==0){if(P){clearInterval(P);P=null;if(M.global&&!--o.active){o.event.trigger("ajaxStop")}}}else{if(!K&&J&&(J.readyState==4||X=="timeout")){K=true;if(P){clearInterval(P);P=null}R=X=="timeout"?"timeout":!o.httpSuccess(J)?"error":M.ifModified&&o.httpNotModified(J,M.url)?"notmodified":"success";if(R=="success"){try{V=o.httpData(J,M.dataType,M)}catch(Z){R="parsererror"}}if(R=="success"){var Y;try{Y=J.getResponseHeader("Last-Modified")}catch(Z){}if(M.ifModified&&Y){o.lastModified[M.url]=Y}if(!W){I()}}else{o.handleError(M,J,R)}L();if(X){J.abort()}if(M.async){J=null}}}};if(M.async){var P=setInterval(N,13);if(M.timeout>0){setTimeout(function(){if(J&&!K){N("timeout")}},M.timeout)}}try{J.send(M.data)}catch(S){o.handleError(M,J,null,S)}if(!M.async){N()}function I(){if(M.success){M.success(V,R)}if(M.global){o.event.trigger("ajaxSuccess",[J,M])}}function L(){if(M.complete){M.complete(J,R)}if(M.global){o.event.trigger("ajaxComplete",[J,M])}if(M.global&&!--o.active){o.event.trigger("ajaxStop")}}return J},handleError:function(F,H,E,G){if(F.error){F.error(H,E,G)}if(F.global){o.event.trigger("ajaxError",[H,F,G])}},active:0,httpSuccess:function(F){try{return !F.status&&location.protocol=="file:"||(F.status>=200&&F.status<300)||F.status==304||F.status==1223}catch(E){}return false},httpNotModified:function(G,E){try{var H=G.getResponseHeader("Last-Modified");return G.status==304||H==o.lastModified[E]}catch(F){}return false},httpData:function(J,H,G){var F=J.getResponseHeader("content-type"),E=H=="xml"||!H&&F&&F.indexOf("xml")>=0,I=E?J.responseXML:J.responseText;if(E&&I.documentElement.tagName=="parsererror"){throw"parsererror"}if(G&&G.dataFilter){I=G.dataFilter(I,H)}if(typeof I==="string"){if(H=="script"){o.globalEval(I)}if(H=="json"){I=l["eval"]("("+I+")")}}return I},param:function(E){var G=[];function H(I,J){G[G.length]=encodeURIComponent(I)+"="+encodeURIComponent(J)}if(o.isArray(E)||E.jquery){o.each(E,function(){H(this.name,this.value)})}else{for(var F in E){if(o.isArray(E[F])){o.each(E[F],function(){H(F,this)})}else{H(F,o.isFunction(E[F])?E[F]():E[F])}}}return G.join("&").replace(/%20/g,"+")}});var m={},n,d=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]];function t(F,E){var G={};o.each(d.concat.apply([],d.slice(0,E)),function() -{G[this]=F});return G}o.fn.extend({show:function(J,L){if(J){return this.animate(t("show",3),J,L)}else{for(var H=0,F=this.length;H").appendTo("body");K=I.css("display");if(K==="none"){K="block"}I.remove();m[G]=K}o.data(this[H],"olddisplay",K)}}for(var H=0,F=this.length;H=0;H--){if(G[H].elem==this){if(E){G[H](true)}G.splice(H,1)}}});if(!E){this.dequeue()}return this}});o.each({slideDown:t("show",1),slideUp:t("hide",1),slideToggle:t("toggle",1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"}},function(E,F){o.fn[E]=function(G,H){return this.animate(F,G,H)}});o.extend({speed:function(G,H,F){var E=typeof G==="object"?G:{complete:F||!F&&H||o.isFunction(G)&&G,duration:G,easing:F&&H||H&&!o.isFunction(H)&&H};E.duration=o.fx.off?0:typeof E.duration==="number"?E.duration:o.fx.speeds[E.duration]||o.fx.speeds._default;E.old=E.complete;E.complete=function(){if(E.queue!==false){o(this).dequeue()}if(o.isFunction(E.old)){E.old.call(this)}};return E},easing:{linear:function(G,H,E,F){return E+F*G},swing:function(G,H,E,F){return((-Math.cos(G*Math.PI)/2)+0.5)*F+E}},timers:[],fx:function(F,E,G){this.options=E;this.elem=F;this.prop=G;if(!E.orig){E.orig={}}}});o.fx.prototype={update:function(){if(this.options.step){this.options.step.call(this.elem,this.now,this)}(o.fx.step[this.prop]||o.fx.step._default)(this);if((this.prop=="height"||this.prop=="width")&&this.elem.style){this.elem.style.display="block"}},cur:function(F){if(this.elem[this.prop]!=null&&(!this.elem.style||this.elem.style[this.prop]==null)){return this.elem[this.prop]}var E=parseFloat(o.css(this.elem,this.prop,F));return E&&E>-10000?E:parseFloat(o.curCSS(this.elem,this.prop))||0},custom:function(I,H,G){this.startTime=e();this.start=I;this.end=H;this.unit=G||this.unit||"px";this.now=this.start;this.pos=this.state=0;var E=this;function F(J){return E.step(J)}F.elem=this.elem;if(F()&&o.timers.push(F)&&!n){n=setInterval(function(){var K=o.timers;for(var J=0;J=this.options.duration+this.startTime){this.now=this.end;this.pos=this.state=1;this.update();this.options.curAnim[this.prop]=true;var E=true;for(var F in this.options.curAnim){if(this.options.curAnim[F]!==true){E=false}}if(E){if(this.options.display!=null){this.elem.style.overflow=this.options.overflow;this.elem.style.display=this.options.display;if(o.css(this.elem,"display")=="none"){this.elem.style.display="block"}}if(this.options.hide){o(this.elem).hide()}if(this.options.hide||this.options.show){for(var I in this.options.curAnim){o.attr(this.elem.style,I,this.options.orig[I])}}this.options.complete.call(this.elem)}return false}else{var J=G-this.startTime;this.state=J/this.options.duration;this.pos=o.easing[this.options.easing||(o.easing.swing?"swing":"linear")](this.state,J,0,1,this.options.duration);this.now=this.start+((this.end-this.start)*this.pos);this.update()}return true}};o.extend(o.fx,{speeds:{slow:600,fast:200,_default:400},step:{opacity:function(E){o.attr(E.elem.style,"opacity",E.now)},_default:function(E){if(E.elem.style&&E.elem.style[E.prop]!=null){E.elem.style[E.prop]=E.now+E.unit}else{E.elem[E.prop]=E.now}}}});if(document.documentElement.getBoundingClientRect){o.fn.offset=function(){if(!this[0]){return{top:0,left:0}}if(this[0]===this[0].ownerDocument.body){return o.offset.bodyOffset(this[0])}var G=this[0].getBoundingClientRect(),J=this[0].ownerDocument,F=J.body,E=J.documentElement,L=E.clientTop||F.clientTop||0,K=E.clientLeft||F.clientLeft||0,I=G.top+(self.pageYOffset||o.boxModel&&E.scrollTop||F.scrollTop)-L,H=G.left+(self.pageXOffset||o.boxModel&&E.scrollLeft||F.scrollLeft)-K;return{top:I,left:H}}}else{o.fn.offset=function(){if(!this[0]){return{top:0,left:0}}if(this[0]===this[0].ownerDocument.body){return o.offset.bodyOffset(this[0])}o.offset.initialized||o.offset.initialize();var J=this[0],G=J.offsetParent,F=J,O=J.ownerDocument,M,H=O.documentElement,K=O.body,L=O.defaultView,E=L.getComputedStyle(J,null),N=J.offsetTop,I=J.offsetLeft;while((J=J.parentNode)&&J!==K&&J!==H){M=L.getComputedStyle(J,null);N-=J.scrollTop,I-=J.scrollLeft;if(J===G){N+=J.offsetTop,I+=J.offsetLeft;if(o.offset.doesNotAddBorder&&!(o.offset.doesAddBorderForTableAndCells&&/^t(able|d|h)$/i.test(J.tagName))){N+=parseInt(M.borderTopWidth,10)||0,I+=parseInt(M.borderLeftWidth,10)||0}F=G,G=J.offsetParent}if(o.offset.subtractsBorderForOverflowNotVisible&&M.overflow!=="visible"){N+=parseInt(M.borderTopWidth,10)||0,I+=parseInt(M.borderLeftWidth,10)||0}E=M}if(E.position==="relative"||E.position==="static"){N+=K.offsetTop,I+=K.offsetLeft}if(E.position==="fixed"){N+=Math.max(H.scrollTop,K.scrollTop),I+=Math.max(H.scrollLeft,K.scrollLeft)}return{top:N,left:I}}}o.offset={initialize:function(){if(this.initialized){return}var L=document.body,F=document.createElement("div"),H,G,N,I,M,E,J=L.style.marginTop,K='
';M={position:"absolute",top:0,left:0,margin:0,border:0,width:"1px",height:"1px",visibility:"hidden"};for(E in M){F.style[E]=M[E]}F.innerHTML=K;L.insertBefore(F,L.firstChild);H=F.firstChild,G=H.firstChild,I=H.nextSibling.firstChild.firstChild;this.doesNotAddBorder=(G.offsetTop!==5);this.doesAddBorderForTableAndCells=(I.offsetTop===5);H.style.overflow="hidden",H.style.position="relative";this.subtractsBorderForOverflowNotVisible=(G.offsetTop===-5);L.style.marginTop="1px";this.doesNotIncludeMarginInBodyOffset=(L.offsetTop===0);L.style.marginTop=J;L.removeChild(F);this.initialized=true},bodyOffset:function(E){o.offset.initialized||o.offset.initialize();var G=E.offsetTop,F=E.offsetLeft;if(o.offset.doesNotIncludeMarginInBodyOffset){G+=parseInt(o.curCSS(E,"marginTop",true),10)||0,F+=parseInt(o.curCSS(E,"marginLeft",true),10)||0}return{top:G,left:F}}};o.fn.extend({position:function(){var I=0,H=0,F;if(this[0]){var G=this.offsetParent(),J=this.offset(),E=/^body|html$/i.test(G[0].tagName)?{top:0,left:0}:G.offset();J.top-=j(this,"marginTop");J.left-=j(this,"marginLeft");E.top+=j(G,"borderTopWidth");E.left+=j(G,"borderLeftWidth");F={top:J.top-E.top,left:J.left-E.left}}return F},offsetParent:function(){var E=this[0].offsetParent||document.body;while(E&&(!/^body|html$/i.test(E.tagName)&&o.css(E,"position")=="static")){E=E.offsetParent}return o(E)}});o.each(["Left","Top"],function(F,E){var G="scroll"+E;o.fn[G]=function(H){if(!this[0]){return null}return H!==g?this.each(function(){this==l||this==document?l.scrollTo(!F?H:o(l).scrollLeft(),F?H:o(l).scrollTop()):this[G]=H}):this[0]==l||this[0]==document?self[F?"pageYOffset":"pageXOffset"]||o.boxModel&&document.documentElement[G]||document.body[G]:this[0][G]}});o.each(["Height","Width"],function(I,G){var E=I?"Left":"Top",H=I?"Right":"Bottom",F=G.toLowerCase();o.fn["inner"+G]=function(){return this[0]?o.css(this[0],F,false,"padding"):null};o.fn["outer"+G]=function(K){return this[0]?o.css(this[0],F,false,K?"margin":"border"):null};var J=G.toLowerCase();o.fn[J]=function(K){return this[0]==l?document.compatMode=="CSS1Compat"&&document.documentElement["client"+G]||document.body["client"+G]:this[0]==document?Math.max(document.documentElement["client"+G],document.body["scroll"+G],document.documentElement["scroll"+G],document.body["offset"+G],document.documentElement["offset"+G]):K===g?(this.length?o.css(this[0],J):null):this.css(J,typeof K==="string"?K:K+"px")}})})(); -/* - * jQuery UI 1.7.2 - * - * Copyright (c) 2009 AUTHORS.txt (http://jqueryui.com/about) - * Dual licensed under the MIT (MIT-LICENSE.txt) - * and GPL (GPL-LICENSE.txt) licenses. - * - * http://docs.jquery.com/UI - */ -jQuery.ui||(function(c){var i=c.fn.remove,d=c.browser.mozilla&&(parseFloat(c.browser.version)<1.9);c.ui={version:"1.7.2",plugin:{add:function(k,l,n){var m=c.ui[k].prototype;for(var j in n){m.plugins[j]=m.plugins[j]||[];m.plugins[j].push([l,n[j]])}},call:function(j,l,k){var n=j.plugins[l];if(!n||!j.element[0].parentNode){return}for(var m=0;m0){return true}m[j]=1;l=(m[j]>0);m[j]=0;return l},isOverAxis:function(k,j,l){return(k>j)&&(k<(j+l))},isOver:function(o,k,n,m,j,l){return c.ui.isOverAxis(o,n,j)&&c.ui.isOverAxis(k,m,l)},keyCode:{BACKSPACE:8,CAPS_LOCK:20,COMMA:188,CONTROL:17,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,INSERT:45,LEFT:37,NUMPAD_ADD:107,NUMPAD_DECIMAL:110,NUMPAD_DIVIDE:111,NUMPAD_ENTER:108,NUMPAD_MULTIPLY:106,NUMPAD_SUBTRACT:109,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SHIFT:16,SPACE:32,TAB:9,UP:38}};if(d){var f=c.attr,e=c.fn.removeAttr,h="http://www.w3.org/2005/07/aaa",a=/^aria-/,b=/^wairole:/;c.attr=function(k,j,l){var m=l!==undefined;return(j=="role"?(m?f.call(this,k,j,"wairole:"+l):(f.apply(this,arguments)||"").replace(b,"")):(a.test(j)?(m?k.setAttributeNS(h,j.replace(a,"aaa:"),l):f.call(this,k,j.replace(a,"aaa:"))):f.apply(this,arguments)))};c.fn.removeAttr=function(j){return(a.test(j)?this.each(function(){this.removeAttributeNS(h,j.replace(a,""))}):e.call(this,j))}}c.fn.extend({remove:function(){c("*",this).add(this).each(function(){c(this).triggerHandler("remove")});return i.apply(this,arguments)},enableSelection:function(){return this.attr("unselectable","off").css("MozUserSelect","").unbind("selectstart.ui")},disableSelection:function(){return this.attr("unselectable","on").css("MozUserSelect","none").bind("selectstart.ui",function(){return false})},scrollParent:function(){var j;if((c.browser.msie&&(/(static|relative)/).test(this.css("position")))||(/absolute/).test(this.css("position"))){j=this.parents().filter(function(){return(/(relative|absolute|fixed)/).test(c.curCSS(this,"position",1))&&(/(auto|scroll)/).test(c.curCSS(this,"overflow",1)+c.curCSS(this,"overflow-y",1)+c.curCSS(this,"overflow-x",1))}).eq(0)}else{j=this.parents().filter(function(){return(/(auto|scroll)/).test(c.curCSS(this,"overflow",1)+c.curCSS(this,"overflow-y",1)+c.curCSS(this,"overflow-x",1))}).eq(0)}return(/fixed/).test(this.css("position"))||!j.length?c(document):j}});c.extend(c.expr[":"],{data:function(l,k,j){return !!c.data(l,j[3])},focusable:function(k){var l=k.nodeName.toLowerCase(),j=c.attr(k,"tabindex");return(/input|select|textarea|button|object/.test(l)?!k.disabled:"a"==l||"area"==l?k.href||!isNaN(j):!isNaN(j))&&!c(k)["area"==l?"parents":"closest"](":hidden").length},tabbable:function(k){var j=c.attr(k,"tabindex");return(isNaN(j)||j>=0)&&c(k).is(":focusable")}});function g(m,n,o,l){function k(q){var p=c[m][n][q]||[];return(typeof p=="string"?p.split(/,?\s+/):p)}var j=k("getter");if(l.length==1&&typeof l[0]=="string"){j=j.concat(k("getterSetter"))}return(c.inArray(o,j)!=-1)}c.widget=function(k,j){var l=k.split(".")[0];k=k.split(".")[1];c.fn[k]=function(p){var n=(typeof p=="string"),o=Array.prototype.slice.call(arguments,1);if(n&&p.substring(0,1)=="_"){return this}if(n&&g(l,k,p,o)){var m=c.data(this[0],k);return(m?m[p].apply(m,o):undefined)}return this.each(function(){var q=c.data(this,k);(!q&&!n&&c.data(this,k,new c[l][k](this,p))._init());(q&&n&&c.isFunction(q[p])&&q[p].apply(q,o))})};c[l]=c[l]||{};c[l][k]=function(o,n){var m=this;this.namespace=l;this.widgetName=k;this.widgetEventPrefix=c[l][k].eventPrefix||k;this.widgetBaseClass=l+"-"+k;this.options=c.extend({},c.widget.defaults,c[l][k].defaults,c.metadata&&c.metadata.get(o)[k],n);this.element=c(o).bind("setData."+k,function(q,p,r){if(q.target==o){return m._setData(p,r)}}).bind("getData."+k,function(q,p){if(q.target==o){return m._getData(p)}}).bind("remove",function(){return m.destroy()})};c[l][k].prototype=c.extend({},c.widget.prototype,j);c[l][k].getterSetter="option"};c.widget.prototype={_init:function(){},destroy:function(){this.element.removeData(this.widgetName).removeClass(this.widgetBaseClass+"-disabled "+this.namespace+"-state-disabled").removeAttr("aria-disabled")},option:function(l,m){var k=l,j=this;if(typeof l=="string"){if(m===undefined){return this._getData(l)}k={};k[l]=m}c.each(k,function(n,o){j._setData(n,o)})},_getData:function(j){return this.options[j]},_setData:function(j,k){this.options[j]=k;if(j=="disabled"){this.element[k?"addClass":"removeClass"](this.widgetBaseClass+"-disabled "+this.namespace+"-state-disabled").attr("aria-disabled",k)}},enable:function(){this._setData("disabled",false)},disable:function(){this._setData("disabled",true)},_trigger:function(l,m,n){var p=this.options[l],j=(l==this.widgetEventPrefix?l:this.widgetEventPrefix+l);m=c.Event(m);m.type=j;if(m.originalEvent){for(var k=c.event.props.length,o;k;){o=c.event.props[--k];m[o]=m.originalEvent[o]}}this.element.trigger(m,n);return !(c.isFunction(p)&&p.call(this.element[0],m,n)===false||m.isDefaultPrevented())}};c.widget.defaults={disabled:false};c.ui.mouse={_mouseInit:function(){var j=this;this.element.bind("mousedown."+this.widgetName,function(k){return j._mouseDown(k)}).bind("click."+this.widgetName,function(k){if(j._preventClickEvent){j._preventClickEvent=false;k.stopImmediatePropagation();return false}});if(c.browser.msie){this._mouseUnselectable=this.element.attr("unselectable");this.element.attr("unselectable","on")}this.started=false},_mouseDestroy:function(){this.element.unbind("."+this.widgetName);(c.browser.msie&&this.element.attr("unselectable",this._mouseUnselectable))},_mouseDown:function(l){l.originalEvent=l.originalEvent||{};if(l.originalEvent.mouseHandled){return}(this._mouseStarted&&this._mouseUp(l));this._mouseDownEvent=l;var k=this,m=(l.which==1),j=(typeof this.options.cancel=="string"?c(l.target).parents().add(l.target).filter(this.options.cancel).length:false);if(!m||j||!this._mouseCapture(l)){return true}this.mouseDelayMet=!this.options.delay;if(!this.mouseDelayMet){this._mouseDelayTimer=setTimeout(function(){k.mouseDelayMet=true},this.options.delay)}if(this._mouseDistanceMet(l)&&this._mouseDelayMet(l)){this._mouseStarted=(this._mouseStart(l)!==false);if(!this._mouseStarted){l.preventDefault();return true}}this._mouseMoveDelegate=function(n){return k._mouseMove(n)};this._mouseUpDelegate=function(n){return k._mouseUp(n)};c(document).bind("mousemove."+this.widgetName,this._mouseMoveDelegate).bind("mouseup."+this.widgetName,this._mouseUpDelegate);(c.browser.safari||l.preventDefault());l.originalEvent.mouseHandled=true;return true},_mouseMove:function(j){if(c.browser.msie&&!j.button){return this._mouseUp(j)}if(this._mouseStarted){this._mouseDrag(j);return j.preventDefault()}if(this._mouseDistanceMet(j)&&this._mouseDelayMet(j)){this._mouseStarted=(this._mouseStart(this._mouseDownEvent,j)!==false);(this._mouseStarted?this._mouseDrag(j):this._mouseUp(j))}return !this._mouseStarted},_mouseUp:function(j){c(document).unbind("mousemove."+this.widgetName,this._mouseMoveDelegate).unbind("mouseup."+this.widgetName,this._mouseUpDelegate);if(this._mouseStarted){this._mouseStarted=false;this._preventClickEvent=(j.target==this._mouseDownEvent.target);this._mouseStop(j)}return false},_mouseDistanceMet:function(j){return(Math.max(Math.abs(this._mouseDownEvent.pageX-j.pageX),Math.abs(this._mouseDownEvent.pageY-j.pageY))>=this.options.distance)},_mouseDelayMet:function(j){return this.mouseDelayMet},_mouseStart:function(j){},_mouseDrag:function(j){},_mouseStop:function(j){},_mouseCapture:function(j){return true}};c.ui.mouse.defaults={cancel:null,distance:1,delay:0}})(jQuery);;/* * jQuery UI Resizable 1.7.2 - * - * Copyright (c) 2009 AUTHORS.txt (http://jqueryui.com/about) - * Dual licensed under the MIT (MIT-LICENSE.txt) - * and GPL (GPL-LICENSE.txt) licenses. - * - * http://docs.jquery.com/UI/Resizables - * - * Depends: - * ui.core.js - */ -(function(c){c.widget("ui.resizable",c.extend({},c.ui.mouse,{_init:function(){var e=this,j=this.options;this.element.addClass("ui-resizable");c.extend(this,{_aspectRatio:!!(j.aspectRatio),aspectRatio:j.aspectRatio,originalElement:this.element,_proportionallyResizeElements:[],_helper:j.helper||j.ghost||j.animate?j.helper||"ui-resizable-helper":null});if(this.element[0].nodeName.match(/canvas|textarea|input|select|button|img/i)){if(/relative/.test(this.element.css("position"))&&c.browser.opera){this.element.css({position:"relative",top:"auto",left:"auto"})}this.element.wrap(c('
').css({position:this.element.css("position"),width:this.element.outerWidth(),height:this.element.outerHeight(),top:this.element.css("top"),left:this.element.css("left")}));this.element=this.element.parent().data("resizable",this.element.data("resizable"));this.elementIsWrapper=true;this.element.css({marginLeft:this.originalElement.css("marginLeft"),marginTop:this.originalElement.css("marginTop"),marginRight:this.originalElement.css("marginRight"),marginBottom:this.originalElement.css("marginBottom")});this.originalElement.css({marginLeft:0,marginTop:0,marginRight:0,marginBottom:0});this.originalResizeStyle=this.originalElement.css("resize");this.originalElement.css("resize","none");this._proportionallyResizeElements.push(this.originalElement.css({position:"static",zoom:1,display:"block"}));this.originalElement.css({margin:this.originalElement.css("margin")});this._proportionallyResize()}this.handles=j.handles||(!c(".ui-resizable-handle",this.element).length?"e,s,se":{n:".ui-resizable-n",e:".ui-resizable-e",s:".ui-resizable-s",w:".ui-resizable-w",se:".ui-resizable-se",sw:".ui-resizable-sw",ne:".ui-resizable-ne",nw:".ui-resizable-nw"});if(this.handles.constructor==String){if(this.handles=="all"){this.handles="n,e,s,w,se,sw,ne,nw"}var k=this.handles.split(",");this.handles={};for(var f=0;f
');if(/sw|se|ne|nw/.test(h)){g.css({zIndex:++j.zIndex})}if("se"==h){g.addClass("ui-icon ui-icon-gripsmall-diagonal-se")}this.handles[h]=".ui-resizable-"+h;this.element.append(g)}}this._renderAxis=function(p){p=p||this.element;for(var m in this.handles){if(this.handles[m].constructor==String){this.handles[m]=c(this.handles[m],this.element).show()}if(this.elementIsWrapper&&this.originalElement[0].nodeName.match(/textarea|input|select|button/i)){var n=c(this.handles[m],this.element),o=0;o=/sw|ne|nw|se|n|s/.test(m)?n.outerHeight():n.outerWidth();var l=["padding",/ne|nw|n/.test(m)?"Top":/se|sw|s/.test(m)?"Bottom":/^e$/.test(m)?"Right":"Left"].join("");p.css(l,o);this._proportionallyResize()}if(!c(this.handles[m]).length){continue}}};this._renderAxis(this.element);this._handles=c(".ui-resizable-handle",this.element).disableSelection();this._handles.mouseover(function(){if(!e.resizing){if(this.className){var i=this.className.match(/ui-resizable-(se|sw|ne|nw|n|e|s|w)/i)}e.axis=i&&i[1]?i[1]:"se"}});if(j.autoHide){this._handles.hide();c(this.element).addClass("ui-resizable-autohide").hover(function(){c(this).removeClass("ui-resizable-autohide");e._handles.show()},function(){if(!e.resizing){c(this).addClass("ui-resizable-autohide");e._handles.hide()}})}this._mouseInit()},destroy:function(){this._mouseDestroy();var d=function(f){c(f).removeClass("ui-resizable ui-resizable-disabled ui-resizable-resizing").removeData("resizable").unbind(".resizable").find(".ui-resizable-handle").remove()};if(this.elementIsWrapper){d(this.element);var e=this.element;e.parent().append(this.originalElement.css({position:e.css("position"),width:e.outerWidth(),height:e.outerHeight(),top:e.css("top"),left:e.css("left")})).end().remove()}this.originalElement.css("resize",this.originalResizeStyle);d(this.originalElement)},_mouseCapture:function(e){var f=false;for(var d in this.handles){if(c(this.handles[d])[0]==e.target){f=true}}return this.options.disabled||!!f},_mouseStart:function(f){var i=this.options,e=this.element.position(),d=this.element;this.resizing=true;this.documentScroll={top:c(document).scrollTop(),left:c(document).scrollLeft()};if(d.is(".ui-draggable")||(/absolute/).test(d.css("position"))){d.css({position:"absolute",top:e.top,left:e.left})}if(c.browser.opera&&(/relative/).test(d.css("position"))){d.css({position:"relative",top:"auto",left:"auto"})}this._renderProxy();var j=b(this.helper.css("left")),g=b(this.helper.css("top"));if(i.containment){j+=c(i.containment).scrollLeft()||0;g+=c(i.containment).scrollTop()||0}this.offset=this.helper.offset();this.position={left:j,top:g};this.size=this._helper?{width:d.outerWidth(),height:d.outerHeight()}:{width:d.width(),height:d.height()};this.originalSize=this._helper?{width:d.outerWidth(),height:d.outerHeight()}:{width:d.width(),height:d.height()};this.originalPosition={left:j,top:g};this.sizeDiff={width:d.outerWidth()-d.width(),height:d.outerHeight()-d.height()};this.originalMousePosition={left:f.pageX,top:f.pageY};this.aspectRatio=(typeof i.aspectRatio=="number")?i.aspectRatio:((this.originalSize.width/this.originalSize.height)||1);var h=c(".ui-resizable-"+this.axis).css("cursor");c("body").css("cursor",h=="auto"?this.axis+"-resize":h);d.addClass("ui-resizable-resizing");this._propagate("start",f);return true},_mouseDrag:function(d){var g=this.helper,f=this.options,l={},p=this,i=this.originalMousePosition,m=this.axis;var q=(d.pageX-i.left)||0,n=(d.pageY-i.top)||0;var h=this._change[m];if(!h){return false}var k=h.apply(this,[d,q,n]),j=c.browser.msie&&c.browser.version<7,e=this.sizeDiff;if(this._aspectRatio||d.shiftKey){k=this._updateRatio(k,d)}k=this._respectSize(k,d);this._propagate("resize",d);g.css({top:this.position.top+"px",left:this.position.left+"px",width:this.size.width+"px",height:this.size.height+"px"});if(!this._helper&&this._proportionallyResizeElements.length){this._proportionallyResize()}this._updateCache(k);this._trigger("resize",d,this.ui());return false},_mouseStop:function(g){this.resizing=false;var h=this.options,l=this;if(this._helper){var f=this._proportionallyResizeElements,d=f.length&&(/textarea/i).test(f[0].nodeName),e=d&&c.ui.hasScroll(f[0],"left")?0:l.sizeDiff.height,j=d?0:l.sizeDiff.width;var m={width:(l.size.width-j),height:(l.size.height-e)},i=(parseInt(l.element.css("left"),10)+(l.position.left-l.originalPosition.left))||null,k=(parseInt(l.element.css("top"),10)+(l.position.top-l.originalPosition.top))||null;if(!h.animate){this.element.css(c.extend(m,{top:k,left:i}))}l.helper.height(l.size.height);l.helper.width(l.size.width);if(this._helper&&!h.animate){this._proportionallyResize()}}c("body").css("cursor","auto");this.element.removeClass("ui-resizable-resizing");this._propagate("stop",g);if(this._helper){this.helper.remove()}return false},_updateCache:function(d){var e=this.options;this.offset=this.helper.offset();if(a(d.left)){this.position.left=d.left}if(a(d.top)){this.position.top=d.top}if(a(d.height)){this.size.height=d.height}if(a(d.width)){this.size.width=d.width}},_updateRatio:function(g,f){var h=this.options,i=this.position,e=this.size,d=this.axis;if(g.height){g.width=(e.height*this.aspectRatio)}else{if(g.width){g.height=(e.width/this.aspectRatio)}}if(d=="sw"){g.left=i.left+(e.width-g.width);g.top=null}if(d=="nw"){g.top=i.top+(e.height-g.height);g.left=i.left+(e.width-g.width)}return g},_respectSize:function(k,f){var i=this.helper,h=this.options,q=this._aspectRatio||f.shiftKey,p=this.axis,s=a(k.width)&&h.maxWidth&&(h.maxWidthk.width),r=a(k.height)&&h.minHeight&&(h.minHeight>k.height);if(g){k.width=h.minWidth}if(r){k.height=h.minHeight}if(s){k.width=h.maxWidth}if(l){k.height=h.maxHeight}var e=this.originalPosition.left+this.originalSize.width,n=this.position.top+this.size.height;var j=/sw|nw|w/.test(p),d=/nw|ne|n/.test(p);if(g&&j){k.left=e-h.minWidth}if(s&&j){k.left=e-h.maxWidth}if(r&&d){k.top=n-h.minHeight}if(l&&d){k.top=n-h.maxHeight}var m=!k.width&&!k.height;if(m&&!k.left&&k.top){k.top=null}else{if(m&&!k.top&&k.left){k.left=null}}return k},_proportionallyResize:function(){var j=this.options;if(!this._proportionallyResizeElements.length){return}var f=this.helper||this.element;for(var e=0;e');var d=c.browser.msie&&c.browser.version<7,f=(d?1:0),g=(d?2:-1);this.helper.addClass(this._helper).css({width:this.element.outerWidth()+g,height:this.element.outerHeight()+g,position:"absolute",left:this.elementOffset.left-f+"px",top:this.elementOffset.top-f+"px",zIndex:++h.zIndex});this.helper.appendTo("body").disableSelection()}else{this.helper=this.element}},_change:{e:function(f,e,d){return{width:this.originalSize.width+e}},w:function(g,e,d){var i=this.options,f=this.originalSize,h=this.originalPosition;return{left:h.left+e,width:f.width-e}},n:function(g,e,d){var i=this.options,f=this.originalSize,h=this.originalPosition;return{top:h.top+d,height:f.height-d}},s:function(f,e,d){return{height:this.originalSize.height+d}},se:function(f,e,d){return c.extend(this._change.s.apply(this,arguments),this._change.e.apply(this,[f,e,d]))},sw:function(f,e,d){return c.extend(this._change.s.apply(this,arguments),this._change.w.apply(this,[f,e,d]))},ne:function(f,e,d){return c.extend(this._change.n.apply(this,arguments),this._change.e.apply(this,[f,e,d]))},nw:function(f,e,d){return c.extend(this._change.n.apply(this,arguments),this._change.w.apply(this,[f,e,d]))}},_propagate:function(e,d){c.ui.plugin.call(this,e,[d,this.ui()]);(e!="resize"&&this._trigger(e,d,this.ui()))},plugins:{},ui:function(){return{originalElement:this.originalElement,element:this.element,helper:this.helper,position:this.position,size:this.size,originalSize:this.originalSize,originalPosition:this.originalPosition}}}));c.extend(c.ui.resizable,{version:"1.7.2",eventPrefix:"resize",defaults:{alsoResize:false,animate:false,animateDuration:"slow",animateEasing:"swing",aspectRatio:false,autoHide:false,cancel:":input,option",containment:false,delay:0,distance:1,ghost:false,grid:false,handles:"e,s,se",helper:false,maxHeight:null,maxWidth:null,minHeight:10,minWidth:10,zIndex:1000}});c.ui.plugin.add("resizable","alsoResize",{start:function(e,f){var d=c(this).data("resizable"),g=d.options;_store=function(h){c(h).each(function(){c(this).data("resizable-alsoresize",{width:parseInt(c(this).width(),10),height:parseInt(c(this).height(),10),left:parseInt(c(this).css("left"),10),top:parseInt(c(this).css("top"),10)})})};if(typeof(g.alsoResize)=="object"&&!g.alsoResize.parentNode){if(g.alsoResize.length){g.alsoResize=g.alsoResize[0];_store(g.alsoResize)}else{c.each(g.alsoResize,function(h,i){_store(h)})}}else{_store(g.alsoResize)}},resize:function(f,h){var e=c(this).data("resizable"),i=e.options,g=e.originalSize,k=e.originalPosition;var j={height:(e.size.height-g.height)||0,width:(e.size.width-g.width)||0,top:(e.position.top-k.top)||0,left:(e.position.left-k.left)||0},d=function(l,m){c(l).each(function(){var p=c(this),q=c(this).data("resizable-alsoresize"),o={},n=m&&m.length?m:["width","height","top","left"];c.each(n||["width","height","top","left"],function(r,t){var s=(q[t]||0)+(j[t]||0);if(s&&s>=0){o[t]=s||null}});if(/relative/.test(p.css("position"))&&c.browser.opera){e._revertToRelativePosition=true;p.css({position:"absolute",top:"auto",left:"auto"})}p.css(o)})};if(typeof(i.alsoResize)=="object"&&!i.alsoResize.nodeType){c.each(i.alsoResize,function(l,m){d(l,m)})}else{d(i.alsoResize)}},stop:function(e,f){var d=c(this).data("resizable");if(d._revertToRelativePosition&&c.browser.opera){d._revertToRelativePosition=false;el.css({position:"relative"})}c(this).removeData("resizable-alsoresize-start")}});c.ui.plugin.add("resizable","animate",{stop:function(h,m){var n=c(this).data("resizable"),i=n.options;var g=n._proportionallyResizeElements,d=g.length&&(/textarea/i).test(g[0].nodeName),e=d&&c.ui.hasScroll(g[0],"left")?0:n.sizeDiff.height,k=d?0:n.sizeDiff.width;var f={width:(n.size.width-k),height:(n.size.height-e)},j=(parseInt(n.element.css("left"),10)+(n.position.left-n.originalPosition.left))||null,l=(parseInt(n.element.css("top"),10)+(n.position.top-n.originalPosition.top))||null;n.element.animate(c.extend(f,l&&j?{top:l,left:j}:{}),{duration:i.animateDuration,easing:i.animateEasing,step:function(){var o={width:parseInt(n.element.css("width"),10),height:parseInt(n.element.css("height"),10),top:parseInt(n.element.css("top"),10),left:parseInt(n.element.css("left"),10)};if(g&&g.length){c(g[0]).css({width:o.width,height:o.height})}n._updateCache(o);n._propagate("resize",h)}})}});c.ui.plugin.add("resizable","containment",{start:function(e,q){var s=c(this).data("resizable"),i=s.options,k=s.element;var f=i.containment,j=(f instanceof c)?f.get(0):(/parent/.test(f))?k.parent().get(0):f;if(!j){return}s.containerElement=c(j);if(/document/.test(f)||f==document){s.containerOffset={left:0,top:0};s.containerPosition={left:0,top:0};s.parentData={element:c(document),left:0,top:0,width:c(document).width(),height:c(document).height()||document.body.parentNode.scrollHeight}}else{var m=c(j),h=[];c(["Top","Right","Left","Bottom"]).each(function(p,o){h[p]=b(m.css("padding"+o))});s.containerOffset=m.offset();s.containerPosition=m.position();s.containerSize={height:(m.innerHeight()-h[3]),width:(m.innerWidth()-h[1])};var n=s.containerOffset,d=s.containerSize.height,l=s.containerSize.width,g=(c.ui.hasScroll(j,"left")?j.scrollWidth:l),r=(c.ui.hasScroll(j)?j.scrollHeight:d);s.parentData={element:j,left:n.left,top:n.top,width:g,height:r}}},resize:function(f,p){var s=c(this).data("resizable"),h=s.options,e=s.containerSize,n=s.containerOffset,l=s.size,m=s.position,q=s._aspectRatio||f.shiftKey,d={top:0,left:0},g=s.containerElement;if(g[0]!=document&&(/static/).test(g.css("position"))){d=n}if(m.left<(s._helper?n.left:0)){s.size.width=s.size.width+(s._helper?(s.position.left-n.left):(s.position.left-d.left));if(q){s.size.height=s.size.width/h.aspectRatio}s.position.left=h.helper?n.left:0}if(m.top<(s._helper?n.top:0)) -{s.size.height=s.size.height+(s._helper?(s.position.top-n.top):s.position.top);if(q){s.size.width=s.size.height*h.aspectRatio}s.position.top=s._helper?n.top:0}s.offset.left=s.parentData.left+s.position.left;s.offset.top=s.parentData.top+s.position.top;var k=Math.abs((s._helper?s.offset.left-d.left:(s.offset.left-d.left))+s.sizeDiff.width),r=Math.abs((s._helper?s.offset.top-d.top:(s.offset.top-n.top))+s.sizeDiff.height);var j=s.containerElement.get(0)==s.element.parent().get(0),i=/relative|absolute/.test(s.containerElement.css("position"));if(j&&i){k-=s.parentData.left}if(k+s.size.width>=s.parentData.width){s.size.width=s.parentData.width-k;if(q){s.size.height=s.size.width/s.aspectRatio}}if(r+s.size.height>=s.parentData.height){s.size.height=s.parentData.height-r;if(q){s.size.width=s.size.height*s.aspectRatio}}},stop:function(e,m){var p=c(this).data("resizable"),f=p.options,k=p.position,l=p.containerOffset,d=p.containerPosition,g=p.containerElement;var i=c(p.helper),q=i.offset(),n=i.outerWidth()-p.sizeDiff.width,j=i.outerHeight()-p.sizeDiff.height;if(p._helper&&!f.animate&&(/relative/).test(g.css("position"))){c(this).css({left:q.left-d.left-l.left,width:n,height:j})}if(p._helper&&!f.animate&&(/static/).test(g.css("position"))){c(this).css({left:q.left-d.left-l.left,width:n,height:j})}}});c.ui.plugin.add("resizable","ghost",{start:function(f,g){var d=c(this).data("resizable"),h=d.options,e=d.size;d.ghost=d.originalElement.clone();d.ghost.css({opacity:0.25,display:"block",position:"relative",height:e.height,width:e.width,margin:0,left:0,top:0}).addClass("ui-resizable-ghost").addClass(typeof h.ghost=="string"?h.ghost:"");d.ghost.appendTo(d.helper)},resize:function(e,f){var d=c(this).data("resizable"),g=d.options;if(d.ghost){d.ghost.css({position:"relative",height:d.size.height,width:d.size.width})}},stop:function(e,f){var d=c(this).data("resizable"),g=d.options;if(d.ghost&&d.helper){d.helper.get(0).removeChild(d.ghost.get(0))}}});c.ui.plugin.add("resizable","grid",{resize:function(d,l){var n=c(this).data("resizable"),g=n.options,j=n.size,h=n.originalSize,i=n.originalPosition,m=n.axis,k=g._aspectRatio||d.shiftKey;g.grid=typeof g.grid=="number"?[g.grid,g.grid]:g.grid;var f=Math.round((j.width-h.width)/(g.grid[0]||1))*(g.grid[0]||1),e=Math.round((j.height-h.height)/(g.grid[1]||1))*(g.grid[1]||1);if(/^(se|s|e)$/.test(m)){n.size.width=h.width+f;n.size.height=h.height+e}else{if(/^(ne)$/.test(m)){n.size.width=h.width+f;n.size.height=h.height+e;n.position.top=i.top-e}else{if(/^(sw)$/.test(m)){n.size.width=h.width+f;n.size.height=h.height+e;n.position.left=i.left-f}else{n.size.width=h.width+f;n.size.height=h.height+e;n.position.top=i.top-e;n.position.left=i.left-f}}}}});var b=function(d){return parseInt(d,10)||0};var a=function(d){return !isNaN(parseInt(d,10))}})(jQuery);; -/** - * jQuery.ScrollTo - Easy element scrolling using jQuery. - * Copyright (c) 2008 Ariel Flesler - aflesler(at)gmail(dot)com - * Licensed under GPL license (http://www.opensource.org/licenses/gpl-license.php). - * Date: 2/8/2008 - * @author Ariel Flesler - * @version 1.3.2 - */ -;(function($){var o=$.scrollTo=function(a,b,c){o.window().scrollTo(a,b,c)};o.defaults={axis:'y',duration:1};o.window=function(){return $($.browser.safari?'body':'html')};$.fn.scrollTo=function(l,m,n){if(typeof m=='object'){n=m;m=0}n=$.extend({},o.defaults,n);m=m||n.speed||n.duration;n.queue=n.queue&&n.axis.length>1;if(n.queue)m/=2;n.offset=j(n.offset);n.over=j(n.over);return this.each(function(){var a=this,b=$(a),t=l,c,d={},w=b.is('html,body');switch(typeof t){case'number':case'string':if(/^([+-]=)?\d+(px)?$/.test(t)){t=j(t);break}t=$(t,this);case'object':if(t.is||t.style)c=(t=$(t)).offset()}$.each(n.axis.split(''),function(i,f){var P=f=='x'?'Left':'Top',p=P.toLowerCase(),k='scroll'+P,e=a[k],D=f=='x'?'Width':'Height';if(c){d[k]=c[p]+(w?0:e-b.offset()[p]);if(n.margin){d[k]-=parseInt(t.css('margin'+P))||0;d[k]-=parseInt(t.css('border'+P+'Width'))||0}d[k]+=n.offset[p]||0;if(n.over[p])d[k]+=t[D.toLowerCase()]()*n.over[p]}else d[k]=t[p];if(/^\d+$/.test(d[k]))d[k]=d[k]<=0?0:Math.min(d[k],h(D));if(!i&&n.queue){if(e!=d[k])g(n.onAfterFirst);delete d[k]}});g(n.onAfter);function g(a){b.animate(d,m,n.easing,a&&function(){a.call(this,l)})};function h(D){var b=w?$.browser.opera?document.body:document.documentElement:a;return b['scroll'+D]-b['client'+D]}})};function j(a){return typeof a=='object'?a:{top:a,left:a}}})(jQuery); - diff --git a/hecl-gui/quazip/doc/html/nav_f.png b/hecl-gui/quazip/doc/html/nav_f.png deleted file mode 100644 index 1b07a1620..000000000 Binary files a/hecl-gui/quazip/doc/html/nav_f.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/nav_h.png b/hecl-gui/quazip/doc/html/nav_h.png deleted file mode 100644 index 01f5fa6a5..000000000 Binary files a/hecl-gui/quazip/doc/html/nav_h.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/open.png b/hecl-gui/quazip/doc/html/open.png deleted file mode 100644 index 7b35d2c2c..000000000 Binary files a/hecl-gui/quazip/doc/html/open.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/pages.html b/hecl-gui/quazip/doc/html/pages.html deleted file mode 100644 index 2e2d852d7..000000000 --- a/hecl-gui/quazip/doc/html/pages.html +++ /dev/null @@ -1,49 +0,0 @@ - - - - -QuaZIP: Related Pages - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- -
-
-
-
Related Pages
-
-
-
Here is a list of all related documentation pages:
-
- - - diff --git a/hecl-gui/quazip/doc/html/quaadler32_8h_source.html b/hecl-gui/quazip/doc/html/quaadler32_8h_source.html deleted file mode 100644 index 3281fb8e9..000000000 --- a/hecl-gui/quazip/doc/html/quaadler32_8h_source.html +++ /dev/null @@ -1,104 +0,0 @@ - - - - -QuaZIP: quazip/quaadler32.h Source File - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - -
-
-
-
quaadler32.h
-
-
-
00001 #ifndef QUAADLER32_H
-00002 #define QUAADLER32_H
-00003 
-00004 /*
-00005 Copyright (C) 2010 Adam Walczak
-00006 Copyright (C) 2005-2014 Sergey A. Tachenov
-00007 
-00008 This file is part of QuaZIP.
-00009 
-00010 QuaZIP is free software: you can redistribute it and/or modify
-00011 it under the terms of the GNU Lesser General Public License as published by
-00012 the Free Software Foundation, either version 3 of the License, or
-00013 (at your option) any later version.
-00014 
-00015 QuaZIP is distributed in the hope that it will be useful,
-00016 but WITHOUT ANY WARRANTY; without even the implied warranty of
-00017 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-00018 GNU Lesser General Public License for more details.
-00019 
-00020 You should have received a copy of the GNU Lesser General Public License
-00021 along with QuaZIP.  If not, see <http://www.gnu.org/licenses/>.
-00022 
-00023 See COPYING file for the full LGPL text.
-00024 
-00025 Original ZIP package is copyrighted by Gilles Vollant and contributors,
-00026 see quazip/(un)zip.h files for details. Basically it's the zlib license.
-00027 */
-00028 
-00029 #include <QByteArray>
-00030 
-00031 #include "quachecksum32.h"
-00032 
-00034 
-00038 class QUAZIP_EXPORT QuaAdler32 : public QuaChecksum32
-00039 {
-00040 
-00041 public:
-00042         QuaAdler32();
-00043 
-00044         quint32 calculate(const QByteArray &data);
-00045 
-00046         void reset();
-00047         void update(const QByteArray &buf);
-00048         quint32 value();
-00049 
-00050 private:
-00051         quint32 checksum;
-00052 };
-00053 
-00054 #endif //QUAADLER32_H
-
- - - - diff --git a/hecl-gui/quazip/doc/html/quachecksum32_8h_source.html b/hecl-gui/quazip/doc/html/quachecksum32_8h_source.html deleted file mode 100644 index cafa25c93..000000000 --- a/hecl-gui/quazip/doc/html/quachecksum32_8h_source.html +++ /dev/null @@ -1,102 +0,0 @@ - - - - -QuaZIP: quazip/quachecksum32.h Source File - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - -
-
-
-
quachecksum32.h
-
-
-
00001 #ifndef QUACHECKSUM32_H
-00002 #define QUACHECKSUM32_H
-00003 
-00004 /*
-00005 Copyright (C) 2005-2014 Sergey A. Tachenov
-00006 
-00007 This file is part of QuaZIP.
-00008 
-00009 QuaZIP is free software: you can redistribute it and/or modify
-00010 it under the terms of the GNU Lesser General Public License as published by
-00011 the Free Software Foundation, either version 3 of the License, or
-00012 (at your option) any later version.
-00013 
-00014 QuaZIP is distributed in the hope that it will be useful,
-00015 but WITHOUT ANY WARRANTY; without even the implied warranty of
-00016 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-00017 GNU Lesser General Public License for more details.
-00018 
-00019 You should have received a copy of the GNU Lesser General Public License
-00020 along with QuaZIP.  If not, see <http://www.gnu.org/licenses/>.
-00021 
-00022 See COPYING file for the full LGPL text.
-00023 
-00024 Original ZIP package is copyrighted by Gilles Vollant and contributors,
-00025 see quazip/(un)zip.h files for details. Basically it's the zlib license.
-00026 */
-00027 
-00028 #include <QByteArray>
-00029 #include "quazip_global.h"
-00030 
-00032 
-00052 class QUAZIP_EXPORT QuaChecksum32
-00053 {
-00054 
-00055 public:
-00057 
-00062         virtual quint32 calculate(const QByteArray &data) = 0;
-00063 
-00065         virtual void reset() = 0;
-00066 
-00068 
-00070         virtual void update(const QByteArray &buf) = 0;
-00071 
-00073 
-00075         virtual quint32 value() = 0;
-00076 };
-00077 
-00078 #endif //QUACHECKSUM32_H
-
- - - - diff --git a/hecl-gui/quazip/doc/html/quacrc32_8h_source.html b/hecl-gui/quazip/doc/html/quacrc32_8h_source.html deleted file mode 100644 index c1a5c7768..000000000 --- a/hecl-gui/quazip/doc/html/quacrc32_8h_source.html +++ /dev/null @@ -1,100 +0,0 @@ - - - - -QuaZIP: quazip/quacrc32.h Source File - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - -
-
-
-
quacrc32.h
-
-
-
00001 #ifndef QUACRC32_H
-00002 #define QUACRC32_H
-00003 
-00004 /*
-00005 Copyright (C) 2005-2014 Sergey A. Tachenov
-00006 
-00007 This file is part of QuaZIP.
-00008 
-00009 QuaZIP is free software: you can redistribute it and/or modify
-00010 it under the terms of the GNU Lesser General Public License as published by
-00011 the Free Software Foundation, either version 3 of the License, or
-00012 (at your option) any later version.
-00013 
-00014 QuaZIP is distributed in the hope that it will be useful,
-00015 but WITHOUT ANY WARRANTY; without even the implied warranty of
-00016 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-00017 GNU Lesser General Public License for more details.
-00018 
-00019 You should have received a copy of the GNU Lesser General Public License
-00020 along with QuaZIP.  If not, see <http://www.gnu.org/licenses/>.
-00021 
-00022 See COPYING file for the full LGPL text.
-00023 
-00024 Original ZIP package is copyrighted by Gilles Vollant and contributors,
-00025 see quazip/(un)zip.h files for details. Basically it's the zlib license.
-00026 */
-00027 
-00028 #include "quachecksum32.h"
-00029 
-00031 
-00035 class QUAZIP_EXPORT QuaCrc32 : public QuaChecksum32 {
-00036 
-00037 public:
-00038         QuaCrc32();
-00039 
-00040         quint32 calculate(const QByteArray &data);
-00041 
-00042         void reset();
-00043         void update(const QByteArray &buf);
-00044         quint32 value();
-00045 
-00046 private:
-00047         quint32 checksum;
-00048 };
-00049 
-00050 #endif //QUACRC32_H
-
- - - - diff --git a/hecl-gui/quazip/doc/html/quagzipfile_8h_source.html b/hecl-gui/quazip/doc/html/quagzipfile_8h_source.html deleted file mode 100644 index 6c5826441..000000000 --- a/hecl-gui/quazip/doc/html/quagzipfile_8h_source.html +++ /dev/null @@ -1,121 +0,0 @@ - - - - -QuaZIP: quazip/quagzipfile.h Source File - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - -
-
-
-
quagzipfile.h
-
-
-
00001 #ifndef QUAZIP_QUAGZIPFILE_H
-00002 #define QUAZIP_QUAGZIPFILE_H
-00003 
-00004 /*
-00005 Copyright (C) 2005-2014 Sergey A. Tachenov
-00006 
-00007 This file is part of QuaZIP.
-00008 
-00009 QuaZIP is free software: you can redistribute it and/or modify
-00010 it under the terms of the GNU Lesser General Public License as published by
-00011 the Free Software Foundation, either version 3 of the License, or
-00012 (at your option) any later version.
-00013 
-00014 QuaZIP is distributed in the hope that it will be useful,
-00015 but WITHOUT ANY WARRANTY; without even the implied warranty of
-00016 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-00017 GNU Lesser General Public License for more details.
-00018 
-00019 You should have received a copy of the GNU Lesser General Public License
-00020 along with QuaZIP.  If not, see <http://www.gnu.org/licenses/>.
-00021 
-00022 See COPYING file for the full LGPL text.
-00023 
-00024 Original ZIP package is copyrighted by Gilles Vollant and contributors,
-00025 see quazip/(un)zip.h files for details. Basically it's the zlib license.
-00026 */
-00027 
-00028 #include <QIODevice>
-00029 #include "quazip_global.h"
-00030 
-00031 #include <zlib.h>
-00032 
-00033 class QuaGzipFilePrivate;
-00034 
-00036 
-00039 class QUAZIP_EXPORT QuaGzipFile: public QIODevice {
-00040   Q_OBJECT
-00041 public:
-00043 
-00046   QuaGzipFile();
-00048 
-00052   QuaGzipFile(QObject *parent);
-00054 
-00058   QuaGzipFile(const QString &fileName, QObject *parent = NULL);
-00060   virtual ~QuaGzipFile();
-00062   void setFileName(const QString& fileName);
-00064   QString getFileName() const;
-00066 
-00073   virtual bool isSequential() const;
-00075 
-00079   virtual bool open(QIODevice::OpenMode mode);
-00081 
-00087   virtual bool open(int fd, QIODevice::OpenMode mode);
-00089 
-00093   virtual bool flush();
-00095   virtual void close();
-00096 protected:
-00098   virtual qint64 readData(char *data, qint64 maxSize);
-00100   virtual qint64 writeData(const char *data, qint64 maxSize);
-00101 private:
-00102     // not implemented by design to disable copy
-00103     QuaGzipFile(const QuaGzipFile &that);
-00104     QuaGzipFile& operator=(const QuaGzipFile &that);
-00105     QuaGzipFilePrivate *d;
-00106 };
-00107 
-00108 #endif // QUAZIP_QUAGZIPFILE_H
-
- - - - diff --git a/hecl-gui/quazip/doc/html/quaziodevice_8h_source.html b/hecl-gui/quazip/doc/html/quaziodevice_8h_source.html deleted file mode 100644 index 59b179ae9..000000000 --- a/hecl-gui/quazip/doc/html/quaziodevice_8h_source.html +++ /dev/null @@ -1,110 +0,0 @@ - - - - -QuaZIP: quazip/quaziodevice.h Source File - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - -
-
-
-
quaziodevice.h
-
-
-
00001 #ifndef QUAZIP_QUAZIODEVICE_H
-00002 #define QUAZIP_QUAZIODEVICE_H
-00003 
-00004 /*
-00005 Copyright (C) 2005-2014 Sergey A. Tachenov
-00006 
-00007 This file is part of QuaZIP.
-00008 
-00009 QuaZIP is free software: you can redistribute it and/or modify
-00010 it under the terms of the GNU Lesser General Public License as published by
-00011 the Free Software Foundation, either version 3 of the License, or
-00012 (at your option) any later version.
-00013 
-00014 QuaZIP is distributed in the hope that it will be useful,
-00015 but WITHOUT ANY WARRANTY; without even the implied warranty of
-00016 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-00017 GNU Lesser General Public License for more details.
-00018 
-00019 You should have received a copy of the GNU Lesser General Public License
-00020 along with QuaZIP.  If not, see <http://www.gnu.org/licenses/>.
-00021 
-00022 See COPYING file for the full LGPL text.
-00023 
-00024 Original ZIP package is copyrighted by Gilles Vollant and contributors,
-00025 see quazip/(un)zip.h files for details. Basically it's the zlib license.
-00026 */
-00027 
-00028 #include <QIODevice>
-00029 #include "quazip_global.h"
-00030 
-00031 #include <zlib.h>
-00032 
-00033 class QuaZIODevicePrivate;
-00034 
-00036 
-00041 class QUAZIP_EXPORT QuaZIODevice: public QIODevice {
-00042   Q_OBJECT
-00043 public:
-00045 
-00049   QuaZIODevice(QIODevice *io, QObject *parent = NULL);
-00051   ~QuaZIODevice();
-00053 
-00073   virtual bool flush();
-00075 
-00079   virtual bool open(QIODevice::OpenMode mode);
-00081 
-00085   virtual void close();
-00087   QIODevice *getIoDevice() const;
-00089   virtual bool isSequential() const;
-00090 protected:
-00092   virtual qint64 readData(char *data, qint64 maxSize);
-00094   virtual qint64 writeData(const char *data, qint64 maxSize);
-00095 private:
-00096   QuaZIODevicePrivate *d;
-00097 };
-00098 #endif // QUAZIP_QUAZIODEVICE_H
-
- - - - diff --git a/hecl-gui/quazip/doc/html/quazip_8h_source.html b/hecl-gui/quazip/doc/html/quazip_8h_source.html deleted file mode 100644 index a9619960e..000000000 --- a/hecl-gui/quazip/doc/html/quazip_8h_source.html +++ /dev/null @@ -1,208 +0,0 @@ - - - - -QuaZIP: quazip/quazip.h Source File - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - -
-
-
-
quazip.h
-
-
-
00001 #ifndef QUA_ZIP_H
-00002 #define QUA_ZIP_H
-00003 
-00004 /*
-00005 Copyright (C) 2005-2014 Sergey A. Tachenov
-00006 
-00007 This file is part of QuaZIP.
-00008 
-00009 QuaZIP is free software: you can redistribute it and/or modify
-00010 it under the terms of the GNU Lesser General Public License as published by
-00011 the Free Software Foundation, either version 3 of the License, or
-00012 (at your option) any later version.
-00013 
-00014 QuaZIP is distributed in the hope that it will be useful,
-00015 but WITHOUT ANY WARRANTY; without even the implied warranty of
-00016 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-00017 GNU Lesser General Public License for more details.
-00018 
-00019 You should have received a copy of the GNU Lesser General Public License
-00020 along with QuaZIP.  If not, see <http://www.gnu.org/licenses/>.
-00021 
-00022 See COPYING file for the full LGPL text.
-00023 
-00024 Original ZIP package is copyrighted by Gilles Vollant, see
-00025 quazip/(un)zip.h files for details, basically it's zlib license.
-00026  **/
-00027 
-00028 #include <QString>
-00029 #include <QStringList>
-00030 #include <QTextCodec>
-00031 
-00032 #include "zip.h"
-00033 #include "unzip.h"
-00034 
-00035 #include "quazip_global.h"
-00036 #include "quazipfileinfo.h"
-00037 
-00038 // just in case it will be defined in the later versions of the ZIP/UNZIP
-00039 #ifndef UNZ_OPENERROR
-00040 // define additional error code
-00041 #define UNZ_OPENERROR -1000
-00042 #endif
-00043 
-00044 class QuaZipPrivate;
-00045 
-00047 
-00084 class QUAZIP_EXPORT QuaZip {
-00085   friend class QuaZipPrivate;
-00086   public:
-00088     enum Constants {
-00089       MAX_FILE_NAME_LENGTH=256 
-00092     };
-00094     enum Mode {
-00095       mdNotOpen, 
-00096       mdUnzip, 
-00097       mdCreate, 
-00098       mdAppend, 
-00106       mdAdd 
-00107     };
-00109 
-00114     enum CaseSensitivity {
-00115       csDefault=0, 
-00116       csSensitive=1, 
-00117       csInsensitive=2 
-00118     };
-00120 
-00126     static Qt::CaseSensitivity convertCaseSensitivity(
-00127             CaseSensitivity cs);
-00128   private:
-00129     QuaZipPrivate *p;
-00130     // not (and will not be) implemented
-00131     QuaZip(const QuaZip& that);
-00132     // not (and will not be) implemented
-00133     QuaZip& operator=(const QuaZip& that);
-00134   public:
-00136 
-00137     QuaZip();
-00139     QuaZip(const QString& zipName);
-00141 
-00142     QuaZip(QIODevice *ioDevice);
-00144 
-00145     ~QuaZip();
-00147 
-00187     bool open(Mode mode, zlib_filefunc_def *ioApi =NULL);
-00189 
-00211     void close();
-00213 
-00218     void setFileNameCodec(QTextCodec *fileNameCodec);
-00220 
-00223     void setFileNameCodec(const char *fileNameCodecName);
-00225     QTextCodec* getFileNameCodec() const;
-00227 
-00229     void setCommentCodec(QTextCodec *commentCodec);
-00231 
-00234     void setCommentCodec(const char *commentCodecName);
-00236     QTextCodec* getCommentCodec() const;
-00238 
-00243     QString getZipName() const;
-00245 
-00250     void setZipName(const QString& zipName);
-00252 
-00256     QIODevice *getIoDevice() const;
-00258 
-00263     void setIoDevice(QIODevice *ioDevice);
-00265     Mode getMode() const;
-00267     bool isOpen() const;
-00269 
-00277     int getZipError() const;
-00279 
-00282     int getEntriesCount() const;
-00284     QString getComment() const;
-00286 
-00294     void setComment(const QString& comment);
-00296 
-00299     bool goToFirstFile();
-00301 
-00318     bool goToNextFile();
-00320 
-00344     bool setCurrentFile(const QString& fileName, CaseSensitivity cs =csDefault);
-00346     bool hasCurrentFile() const;
-00348 
-00369     bool getCurrentFileInfo(QuaZipFileInfo* info)const;
-00371 
-00379     bool getCurrentFileInfo(QuaZipFileInfo64* info)const;
-00381 
-00387     QString getCurrentFileName()const;
-00389 
-00404     unzFile getUnzFile();
-00406 
-00410     zipFile getZipFile();
-00412 
-00435     void setDataDescriptorWritingEnabled(bool enabled);
-00437 
-00440     bool isDataDescriptorWritingEnabled() const;
-00442 
-00448     QStringList getFileNameList() const;
-00450 
-00462     QList<QuaZipFileInfo> getFileInfoList() const;
-00464 
-00472     QList<QuaZipFileInfo64> getFileInfoList64() const;
-00474 
-00487     void setZip64Enabled(bool zip64);
-00489 
-00494     bool isZip64Enabled() const;
-00496 
-00499     bool isAutoClose() const;
-00501 
-00521     void setAutoClose(bool autoClose) const;
-00523 
-00552     static void setDefaultFileNameCodec(QTextCodec *codec);
-00558     static void setDefaultFileNameCodec(const char *codecName);
-00559 };
-00560 
-00561 #endif
-
- - - - diff --git a/hecl-gui/quazip/doc/html/quazip__global_8h_source.html b/hecl-gui/quazip/doc/html/quazip__global_8h_source.html deleted file mode 100644 index 285a7d41e..000000000 --- a/hecl-gui/quazip/doc/html/quazip__global_8h_source.html +++ /dev/null @@ -1,104 +0,0 @@ - - - - -QuaZIP: quazip/quazip_global.h Source File - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - -
-
-
-
quazip_global.h
-
-
-
00001 #ifndef QUAZIP_GLOBAL_H
-00002 #define QUAZIP_GLOBAL_H
-00003 
-00004 /*
-00005 Copyright (C) 2005-2014 Sergey A. Tachenov
-00006 
-00007 This file is part of QuaZIP.
-00008 
-00009 QuaZIP is free software: you can redistribute it and/or modify
-00010 it under the terms of the GNU Lesser General Public License as published by
-00011 the Free Software Foundation, either version 3 of the License, or
-00012 (at your option) any later version.
-00013 
-00014 QuaZIP is distributed in the hope that it will be useful,
-00015 but WITHOUT ANY WARRANTY; without even the implied warranty of
-00016 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-00017 GNU Lesser General Public License for more details.
-00018 
-00019 You should have received a copy of the GNU Lesser General Public License
-00020 along with QuaZIP.  If not, see <http://www.gnu.org/licenses/>.
-00021 
-00022 See COPYING file for the full LGPL text.
-00023 
-00024 Original ZIP package is copyrighted by Gilles Vollant and contributors,
-00025 see quazip/(un)zip.h files for details. Basically it's the zlib license.
-00026 */
-00027 
-00028 #include <QtCore/qglobal.h>
-00029 
-00036 #ifdef QUAZIP_STATIC
-00037 #define QUAZIP_EXPORT
-00038 #else
-00039 
-00043 #if defined(QUAZIP_BUILD)
-00044         #define QUAZIP_EXPORT Q_DECL_EXPORT
-00045 #else
-00046         #define QUAZIP_EXPORT Q_DECL_IMPORT
-00047 #endif
-00048 #endif // QUAZIP_STATIC
-00049 
-00050 #ifdef __GNUC__
-00051 #define UNUSED __attribute__((__unused__))
-00052 #else
-00053 #define UNUSED
-00054 #endif
-00055 
-00056 #define QUAZIP_EXTRA_NTFS_MAGIC 0x000Au
-00057 #define QUAZIP_EXTRA_NTFS_TIME_MAGIC 0x0001u
-00058 
-00059 #endif // QUAZIP_GLOBAL_H
-
- - - - diff --git a/hecl-gui/quazip/doc/html/quazipdir_8h_source.html b/hecl-gui/quazip/doc/html/quazipdir_8h_source.html deleted file mode 100644 index ab7f33d1e..000000000 --- a/hecl-gui/quazip/doc/html/quazipdir_8h_source.html +++ /dev/null @@ -1,155 +0,0 @@ - - - - -QuaZIP: quazip/quazipdir.h Source File - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - -
-
-
-
quazipdir.h
-
-
-
00001 #ifndef QUAZIP_QUAZIPDIR_H
-00002 #define QUAZIP_QUAZIPDIR_H
-00003 
-00004 /*
-00005 Copyright (C) 2005-2014 Sergey A. Tachenov
-00006 
-00007 This file is part of QuaZIP.
-00008 
-00009 QuaZIP is free software: you can redistribute it and/or modify
-00010 it under the terms of the GNU Lesser General Public License as published by
-00011 the Free Software Foundation, either version 3 of the License, or
-00012 (at your option) any later version.
-00013 
-00014 QuaZIP is distributed in the hope that it will be useful,
-00015 but WITHOUT ANY WARRANTY; without even the implied warranty of
-00016 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-00017 GNU Lesser General Public License for more details.
-00018 
-00019 You should have received a copy of the GNU Lesser General Public License
-00020 along with QuaZIP.  If not, see <http://www.gnu.org/licenses/>.
-00021 
-00022 See COPYING file for the full LGPL text.
-00023 
-00024 Original ZIP package is copyrighted by Gilles Vollant and contributors,
-00025 see quazip/(un)zip.h files for details. Basically it's the zlib license.
-00026 */
-00027 
-00028 class QuaZipDirPrivate;
-00029 
-00030 #include "quazip.h"
-00031 #include "quazipfileinfo.h"
-00032 #include <QDir>
-00033 #include <QList>
-00034 #include <QSharedDataPointer>
-00035 
-00037 
-00054 class QUAZIP_EXPORT QuaZipDir {
-00055 private:
-00056     QSharedDataPointer<QuaZipDirPrivate> d;
-00057 public:
-00059     QuaZipDir(const QuaZipDir &that);
-00061 
-00065     QuaZipDir(QuaZip *zip, const QString &dir = QString());
-00067     ~QuaZipDir();
-00069     bool operator==(const QuaZipDir &that);
-00071 
-00075     inline bool operator!=(const QuaZipDir &that) {return !operator==(that);}
-00077 
-00081     QuaZipDir& operator=(const QuaZipDir &that);
-00083     QString operator[](int pos) const;
-00085     QuaZip::CaseSensitivity caseSensitivity() const;
-00087 
-00096     bool cd(const QString &dirName);
-00098     bool cdUp();
-00100     uint count() const;
-00102 
-00105     QString dirName() const;
-00107 
-00114     QList<QuaZipFileInfo> entryInfoList(const QStringList &nameFilters,
-00115         QDir::Filters filters = QDir::NoFilter,
-00116         QDir::SortFlags sort = QDir::NoSort) const;
-00118 
-00123     QList<QuaZipFileInfo> entryInfoList(QDir::Filters filters = QDir::NoFilter,
-00124         QDir::SortFlags sort = QDir::NoSort) const;
-00126 
-00133     QList<QuaZipFileInfo64> entryInfoList64(const QStringList &nameFilters,
-00134         QDir::Filters filters = QDir::NoFilter,
-00135         QDir::SortFlags sort = QDir::NoSort) const;
-00137 
-00142     QList<QuaZipFileInfo64> entryInfoList64(QDir::Filters filters = QDir::NoFilter,
-00143         QDir::SortFlags sort = QDir::NoSort) const;
-00145 
-00149     QStringList entryList(const QStringList &nameFilters,
-00150         QDir::Filters filters = QDir::NoFilter,
-00151         QDir::SortFlags sort = QDir::NoSort) const;
-00153 
-00158     QStringList entryList(QDir::Filters filters = QDir::NoFilter,
-00159         QDir::SortFlags sort = QDir::NoSort) const;
-00161 
-00167     bool exists(const QString &fileName) const;
-00169     bool exists() const;
-00171 
-00174     QString filePath(const QString &fileName) const;
-00176     QDir::Filters filter();
-00178 
-00181     bool isRoot() const;
-00183     QStringList nameFilters() const;
-00185 
-00189     QString path() const;
-00191 
-00199     QString relativeFilePath(const QString &fileName) const;
-00201     void setCaseSensitivity(QuaZip::CaseSensitivity caseSensitivity);
-00203     void setFilter(QDir::Filters filters);
-00205     void setNameFilters(const QStringList &nameFilters);
-00207 
-00216     void setPath(const QString &path);
-00218     void setSorting(QDir::SortFlags sort);
-00220     QDir::SortFlags sorting() const;
-00221 };
-00222 
-00223 #endif // QUAZIP_QUAZIPDIR_H
-
- - - - diff --git a/hecl-gui/quazip/doc/html/quazipfile_8h_source.html b/hecl-gui/quazip/doc/html/quazipfile_8h_source.html deleted file mode 100644 index 36f5f8bed..000000000 --- a/hecl-gui/quazip/doc/html/quazipfile_8h_source.html +++ /dev/null @@ -1,167 +0,0 @@ - - - - -QuaZIP: quazip/quazipfile.h Source File - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - -
-
-
-
quazipfile.h
-
-
-
00001 #ifndef QUA_ZIPFILE_H
-00002 #define QUA_ZIPFILE_H
-00003 
-00004 /*
-00005 Copyright (C) 2005-2014 Sergey A. Tachenov
-00006 
-00007 This file is part of QuaZIP.
-00008 
-00009 QuaZIP is free software: you can redistribute it and/or modify
-00010 it under the terms of the GNU Lesser General Public License as published by
-00011 the Free Software Foundation, either version 3 of the License, or
-00012 (at your option) any later version.
-00013 
-00014 QuaZIP is distributed in the hope that it will be useful,
-00015 but WITHOUT ANY WARRANTY; without even the implied warranty of
-00016 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-00017 GNU Lesser General Public License for more details.
-00018 
-00019 You should have received a copy of the GNU Lesser General Public License
-00020 along with QuaZIP.  If not, see <http://www.gnu.org/licenses/>.
-00021 
-00022 See COPYING file for the full LGPL text.
-00023 
-00024 Original ZIP package is copyrighted by Gilles Vollant, see
-00025 quazip/(un)zip.h files for details, basically it's zlib license.
-00026  **/
-00027 
-00028 #include <QIODevice>
-00029 
-00030 #include "quazip_global.h"
-00031 #include "quazip.h"
-00032 #include "quazipnewinfo.h"
-00033 
-00034 class QuaZipFilePrivate;
-00035 
-00037 
-00074 class QUAZIP_EXPORT QuaZipFile: public QIODevice {
-00075   friend class QuaZipFilePrivate;
-00076   Q_OBJECT
-00077   private:
-00078     QuaZipFilePrivate *p;
-00079     // these are not supported nor implemented
-00080     QuaZipFile(const QuaZipFile& that);
-00081     QuaZipFile& operator=(const QuaZipFile& that);
-00082   protected:
-00084     qint64 readData(char *data, qint64 maxSize);
-00086     qint64 writeData(const char *data, qint64 maxSize);
-00087   public:
-00089 
-00092     QuaZipFile();
-00094 
-00099     QuaZipFile(QObject *parent);
-00101 
-00110     QuaZipFile(const QString& zipName, QObject *parent =NULL);
-00112 
-00121     QuaZipFile(const QString& zipName, const QString& fileName,
-00122         QuaZip::CaseSensitivity cs =QuaZip::csDefault, QObject *parent =NULL);
-00124 
-00172     QuaZipFile(QuaZip *zip, QObject *parent =NULL);
-00174 
-00177     virtual ~QuaZipFile();
-00179 
-00188     QString getZipName()const;
-00190 
-00193     QuaZip* getZip()const;
-00195 
-00207     QString getFileName() const;
-00209 
-00220     QuaZip::CaseSensitivity getCaseSensitivity() const;
-00222 
-00246     QString getActualFileName()const;
-00248 
-00254     void setZipName(const QString& zipName);
-00256 
-00260     bool isRaw() const;
-00262 
-00270     void setZip(QuaZip *zip);
-00272 
-00283     void setFileName(const QString& fileName, QuaZip::CaseSensitivity cs =QuaZip::csDefault);
-00285 
-00292     virtual bool open(OpenMode mode);
-00294 
-00298     inline bool open(OpenMode mode, const char *password)
-00299     {return open(mode, NULL, NULL, false, password);}
-00301 
-00312     bool open(OpenMode mode, int *method, int *level, bool raw, const char *password =NULL);
-00314 
-00341     bool open(OpenMode mode, const QuaZipNewInfo& info,
-00342         const char *password =NULL, quint32 crc =0,
-00343         int method =Z_DEFLATED, int level =Z_DEFAULT_COMPRESSION, bool raw =false,
-00344         int windowBits =-MAX_WBITS, int memLevel =DEF_MEM_LEVEL, int strategy =Z_DEFAULT_STRATEGY);
-00346     virtual bool isSequential()const;
-00348 
-00369     virtual qint64 pos()const;
-00371 
-00387     virtual bool atEnd()const;
-00389 
-00401     virtual qint64 size()const;
-00403 
-00410     qint64 csize()const;
-00412 
-00420     qint64 usize()const;
-00422 
-00438     bool getFileInfo(QuaZipFileInfo *info);
-00440 
-00445     bool getFileInfo(QuaZipFileInfo64 *info);
-00447 
-00449     virtual void close();
-00451     int getZipError() const;
-00453     virtual qint64 bytesAvailable() const;
-00454 };
-00455 
-00456 #endif
-
- - - - diff --git a/hecl-gui/quazip/doc/html/quazipfileinfo_8h_source.html b/hecl-gui/quazip/doc/html/quazipfileinfo_8h_source.html deleted file mode 100644 index 5c2089d11..000000000 --- a/hecl-gui/quazip/doc/html/quazipfileinfo_8h_source.html +++ /dev/null @@ -1,137 +0,0 @@ - - - - -QuaZIP: quazip/quazipfileinfo.h Source File - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - -
-
-
-
quazipfileinfo.h
-
-
-
00001 #ifndef QUA_ZIPFILEINFO_H
-00002 #define QUA_ZIPFILEINFO_H
-00003 
-00004 /*
-00005 Copyright (C) 2005-2014 Sergey A. Tachenov
-00006 
-00007 This file is part of QuaZIP.
-00008 
-00009 QuaZIP is free software: you can redistribute it and/or modify
-00010 it under the terms of the GNU Lesser General Public License as published by
-00011 the Free Software Foundation, either version 3 of the License, or
-00012 (at your option) any later version.
-00013 
-00014 QuaZIP is distributed in the hope that it will be useful,
-00015 but WITHOUT ANY WARRANTY; without even the implied warranty of
-00016 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-00017 GNU Lesser General Public License for more details.
-00018 
-00019 You should have received a copy of the GNU Lesser General Public License
-00020 along with QuaZIP.  If not, see <http://www.gnu.org/licenses/>.
-00021 
-00022 See COPYING file for the full LGPL text.
-00023 
-00024 Original ZIP package is copyrighted by Gilles Vollant and contributors,
-00025 see quazip/(un)zip.h files for details. Basically it's the zlib license.
-00026 */
-00027 
-00028 #include <QByteArray>
-00029 #include <QDateTime>
-00030 #include <QFile>
-00031 
-00032 #include "quazip_global.h"
-00033 
-00035 
-00037 struct QUAZIP_EXPORT QuaZipFileInfo {
-00039   QString name;
-00041   quint16 versionCreated;
-00043   quint16 versionNeeded;
-00045   quint16 flags;
-00047   quint16 method;
-00049   QDateTime dateTime;
-00051   quint32 crc;
-00053   quint32 compressedSize;
-00055   quint32 uncompressedSize;
-00057   quint16 diskNumberStart;
-00059   quint16 internalAttr;
-00061   quint32 externalAttr;
-00063   QString comment;
-00065   QByteArray extra;
-00067 
-00071   QFile::Permissions getPermissions() const;
-00072 };
-00073 
-00075 
-00077 struct QUAZIP_EXPORT QuaZipFileInfo64 {
-00079   QString name;
-00081   quint16 versionCreated;
-00083   quint16 versionNeeded;
-00085   quint16 flags;
-00087   quint16 method;
-00089 
-00096   QDateTime dateTime;
-00098   quint32 crc;
-00100   quint64 compressedSize;
-00102   quint64 uncompressedSize;
-00104   quint16 diskNumberStart;
-00106   quint16 internalAttr;
-00108   quint32 externalAttr;
-00110   QString comment;
-00112   QByteArray extra;
-00114 
-00118   QFile::Permissions getPermissions() const;
-00120 
-00130   bool toQuaZipFileInfo(QuaZipFileInfo &info) const;
-00132 
-00143   QDateTime getNTFSmTime(int *fineTicks = NULL) const;
-00145 
-00156   QDateTime getNTFSaTime(int *fineTicks = NULL) const;
-00158 
-00169   QDateTime getNTFScTime(int *fineTicks = NULL) const;
-00170 };
-00171 
-00172 #endif
-
- - - - diff --git a/hecl-gui/quazip/doc/html/quazipnewinfo_8h_source.html b/hecl-gui/quazip/doc/html/quazipnewinfo_8h_source.html deleted file mode 100644 index 2ed744925..000000000 --- a/hecl-gui/quazip/doc/html/quazipnewinfo_8h_source.html +++ /dev/null @@ -1,129 +0,0 @@ - - - - -QuaZIP: quazip/quazipnewinfo.h Source File - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - - -
-
-
-
quazipnewinfo.h
-
-
-
00001 #ifndef QUA_ZIPNEWINFO_H
-00002 #define QUA_ZIPNEWINFO_H
-00003 
-00004 /*
-00005 Copyright (C) 2005-2014 Sergey A. Tachenov
-00006 
-00007 This file is part of QuaZIP.
-00008 
-00009 QuaZIP is free software: you can redistribute it and/or modify
-00010 it under the terms of the GNU Lesser General Public License as published by
-00011 the Free Software Foundation, either version 3 of the License, or
-00012 (at your option) any later version.
-00013 
-00014 QuaZIP is distributed in the hope that it will be useful,
-00015 but WITHOUT ANY WARRANTY; without even the implied warranty of
-00016 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-00017 GNU Lesser General Public License for more details.
-00018 
-00019 You should have received a copy of the GNU Lesser General Public License
-00020 along with QuaZIP.  If not, see <http://www.gnu.org/licenses/>.
-00021 
-00022 See COPYING file for the full LGPL text.
-00023 
-00024 Original ZIP package is copyrighted by Gilles Vollant, see
-00025 quazip/(un)zip.h files for details, basically it's zlib license.
-00026  **/
-00027 
-00028 #include <QDateTime>
-00029 #include <QFile>
-00030 #include <QString>
-00031 
-00032 #include "quazip_global.h"
-00033 
-00034 #include "quazipfileinfo.h"
-00035 
-00037 
-00050 struct QUAZIP_EXPORT QuaZipNewInfo {
-00052 
-00055   QString name;
-00057 
-00062   QDateTime dateTime;
-00064   quint16 internalAttr;
-00066 
-00071   quint32 externalAttr;
-00073 
-00075   QString comment;
-00077   QByteArray extraLocal;
-00079   QByteArray extraGlobal;
-00081 
-00084   ulong uncompressedSize;
-00086 
-00090   QuaZipNewInfo(const QString& name);
-00092 
-00100   QuaZipNewInfo(const QString& name, const QString& file);
-00102 
-00108   QuaZipNewInfo(const QuaZipFileInfo &existing);
-00110 
-00116   QuaZipNewInfo(const QuaZipFileInfo64 &existing);
-00118 
-00132   void setFileDateTime(const QString& file);
-00134 
-00139   void setFilePermissions(const QString &file);
-00141 
-00146   void setPermissions(QFile::Permissions permissions);
-00148 
-00162   void setFileNTFSTimes(const QString &fileName);
-00164 
-00176   void setFileNTFSmTime(const QDateTime &mTime, int fineTicks = 0);
-00178 
-00190   void setFileNTFSaTime(const QDateTime &aTime, int fineTicks = 0);
-00192 
-00204   void setFileNTFScTime(const QDateTime &cTime, int fineTicks = 0);
-00205 };
-00206 
-00207 #endif
-
- - - - diff --git a/hecl-gui/quazip/doc/html/structQuaZipFileInfo-members.html b/hecl-gui/quazip/doc/html/structQuaZipFileInfo-members.html deleted file mode 100644 index 656d729f5..000000000 --- a/hecl-gui/quazip/doc/html/structQuaZipFileInfo-members.html +++ /dev/null @@ -1,66 +0,0 @@ - - - - -QuaZIP: Member List - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
-
-
QuaZipFileInfo Member List
-
- - - - diff --git a/hecl-gui/quazip/doc/html/structQuaZipFileInfo.html b/hecl-gui/quazip/doc/html/structQuaZipFileInfo.html deleted file mode 100644 index fe5603942..000000000 --- a/hecl-gui/quazip/doc/html/structQuaZipFileInfo.html +++ /dev/null @@ -1,137 +0,0 @@ - - - - -QuaZIP: QuaZipFileInfo Struct Reference - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
- -
-
QuaZipFileInfo Struct Reference
-
-
- -

Information about a file inside archive. - More...

- -

#include <quazipfileinfo.h>

- -

List of all members.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

QFile::Permissions getPermissions () const
 Get the file permissions.

-Public Attributes

-QString name
 File name.
-quint16 versionCreated
 Version created by.
-quint16 versionNeeded
 Version needed to extract.
-quint16 flags
 General purpose flags.
-quint16 method
 Compression method.
-QDateTime dateTime
 Last modification date and time.
-quint32 crc
 CRC.
-quint32 compressedSize
 Compressed file size.
-quint32 uncompressedSize
 Uncompressed file size.
-quint16 diskNumberStart
 Disk number start.
-quint16 internalAttr
 Internal file attributes.
-quint32 externalAttr
 External file attributes.
-QString comment
 Comment.
-QByteArray extra
 Extra field.
-

Detailed Description

-

Information about a file inside archive.

-

Call QuaZip::getCurrentFileInfo() or QuaZipFile::getFileInfo() to fill this structure.

-

Member Function Documentation

- -
-
- - - - - - - -
QFile::Permissions QuaZipFileInfo::getPermissions () const
-
-
- -

Get the file permissions.

-

Returns the high 16 bits of external attributes converted to QFile::Permissions.

- -
-
-
The documentation for this struct was generated from the following files: -
- - - diff --git a/hecl-gui/quazip/doc/html/structQuaZipFileInfo64-members.html b/hecl-gui/quazip/doc/html/structQuaZipFileInfo64-members.html deleted file mode 100644 index 3590ed0e8..000000000 --- a/hecl-gui/quazip/doc/html/structQuaZipFileInfo64-members.html +++ /dev/null @@ -1,70 +0,0 @@ - - - - -QuaZIP: Member List - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
-
-
QuaZipFileInfo64 Member List
-
- - - - diff --git a/hecl-gui/quazip/doc/html/structQuaZipFileInfo64.html b/hecl-gui/quazip/doc/html/structQuaZipFileInfo64.html deleted file mode 100644 index 96c67f24f..000000000 --- a/hecl-gui/quazip/doc/html/structQuaZipFileInfo64.html +++ /dev/null @@ -1,284 +0,0 @@ - - - - -QuaZIP: QuaZipFileInfo64 Struct Reference - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
- -
-
QuaZipFileInfo64 Struct Reference
-
-
- -

Information about a file inside archive (with zip64 support). - More...

- -

#include <quazipfileinfo.h>

- -

List of all members.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

QFile::Permissions getPermissions () const
 Get the file permissions.
bool toQuaZipFileInfo (QuaZipFileInfo &info) const
 Converts to QuaZipFileInfo.
QDateTime getNTFSmTime (int *fineTicks=NULL) const
 Returns the NTFS modification time.
QDateTime getNTFSaTime (int *fineTicks=NULL) const
 Returns the NTFS access time.
QDateTime getNTFScTime (int *fineTicks=NULL) const
 Returns the NTFS creation time.

-Public Attributes

-QString name
 File name.
-quint16 versionCreated
 Version created by.
-quint16 versionNeeded
 Version needed to extract.
-quint16 flags
 General purpose flags.
-quint16 method
 Compression method.
QDateTime dateTime
 Last modification date and time.
-quint32 crc
 CRC.
-quint64 compressedSize
 Compressed file size.
-quint64 uncompressedSize
 Uncompressed file size.
-quint16 diskNumberStart
 Disk number start.
-quint16 internalAttr
 Internal file attributes.
-quint32 externalAttr
 External file attributes.
-QString comment
 Comment.
-QByteArray extra
 Extra field.
-

Detailed Description

-

Information about a file inside archive (with zip64 support).

-

Call QuaZip::getCurrentFileInfo() or QuaZipFile::getFileInfo() to fill this structure.

-

Member Function Documentation

- -
-
- - - - - - - -
QFile::Permissions QuaZipFileInfo64::getPermissions () const
-
-
- -

Get the file permissions.

-

Returns the high 16 bits of external attributes converted to QFile::Permissions.

- -
-
- -
-
- - - - - - - - -
bool QuaZipFileInfo64::toQuaZipFileInfo (QuaZipFileInfoinfo) const
-
-
- -

Converts to QuaZipFileInfo.

-

If any of the fields are greater than 0xFFFFFFFFu, they are set to 0xFFFFFFFFu exactly, not just truncated. This function should be mainly used for compatibility with the old code expecting QuaZipFileInfo, in the cases when it's impossible or otherwise unadvisable (due to ABI compatibility reasons, for example) to modify that old code to use QuaZipFileInfo64.

-
Returns:
true if all fields converted correctly, false if an overflow occured.
- -

References comment, QuaZipFileInfo::comment, QuaZipFileInfo::compressedSize, compressedSize, crc, QuaZipFileInfo::crc, dateTime, QuaZipFileInfo::dateTime, diskNumberStart, QuaZipFileInfo::diskNumberStart, externalAttr, QuaZipFileInfo::externalAttr, extra, QuaZipFileInfo::extra, flags, QuaZipFileInfo::flags, internalAttr, QuaZipFileInfo::internalAttr, method, QuaZipFileInfo::method, name, QuaZipFileInfo::name, QuaZipFileInfo::uncompressedSize, uncompressedSize, versionCreated, QuaZipFileInfo::versionCreated, versionNeeded, and QuaZipFileInfo::versionNeeded.

- -

Referenced by QuaZip::getCurrentFileInfo(), and QuaZipFile::getFileInfo().

- -
-
- -
-
- - - - - - - - -
QDateTime QuaZipFileInfo64::getNTFSmTime (int * fineTicks = NULL) const
-
-
- -

Returns the NTFS modification time.

-

The getNTFS*Time() functions only work if there is an NTFS extra field present. Otherwise, they all return invalid null timestamps.

-
Parameters:
- - -
fineTicksIf not NULL, the fractional part of milliseconds returned there, measured in 100-nanosecond ticks. Will be set to zero if there is no NTFS extra field.
-
-
-
See also:
dateTime
-
-getNTFSaTime()
-
-getNTFScTime()
-
Returns:
The NTFS modification time, UTC
- -
-
- -
-
- - - - - - - - -
QDateTime QuaZipFileInfo64::getNTFSaTime (int * fineTicks = NULL) const
-
-
- -

Returns the NTFS access time.

-

The getNTFS*Time() functions only work if there is an NTFS extra field present. Otherwise, they all return invalid null timestamps.

-
Parameters:
- - -
fineTicksIf not NULL, the fractional part of milliseconds returned there, measured in 100-nanosecond ticks. Will be set to zero if there is no NTFS extra field.
-
-
-
See also:
dateTime
-
-getNTFSmTime()
-
-getNTFScTime()
-
Returns:
The NTFS access time, UTC
- -
-
- -
-
- - - - - - - - -
QDateTime QuaZipFileInfo64::getNTFScTime (int * fineTicks = NULL) const
-
-
- -

Returns the NTFS creation time.

-

The getNTFS*Time() functions only work if there is an NTFS extra field present. Otherwise, they all return invalid null timestamps.

-
Parameters:
- - -
fineTicksIf not NULL, the fractional part of milliseconds returned there, measured in 100-nanosecond ticks. Will be set to zero if there is no NTFS extra field.
-
-
-
See also:
dateTime
-
-getNTFSmTime()
-
-getNTFSaTime()
-
Returns:
The NTFS creation time, UTC
- -
-
-

Member Data Documentation

- -
-
- - - - -
QDateTime QuaZipFileInfo64::dateTime
-
-
- -

Last modification date and time.

-

This is the time stored in the standard ZIP header. This format only allows to store time with 2-second precision, so the seconds will always be even and the milliseconds will always be zero. If you need more precise date and time, you can try to call the getNTFSmTime() function or its siblings, provided that the archive itself contains these NTFS times.

- -

Referenced by QuaZip::getCurrentFileInfo(), and toQuaZipFileInfo().

- -
-
-
The documentation for this struct was generated from the following files: -
- - - diff --git a/hecl-gui/quazip/doc/html/structQuaZipNewInfo-members.html b/hecl-gui/quazip/doc/html/structQuaZipNewInfo-members.html deleted file mode 100644 index 1267783bd..000000000 --- a/hecl-gui/quazip/doc/html/structQuaZipNewInfo-members.html +++ /dev/null @@ -1,70 +0,0 @@ - - - - -QuaZIP: Member List - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
-
-
QuaZipNewInfo Member List
-
-
-This is the complete list of members for QuaZipNewInfo, including all inherited members. - - - - - - - - - - - - - - - - - - - -
commentQuaZipNewInfo
dateTimeQuaZipNewInfo
externalAttrQuaZipNewInfo
extraGlobalQuaZipNewInfo
extraLocalQuaZipNewInfo
internalAttrQuaZipNewInfo
nameQuaZipNewInfo
QuaZipNewInfo(const QString &name)QuaZipNewInfo
QuaZipNewInfo(const QString &name, const QString &file)QuaZipNewInfo
QuaZipNewInfo(const QuaZipFileInfo &existing)QuaZipNewInfo
QuaZipNewInfo(const QuaZipFileInfo64 &existing)QuaZipNewInfo
setFileDateTime(const QString &file)QuaZipNewInfo
setFileNTFSaTime(const QDateTime &aTime, int fineTicks=0)QuaZipNewInfo
setFileNTFScTime(const QDateTime &cTime, int fineTicks=0)QuaZipNewInfo
setFileNTFSmTime(const QDateTime &mTime, int fineTicks=0)QuaZipNewInfo
setFileNTFSTimes(const QString &fileName)QuaZipNewInfo
setFilePermissions(const QString &file)QuaZipNewInfo
setPermissions(QFile::Permissions permissions)QuaZipNewInfo
uncompressedSizeQuaZipNewInfo
- - - diff --git a/hecl-gui/quazip/doc/html/structQuaZipNewInfo.html b/hecl-gui/quazip/doc/html/structQuaZipNewInfo.html deleted file mode 100644 index 94c5daee2..000000000 --- a/hecl-gui/quazip/doc/html/structQuaZipNewInfo.html +++ /dev/null @@ -1,539 +0,0 @@ - - - - -QuaZIP: QuaZipNewInfo Struct Reference - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- - -
-
- -
-
QuaZipNewInfo Struct Reference
-
-
- -

Information about a file to be created. - More...

- -

#include <quazipnewinfo.h>

- -

List of all members.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

 QuaZipNewInfo (const QString &name)
 Constructs QuaZipNewInfo instance.
 QuaZipNewInfo (const QString &name, const QString &file)
 Constructs QuaZipNewInfo instance.
 QuaZipNewInfo (const QuaZipFileInfo &existing)
 Initializes the new instance from existing file info.
 QuaZipNewInfo (const QuaZipFileInfo64 &existing)
 Initializes the new instance from existing file info.
void setFileDateTime (const QString &file)
 Sets the file timestamp from the existing file.
void setFilePermissions (const QString &file)
 Sets the file permissions from the existing file.
void setPermissions (QFile::Permissions permissions)
 Sets the file permissions.
void setFileNTFSTimes (const QString &fileName)
 Sets the NTFS times from an existing file.
void setFileNTFSmTime (const QDateTime &mTime, int fineTicks=0)
 Sets the NTFS modification time.
void setFileNTFSaTime (const QDateTime &aTime, int fineTicks=0)
 Sets the NTFS access time.
void setFileNTFScTime (const QDateTime &cTime, int fineTicks=0)
 Sets the NTFS creation time.

-Public Attributes

QString name
 File name.
QDateTime dateTime
 File timestamp.
-quint16 internalAttr
 File internal attributes.
quint32 externalAttr
 File external attributes.
QString comment
 File comment.
-QByteArray extraLocal
 File local extra field.
-QByteArray extraGlobal
 File global extra field.
ulong uncompressedSize
 Uncompressed file size.
-

Detailed Description

-

Information about a file to be created.

-

This structure holds information about a file to be created inside ZIP archive. At least name should be set to something correct before passing this structure to QuaZipFile::open(OpenMode,const QuaZipNewInfo&,int,int,bool).

-

Zip64 support of this structure is slightly limited: in the raw mode (when a pre-compressed file is written into a ZIP file as-is), it is necessary to specify the uncompressed file size and the appropriate field is 32 bit. Since the raw mode is used extremely rare, there is no real need to have a separate QuaZipNewInfo64 structure like QuaZipFileInfo64. It may be added in the future though, if there is a demand for the raw mode with zip64 archives.

-

Constructor & Destructor Documentation

- -
-
- - - - - - - - -
QuaZipNewInfo::QuaZipNewInfo (const QString & name)
-
-
- -

Constructs QuaZipNewInfo instance.

-

Initializes name with name, dateTime with current date and time. Attributes are initialized with zeros, comment and extra field with null values.

- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
QuaZipNewInfo::QuaZipNewInfo (const QString & name,
const QString & file 
)
-
-
- -

Constructs QuaZipNewInfo instance.

-

Initializes name with name. Timestamp and permissions are taken from the specified file. If the file does not exists or its timestamp is inaccessible (e. g. you do not have read permission for the directory file in), uses current time and zero permissions. Other attributes are initialized with zeros, comment and extra field with null values.

-
See also:
setFileDateTime()
- -

References dateTime.

- -
-
- -
-
- - - - - - - - -
QuaZipNewInfo::QuaZipNewInfo (const QuaZipFileInfoexisting)
-
-
- -

Initializes the new instance from existing file info.

-

Mainly used when copying files between archives.

-

Both extra fields are initialized to existing.extra. QuaZipNewInfo

-
Parameters:
- - -
existing
-
-
- -
-
- -
-
- - - - - - - - -
QuaZipNewInfo::QuaZipNewInfo (const QuaZipFileInfo64existing)
-
-
- -

Initializes the new instance from existing file info.

-

Mainly used when copying files between archives.

-

Both extra fields are initialized to existing.extra. QuaZipNewInfo

-
Parameters:
- - -
existing
-
-
- -
-
-

Member Function Documentation

- -
-
- - - - - - - - -
void QuaZipNewInfo::setFileDateTime (const QString & file)
-
-
- -

Sets the file timestamp from the existing file.

-

Use this function to set the file timestamp from the existing file. Use it like this:

-
 QuaZipFile zipFile(&zip);
- QFile file("file-to-add");
- file.open(QIODevice::ReadOnly);
- QuaZipNewInfo info("file-name-in-archive");
- info.setFileDateTime("file-to-add"); // take the timestamp from file
- zipFile.open(QIODevice::WriteOnly, info);
-

This function does not change dateTime if some error occured (e. g. file is inaccessible).

- -

References dateTime.

- -
-
- -
-
- - - - - - - - -
void QuaZipNewInfo::setFilePermissions (const QString & file)
-
-
- -

Sets the file permissions from the existing file.

-

Takes permissions from the file and sets the high 16 bits of external attributes. Uses QFileInfo to get permissions on all platforms.

- -
-
- -
-
- - - - - - - - -
void QuaZipNewInfo::setPermissions (QFile::Permissions permissions)
-
-
- -

Sets the file permissions.

-

Modifies the highest 16 bits of external attributes. The type part is set to dir if the name ends with a slash, and to regular file otherwise.

- -

References name.

- -
-
- -
-
- - - - - - - - -
void QuaZipNewInfo::setFileNTFSTimes (const QString & fileName)
-
-
- -

Sets the NTFS times from an existing file.

-

If the file doesn't exist, a warning is printed to the stderr and nothing is done. Otherwise, all three times, as reported by QFileInfo::lastModified(), QFileInfo::lastRead() and QFileInfo::created(), are written to the NTFS extra field record.

-

The NTFS record is written to both the local and the global extra fields, updating the existing record if there is one, or creating a new one and appending it to the end of each extra field.

-

The microseconds will be zero, as they aren't reported by QFileInfo.

-
Parameters:
- - -
fileName
-
-
- -

References setFileNTFSaTime(), setFileNTFScTime(), and setFileNTFSmTime().

- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
void QuaZipNewInfo::setFileNTFSmTime (const QDateTime & mTime,
int fineTicks = 0 
)
-
-
- -

Sets the NTFS modification time.

-

The time is written into the NTFS record in both the local and the global extra fields, updating the existing record if there is one, or creating a new one and appending it to the end of each extra field. When updating an existing record, all other fields are left intact.

-
Parameters:
- - - -
mTimeThe new modification time.
fineTicksThe fractional part of milliseconds, in 100-nanosecond ticks (i. e. 9999 ticks = 999.9 microsecond). Values greater than 9999 will add milliseconds or even seconds, but this can be confusing and therefore is discouraged.
-
-
- -

References extraGlobal, and extraLocal.

- -

Referenced by setFileNTFSTimes().

- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
void QuaZipNewInfo::setFileNTFSaTime (const QDateTime & aTime,
int fineTicks = 0 
)
-
-
- -

Sets the NTFS access time.

-

The time is written into the NTFS record in both the local and the global extra fields, updating the existing record if there is one, or creating a new one and appending it to the end of each extra field. When updating an existing record, all other fields are left intact.

-
Parameters:
- - - -
aTimeThe new access time.
fineTicksThe fractional part of milliseconds, in 100-nanosecond ticks (i. e. 9999 ticks = 999.9 microsecond). Values greater than 9999 will add milliseconds or even seconds, but this can be confusing and therefore is discouraged.
-
-
- -

References extraGlobal, and extraLocal.

- -

Referenced by setFileNTFSTimes().

- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
void QuaZipNewInfo::setFileNTFScTime (const QDateTime & cTime,
int fineTicks = 0 
)
-
-
- -

Sets the NTFS creation time.

-

The time is written into the NTFS record in both the local and the global extra fields, updating the existing record if there is one, or creating a new one and appending it to the end of each extra field. When updating an existing record, all other fields are left intact.

-
Parameters:
- - - -
cTimeThe new creation time.
fineTicksThe fractional part of milliseconds, in 100-nanosecond ticks (i. e. 9999 ticks = 999.9 microsecond). Values greater than 9999 will add milliseconds or even seconds, but this can be confusing and therefore is discouraged.
-
-
- -

References extraGlobal, and extraLocal.

- -

Referenced by setFileNTFSTimes().

- -
-
-

Member Data Documentation

- -
-
- - - - -
QString QuaZipNewInfo::name
-
-
- -

File name.

-

This field holds file name inside archive, including path relative to archive root.

- -

Referenced by QuaZipFile::open(), and setPermissions().

- -
-
- -
-
- - - - -
QDateTime QuaZipNewInfo::dateTime
-
-
- -

File timestamp.

-

This is the last file modification date and time. Will be stored in the archive central directory. It is a good practice to set it to the source file timestamp instead of archive creating time. Use setFileDateTime() or QuaZipNewInfo(const QString&, const QString&).

- -

Referenced by QuaZipFile::open(), QuaZipNewInfo(), and setFileDateTime().

- -
-
- -
-
- - - - -
quint32 QuaZipNewInfo::externalAttr
-
-
- -

File external attributes.

-

The highest 16 bits contain Unix file permissions and type (dir or file). The constructor QuaZipNewInfo(const QString&, const QString&) takes permissions from the provided file.

- -

Referenced by QuaZipFile::open().

- -
-
- -
-
- - - - -
QString QuaZipNewInfo::comment
-
-
- -

File comment.

-

Will be encoded using QuaZip::getCommentCodec().

- -

Referenced by QuaZipFile::open().

- -
-
- -
- -
- -

Uncompressed file size.

-

This is only needed if you are using raw file zipping mode, i. e. adding precompressed file in the zip archive.

- -

Referenced by QuaZipFile::open().

- -
-
-
The documentation for this struct was generated from the following files: -
- - - diff --git a/hecl-gui/quazip/doc/html/tab_a.png b/hecl-gui/quazip/doc/html/tab_a.png deleted file mode 100644 index 2d99ef23f..000000000 Binary files a/hecl-gui/quazip/doc/html/tab_a.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/tab_b.png b/hecl-gui/quazip/doc/html/tab_b.png deleted file mode 100644 index b2c3d2be3..000000000 Binary files a/hecl-gui/quazip/doc/html/tab_b.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/tab_h.png b/hecl-gui/quazip/doc/html/tab_h.png deleted file mode 100644 index c11f48f19..000000000 Binary files a/hecl-gui/quazip/doc/html/tab_h.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/tab_s.png b/hecl-gui/quazip/doc/html/tab_s.png deleted file mode 100644 index 978943ac8..000000000 Binary files a/hecl-gui/quazip/doc/html/tab_s.png and /dev/null differ diff --git a/hecl-gui/quazip/doc/html/tabs.css b/hecl-gui/quazip/doc/html/tabs.css deleted file mode 100644 index 21920562a..000000000 --- a/hecl-gui/quazip/doc/html/tabs.css +++ /dev/null @@ -1,59 +0,0 @@ -.tabs, .tabs2, .tabs3 { - background-image: url('tab_b.png'); - width: 100%; - z-index: 101; - font-size: 13px; -} - -.tabs2 { - font-size: 10px; -} -.tabs3 { - font-size: 9px; -} - -.tablist { - margin: 0; - padding: 0; - display: table; -} - -.tablist li { - float: left; - display: table-cell; - background-image: url('tab_b.png'); - line-height: 36px; - list-style: none; -} - -.tablist a { - display: block; - padding: 0 20px; - font-weight: bold; - background-image:url('tab_s.png'); - background-repeat:no-repeat; - background-position:right; - color: #283A5D; - text-shadow: 0px 1px 1px rgba(255, 255, 255, 0.9); - text-decoration: none; - outline: none; -} - -.tabs3 .tablist a { - padding: 0 10px; -} - -.tablist a:hover { - background-image: url('tab_h.png'); - background-repeat:repeat-x; - color: #fff; - text-shadow: 0px 1px 1px rgba(0, 0, 0, 1.0); - text-decoration: none; -} - -.tablist li.current a { - background-image: url('tab_a.png'); - background-repeat:repeat-x; - color: #fff; - text-shadow: 0px 1px 1px rgba(0, 0, 0, 1.0); -} diff --git a/hecl-gui/quazip/doc/html/usage.html b/hecl-gui/quazip/doc/html/usage.html deleted file mode 100644 index ed19682ee..000000000 --- a/hecl-gui/quazip/doc/html/usage.html +++ /dev/null @@ -1,61 +0,0 @@ - - - - -QuaZIP: Usage - - - - - -
-
- - - - - - -
-
QuaZIP quazip-0-6-2
-
-
- -
-
-
-
Usage
-
-
-

This page provides general information on QuaZIP usage. See classes QuaZip and QuaZipFile for the detailed documentation on what can QuaZIP do and what it can not. Also, reading comments in the zip.h and unzip.h files (taken from the original ZIP/UNZIP package) is always a good idea too. After all, QuaZIP is just a wrapper with a few convenience extensions and reimplementations.

-

QuaZip is a class representing ZIP archive, QuaZipFile represents a file inside archive and subclasses QIODevice as well. One limitation is that there can be only one instance of QuaZipFile per QuaZip instance, which kind of makes it confusing why there are two classes instead of one. This is actually no more than an API design mistake.

-

-Terminology

-

"QuaZIP" means whole this library, while "QuaZip" (note the lower case) is just one class in it.

-

"ZIP/UNZIP API" or "minizip" means the original API of the Gilles Vollant's ZIP/UNZIP package. It was slightly modified to better integrate with Qt. These modifications are not source or binary compatible with the official minizip release, which means you can't just drop the newer minizip version into QuaZIP sources and make it work.

-

"ZIP", "ZIP archive" or "ZIP file" means any ZIP archive. Typically this is a plain file with ".zip" (or ".ZIP") file name suffix, but it can also be any seekable QIODevice (say, QBuffer, but not QTcpSocket).

-

"A file inside archive", "a file inside ZIP" or something like that means file either being read or written from/to some ZIP archive.

-

-Error handling

-

Almost any call to ZIP/UNZIP API return some error code. Most of the original API's error checking could be done in this wrapper as well, but it would cause unnecessary code bloating without any benefit. So, QuaZIP only checks for situations that ZIP/UNZIP API can not check for. For example, ZIP/UNZIP API has no "ZIP open mode" concept because read and write modes are completely separated. On the other hand, to avoid creating classes like "QuaZipReader", "QuaZipWriter" or something like that, QuaZIP introduces "ZIP open mode" concept instead, thus making it possible to use one class (QuaZip) for both reading and writing. But this leads to additional open mode checks which are not done in ZIP/UNZIP package.

-

Therefore, error checking is two-level (QuaZIP's level and ZIP/UNZIP API level), which sometimes can be confusing, so here are some advices on how the error checking should be properly done:

-
    -
  • Both QuaZip and QuaZipFile have getZipError() function, which return error code of the last ZIP/UNZIP API call. Most function calls reset error code to UNZ_OK on success and set error code on failure. Some functions do not reset error code. Most of them are const and do not access ZIP archive in any way. Some, on the other hand, do access ZIP archive, but do not reset or set error code. For example, QuaZipFile::pos() function. Such functions are explicitly marked in the documentation.
  • -
  • Most functions have their own way to report errors, by returning a null string, negative value or false. If such a function returns error value, call getZipError() to get more information about error. See "zip.h" and "unzip.h" of the ZIP/UNZIP package for error codes.
  • -
  • If the function returns error-stating value (like false), but getZipError() returns UNZ_OK, it means that you did something obviously wrong. For example, tried to write in the archive open for reading or not open at all. You better just not do that! Most functions also issue a warning using qWarning() function in such cases. See documentation for a specific function for details on when it should not be called.
  • -
-

I know that this is somewhat messy, but I could not find a better way to do all the error handling.

-
- - - diff --git a/hecl-gui/quazip/doc/latex/Makefile b/hecl-gui/quazip/doc/latex/Makefile deleted file mode 100644 index 5155fffad..000000000 --- a/hecl-gui/quazip/doc/latex/Makefile +++ /dev/null @@ -1,39 +0,0 @@ -all: refman.dvi - -ps: refman.ps - -pdf: refman.pdf - -ps_2on1: refman_2on1.ps - -pdf_2on1: refman_2on1.pdf - -refman.ps: refman.dvi - dvips -o refman.ps refman.dvi - -refman.pdf: refman.ps - gswin32c -q -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile=refman.pdf -c save pop -f refman.ps - -refman.dvi: clean refman.tex doxygen.sty - echo "Running latex..." - latex refman.tex - echo "Running makeindex..." - makeindex refman.idx - echo "Rerunning latex...." - latex refman.tex - latex_count=5 ; \ - while egrep -s 'Rerun (LaTeX|to get cross-references right)' refman.log && [ $$latex_count -gt 0 ] ;\ - do \ - echo "Rerunning latex...." ;\ - latex refman.tex ;\ - latex_count=`expr $$latex_count - 1` ;\ - done - -refman_2on1.ps: refman.ps - psnup -2 refman.ps >refman_2on1.ps - -refman_2on1.pdf: refman_2on1.ps - gswin32c -q -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile=refman_2on1.pdf -c save pop -f refman_2on1.ps - -clean: - del /s/y *.ps *.dvi *.aux *.toc *.idx *.ind *.ilg *.log *.out refman.pdf diff --git a/hecl-gui/quazip/doc/latex/annotated.tex b/hecl-gui/quazip/doc/latex/annotated.tex deleted file mode 100644 index 8ac94f5ae..000000000 --- a/hecl-gui/quazip/doc/latex/annotated.tex +++ /dev/null @@ -1,17 +0,0 @@ -\section{Class List} -Here are the classes, structs, unions and interfaces with brief descriptions:\begin{DoxyCompactList} -\item\contentsline{section}{{\bf JlCompress} (Utility class for typical operations )}{\pageref{classJlCompress}}{} -\item\contentsline{section}{{\bf QuaAdler32} (Adler32 checksum )}{\pageref{classQuaAdler32}}{} -\item\contentsline{section}{{\bf QuaChecksum32} (Checksum interface )}{\pageref{classQuaChecksum32}}{} -\item\contentsline{section}{{\bf QuaCrc32} (CRC32 checksum )}{\pageref{classQuaCrc32}}{} -\item\contentsline{section}{{\bf QuaGzipFile} (GZIP file )}{\pageref{classQuaGzipFile}}{} -\item\contentsline{section}{{\bf QuaZIODevice} (A class to compress/decompress QIODevice )}{\pageref{classQuaZIODevice}}{} -\item\contentsline{section}{{\bf QuaZip} (ZIP archive )}{\pageref{classQuaZip}}{} -\item\contentsline{section}{{\bf QuaZipDir} (Provides ZIP archive navigation )}{\pageref{classQuaZipDir}}{} -\item\contentsline{section}{{\bf QuaZipFile} (A file inside ZIP archive )}{\pageref{classQuaZipFile}}{} -\item\contentsline{section}{{\bf QuaZipFileInfo} (Information about a file inside archive )}{\pageref{structQuaZipFileInfo}}{} -\item\contentsline{section}{{\bf QuaZipFileInfo64} (Information about a file inside archive (with zip64 support) )}{\pageref{structQuaZipFileInfo64}}{} -\item\contentsline{section}{{\bf QuaZipFilePrivate} (The implementation class for \doxyref{QuaZip}{p.}{classQuaZip} )}{\pageref{classQuaZipFilePrivate}}{} -\item\contentsline{section}{{\bf QuaZipNewInfo} (Information about a file to be created )}{\pageref{structQuaZipNewInfo}}{} -\item\contentsline{section}{{\bf QuaZipPrivate} (All the internal stuff for the \doxyref{QuaZip}{p.}{classQuaZip} class )}{\pageref{classQuaZipPrivate}}{} -\end{DoxyCompactList} diff --git a/hecl-gui/quazip/doc/latex/classJlCompress.tex b/hecl-gui/quazip/doc/latex/classJlCompress.tex deleted file mode 100644 index b2eecfac1..000000000 --- a/hecl-gui/quazip/doc/latex/classJlCompress.tex +++ /dev/null @@ -1,239 +0,0 @@ -\section{JlCompress Class Reference} -\label{classJlCompress}\index{JlCompress@{JlCompress}} - - -Utility class for typical operations. - - - - -{\ttfamily \#include $<$JlCompress.h$>$} - -\subsection*{Static Public Member Functions} -\begin{DoxyCompactItemize} -\item -static bool {\bf compressFile} (QString fileCompressed, QString file) -\begin{DoxyCompactList}\small\item\em Compress a single file. \end{DoxyCompactList}\item -static bool {\bf compressFiles} (QString fileCompressed, QStringList files) -\begin{DoxyCompactList}\small\item\em Compress a list of files. \end{DoxyCompactList}\item -static bool {\bf compressDir} (QString fileCompressed, QString dir=QString(), bool recursive=true) -\begin{DoxyCompactList}\small\item\em Compress a whole directory. \end{DoxyCompactList}\item -static QString {\bf extractFile} (QString fileCompressed, QString fileName, QString fileDest=QString()) -\begin{DoxyCompactList}\small\item\em Extract a single file. \end{DoxyCompactList}\item -static QStringList {\bf extractFiles} (QString fileCompressed, QStringList files, QString dir=QString()) -\begin{DoxyCompactList}\small\item\em Extract a list of files. \end{DoxyCompactList}\item -static QStringList {\bf extractDir} (QString fileCompressed, QString dir=QString()) -\begin{DoxyCompactList}\small\item\em Extract a whole archive. \end{DoxyCompactList}\item -static QStringList {\bf getFileList} (QString fileCompressed) -\begin{DoxyCompactList}\small\item\em Get the file list. \end{DoxyCompactList}\end{DoxyCompactItemize} - - -\subsection{Detailed Description} -Utility class for typical operations. - -This class contains a number of useful static functions to perform simple operations, such as mass ZIP packing or extraction. - -\subsection{Member Function Documentation} -\index{JlCompress@{JlCompress}!compressFile@{compressFile}} -\index{compressFile@{compressFile}!JlCompress@{JlCompress}} -\subsubsection[{compressFile}]{\setlength{\rightskip}{0pt plus 5cm}bool JlCompress::compressFile ( -\begin{DoxyParamCaption} -\item[{QString}]{fileCompressed, } -\item[{QString}]{file} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [static]}}\label{classJlCompress_a4a4de9c62ecf161bb658d4d80495ea97} - - -Compress a single file. - - -\begin{DoxyParams}{Parameters} -{\em fileCompressed} & The name of the archive. \\ -\hline -{\em file} & The file to compress. \\ -\hline -\end{DoxyParams} -\begin{DoxyReturn}{Returns} -true if success, false otherwise. -\end{DoxyReturn} -OK Comprime il file fileName nel file fileCompressed. Se la funzione fallisce restituisce false e cancella il file che si e tentato di creare. - -La funzione fallisce se: $\ast$ non si riesce ad aprire l'oggetto zip; $\ast$ la compressione del file fallisce; $\ast$ non si riesce a chiudere l'oggetto zip; - -References QuaZip::close(), QuaZip::getZipError(), QuaZip::mdCreate, and QuaZip::open(). - -\index{JlCompress@{JlCompress}!compressFiles@{compressFiles}} -\index{compressFiles@{compressFiles}!JlCompress@{JlCompress}} -\subsubsection[{compressFiles}]{\setlength{\rightskip}{0pt plus 5cm}bool JlCompress::compressFiles ( -\begin{DoxyParamCaption} -\item[{QString}]{fileCompressed, } -\item[{QStringList}]{files} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [static]}}\label{classJlCompress_a9cdb92d29a94c6b13a718a3249685846} - - -Compress a list of files. - - -\begin{DoxyParams}{Parameters} -{\em fileCompressed} & The name of the archive. \\ -\hline -{\em files} & The file list to compress. \\ -\hline -\end{DoxyParams} -\begin{DoxyReturn}{Returns} -true if success, false otherwise. -\end{DoxyReturn} -OK Comprime i file specificati in files nel file fileCompressed. Se la funzione fallisce restituisce false e cancella il file che si e tentato di creare. - -La funzione fallisce se: $\ast$ non si riesce ad aprire l'oggetto zip; $\ast$ la compressione di un file fallisce; $\ast$ non si riesce a chiudere l'oggetto zip; - -References QuaZip::close(), QuaZip::getZipError(), QuaZip::mdCreate, and QuaZip::open(). - -\index{JlCompress@{JlCompress}!compressDir@{compressDir}} -\index{compressDir@{compressDir}!JlCompress@{JlCompress}} -\subsubsection[{compressDir}]{\setlength{\rightskip}{0pt plus 5cm}bool JlCompress::compressDir ( -\begin{DoxyParamCaption} -\item[{QString}]{fileCompressed, } -\item[{QString}]{dir = {\ttfamily QString()}, } -\item[{bool}]{recursive = {\ttfamily true}} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [static]}}\label{classJlCompress_a8708eafcadc5c192a1d492e784cfc98f} - - -Compress a whole directory. - - -\begin{DoxyParams}{Parameters} -{\em fileCompressed} & The name of the archive. \\ -\hline -{\em dir} & The directory to compress. \\ -\hline -{\em recursive} & Whether to pack the subdirectories as well, or just regular files. \\ -\hline -\end{DoxyParams} -\begin{DoxyReturn}{Returns} -true if success, false otherwise. -\end{DoxyReturn} -OK Comprime la cartella dir nel file fileCompressed, se recursive e true allora comprime anche le sotto cartelle. Se la funzione fallisce restituisce false e cancella il file che si e tentato di creare. - -La funzione fallisce se: $\ast$ non si riesce ad aprire l'oggetto zip; $\ast$ la compressione di un file fallisce; $\ast$ non si riesce a chiudere l'oggetto zip; - -References QuaZip::close(), QuaZip::getZipError(), QuaZip::mdCreate, and QuaZip::open(). - -\index{JlCompress@{JlCompress}!extractFile@{extractFile}} -\index{extractFile@{extractFile}!JlCompress@{JlCompress}} -\subsubsection[{extractFile}]{\setlength{\rightskip}{0pt plus 5cm}QString JlCompress::extractFile ( -\begin{DoxyParamCaption} -\item[{QString}]{fileCompressed, } -\item[{QString}]{fileName, } -\item[{QString}]{fileDest = {\ttfamily QString()}} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [static]}}\label{classJlCompress_a38c0d58bfe3bbbcb3cf4e98d126633a3} - - -Extract a single file. - - -\begin{DoxyParams}{Parameters} -{\em fileCompressed} & The name of the archive. \\ -\hline -{\em fileName} & The file to extract. \\ -\hline -{\em fileDest} & The destination file, assumed to be identical to {\itshape file\/} if left empty. \\ -\hline -\end{DoxyParams} -\begin{DoxyReturn}{Returns} -The list of the full paths of the files extracted, empty on failure. -\end{DoxyReturn} -OK Estrae il file fileName, contenuto nel file fileCompressed, con il nome fileDest. Se fileDest = \char`\"{}\char`\"{} allora il file viene estratto con lo stesso nome con cui e stato compresso. Se la funzione fallisce cancella il file che si e tentato di estrarre. Restituisce il nome assoluto del file estratto. - -La funzione fallisce se: $\ast$ non si riesce ad aprire l'oggetto zip; $\ast$ l'estrazione del file fallisce; $\ast$ non si riesce a chiudere l'oggetto zip; - -References QuaZip::close(), QuaZip::getZipError(), QuaZip::mdUnzip, and QuaZip::open(). - -\index{JlCompress@{JlCompress}!extractFiles@{extractFiles}} -\index{extractFiles@{extractFiles}!JlCompress@{JlCompress}} -\subsubsection[{extractFiles}]{\setlength{\rightskip}{0pt plus 5cm}QStringList JlCompress::extractFiles ( -\begin{DoxyParamCaption} -\item[{QString}]{fileCompressed, } -\item[{QStringList}]{files, } -\item[{QString}]{dir = {\ttfamily QString()}} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [static]}}\label{classJlCompress_a309e9ee366719a4d8aa28f837fab73ae} - - -Extract a list of files. - - -\begin{DoxyParams}{Parameters} -{\em fileCompressed} & The name of the archive. \\ -\hline -{\em files} & The file list to extract. \\ -\hline -{\em dir} & The directory to put the files to, the current directory if left empty. \\ -\hline -\end{DoxyParams} -\begin{DoxyReturn}{Returns} -The list of the full paths of the files extracted, empty on failure. -\end{DoxyReturn} -OK Estrae i file specificati in files, contenuti nel file fileCompressed, nella cartella dir. La struttura a cartelle del file compresso viene rispettata. Se dir = \char`\"{}\char`\"{} allora il file viene estratto nella cartella corrente. Se la funzione fallisce cancella i file che si e tentato di estrarre. Restituisce i nomi assoluti dei file estratti. - -La funzione fallisce se: $\ast$ non si riesce ad aprire l'oggetto zip; $\ast$ l'estrazione di un file fallisce; $\ast$ non si riesce a chiudere l'oggetto zip; - -References QuaZip::close(), QuaZip::getZipError(), QuaZip::mdUnzip, and QuaZip::open(). - -\index{JlCompress@{JlCompress}!extractDir@{extractDir}} -\index{extractDir@{extractDir}!JlCompress@{JlCompress}} -\subsubsection[{extractDir}]{\setlength{\rightskip}{0pt plus 5cm}QStringList JlCompress::extractDir ( -\begin{DoxyParamCaption} -\item[{QString}]{fileCompressed, } -\item[{QString}]{dir = {\ttfamily QString()}} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [static]}}\label{classJlCompress_a365a153baa4c11812d93cbca60b6a293} - - -Extract a whole archive. - - -\begin{DoxyParams}{Parameters} -{\em fileCompressed} & The name of the archive. \\ -\hline -{\em dir} & The directory to extract to, the current directory if left empty. \\ -\hline -\end{DoxyParams} -\begin{DoxyReturn}{Returns} -The list of the full paths of the files extracted, empty on failure. -\end{DoxyReturn} -OK Estrae il file fileCompressed nella cartella dir. Se dir = \char`\"{}\char`\"{} allora il file viene estratto nella cartella corrente. Se la funzione fallisce cancella i file che si e tentato di estrarre. Restituisce i nomi assoluti dei file estratti. - -La funzione fallisce se: $\ast$ non si riesce ad aprire l'oggetto zip; $\ast$ la compressione di un file fallisce; $\ast$ non si riesce a chiudere l'oggetto zip; - -References QuaZip::close(), QuaZip::getCurrentFileName(), QuaZip::getZipError(), QuaZip::goToFirstFile(), QuaZip::goToNextFile(), QuaZip::mdUnzip, and QuaZip::open(). - -\index{JlCompress@{JlCompress}!getFileList@{getFileList}} -\index{getFileList@{getFileList}!JlCompress@{JlCompress}} -\subsubsection[{getFileList}]{\setlength{\rightskip}{0pt plus 5cm}QStringList JlCompress::getFileList ( -\begin{DoxyParamCaption} -\item[{QString}]{fileCompressed} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [static]}}\label{classJlCompress_ab42422be913f817d7e04c1b1cd5d0156} - - -Get the file list. - -\begin{DoxyReturn}{Returns} -The list of the files in the archive, or, more precisely, the list of the entries, including both files and directories if they are present separately. -\end{DoxyReturn} -OK Restituisce la lista dei file resenti nel file compresso fileCompressed. Se la funzione fallisce, restituisce un elenco vuoto. - -La funzione fallisce se: $\ast$ non si riesce ad aprire l'oggetto zip; $\ast$ la richiesta di informazioni di un file fallisce; $\ast$ non si riesce a chiudere l'oggetto zip; - -References QuaZip::close(), QuaZip::getCurrentFileInfo(), QuaZip::getZipError(), QuaZip::goToFirstFile(), QuaZip::goToNextFile(), QuaZip::mdUnzip, QuaZipFileInfo64::name, and QuaZip::open(). - - - -The documentation for this class was generated from the following files:\begin{DoxyCompactItemize} -\item -quazip/JlCompress.h\item -quazip/JlCompress.cpp\end{DoxyCompactItemize} diff --git a/hecl-gui/quazip/doc/latex/classQuaAdler32.tex b/hecl-gui/quazip/doc/latex/classQuaAdler32.tex deleted file mode 100644 index 369609d11..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaAdler32.tex +++ /dev/null @@ -1,108 +0,0 @@ -\section{QuaAdler32 Class Reference} -\label{classQuaAdler32}\index{QuaAdler32@{QuaAdler32}} - - -Adler32 checksum. - - - - -{\ttfamily \#include $<$quazip/quaadler32.h$>$} - - - -Inheritance diagram for QuaAdler32: -\nopagebreak -\begin{figure}[H] -\begin{center} -\leavevmode -\includegraphics[width=136pt]{classQuaAdler32__inherit__graph} -\end{center} -\end{figure} - - -Collaboration diagram for QuaAdler32: -\nopagebreak -\begin{figure}[H] -\begin{center} -\leavevmode -\includegraphics[width=136pt]{classQuaAdler32__coll__graph} -\end{center} -\end{figure} -\subsection*{Public Member Functions} -\begin{DoxyCompactItemize} -\item -quint32 {\bf calculate} (const QByteArray \&data) -\begin{DoxyCompactList}\small\item\em Calculates the checksum for data. \end{DoxyCompactList}\item -void {\bf reset} ()\label{classQuaAdler32_a2fe6ac9eb289bafda6a9fd20e6472ab5} - -\begin{DoxyCompactList}\small\item\em Resets the calculation on a checksun for a stream. \end{DoxyCompactList}\item -void {\bf update} (const QByteArray \&buf) -\begin{DoxyCompactList}\small\item\em Updates the calculated checksum for the stream. \end{DoxyCompactList}\item -quint32 {\bf value} () -\begin{DoxyCompactList}\small\item\em Value of the checksum calculated for the stream passed throw \doxyref{update()}{p.}{classQuaAdler32_aba24f7b16aa0cdc26f81a9ad687fc653}. \end{DoxyCompactList}\end{DoxyCompactItemize} - - -\subsection{Detailed Description} -Adler32 checksum. - -This class wrappers the adler32 function with the \doxyref{QuaChecksum32}{p.}{classQuaChecksum32} interface. See \doxyref{QuaChecksum32}{p.}{classQuaChecksum32} for more info. - -\subsection{Member Function Documentation} -\index{QuaAdler32@{QuaAdler32}!calculate@{calculate}} -\index{calculate@{calculate}!QuaAdler32@{QuaAdler32}} -\subsubsection[{calculate}]{\setlength{\rightskip}{0pt plus 5cm}quint32 QuaAdler32::calculate ( -\begin{DoxyParamCaption} -\item[{const QByteArray \&}]{data} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [virtual]}}\label{classQuaAdler32_a350e84fd000ebfa3c33503336a7b21bb} - - -Calculates the checksum for data. - -{\itshape data\/} source data \begin{DoxyReturn}{Returns} -data checksum -\end{DoxyReturn} -This function has no efect on the value returned by \doxyref{value()}{p.}{classQuaAdler32_a2022e1db95c23cef220b335e44d74fb1}. - -Implements {\bf QuaChecksum32} \doxyref{}{p.}{classQuaChecksum32_a14d800fcfd55b2ae11ef07d3924fe0b1}. - -\index{QuaAdler32@{QuaAdler32}!update@{update}} -\index{update@{update}!QuaAdler32@{QuaAdler32}} -\subsubsection[{update}]{\setlength{\rightskip}{0pt plus 5cm}void QuaAdler32::update ( -\begin{DoxyParamCaption} -\item[{const QByteArray \&}]{buf} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [virtual]}}\label{classQuaAdler32_aba24f7b16aa0cdc26f81a9ad687fc653} - - -Updates the calculated checksum for the stream. - -{\itshape buf\/} next portion of data from the stream - -Implements {\bf QuaChecksum32} \doxyref{}{p.}{classQuaChecksum32_a63a6ed3171f9243214d307da67557f7e}. - -\index{QuaAdler32@{QuaAdler32}!value@{value}} -\index{value@{value}!QuaAdler32@{QuaAdler32}} -\subsubsection[{value}]{\setlength{\rightskip}{0pt plus 5cm}quint32 QuaAdler32::value ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [virtual]}}\label{classQuaAdler32_a2022e1db95c23cef220b335e44d74fb1} - - -Value of the checksum calculated for the stream passed throw \doxyref{update()}{p.}{classQuaAdler32_aba24f7b16aa0cdc26f81a9ad687fc653}. - -\begin{DoxyReturn}{Returns} -checksum -\end{DoxyReturn} - - -Implements {\bf QuaChecksum32} \doxyref{}{p.}{classQuaChecksum32_afd836e7534194fce08356be6a8336da7}. - - - -The documentation for this class was generated from the following files:\begin{DoxyCompactItemize} -\item -quazip/quaadler32.h\item -quazip/quaadler32.cpp\end{DoxyCompactItemize} diff --git a/hecl-gui/quazip/doc/latex/classQuaAdler32__coll__graph.eps b/hecl-gui/quazip/doc/latex/classQuaAdler32__coll__graph.eps deleted file mode 100644 index 70098d097..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaAdler32__coll__graph.eps +++ /dev/null @@ -1,263 +0,0 @@ -%!PS-Adobe-3.0 -%%Creator: graphviz version 2.28.0 (20110507.0327) -%%Title: G -%%Pages: (atend) -%%BoundingBox: (atend) -%%EndComments -save -%%BeginProlog -/DotDict 200 dict def -DotDict begin - -/setupLatin1 { -mark -/EncodingVector 256 array def - EncodingVector 0 - -ISOLatin1Encoding 0 255 getinterval putinterval -EncodingVector 45 /hyphen put - -% Set up ISO Latin 1 character encoding -/starnetISO { - dup dup findfont dup length dict begin - { 1 index /FID ne { def }{ pop pop } ifelse - } forall - /Encoding EncodingVector def - currentdict end definefont -} def -/Times-Roman starnetISO def -/Times-Italic starnetISO def -/Times-Bold starnetISO def -/Times-BoldItalic starnetISO def -/Helvetica starnetISO def -/Helvetica-Oblique starnetISO def -/Helvetica-Bold starnetISO def -/Helvetica-BoldOblique starnetISO def -/Courier starnetISO def -/Courier-Oblique starnetISO def -/Courier-Bold starnetISO def -/Courier-BoldOblique starnetISO def -cleartomark -} bind def - -%%BeginResource: procset graphviz 0 0 -/coord-font-family /Times-Roman def -/default-font-family /Times-Roman def -/coordfont coord-font-family findfont 8 scalefont def - -/InvScaleFactor 1.0 def -/set_scale { - dup 1 exch div /InvScaleFactor exch def - scale -} bind def - -% styles -/solid { [] 0 setdash } bind def -/dashed { [9 InvScaleFactor mul dup ] 0 setdash } bind def -/dotted { [1 InvScaleFactor mul 6 InvScaleFactor mul] 0 setdash } bind def -/invis {/fill {newpath} def /stroke {newpath} def /show {pop newpath} def} bind def -/bold { 2 setlinewidth } bind def -/filled { } bind def -/unfilled { } bind def -/rounded { } bind def -/diagonals { } bind def - -% hooks for setting color -/nodecolor { sethsbcolor } bind def -/edgecolor { sethsbcolor } bind def -/graphcolor { sethsbcolor } bind def -/nopcolor {pop pop pop} bind def - -/beginpage { % i j npages - /npages exch def - /j exch def - /i exch def - /str 10 string def - npages 1 gt { - gsave - coordfont setfont - 0 0 moveto - (\() show i str cvs show (,) show j str cvs show (\)) show - grestore - } if -} bind def - -/set_font { - findfont exch - scalefont setfont -} def - -% draw text fitted to its expected width -/alignedtext { % width text - /text exch def - /width exch def - gsave - width 0 gt { - [] 0 setdash - text stringwidth pop width exch sub text length div 0 text ashow - } if - grestore -} def - -/boxprim { % xcorner ycorner xsize ysize - 4 2 roll - moveto - 2 copy - exch 0 rlineto - 0 exch rlineto - pop neg 0 rlineto - closepath -} bind def - -/ellipse_path { - /ry exch def - /rx exch def - /y exch def - /x exch def - matrix currentmatrix - newpath - x y translate - rx ry scale - 0 0 1 0 360 arc - setmatrix -} bind def - -/endpage { showpage } bind def -/showpage { } def - -/layercolorseq - [ % layer color sequence - darkest to lightest - [0 0 0] - [.2 .8 .8] - [.4 .8 .8] - [.6 .8 .8] - [.8 .8 .8] - ] -def - -/layerlen layercolorseq length def - -/setlayer {/maxlayer exch def /curlayer exch def - layercolorseq curlayer 1 sub layerlen mod get - aload pop sethsbcolor - /nodecolor {nopcolor} def - /edgecolor {nopcolor} def - /graphcolor {nopcolor} def -} bind def - -/onlayer { curlayer ne {invis} if } def - -/onlayers { - /myupper exch def - /mylower exch def - curlayer mylower lt - curlayer myupper gt - or - {invis} if -} def - -/curlayer 0 def - -%%EndResource -%%EndProlog -%%BeginSetup -14 default-font-family set_font -1 setmiterlimit -% /arrowlength 10 def -% /arrowwidth 5 def - -% make sure pdfmark is harmless for PS-interpreters other than Distiller -/pdfmark where {pop} {userdict /pdfmark /cleartomark load put} ifelse -% make '<<' and '>>' safe on PS Level 1 devices -/languagelevel where {pop languagelevel}{1} ifelse -2 lt { - userdict (<<) cvn ([) cvn load put - userdict (>>) cvn ([) cvn load put -} if - -%%EndSetup -setupLatin1 -%%Page: 1 1 -%%PageBoundingBox: 36 36 136 120 -%%PageOrientation: Portrait -0 0 1 beginpage -gsave -36 36 100 84 boxprim clip newpath -1 1 set_scale 0 rotate 40 41 translate -% Node1 -gsave -0 0 0.74902 nodecolor -newpath 12 .5 moveto -12 19.5 lineto -80 19.5 lineto -80 .5 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath 12 .5 moveto -12 19.5 lineto -80 19.5 lineto -80 .5 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -20 7.5 moveto 52 (QuaAdler32) alignedtext -grestore -% Node2 -gsave -[ /Rect [ 0 56 92 76 ] - /Border [ 0 0 0 ] - /Action << /Subtype /URI /URI ($classQuaChecksum32.html) >> - /Subtype /Link -/ANN pdfmark -0 0 1 nodecolor -newpath 0 56.5 moveto -0 75.5 lineto -92 75.5 lineto -92 56.5 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath 0 56.5 moveto -0 75.5 lineto -92 75.5 lineto -92 56.5 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -8 63.5 moveto 76 (QuaChecksum32) alignedtext -grestore -% Node2->Node1 -gsave -1 setlinewidth -solid -0.66667 0.77647 0.43922 edgecolor -newpath 46 45.8 moveto -46 36.91 46 26.78 46 19.75 curveto -stroke -0.66667 0.77647 0.43922 edgecolor -newpath 42.5 46.08 moveto -46 56.08 lineto -49.5 46.08 lineto -closepath fill -1 setlinewidth -solid -0.66667 0.77647 0.43922 edgecolor -newpath 42.5 46.08 moveto -46 56.08 lineto -49.5 46.08 lineto -closepath stroke -grestore -endpage -showpage -grestore -%%PageTrailer -%%EndPage: 1 -%%Trailer -%%Pages: 1 -%%BoundingBox: 36 36 136 120 -end -restore -%%EOF diff --git a/hecl-gui/quazip/doc/latex/classQuaAdler32__coll__graph.md5 b/hecl-gui/quazip/doc/latex/classQuaAdler32__coll__graph.md5 deleted file mode 100644 index 19124ff2a..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaAdler32__coll__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -dbe414b63f5eac72ebd22d72dbae868f \ No newline at end of file diff --git a/hecl-gui/quazip/doc/latex/classQuaAdler32__inherit__graph.eps b/hecl-gui/quazip/doc/latex/classQuaAdler32__inherit__graph.eps deleted file mode 100644 index 70098d097..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaAdler32__inherit__graph.eps +++ /dev/null @@ -1,263 +0,0 @@ -%!PS-Adobe-3.0 -%%Creator: graphviz version 2.28.0 (20110507.0327) -%%Title: G -%%Pages: (atend) -%%BoundingBox: (atend) -%%EndComments -save -%%BeginProlog -/DotDict 200 dict def -DotDict begin - -/setupLatin1 { -mark -/EncodingVector 256 array def - EncodingVector 0 - -ISOLatin1Encoding 0 255 getinterval putinterval -EncodingVector 45 /hyphen put - -% Set up ISO Latin 1 character encoding -/starnetISO { - dup dup findfont dup length dict begin - { 1 index /FID ne { def }{ pop pop } ifelse - } forall - /Encoding EncodingVector def - currentdict end definefont -} def -/Times-Roman starnetISO def -/Times-Italic starnetISO def -/Times-Bold starnetISO def -/Times-BoldItalic starnetISO def -/Helvetica starnetISO def -/Helvetica-Oblique starnetISO def -/Helvetica-Bold starnetISO def -/Helvetica-BoldOblique starnetISO def -/Courier starnetISO def -/Courier-Oblique starnetISO def -/Courier-Bold starnetISO def -/Courier-BoldOblique starnetISO def -cleartomark -} bind def - -%%BeginResource: procset graphviz 0 0 -/coord-font-family /Times-Roman def -/default-font-family /Times-Roman def -/coordfont coord-font-family findfont 8 scalefont def - -/InvScaleFactor 1.0 def -/set_scale { - dup 1 exch div /InvScaleFactor exch def - scale -} bind def - -% styles -/solid { [] 0 setdash } bind def -/dashed { [9 InvScaleFactor mul dup ] 0 setdash } bind def -/dotted { [1 InvScaleFactor mul 6 InvScaleFactor mul] 0 setdash } bind def -/invis {/fill {newpath} def /stroke {newpath} def /show {pop newpath} def} bind def -/bold { 2 setlinewidth } bind def -/filled { } bind def -/unfilled { } bind def -/rounded { } bind def -/diagonals { } bind def - -% hooks for setting color -/nodecolor { sethsbcolor } bind def -/edgecolor { sethsbcolor } bind def -/graphcolor { sethsbcolor } bind def -/nopcolor {pop pop pop} bind def - -/beginpage { % i j npages - /npages exch def - /j exch def - /i exch def - /str 10 string def - npages 1 gt { - gsave - coordfont setfont - 0 0 moveto - (\() show i str cvs show (,) show j str cvs show (\)) show - grestore - } if -} bind def - -/set_font { - findfont exch - scalefont setfont -} def - -% draw text fitted to its expected width -/alignedtext { % width text - /text exch def - /width exch def - gsave - width 0 gt { - [] 0 setdash - text stringwidth pop width exch sub text length div 0 text ashow - } if - grestore -} def - -/boxprim { % xcorner ycorner xsize ysize - 4 2 roll - moveto - 2 copy - exch 0 rlineto - 0 exch rlineto - pop neg 0 rlineto - closepath -} bind def - -/ellipse_path { - /ry exch def - /rx exch def - /y exch def - /x exch def - matrix currentmatrix - newpath - x y translate - rx ry scale - 0 0 1 0 360 arc - setmatrix -} bind def - -/endpage { showpage } bind def -/showpage { } def - -/layercolorseq - [ % layer color sequence - darkest to lightest - [0 0 0] - [.2 .8 .8] - [.4 .8 .8] - [.6 .8 .8] - [.8 .8 .8] - ] -def - -/layerlen layercolorseq length def - -/setlayer {/maxlayer exch def /curlayer exch def - layercolorseq curlayer 1 sub layerlen mod get - aload pop sethsbcolor - /nodecolor {nopcolor} def - /edgecolor {nopcolor} def - /graphcolor {nopcolor} def -} bind def - -/onlayer { curlayer ne {invis} if } def - -/onlayers { - /myupper exch def - /mylower exch def - curlayer mylower lt - curlayer myupper gt - or - {invis} if -} def - -/curlayer 0 def - -%%EndResource -%%EndProlog -%%BeginSetup -14 default-font-family set_font -1 setmiterlimit -% /arrowlength 10 def -% /arrowwidth 5 def - -% make sure pdfmark is harmless for PS-interpreters other than Distiller -/pdfmark where {pop} {userdict /pdfmark /cleartomark load put} ifelse -% make '<<' and '>>' safe on PS Level 1 devices -/languagelevel where {pop languagelevel}{1} ifelse -2 lt { - userdict (<<) cvn ([) cvn load put - userdict (>>) cvn ([) cvn load put -} if - -%%EndSetup -setupLatin1 -%%Page: 1 1 -%%PageBoundingBox: 36 36 136 120 -%%PageOrientation: Portrait -0 0 1 beginpage -gsave -36 36 100 84 boxprim clip newpath -1 1 set_scale 0 rotate 40 41 translate -% Node1 -gsave -0 0 0.74902 nodecolor -newpath 12 .5 moveto -12 19.5 lineto -80 19.5 lineto -80 .5 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath 12 .5 moveto -12 19.5 lineto -80 19.5 lineto -80 .5 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -20 7.5 moveto 52 (QuaAdler32) alignedtext -grestore -% Node2 -gsave -[ /Rect [ 0 56 92 76 ] - /Border [ 0 0 0 ] - /Action << /Subtype /URI /URI ($classQuaChecksum32.html) >> - /Subtype /Link -/ANN pdfmark -0 0 1 nodecolor -newpath 0 56.5 moveto -0 75.5 lineto -92 75.5 lineto -92 56.5 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath 0 56.5 moveto -0 75.5 lineto -92 75.5 lineto -92 56.5 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -8 63.5 moveto 76 (QuaChecksum32) alignedtext -grestore -% Node2->Node1 -gsave -1 setlinewidth -solid -0.66667 0.77647 0.43922 edgecolor -newpath 46 45.8 moveto -46 36.91 46 26.78 46 19.75 curveto -stroke -0.66667 0.77647 0.43922 edgecolor -newpath 42.5 46.08 moveto -46 56.08 lineto -49.5 46.08 lineto -closepath fill -1 setlinewidth -solid -0.66667 0.77647 0.43922 edgecolor -newpath 42.5 46.08 moveto -46 56.08 lineto -49.5 46.08 lineto -closepath stroke -grestore -endpage -showpage -grestore -%%PageTrailer -%%EndPage: 1 -%%Trailer -%%Pages: 1 -%%BoundingBox: 36 36 136 120 -end -restore -%%EOF diff --git a/hecl-gui/quazip/doc/latex/classQuaAdler32__inherit__graph.md5 b/hecl-gui/quazip/doc/latex/classQuaAdler32__inherit__graph.md5 deleted file mode 100644 index 19124ff2a..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaAdler32__inherit__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -dbe414b63f5eac72ebd22d72dbae868f \ No newline at end of file diff --git a/hecl-gui/quazip/doc/latex/classQuaChecksum32.tex b/hecl-gui/quazip/doc/latex/classQuaChecksum32.tex deleted file mode 100644 index a1fc69081..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaChecksum32.tex +++ /dev/null @@ -1,113 +0,0 @@ -\section{QuaChecksum32 Class Reference} -\label{classQuaChecksum32}\index{QuaChecksum32@{QuaChecksum32}} - - -Checksum interface. - - - - -{\ttfamily \#include $<$quazip/quachecksum32.h$>$} - - - -Inheritance diagram for QuaChecksum32: -\nopagebreak -\begin{figure}[H] -\begin{center} -\leavevmode -\includegraphics[width=190pt]{classQuaChecksum32__inherit__graph} -\end{center} -\end{figure} -\subsection*{Public Member Functions} -\begin{DoxyCompactItemize} -\item -virtual quint32 {\bf calculate} (const QByteArray \&data)=0 -\begin{DoxyCompactList}\small\item\em Calculates the checksum for data. \end{DoxyCompactList}\item -virtual void {\bf reset} ()=0\label{classQuaChecksum32_ad3f5db3c76b00069db9bda333cb49d57} - -\begin{DoxyCompactList}\small\item\em Resets the calculation on a checksun for a stream. \end{DoxyCompactList}\item -virtual void {\bf update} (const QByteArray \&buf)=0 -\begin{DoxyCompactList}\small\item\em Updates the calculated checksum for the stream. \end{DoxyCompactList}\item -virtual quint32 {\bf value} ()=0 -\begin{DoxyCompactList}\small\item\em Value of the checksum calculated for the stream passed throw \doxyref{update()}{p.}{classQuaChecksum32_a63a6ed3171f9243214d307da67557f7e}. \end{DoxyCompactList}\end{DoxyCompactItemize} - - -\subsection{Detailed Description} -Checksum interface. - -This is an interface for 32 bit checksums. Classes implementing this interface can calcunate a certin checksum in a single step: -\begin{DoxyCode} - QChecksum32 *crc32 = new QuaCrc32(); - rasoult = crc32->calculate(data); -\end{DoxyCode} - or by streaming the data: -\begin{DoxyCode} - QChecksum32 *crc32 = new QuaCrc32(); - while(!fileA.atEnd()) - crc32->update(fileA.read(bufSize)); - resoultA = crc32->value(); - crc32->reset(); - while(!fileB.atEnd()) - crc32->update(fileB.read(bufSize)); - resoultB = crc32->value(); -\end{DoxyCode} - - -\subsection{Member Function Documentation} -\index{QuaChecksum32@{QuaChecksum32}!calculate@{calculate}} -\index{calculate@{calculate}!QuaChecksum32@{QuaChecksum32}} -\subsubsection[{calculate}]{\setlength{\rightskip}{0pt plus 5cm}virtual quint32 QuaChecksum32::calculate ( -\begin{DoxyParamCaption} -\item[{const QByteArray \&}]{data} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [pure virtual]}}\label{classQuaChecksum32_a14d800fcfd55b2ae11ef07d3924fe0b1} - - -Calculates the checksum for data. - -{\itshape data\/} source data \begin{DoxyReturn}{Returns} -data checksum -\end{DoxyReturn} -This function has no efect on the value returned by \doxyref{value()}{p.}{classQuaChecksum32_afd836e7534194fce08356be6a8336da7}. - -Implemented in {\bf QuaAdler32} \doxyref{}{p.}{classQuaAdler32_a350e84fd000ebfa3c33503336a7b21bb}, and {\bf QuaCrc32} \doxyref{}{p.}{classQuaCrc32_aaf6fdf6e36e55c97bf9eab6ec65ecb9e}. - -\index{QuaChecksum32@{QuaChecksum32}!update@{update}} -\index{update@{update}!QuaChecksum32@{QuaChecksum32}} -\subsubsection[{update}]{\setlength{\rightskip}{0pt plus 5cm}virtual void QuaChecksum32::update ( -\begin{DoxyParamCaption} -\item[{const QByteArray \&}]{buf} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [pure virtual]}}\label{classQuaChecksum32_a63a6ed3171f9243214d307da67557f7e} - - -Updates the calculated checksum for the stream. - -{\itshape buf\/} next portion of data from the stream - -Implemented in {\bf QuaAdler32} \doxyref{}{p.}{classQuaAdler32_aba24f7b16aa0cdc26f81a9ad687fc653}, and {\bf QuaCrc32} \doxyref{}{p.}{classQuaCrc32_a5015d80e04afe6e6d094155b7e99888e}. - -\index{QuaChecksum32@{QuaChecksum32}!value@{value}} -\index{value@{value}!QuaChecksum32@{QuaChecksum32}} -\subsubsection[{value}]{\setlength{\rightskip}{0pt plus 5cm}virtual quint32 QuaChecksum32::value ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [pure virtual]}}\label{classQuaChecksum32_afd836e7534194fce08356be6a8336da7} - - -Value of the checksum calculated for the stream passed throw \doxyref{update()}{p.}{classQuaChecksum32_a63a6ed3171f9243214d307da67557f7e}. - -\begin{DoxyReturn}{Returns} -checksum -\end{DoxyReturn} - - -Implemented in {\bf QuaAdler32} \doxyref{}{p.}{classQuaAdler32_a2022e1db95c23cef220b335e44d74fb1}, and {\bf QuaCrc32} \doxyref{}{p.}{classQuaCrc32_a957ce46a53862f75c89d6a3ac4f73389}. - - - -The documentation for this class was generated from the following file:\begin{DoxyCompactItemize} -\item -quazip/quachecksum32.h\end{DoxyCompactItemize} diff --git a/hecl-gui/quazip/doc/latex/classQuaChecksum32__inherit__graph.eps b/hecl-gui/quazip/doc/latex/classQuaChecksum32__inherit__graph.eps deleted file mode 100644 index b9994b395..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaChecksum32__inherit__graph.eps +++ /dev/null @@ -1,309 +0,0 @@ -%!PS-Adobe-3.0 -%%Creator: graphviz version 2.28.0 (20110507.0327) -%%Title: G -%%Pages: (atend) -%%BoundingBox: (atend) -%%EndComments -save -%%BeginProlog -/DotDict 200 dict def -DotDict begin - -/setupLatin1 { -mark -/EncodingVector 256 array def - EncodingVector 0 - -ISOLatin1Encoding 0 255 getinterval putinterval -EncodingVector 45 /hyphen put - -% Set up ISO Latin 1 character encoding -/starnetISO { - dup dup findfont dup length dict begin - { 1 index /FID ne { def }{ pop pop } ifelse - } forall - /Encoding EncodingVector def - currentdict end definefont -} def -/Times-Roman starnetISO def -/Times-Italic starnetISO def -/Times-Bold starnetISO def -/Times-BoldItalic starnetISO def -/Helvetica starnetISO def -/Helvetica-Oblique starnetISO def -/Helvetica-Bold starnetISO def -/Helvetica-BoldOblique starnetISO def -/Courier starnetISO def -/Courier-Oblique starnetISO def -/Courier-Bold starnetISO def -/Courier-BoldOblique starnetISO def -cleartomark -} bind def - -%%BeginResource: procset graphviz 0 0 -/coord-font-family /Times-Roman def -/default-font-family /Times-Roman def -/coordfont coord-font-family findfont 8 scalefont def - -/InvScaleFactor 1.0 def -/set_scale { - dup 1 exch div /InvScaleFactor exch def - scale -} bind def - -% styles -/solid { [] 0 setdash } bind def -/dashed { [9 InvScaleFactor mul dup ] 0 setdash } bind def -/dotted { [1 InvScaleFactor mul 6 InvScaleFactor mul] 0 setdash } bind def -/invis {/fill {newpath} def /stroke {newpath} def /show {pop newpath} def} bind def -/bold { 2 setlinewidth } bind def -/filled { } bind def -/unfilled { } bind def -/rounded { } bind def -/diagonals { } bind def - -% hooks for setting color -/nodecolor { sethsbcolor } bind def -/edgecolor { sethsbcolor } bind def -/graphcolor { sethsbcolor } bind def -/nopcolor {pop pop pop} bind def - -/beginpage { % i j npages - /npages exch def - /j exch def - /i exch def - /str 10 string def - npages 1 gt { - gsave - coordfont setfont - 0 0 moveto - (\() show i str cvs show (,) show j str cvs show (\)) show - grestore - } if -} bind def - -/set_font { - findfont exch - scalefont setfont -} def - -% draw text fitted to its expected width -/alignedtext { % width text - /text exch def - /width exch def - gsave - width 0 gt { - [] 0 setdash - text stringwidth pop width exch sub text length div 0 text ashow - } if - grestore -} def - -/boxprim { % xcorner ycorner xsize ysize - 4 2 roll - moveto - 2 copy - exch 0 rlineto - 0 exch rlineto - pop neg 0 rlineto - closepath -} bind def - -/ellipse_path { - /ry exch def - /rx exch def - /y exch def - /x exch def - matrix currentmatrix - newpath - x y translate - rx ry scale - 0 0 1 0 360 arc - setmatrix -} bind def - -/endpage { showpage } bind def -/showpage { } def - -/layercolorseq - [ % layer color sequence - darkest to lightest - [0 0 0] - [.2 .8 .8] - [.4 .8 .8] - [.6 .8 .8] - [.8 .8 .8] - ] -def - -/layerlen layercolorseq length def - -/setlayer {/maxlayer exch def /curlayer exch def - layercolorseq curlayer 1 sub layerlen mod get - aload pop sethsbcolor - /nodecolor {nopcolor} def - /edgecolor {nopcolor} def - /graphcolor {nopcolor} def -} bind def - -/onlayer { curlayer ne {invis} if } def - -/onlayers { - /myupper exch def - /mylower exch def - curlayer mylower lt - curlayer myupper gt - or - {invis} if -} def - -/curlayer 0 def - -%%EndResource -%%EndProlog -%%BeginSetup -14 default-font-family set_font -1 setmiterlimit -% /arrowlength 10 def -% /arrowwidth 5 def - -% make sure pdfmark is harmless for PS-interpreters other than Distiller -/pdfmark where {pop} {userdict /pdfmark /cleartomark load put} ifelse -% make '<<' and '>>' safe on PS Level 1 devices -/languagelevel where {pop languagelevel}{1} ifelse -2 lt { - userdict (<<) cvn ([) cvn load put - userdict (>>) cvn ([) cvn load put -} if - -%%EndSetup -setupLatin1 -%%Page: 1 1 -%%PageBoundingBox: 36 36 190 120 -%%PageOrientation: Portrait -0 0 1 beginpage -gsave -36 36 154 84 boxprim clip newpath -1 1 set_scale 0 rotate 40 41 translate -% Node1 -gsave -0 0 0.74902 nodecolor -newpath 29 56.5 moveto -29 75.5 lineto -121 75.5 lineto -121 56.5 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath 29 56.5 moveto -29 75.5 lineto -121 75.5 lineto -121 56.5 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -37 63.5 moveto 76 (QuaChecksum32) alignedtext -grestore -% Node2 -gsave -[ /Rect [ 0 0 68 20 ] - /Border [ 0 0 0 ] - /Action << /Subtype /URI /URI ($classQuaAdler32.html) >> - /Subtype /Link -/ANN pdfmark -0 0 1 nodecolor -newpath 0 .5 moveto -0 19.5 lineto -68 19.5 lineto -68 .5 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath 0 .5 moveto -0 19.5 lineto -68 19.5 lineto -68 .5 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -8 7.5 moveto 52 (QuaAdler32) alignedtext -grestore -% Node1->Node2 -gsave -1 setlinewidth -solid -0.66667 0.77647 0.43922 edgecolor -newpath 61.98 47.86 moveto -54.88 38.5 46.4 27.33 40.64 19.75 curveto -stroke -0.66667 0.77647 0.43922 edgecolor -newpath 59.39 50.24 moveto -68.23 56.08 lineto -64.97 46 lineto -closepath fill -1 setlinewidth -solid -0.66667 0.77647 0.43922 edgecolor -newpath 59.39 50.24 moveto -68.23 56.08 lineto -64.97 46 lineto -closepath stroke -grestore -% Node3 -gsave -[ /Rect [ 86 0 146 20 ] - /Border [ 0 0 0 ] - /Action << /Subtype /URI /URI ($classQuaCrc32.html) >> - /Subtype /Link -/ANN pdfmark -0 0 1 nodecolor -newpath 86 .5 moveto -86 19.5 lineto -146 19.5 lineto -146 .5 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath 86 .5 moveto -86 19.5 lineto -146 19.5 lineto -146 .5 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -94 7.5 moveto 44 (QuaCrc32) alignedtext -grestore -% Node1->Node3 -gsave -1 setlinewidth -solid -0.66667 0.77647 0.43922 edgecolor -newpath 88.02 47.86 moveto -95.12 38.5 103.6 27.33 109.36 19.75 curveto -stroke -0.66667 0.77647 0.43922 edgecolor -newpath 85.03 46 moveto -81.77 56.08 lineto -90.61 50.24 lineto -closepath fill -1 setlinewidth -solid -0.66667 0.77647 0.43922 edgecolor -newpath 85.03 46 moveto -81.77 56.08 lineto -90.61 50.24 lineto -closepath stroke -grestore -endpage -showpage -grestore -%%PageTrailer -%%EndPage: 1 -%%Trailer -%%Pages: 1 -%%BoundingBox: 36 36 190 120 -end -restore -%%EOF diff --git a/hecl-gui/quazip/doc/latex/classQuaChecksum32__inherit__graph.md5 b/hecl-gui/quazip/doc/latex/classQuaChecksum32__inherit__graph.md5 deleted file mode 100644 index dd4b6e45f..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaChecksum32__inherit__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -fe6eaf22d351a7125f230bf0b6ba2704 \ No newline at end of file diff --git a/hecl-gui/quazip/doc/latex/classQuaCrc32.tex b/hecl-gui/quazip/doc/latex/classQuaCrc32.tex deleted file mode 100644 index f40d1f871..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaCrc32.tex +++ /dev/null @@ -1,108 +0,0 @@ -\section{QuaCrc32 Class Reference} -\label{classQuaCrc32}\index{QuaCrc32@{QuaCrc32}} - - -CRC32 checksum. - - - - -{\ttfamily \#include $<$quazip/quacrc32.h$>$} - - - -Inheritance diagram for QuaCrc32: -\nopagebreak -\begin{figure}[H] -\begin{center} -\leavevmode -\includegraphics[width=136pt]{classQuaCrc32__inherit__graph} -\end{center} -\end{figure} - - -Collaboration diagram for QuaCrc32: -\nopagebreak -\begin{figure}[H] -\begin{center} -\leavevmode -\includegraphics[width=136pt]{classQuaCrc32__coll__graph} -\end{center} -\end{figure} -\subsection*{Public Member Functions} -\begin{DoxyCompactItemize} -\item -quint32 {\bf calculate} (const QByteArray \&data) -\begin{DoxyCompactList}\small\item\em Calculates the checksum for data. \end{DoxyCompactList}\item -void {\bf reset} ()\label{classQuaCrc32_a3fe7ce6cb73512c963ffaabfbbc66363} - -\begin{DoxyCompactList}\small\item\em Resets the calculation on a checksun for a stream. \end{DoxyCompactList}\item -void {\bf update} (const QByteArray \&buf) -\begin{DoxyCompactList}\small\item\em Updates the calculated checksum for the stream. \end{DoxyCompactList}\item -quint32 {\bf value} () -\begin{DoxyCompactList}\small\item\em Value of the checksum calculated for the stream passed throw \doxyref{update()}{p.}{classQuaCrc32_a5015d80e04afe6e6d094155b7e99888e}. \end{DoxyCompactList}\end{DoxyCompactItemize} - - -\subsection{Detailed Description} -CRC32 checksum. - -This class wrappers the crc32 function with the \doxyref{QuaChecksum32}{p.}{classQuaChecksum32} interface. See \doxyref{QuaChecksum32}{p.}{classQuaChecksum32} for more info. - -\subsection{Member Function Documentation} -\index{QuaCrc32@{QuaCrc32}!calculate@{calculate}} -\index{calculate@{calculate}!QuaCrc32@{QuaCrc32}} -\subsubsection[{calculate}]{\setlength{\rightskip}{0pt plus 5cm}quint32 QuaCrc32::calculate ( -\begin{DoxyParamCaption} -\item[{const QByteArray \&}]{data} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [virtual]}}\label{classQuaCrc32_aaf6fdf6e36e55c97bf9eab6ec65ecb9e} - - -Calculates the checksum for data. - -{\itshape data\/} source data \begin{DoxyReturn}{Returns} -data checksum -\end{DoxyReturn} -This function has no efect on the value returned by \doxyref{value()}{p.}{classQuaCrc32_a957ce46a53862f75c89d6a3ac4f73389}. - -Implements {\bf QuaChecksum32} \doxyref{}{p.}{classQuaChecksum32_a14d800fcfd55b2ae11ef07d3924fe0b1}. - -\index{QuaCrc32@{QuaCrc32}!update@{update}} -\index{update@{update}!QuaCrc32@{QuaCrc32}} -\subsubsection[{update}]{\setlength{\rightskip}{0pt plus 5cm}void QuaCrc32::update ( -\begin{DoxyParamCaption} -\item[{const QByteArray \&}]{buf} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [virtual]}}\label{classQuaCrc32_a5015d80e04afe6e6d094155b7e99888e} - - -Updates the calculated checksum for the stream. - -{\itshape buf\/} next portion of data from the stream - -Implements {\bf QuaChecksum32} \doxyref{}{p.}{classQuaChecksum32_a63a6ed3171f9243214d307da67557f7e}. - -\index{QuaCrc32@{QuaCrc32}!value@{value}} -\index{value@{value}!QuaCrc32@{QuaCrc32}} -\subsubsection[{value}]{\setlength{\rightskip}{0pt plus 5cm}quint32 QuaCrc32::value ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [virtual]}}\label{classQuaCrc32_a957ce46a53862f75c89d6a3ac4f73389} - - -Value of the checksum calculated for the stream passed throw \doxyref{update()}{p.}{classQuaCrc32_a5015d80e04afe6e6d094155b7e99888e}. - -\begin{DoxyReturn}{Returns} -checksum -\end{DoxyReturn} - - -Implements {\bf QuaChecksum32} \doxyref{}{p.}{classQuaChecksum32_afd836e7534194fce08356be6a8336da7}. - - - -The documentation for this class was generated from the following files:\begin{DoxyCompactItemize} -\item -quazip/quacrc32.h\item -quazip/quacrc32.cpp\end{DoxyCompactItemize} diff --git a/hecl-gui/quazip/doc/latex/classQuaCrc32__coll__graph.eps b/hecl-gui/quazip/doc/latex/classQuaCrc32__coll__graph.eps deleted file mode 100644 index c7070db22..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaCrc32__coll__graph.eps +++ /dev/null @@ -1,263 +0,0 @@ -%!PS-Adobe-3.0 -%%Creator: graphviz version 2.28.0 (20110507.0327) -%%Title: G -%%Pages: (atend) -%%BoundingBox: (atend) -%%EndComments -save -%%BeginProlog -/DotDict 200 dict def -DotDict begin - -/setupLatin1 { -mark -/EncodingVector 256 array def - EncodingVector 0 - -ISOLatin1Encoding 0 255 getinterval putinterval -EncodingVector 45 /hyphen put - -% Set up ISO Latin 1 character encoding -/starnetISO { - dup dup findfont dup length dict begin - { 1 index /FID ne { def }{ pop pop } ifelse - } forall - /Encoding EncodingVector def - currentdict end definefont -} def -/Times-Roman starnetISO def -/Times-Italic starnetISO def -/Times-Bold starnetISO def -/Times-BoldItalic starnetISO def -/Helvetica starnetISO def -/Helvetica-Oblique starnetISO def -/Helvetica-Bold starnetISO def -/Helvetica-BoldOblique starnetISO def -/Courier starnetISO def -/Courier-Oblique starnetISO def -/Courier-Bold starnetISO def -/Courier-BoldOblique starnetISO def -cleartomark -} bind def - -%%BeginResource: procset graphviz 0 0 -/coord-font-family /Times-Roman def -/default-font-family /Times-Roman def -/coordfont coord-font-family findfont 8 scalefont def - -/InvScaleFactor 1.0 def -/set_scale { - dup 1 exch div /InvScaleFactor exch def - scale -} bind def - -% styles -/solid { [] 0 setdash } bind def -/dashed { [9 InvScaleFactor mul dup ] 0 setdash } bind def -/dotted { [1 InvScaleFactor mul 6 InvScaleFactor mul] 0 setdash } bind def -/invis {/fill {newpath} def /stroke {newpath} def /show {pop newpath} def} bind def -/bold { 2 setlinewidth } bind def -/filled { } bind def -/unfilled { } bind def -/rounded { } bind def -/diagonals { } bind def - -% hooks for setting color -/nodecolor { sethsbcolor } bind def -/edgecolor { sethsbcolor } bind def -/graphcolor { sethsbcolor } bind def -/nopcolor {pop pop pop} bind def - -/beginpage { % i j npages - /npages exch def - /j exch def - /i exch def - /str 10 string def - npages 1 gt { - gsave - coordfont setfont - 0 0 moveto - (\() show i str cvs show (,) show j str cvs show (\)) show - grestore - } if -} bind def - -/set_font { - findfont exch - scalefont setfont -} def - -% draw text fitted to its expected width -/alignedtext { % width text - /text exch def - /width exch def - gsave - width 0 gt { - [] 0 setdash - text stringwidth pop width exch sub text length div 0 text ashow - } if - grestore -} def - -/boxprim { % xcorner ycorner xsize ysize - 4 2 roll - moveto - 2 copy - exch 0 rlineto - 0 exch rlineto - pop neg 0 rlineto - closepath -} bind def - -/ellipse_path { - /ry exch def - /rx exch def - /y exch def - /x exch def - matrix currentmatrix - newpath - x y translate - rx ry scale - 0 0 1 0 360 arc - setmatrix -} bind def - -/endpage { showpage } bind def -/showpage { } def - -/layercolorseq - [ % layer color sequence - darkest to lightest - [0 0 0] - [.2 .8 .8] - [.4 .8 .8] - [.6 .8 .8] - [.8 .8 .8] - ] -def - -/layerlen layercolorseq length def - -/setlayer {/maxlayer exch def /curlayer exch def - layercolorseq curlayer 1 sub layerlen mod get - aload pop sethsbcolor - /nodecolor {nopcolor} def - /edgecolor {nopcolor} def - /graphcolor {nopcolor} def -} bind def - -/onlayer { curlayer ne {invis} if } def - -/onlayers { - /myupper exch def - /mylower exch def - curlayer mylower lt - curlayer myupper gt - or - {invis} if -} def - -/curlayer 0 def - -%%EndResource -%%EndProlog -%%BeginSetup -14 default-font-family set_font -1 setmiterlimit -% /arrowlength 10 def -% /arrowwidth 5 def - -% make sure pdfmark is harmless for PS-interpreters other than Distiller -/pdfmark where {pop} {userdict /pdfmark /cleartomark load put} ifelse -% make '<<' and '>>' safe on PS Level 1 devices -/languagelevel where {pop languagelevel}{1} ifelse -2 lt { - userdict (<<) cvn ([) cvn load put - userdict (>>) cvn ([) cvn load put -} if - -%%EndSetup -setupLatin1 -%%Page: 1 1 -%%PageBoundingBox: 36 36 136 120 -%%PageOrientation: Portrait -0 0 1 beginpage -gsave -36 36 100 84 boxprim clip newpath -1 1 set_scale 0 rotate 40 41 translate -% Node1 -gsave -0 0 0.74902 nodecolor -newpath 16 .5 moveto -16 19.5 lineto -76 19.5 lineto -76 .5 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath 16 .5 moveto -16 19.5 lineto -76 19.5 lineto -76 .5 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -24 7.5 moveto 44 (QuaCrc32) alignedtext -grestore -% Node2 -gsave -[ /Rect [ 0 56 92 76 ] - /Border [ 0 0 0 ] - /Action << /Subtype /URI /URI ($classQuaChecksum32.html) >> - /Subtype /Link -/ANN pdfmark -0 0 1 nodecolor -newpath 0 56.5 moveto -0 75.5 lineto -92 75.5 lineto -92 56.5 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath 0 56.5 moveto -0 75.5 lineto -92 75.5 lineto -92 56.5 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -8 63.5 moveto 76 (QuaChecksum32) alignedtext -grestore -% Node2->Node1 -gsave -1 setlinewidth -solid -0.66667 0.77647 0.43922 edgecolor -newpath 46 45.8 moveto -46 36.91 46 26.78 46 19.75 curveto -stroke -0.66667 0.77647 0.43922 edgecolor -newpath 42.5 46.08 moveto -46 56.08 lineto -49.5 46.08 lineto -closepath fill -1 setlinewidth -solid -0.66667 0.77647 0.43922 edgecolor -newpath 42.5 46.08 moveto -46 56.08 lineto -49.5 46.08 lineto -closepath stroke -grestore -endpage -showpage -grestore -%%PageTrailer -%%EndPage: 1 -%%Trailer -%%Pages: 1 -%%BoundingBox: 36 36 136 120 -end -restore -%%EOF diff --git a/hecl-gui/quazip/doc/latex/classQuaCrc32__coll__graph.md5 b/hecl-gui/quazip/doc/latex/classQuaCrc32__coll__graph.md5 deleted file mode 100644 index 58c6544f5..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaCrc32__coll__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -494c6ee53c032c90c71e084fc73592f9 \ No newline at end of file diff --git a/hecl-gui/quazip/doc/latex/classQuaCrc32__inherit__graph.eps b/hecl-gui/quazip/doc/latex/classQuaCrc32__inherit__graph.eps deleted file mode 100644 index c7070db22..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaCrc32__inherit__graph.eps +++ /dev/null @@ -1,263 +0,0 @@ -%!PS-Adobe-3.0 -%%Creator: graphviz version 2.28.0 (20110507.0327) -%%Title: G -%%Pages: (atend) -%%BoundingBox: (atend) -%%EndComments -save -%%BeginProlog -/DotDict 200 dict def -DotDict begin - -/setupLatin1 { -mark -/EncodingVector 256 array def - EncodingVector 0 - -ISOLatin1Encoding 0 255 getinterval putinterval -EncodingVector 45 /hyphen put - -% Set up ISO Latin 1 character encoding -/starnetISO { - dup dup findfont dup length dict begin - { 1 index /FID ne { def }{ pop pop } ifelse - } forall - /Encoding EncodingVector def - currentdict end definefont -} def -/Times-Roman starnetISO def -/Times-Italic starnetISO def -/Times-Bold starnetISO def -/Times-BoldItalic starnetISO def -/Helvetica starnetISO def -/Helvetica-Oblique starnetISO def -/Helvetica-Bold starnetISO def -/Helvetica-BoldOblique starnetISO def -/Courier starnetISO def -/Courier-Oblique starnetISO def -/Courier-Bold starnetISO def -/Courier-BoldOblique starnetISO def -cleartomark -} bind def - -%%BeginResource: procset graphviz 0 0 -/coord-font-family /Times-Roman def -/default-font-family /Times-Roman def -/coordfont coord-font-family findfont 8 scalefont def - -/InvScaleFactor 1.0 def -/set_scale { - dup 1 exch div /InvScaleFactor exch def - scale -} bind def - -% styles -/solid { [] 0 setdash } bind def -/dashed { [9 InvScaleFactor mul dup ] 0 setdash } bind def -/dotted { [1 InvScaleFactor mul 6 InvScaleFactor mul] 0 setdash } bind def -/invis {/fill {newpath} def /stroke {newpath} def /show {pop newpath} def} bind def -/bold { 2 setlinewidth } bind def -/filled { } bind def -/unfilled { } bind def -/rounded { } bind def -/diagonals { } bind def - -% hooks for setting color -/nodecolor { sethsbcolor } bind def -/edgecolor { sethsbcolor } bind def -/graphcolor { sethsbcolor } bind def -/nopcolor {pop pop pop} bind def - -/beginpage { % i j npages - /npages exch def - /j exch def - /i exch def - /str 10 string def - npages 1 gt { - gsave - coordfont setfont - 0 0 moveto - (\() show i str cvs show (,) show j str cvs show (\)) show - grestore - } if -} bind def - -/set_font { - findfont exch - scalefont setfont -} def - -% draw text fitted to its expected width -/alignedtext { % width text - /text exch def - /width exch def - gsave - width 0 gt { - [] 0 setdash - text stringwidth pop width exch sub text length div 0 text ashow - } if - grestore -} def - -/boxprim { % xcorner ycorner xsize ysize - 4 2 roll - moveto - 2 copy - exch 0 rlineto - 0 exch rlineto - pop neg 0 rlineto - closepath -} bind def - -/ellipse_path { - /ry exch def - /rx exch def - /y exch def - /x exch def - matrix currentmatrix - newpath - x y translate - rx ry scale - 0 0 1 0 360 arc - setmatrix -} bind def - -/endpage { showpage } bind def -/showpage { } def - -/layercolorseq - [ % layer color sequence - darkest to lightest - [0 0 0] - [.2 .8 .8] - [.4 .8 .8] - [.6 .8 .8] - [.8 .8 .8] - ] -def - -/layerlen layercolorseq length def - -/setlayer {/maxlayer exch def /curlayer exch def - layercolorseq curlayer 1 sub layerlen mod get - aload pop sethsbcolor - /nodecolor {nopcolor} def - /edgecolor {nopcolor} def - /graphcolor {nopcolor} def -} bind def - -/onlayer { curlayer ne {invis} if } def - -/onlayers { - /myupper exch def - /mylower exch def - curlayer mylower lt - curlayer myupper gt - or - {invis} if -} def - -/curlayer 0 def - -%%EndResource -%%EndProlog -%%BeginSetup -14 default-font-family set_font -1 setmiterlimit -% /arrowlength 10 def -% /arrowwidth 5 def - -% make sure pdfmark is harmless for PS-interpreters other than Distiller -/pdfmark where {pop} {userdict /pdfmark /cleartomark load put} ifelse -% make '<<' and '>>' safe on PS Level 1 devices -/languagelevel where {pop languagelevel}{1} ifelse -2 lt { - userdict (<<) cvn ([) cvn load put - userdict (>>) cvn ([) cvn load put -} if - -%%EndSetup -setupLatin1 -%%Page: 1 1 -%%PageBoundingBox: 36 36 136 120 -%%PageOrientation: Portrait -0 0 1 beginpage -gsave -36 36 100 84 boxprim clip newpath -1 1 set_scale 0 rotate 40 41 translate -% Node1 -gsave -0 0 0.74902 nodecolor -newpath 16 .5 moveto -16 19.5 lineto -76 19.5 lineto -76 .5 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath 16 .5 moveto -16 19.5 lineto -76 19.5 lineto -76 .5 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -24 7.5 moveto 44 (QuaCrc32) alignedtext -grestore -% Node2 -gsave -[ /Rect [ 0 56 92 76 ] - /Border [ 0 0 0 ] - /Action << /Subtype /URI /URI ($classQuaChecksum32.html) >> - /Subtype /Link -/ANN pdfmark -0 0 1 nodecolor -newpath 0 56.5 moveto -0 75.5 lineto -92 75.5 lineto -92 56.5 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath 0 56.5 moveto -0 75.5 lineto -92 75.5 lineto -92 56.5 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -8 63.5 moveto 76 (QuaChecksum32) alignedtext -grestore -% Node2->Node1 -gsave -1 setlinewidth -solid -0.66667 0.77647 0.43922 edgecolor -newpath 46 45.8 moveto -46 36.91 46 26.78 46 19.75 curveto -stroke -0.66667 0.77647 0.43922 edgecolor -newpath 42.5 46.08 moveto -46 56.08 lineto -49.5 46.08 lineto -closepath fill -1 setlinewidth -solid -0.66667 0.77647 0.43922 edgecolor -newpath 42.5 46.08 moveto -46 56.08 lineto -49.5 46.08 lineto -closepath stroke -grestore -endpage -showpage -grestore -%%PageTrailer -%%EndPage: 1 -%%Trailer -%%Pages: 1 -%%BoundingBox: 36 36 136 120 -end -restore -%%EOF diff --git a/hecl-gui/quazip/doc/latex/classQuaCrc32__inherit__graph.md5 b/hecl-gui/quazip/doc/latex/classQuaCrc32__inherit__graph.md5 deleted file mode 100644 index 58c6544f5..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaCrc32__inherit__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -494c6ee53c032c90c71e084fc73592f9 \ No newline at end of file diff --git a/hecl-gui/quazip/doc/latex/classQuaGzipFile.tex b/hecl-gui/quazip/doc/latex/classQuaGzipFile.tex deleted file mode 100644 index addcc550d..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaGzipFile.tex +++ /dev/null @@ -1,177 +0,0 @@ -\section{QuaGzipFile Class Reference} -\label{classQuaGzipFile}\index{QuaGzipFile@{QuaGzipFile}} - - -GZIP file. - - - - -{\ttfamily \#include $<$quagzipfile.h$>$} - -\subsection*{Public Member Functions} -\begin{DoxyCompactItemize} -\item -{\bf QuaGzipFile} () -\begin{DoxyCompactList}\small\item\em Empty constructor. \end{DoxyCompactList}\item -{\bf QuaGzipFile} (QObject $\ast$parent) -\begin{DoxyCompactList}\small\item\em Empty constructor with a parent. \end{DoxyCompactList}\item -{\bf QuaGzipFile} (const QString \&fileName, QObject $\ast$parent=NULL) -\begin{DoxyCompactList}\small\item\em Constructor. \end{DoxyCompactList}\item -virtual {\bf $\sim$QuaGzipFile} ()\label{classQuaGzipFile_a1200bc76f36bb2e1991e1e0467befbf2} - -\begin{DoxyCompactList}\small\item\em Destructor. \end{DoxyCompactList}\item -void {\bf setFileName} (const QString \&fileName)\label{classQuaGzipFile_a253fbaf410a3d4ae0a719505c5525149} - -\begin{DoxyCompactList}\small\item\em Sets the name of the GZIP file to be opened. \end{DoxyCompactList}\item -QString {\bf getFileName} () const \label{classQuaGzipFile_a9a0954a1db1fcf2aeba0530239bce71c} - -\begin{DoxyCompactList}\small\item\em Returns the name of the GZIP file. \end{DoxyCompactList}\item -virtual bool {\bf isSequential} () const -\begin{DoxyCompactList}\small\item\em Returns true. \end{DoxyCompactList}\item -virtual bool {\bf open} (QIODevice::OpenMode mode) -\begin{DoxyCompactList}\small\item\em Opens the file. \end{DoxyCompactList}\item -virtual bool {\bf open} (int fd, QIODevice::OpenMode mode) -\begin{DoxyCompactList}\small\item\em Opens the file. \end{DoxyCompactList}\item -virtual bool {\bf flush} () -\begin{DoxyCompactList}\small\item\em Flushes data to file. \end{DoxyCompactList}\item -virtual void {\bf close} ()\label{classQuaGzipFile_a273205350b1235a242a1eb5cbf586434} - -\begin{DoxyCompactList}\small\item\em Closes the file. \end{DoxyCompactList}\end{DoxyCompactItemize} -\subsection*{Protected Member Functions} -\begin{DoxyCompactItemize} -\item -virtual qint64 {\bf readData} (char $\ast$data, qint64 maxSize)\label{classQuaGzipFile_a9eab41b46367e63e0c269c42ca883d82} - -\begin{DoxyCompactList}\small\item\em Implementation of QIODevice::readData(). \end{DoxyCompactList}\item -virtual qint64 {\bf writeData} (const char $\ast$data, qint64 maxSize)\label{classQuaGzipFile_a6dd09d41d8a51c96b0f2134eff37f676} - -\begin{DoxyCompactList}\small\item\em Implementation of QIODevice::writeData(). \end{DoxyCompactList}\end{DoxyCompactItemize} - - -\subsection{Detailed Description} -GZIP file. - -This class is a wrapper around GZIP file access functions in zlib. Unlike \doxyref{QuaZip}{p.}{classQuaZip} classes, it doesn't allow reading from a GZIP file opened as QIODevice, for example, if your GZIP file is in QBuffer. It only provides QIODevice access to a GZIP file contents, but the GZIP file itself must be identified by its name on disk or by descriptor id. - -\subsection{Constructor \& Destructor Documentation} -\index{QuaGzipFile@{QuaGzipFile}!QuaGzipFile@{QuaGzipFile}} -\index{QuaGzipFile@{QuaGzipFile}!QuaGzipFile@{QuaGzipFile}} -\subsubsection[{QuaGzipFile}]{\setlength{\rightskip}{0pt plus 5cm}QuaGzipFile::QuaGzipFile ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -)}\label{classQuaGzipFile_a709608207b41ca81d5beed2b34982809} - - -Empty constructor. - -Must call \doxyref{setFileName()}{p.}{classQuaGzipFile_a253fbaf410a3d4ae0a719505c5525149} before trying to open. \index{QuaGzipFile@{QuaGzipFile}!QuaGzipFile@{QuaGzipFile}} -\index{QuaGzipFile@{QuaGzipFile}!QuaGzipFile@{QuaGzipFile}} -\subsubsection[{QuaGzipFile}]{\setlength{\rightskip}{0pt plus 5cm}QuaGzipFile::QuaGzipFile ( -\begin{DoxyParamCaption} -\item[{QObject $\ast$}]{parent} -\end{DoxyParamCaption} -)}\label{classQuaGzipFile_a13996f5db660c4a29645f8d208b9ca6b} - - -Empty constructor with a parent. - -Must call \doxyref{setFileName()}{p.}{classQuaGzipFile_a253fbaf410a3d4ae0a719505c5525149} before trying to open. -\begin{DoxyParams}{Parameters} -{\em parent} & The parent object, as per QObject logic. \\ -\hline -\end{DoxyParams} -\index{QuaGzipFile@{QuaGzipFile}!QuaGzipFile@{QuaGzipFile}} -\index{QuaGzipFile@{QuaGzipFile}!QuaGzipFile@{QuaGzipFile}} -\subsubsection[{QuaGzipFile}]{\setlength{\rightskip}{0pt plus 5cm}QuaGzipFile::QuaGzipFile ( -\begin{DoxyParamCaption} -\item[{const QString \&}]{fileName, } -\item[{QObject $\ast$}]{parent = {\ttfamily NULL}} -\end{DoxyParamCaption} -)}\label{classQuaGzipFile_ac7f7703bda9c6169c001aa15641bb2ea} - - -Constructor. - - -\begin{DoxyParams}{Parameters} -{\em fileName} & The name of the GZIP file. \\ -\hline -{\em parent} & The parent object, as per QObject logic. \\ -\hline -\end{DoxyParams} - - -\subsection{Member Function Documentation} -\index{QuaGzipFile@{QuaGzipFile}!isSequential@{isSequential}} -\index{isSequential@{isSequential}!QuaGzipFile@{QuaGzipFile}} -\subsubsection[{isSequential}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaGzipFile::isSequential ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const\hspace{0.3cm}{\ttfamily [virtual]}}\label{classQuaGzipFile_ae97f4e15d86c965c156df33d00318176} - - -Returns true. - -Strictly speaking, zlib supports seeking for GZIP files, but it is poorly implemented, because there is no way to implement it properly. For reading, seeking backwards is very slow, and for writing, it is downright impossible. Therefore, \doxyref{QuaGzipFile}{p.}{classQuaGzipFile} does not support seeking at all. \index{QuaGzipFile@{QuaGzipFile}!open@{open}} -\index{open@{open}!QuaGzipFile@{QuaGzipFile}} -\subsubsection[{open}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaGzipFile::open ( -\begin{DoxyParamCaption} -\item[{QIODevice::OpenMode}]{mode} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [virtual]}}\label{classQuaGzipFile_a1d560babdfff3a3441d704099a5bc1e4} - - -Opens the file. - - -\begin{DoxyParams}{Parameters} -{\em mode} & Can be either QIODevice::Write or QIODevice::Read. ReadWrite and Append aren't supported. \\ -\hline -\end{DoxyParams} - - -Referenced by open(). - -\index{QuaGzipFile@{QuaGzipFile}!open@{open}} -\index{open@{open}!QuaGzipFile@{QuaGzipFile}} -\subsubsection[{open}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaGzipFile::open ( -\begin{DoxyParamCaption} -\item[{int}]{fd, } -\item[{QIODevice::OpenMode}]{mode} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [virtual]}}\label{classQuaGzipFile_adf5a954bb9bfda2d33cd336a213e2549} - - -Opens the file. - -This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. -\begin{DoxyParams}{Parameters} -{\em fd} & The file descriptor to read/write the GZIP file from/to. \\ -\hline -{\em mode} & Can be either QIODevice::Write or QIODevice::Read. ReadWrite and Append aren't supported. \\ -\hline -\end{DoxyParams} - - -References open(). - -\index{QuaGzipFile@{QuaGzipFile}!flush@{flush}} -\index{flush@{flush}!QuaGzipFile@{QuaGzipFile}} -\subsubsection[{flush}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaGzipFile::flush ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [virtual]}}\label{classQuaGzipFile_ab745f345b727c81abbc3eb5af4dca844} - - -Flushes data to file. - -The data is written using Z\_\-SYNC\_\-FLUSH mode. Doesn't make any sense when reading. - -The documentation for this class was generated from the following files:\begin{DoxyCompactItemize} -\item -quazip/quagzipfile.h\item -quazip/quagzipfile.cpp\end{DoxyCompactItemize} diff --git a/hecl-gui/quazip/doc/latex/classQuaZIODevice.tex b/hecl-gui/quazip/doc/latex/classQuaZIODevice.tex deleted file mode 100644 index bb9518c85..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaZIODevice.tex +++ /dev/null @@ -1,136 +0,0 @@ -\section{QuaZIODevice Class Reference} -\label{classQuaZIODevice}\index{QuaZIODevice@{QuaZIODevice}} - - -A class to compress/decompress QIODevice. - - - - -{\ttfamily \#include $<$quaziodevice.h$>$} - -\subsection*{Public Member Functions} -\begin{DoxyCompactItemize} -\item -{\bf QuaZIODevice} (QIODevice $\ast$io, QObject $\ast$parent=NULL) -\begin{DoxyCompactList}\small\item\em Constructor. \end{DoxyCompactList}\item -{\bf $\sim$QuaZIODevice} ()\label{classQuaZIODevice_ab3524cef44c240c21e6b7680ee5f42de} - -\begin{DoxyCompactList}\small\item\em Destructor. \end{DoxyCompactList}\item -virtual bool {\bf flush} () -\begin{DoxyCompactList}\small\item\em Flushes data waiting to be written. \end{DoxyCompactList}\item -virtual bool {\bf open} (QIODevice::OpenMode mode) -\begin{DoxyCompactList}\small\item\em Opens the device. \end{DoxyCompactList}\item -virtual void {\bf close} () -\begin{DoxyCompactList}\small\item\em Closes this device, but not the underlying one. \end{DoxyCompactList}\item -QIODevice $\ast$ {\bf getIoDevice} () const \label{classQuaZIODevice_ad63e7f1717c7d91b3c2c5ace908c98b7} - -\begin{DoxyCompactList}\small\item\em Returns the underlying device. \end{DoxyCompactList}\item -virtual bool {\bf isSequential} () const \label{classQuaZIODevice_af2697f58c228741d3715801bf48a9a8b} - -\begin{DoxyCompactList}\small\item\em Returns true. \end{DoxyCompactList}\end{DoxyCompactItemize} -\subsection*{Protected Member Functions} -\begin{DoxyCompactItemize} -\item -virtual qint64 {\bf readData} (char $\ast$data, qint64 maxSize)\label{classQuaZIODevice_aa12b8bc9c923e543eda9ae22dbd1ecbb} - -\begin{DoxyCompactList}\small\item\em Implementation of QIODevice::readData(). \end{DoxyCompactList}\item -virtual qint64 {\bf writeData} (const char $\ast$data, qint64 maxSize)\label{classQuaZIODevice_aab23b6badbc3548eb71ca86bf6211902} - -\begin{DoxyCompactList}\small\item\em Implementation of QIODevice::writeData(). \end{DoxyCompactList}\end{DoxyCompactItemize} - - -\subsection{Detailed Description} -A class to compress/decompress QIODevice. - -This class can be used to compress any data written to QIODevice or decompress it back. Compressing data sent over a QTcpSocket is a good example. - -\subsection{Constructor \& Destructor Documentation} -\index{QuaZIODevice@{QuaZIODevice}!QuaZIODevice@{QuaZIODevice}} -\index{QuaZIODevice@{QuaZIODevice}!QuaZIODevice@{QuaZIODevice}} -\subsubsection[{QuaZIODevice}]{\setlength{\rightskip}{0pt plus 5cm}QuaZIODevice::QuaZIODevice ( -\begin{DoxyParamCaption} -\item[{QIODevice $\ast$}]{io, } -\item[{QObject $\ast$}]{parent = {\ttfamily NULL}} -\end{DoxyParamCaption} -)}\label{classQuaZIODevice_a8321ed35ee9b57cf9b1104912e236361} - - -Constructor. - - -\begin{DoxyParams}{Parameters} -{\em io} & The QIODevice to read/write. \\ -\hline -{\em parent} & The parent object, as per QObject logic. \\ -\hline -\end{DoxyParams} - - -\subsection{Member Function Documentation} -\index{QuaZIODevice@{QuaZIODevice}!flush@{flush}} -\index{flush@{flush}!QuaZIODevice@{QuaZIODevice}} -\subsubsection[{flush}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZIODevice::flush ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [virtual]}}\label{classQuaZIODevice_a25f586eb564841b51c395fd17f1cc080} - - -Flushes data waiting to be written. - -Unfortunately, as QIODevice doesn't support \doxyref{flush()}{p.}{classQuaZIODevice_a25f586eb564841b51c395fd17f1cc080} by itself, the only thing this method does is write the compressed data into the device using Z\_\-SYNC\_\-FLUSH mode. If you need the compressed data to actually be flushed from the buffer of the underlying QIODevice, you need to call its \doxyref{flush()}{p.}{classQuaZIODevice_a25f586eb564841b51c395fd17f1cc080} method as well, providing it supports it (like QTcpSocket does). Example: -\begin{DoxyCode} - QuaZIODevice dev(&sock); - dev.open(QIODevice::Write); - dev.write(yourDataGoesHere); - dev.flush(); - sock->flush(); // this actually sends data to network -\end{DoxyCode} - - -This may change in the future versions of QuaZIP by implementing an ugly hack: trying to cast the QIODevice using qobject\_\-cast to known \doxyref{flush()}{p.}{classQuaZIODevice_a25f586eb564841b51c395fd17f1cc080}-\/supporting subclasses, and calling flush if the resulting pointer is not zero. - -Referenced by close(). - -\index{QuaZIODevice@{QuaZIODevice}!open@{open}} -\index{open@{open}!QuaZIODevice@{QuaZIODevice}} -\subsubsection[{open}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZIODevice::open ( -\begin{DoxyParamCaption} -\item[{QIODevice::OpenMode}]{mode} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [virtual]}}\label{classQuaZIODevice_a175446c18eb20c9aff6faf23f09cc67a} - - -Opens the device. - - -\begin{DoxyParams}{Parameters} -{\em mode} & Neither QIODevice::ReadWrite nor QIODevice::Append are not supported. \\ -\hline -\end{DoxyParams} -\index{QuaZIODevice@{QuaZIODevice}!close@{close}} -\index{close@{close}!QuaZIODevice@{QuaZIODevice}} -\subsubsection[{close}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZIODevice::close ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [virtual]}}\label{classQuaZIODevice_ad27e447544d57f897316ee6f44535895} - - -Closes this device, but not the underlying one. - -The underlying QIODevice is not closed in case you want to write something else to it. - -References flush(). - - - -Referenced by $\sim$QuaZIODevice(). - - - -The documentation for this class was generated from the following files:\begin{DoxyCompactItemize} -\item -quazip/quaziodevice.h\item -quazip/quaziodevice.cpp\end{DoxyCompactItemize} diff --git a/hecl-gui/quazip/doc/latex/classQuaZip.tex b/hecl-gui/quazip/doc/latex/classQuaZip.tex deleted file mode 100644 index 8285e88fd..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaZip.tex +++ /dev/null @@ -1,956 +0,0 @@ -\section{QuaZip Class Reference} -\label{classQuaZip}\index{QuaZip@{QuaZip}} - - -ZIP archive. - - - - -{\ttfamily \#include $<$quazip/quazip.h$>$} - - - -Collaboration diagram for QuaZip: -\nopagebreak -\begin{figure}[H] -\begin{center} -\leavevmode -\includegraphics[width=120pt]{classQuaZip__coll__graph} -\end{center} -\end{figure} -\subsection*{Public Types} -\begin{DoxyCompactItemize} -\item -enum {\bf Constants} \{ {\bf MAX\_\-FILE\_\-NAME\_\-LENGTH} = 256 - \} -\begin{DoxyCompactList}\small\item\em Useful constants. \end{DoxyCompactList}\item -enum {\bf Mode} \{ \par -{\bf mdNotOpen}, -{\bf mdUnzip}, -{\bf mdCreate}, -{\bf mdAppend}, -\par -{\bf mdAdd} - \} -\begin{DoxyCompactList}\small\item\em Open mode of the ZIP file. \end{DoxyCompactList}\item -enum {\bf CaseSensitivity} \{ {\bf csDefault} = 0, -{\bf csSensitive} = 1, -{\bf csInsensitive} = 2 - \} -\begin{DoxyCompactList}\small\item\em Case sensitivity for the file names. \end{DoxyCompactList}\end{DoxyCompactItemize} -\subsection*{Public Member Functions} -\begin{DoxyCompactItemize} -\item -{\bf QuaZip} () -\begin{DoxyCompactList}\small\item\em Constructs \doxyref{QuaZip}{p.}{classQuaZip} object. \end{DoxyCompactList}\item -{\bf QuaZip} (const QString \&zipName)\label{classQuaZip_aaea7294b02abd22379cc3a9fccb754b7} - -\begin{DoxyCompactList}\small\item\em Constructs \doxyref{QuaZip}{p.}{classQuaZip} object associated with ZIP file {\itshape zipName\/}. \end{DoxyCompactList}\item -{\bf QuaZip} (QIODevice $\ast$ioDevice) -\begin{DoxyCompactList}\small\item\em Constructs \doxyref{QuaZip}{p.}{classQuaZip} object associated with ZIP file represented by {\itshape ioDevice\/}. \end{DoxyCompactList}\item -{\bf $\sim$QuaZip} () -\begin{DoxyCompactList}\small\item\em Destroys \doxyref{QuaZip}{p.}{classQuaZip} object. \end{DoxyCompactList}\item -bool {\bf open} ({\bf Mode} mode, zlib\_\-filefunc\_\-def $\ast$ioApi=NULL) -\begin{DoxyCompactList}\small\item\em Opens ZIP file. \end{DoxyCompactList}\item -void {\bf close} () -\begin{DoxyCompactList}\small\item\em Closes ZIP file. \end{DoxyCompactList}\item -void {\bf setFileNameCodec} (QTextCodec $\ast$fileNameCodec) -\begin{DoxyCompactList}\small\item\em Sets the codec used to encode/decode file names inside archive. \end{DoxyCompactList}\item -void {\bf setFileNameCodec} (const char $\ast$fileNameCodecName) -\begin{DoxyCompactList}\small\item\em Sets the codec used to encode/decode file names inside archive. \end{DoxyCompactList}\item -QTextCodec $\ast$ {\bf getFileNameCodec} () const \label{classQuaZip_a27b866aa2c75ea6f9c438cbb6e32b43c} - -\begin{DoxyCompactList}\small\item\em Returns the codec used to encode/decode comments inside archive. \end{DoxyCompactList}\item -void {\bf setCommentCodec} (QTextCodec $\ast$commentCodec) -\begin{DoxyCompactList}\small\item\em Sets the codec used to encode/decode comments inside archive. \end{DoxyCompactList}\item -void {\bf setCommentCodec} (const char $\ast$commentCodecName) -\begin{DoxyCompactList}\small\item\em Sets the codec used to encode/decode comments inside archive. \end{DoxyCompactList}\item -QTextCodec $\ast$ {\bf getCommentCodec} () const \label{classQuaZip_a008260161781d8b5d2a0a28493fddaf4} - -\begin{DoxyCompactList}\small\item\em Returns the codec used to encode/decode comments inside archive. \end{DoxyCompactList}\item -QString {\bf getZipName} () const -\begin{DoxyCompactList}\small\item\em Returns the name of the ZIP file. \end{DoxyCompactList}\item -void {\bf setZipName} (const QString \&zipName) -\begin{DoxyCompactList}\small\item\em Sets the name of the ZIP file. \end{DoxyCompactList}\item -QIODevice $\ast$ {\bf getIoDevice} () const -\begin{DoxyCompactList}\small\item\em Returns the device representing this ZIP file. \end{DoxyCompactList}\item -void {\bf setIoDevice} (QIODevice $\ast$ioDevice) -\begin{DoxyCompactList}\small\item\em Sets the device representing the ZIP file. \end{DoxyCompactList}\item -{\bf Mode} {\bf getMode} () const \label{classQuaZip_a129ceff04d28fb00531f7bf7f9329664} - -\begin{DoxyCompactList}\small\item\em Returns the mode in which ZIP file was opened. \end{DoxyCompactList}\item -bool {\bf isOpen} () const \label{classQuaZip_a5b869a9c0d4f49955b759592fec08888} - -\begin{DoxyCompactList}\small\item\em Returns {\ttfamily true} if ZIP file is open, {\ttfamily false} otherwise. \end{DoxyCompactList}\item -int {\bf getZipError} () const -\begin{DoxyCompactList}\small\item\em Returns the error code of the last operation. \end{DoxyCompactList}\item -int {\bf getEntriesCount} () const -\begin{DoxyCompactList}\small\item\em Returns number of the entries in the ZIP central directory. \end{DoxyCompactList}\item -QString {\bf getComment} () const \label{classQuaZip_ae55cfbf2296132df808c557b62433051} - -\begin{DoxyCompactList}\small\item\em Returns global comment in the ZIP file. \end{DoxyCompactList}\item -void {\bf setComment} (const QString \&comment) -\begin{DoxyCompactList}\small\item\em Sets the global comment in the ZIP file. \end{DoxyCompactList}\item -bool {\bf goToFirstFile} () -\begin{DoxyCompactList}\small\item\em Sets the current file to the first file in the archive. \end{DoxyCompactList}\item -bool {\bf goToNextFile} () -\begin{DoxyCompactList}\small\item\em Sets the current file to the next file in the archive. \end{DoxyCompactList}\item -bool {\bf setCurrentFile} (const QString \&fileName, {\bf CaseSensitivity} cs=csDefault) -\begin{DoxyCompactList}\small\item\em Sets current file by its name. \end{DoxyCompactList}\item -bool {\bf hasCurrentFile} () const \label{classQuaZip_a00b237d926648f45da86db25e7cfb697} - -\begin{DoxyCompactList}\small\item\em Returns {\ttfamily true} if the current file has been set. \end{DoxyCompactList}\item -bool {\bf getCurrentFileInfo} ({\bf QuaZipFileInfo} $\ast$info) const -\begin{DoxyCompactList}\small\item\em Retrieves information about the current file. \end{DoxyCompactList}\item -bool {\bf getCurrentFileInfo} ({\bf QuaZipFileInfo64} $\ast$info) const -\begin{DoxyCompactList}\small\item\em Retrieves information about the current file. \end{DoxyCompactList}\item -QString {\bf getCurrentFileName} () const -\begin{DoxyCompactList}\small\item\em Returns the current file name. \end{DoxyCompactList}\item -unzFile {\bf getUnzFile} () -\begin{DoxyCompactList}\small\item\em Returns {\ttfamily unzFile} handle. \end{DoxyCompactList}\item -zipFile {\bf getZipFile} () -\begin{DoxyCompactList}\small\item\em Returns {\ttfamily zipFile} handle. \end{DoxyCompactList}\item -void {\bf setDataDescriptorWritingEnabled} (bool enabled) -\begin{DoxyCompactList}\small\item\em Changes the data descriptor writing mode. \end{DoxyCompactList}\item -bool {\bf isDataDescriptorWritingEnabled} () const -\begin{DoxyCompactList}\small\item\em Returns the data descriptor default writing mode. \end{DoxyCompactList}\item -QStringList {\bf getFileNameList} () const -\begin{DoxyCompactList}\small\item\em Returns a list of files inside the archive. \end{DoxyCompactList}\item -QList$<$ {\bf QuaZipFileInfo} $>$ {\bf getFileInfoList} () const -\begin{DoxyCompactList}\small\item\em Returns information list about all files inside the archive. \end{DoxyCompactList}\item -QList$<$ {\bf QuaZipFileInfo64} $>$ {\bf getFileInfoList64} () const -\begin{DoxyCompactList}\small\item\em Returns information list about all files inside the archive. \end{DoxyCompactList}\item -void {\bf setZip64Enabled} (bool zip64) -\begin{DoxyCompactList}\small\item\em Enables the zip64 mode. \end{DoxyCompactList}\item -bool {\bf isZip64Enabled} () const -\begin{DoxyCompactList}\small\item\em Returns whether the zip64 mode is enabled. \end{DoxyCompactList}\item -bool {\bf isAutoClose} () const -\begin{DoxyCompactList}\small\item\em Returns the auto-\/close flag. \end{DoxyCompactList}\item -void {\bf setAutoClose} (bool autoClose) const -\begin{DoxyCompactList}\small\item\em Sets or unsets the auto-\/close flag. \end{DoxyCompactList}\end{DoxyCompactItemize} -\subsection*{Static Public Member Functions} -\begin{DoxyCompactItemize} -\item -static Qt::CaseSensitivity {\bf convertCaseSensitivity} ({\bf CaseSensitivity} cs) -\begin{DoxyCompactList}\small\item\em Returns the actual case sensitivity for the specified QuaZIP one. \end{DoxyCompactList}\item -static void {\bf setDefaultFileNameCodec} (QTextCodec $\ast$codec) -\begin{DoxyCompactList}\small\item\em Sets the default file name codec to use. \end{DoxyCompactList}\item -static void {\bf setDefaultFileNameCodec} (const char $\ast$codecName) -\end{DoxyCompactItemize} -\subsection*{Friends} -\begin{DoxyCompactItemize} -\item -class {\bf QuaZipPrivate}\label{classQuaZip_a5d400b33a69412e9d419a484aaf476cd} - -\end{DoxyCompactItemize} - - -\subsection{Detailed Description} -ZIP archive. - -This class implements basic interface to the ZIP archive. It can be used to read table contents of the ZIP archive and retreiving information about the files inside it. - -You can also use this class to open files inside archive by passing pointer to the instance of this class to the constructor of the \doxyref{QuaZipFile}{p.}{classQuaZipFile} class. But see \doxyref{QuaZipFile::QuaZipFile(QuaZip$\ast$, QObject$\ast$)}{p.}{classQuaZipFile_a54e944a6b3d27030f64c8f30d2cc33bb} for the possible pitfalls. - -This class is indended to provide interface to the ZIP subpackage of the ZIP/UNZIP package as well as to the UNZIP subpackage. But currently it supports only UNZIP. - -The use of this class is simple -\/ just create instance using constructor, then set ZIP archive file name using setFile() function (if you did not passed the name to the constructor), then \doxyref{open()}{p.}{classQuaZip_abfa4e6018b2964a3d10a4c54e5ab3962} and then use different functions to work with it! Well, if you are paranoid, you may also wish to call close before destructing the instance, to check for errors on close. - -You may also use \doxyref{getUnzFile()}{p.}{classQuaZip_a3b78a652f296ff4a678a791e8294e642} and \doxyref{getZipFile()}{p.}{classQuaZip_a425043a4d7cc31e2fe2bba73d954f15c} functions to get the ZIP archive handle and use it with ZIP/UNZIP package API directly. - -This class supports localized file names inside ZIP archive, but you have to set up proper codec with setCodec() function. By default, locale codec will be used, which is probably ok for UNIX systems, but will almost certainly fail with ZIP archives created in Windows. This is because Windows ZIP programs have strange habit of using DOS encoding for file names in ZIP archives. For example, ZIP archive with cyrillic names created in Windows will have file names in {\ttfamily IBM866} encoding instead of {\ttfamily WINDOWS-\/1251}. I think that calling one function is not much trouble, but for true platform independency it would be nice to have some mechanism for file name encoding auto detection using locale information. Does anyone know a good way to do it? - -\subsection{Member Enumeration Documentation} -\index{QuaZip@{QuaZip}!Constants@{Constants}} -\index{Constants@{Constants}!QuaZip@{QuaZip}} -\subsubsection[{Constants}]{\setlength{\rightskip}{0pt plus 5cm}enum {\bf QuaZip::Constants}}\label{classQuaZip_adce46b942c341dbb5c851eadead65459} - - -Useful constants. - -\begin{Desc} -\item[Enumerator: ]\par -\begin{description} -\index{MAX\_\-FILE\_\-NAME\_\-LENGTH@{MAX\_\-FILE\_\-NAME\_\-LENGTH}!QuaZip@{QuaZip}}\index{QuaZip@{QuaZip}!MAX\_\-FILE\_\-NAME\_\-LENGTH@{MAX\_\-FILE\_\-NAME\_\-LENGTH}}\item[{\em -MAX\_\-FILE\_\-NAME\_\-LENGTH\label{classQuaZip_adce46b942c341dbb5c851eadead65459ab26ce1a9c9e94f901dc2cf90fa5baa4b} -}]Maximum file name length. Taken from {\ttfamily UNZ\_\-MAXFILENAMEINZIP} constant in unzip.c. \end{description} -\end{Desc} - -\index{QuaZip@{QuaZip}!Mode@{Mode}} -\index{Mode@{Mode}!QuaZip@{QuaZip}} -\subsubsection[{Mode}]{\setlength{\rightskip}{0pt plus 5cm}enum {\bf QuaZip::Mode}}\label{classQuaZip_a47e28d4116ee716fdd6b431b821d0be4} - - -Open mode of the ZIP file. - -\begin{Desc} -\item[Enumerator: ]\par -\begin{description} -\index{mdNotOpen@{mdNotOpen}!QuaZip@{QuaZip}}\index{QuaZip@{QuaZip}!mdNotOpen@{mdNotOpen}}\item[{\em -mdNotOpen\label{classQuaZip_a47e28d4116ee716fdd6b431b821d0be4ac87ddb1e901e1ec700c16ee0d4d398ce} -}]ZIP file is not open. This is the initial mode. \index{mdUnzip@{mdUnzip}!QuaZip@{QuaZip}}\index{QuaZip@{QuaZip}!mdUnzip@{mdUnzip}}\item[{\em -mdUnzip\label{classQuaZip_a47e28d4116ee716fdd6b431b821d0be4a803a371910c2dc830d111e9ce5b58897} -}]ZIP file is open for reading files inside it. \index{mdCreate@{mdCreate}!QuaZip@{QuaZip}}\index{QuaZip@{QuaZip}!mdCreate@{mdCreate}}\item[{\em -mdCreate\label{classQuaZip_a47e28d4116ee716fdd6b431b821d0be4a25ae05b12590540af8c66ae8298b928e} -}]ZIP file was created with \doxyref{open()}{p.}{classQuaZip_abfa4e6018b2964a3d10a4c54e5ab3962} call. \index{mdAppend@{mdAppend}!QuaZip@{QuaZip}}\index{QuaZip@{QuaZip}!mdAppend@{mdAppend}}\item[{\em -mdAppend\label{classQuaZip_a47e28d4116ee716fdd6b431b821d0be4ab807f0c65653a16d77b365801fd25582} -}]ZIP file was opened in append mode. This refers to {\ttfamily APPEND\_\-STATUS\_\-CREATEAFTER} mode in ZIP/UNZIP package and means that zip is appended to some existing file what is useful when that file contains self-\/extractor code. This is obviously {\itshape not\/} what you whant to use to add files to the existing ZIP archive. \index{mdAdd@{mdAdd}!QuaZip@{QuaZip}}\index{QuaZip@{QuaZip}!mdAdd@{mdAdd}}\item[{\em -mdAdd\label{classQuaZip_a47e28d4116ee716fdd6b431b821d0be4a22c745f349f06add449af523254fdaec} -}]ZIP file was opened for adding files in the archive. \end{description} -\end{Desc} - -\index{QuaZip@{QuaZip}!CaseSensitivity@{CaseSensitivity}} -\index{CaseSensitivity@{CaseSensitivity}!QuaZip@{QuaZip}} -\subsubsection[{CaseSensitivity}]{\setlength{\rightskip}{0pt plus 5cm}enum {\bf QuaZip::CaseSensitivity}}\label{classQuaZip_a6053a1d249ed210a85c9d5eb7cf9cdbe} - - -Case sensitivity for the file names. - -This is what you specify when accessing files in the archive. Works perfectly fine with any characters thanks to Qt's great unicode support. This is different from ZIP/UNZIP API, where only US-\/ASCII characters was supported. \begin{Desc} -\item[Enumerator: ]\par -\begin{description} -\index{csDefault@{csDefault}!QuaZip@{QuaZip}}\index{QuaZip@{QuaZip}!csDefault@{csDefault}}\item[{\em -csDefault\label{classQuaZip_a6053a1d249ed210a85c9d5eb7cf9cdbeac3cca8c0b976cf6397a28a5c84e75253} -}]Default for platform. Case sensitive for UNIX, not for Windows. \index{csSensitive@{csSensitive}!QuaZip@{QuaZip}}\index{QuaZip@{QuaZip}!csSensitive@{csSensitive}}\item[{\em -csSensitive\label{classQuaZip_a6053a1d249ed210a85c9d5eb7cf9cdbead8d86b0c34203336cad09348cfa5356e} -}]Case sensitive. \index{csInsensitive@{csInsensitive}!QuaZip@{QuaZip}}\index{QuaZip@{QuaZip}!csInsensitive@{csInsensitive}}\item[{\em -csInsensitive\label{classQuaZip_a6053a1d249ed210a85c9d5eb7cf9cdbea3e492bcc3f64f41a74906cecc45fb366} -}]Case insensitive. \end{description} -\end{Desc} - - - -\subsection{Constructor \& Destructor Documentation} -\index{QuaZip@{QuaZip}!QuaZip@{QuaZip}} -\index{QuaZip@{QuaZip}!QuaZip@{QuaZip}} -\subsubsection[{QuaZip}]{\setlength{\rightskip}{0pt plus 5cm}QuaZip::QuaZip ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -)}\label{classQuaZip_a970e0f401c7cfd7a78e78572f758eec4} - - -Constructs \doxyref{QuaZip}{p.}{classQuaZip} object. - -Call setName() before opening constructed object. \index{QuaZip@{QuaZip}!QuaZip@{QuaZip}} -\index{QuaZip@{QuaZip}!QuaZip@{QuaZip}} -\subsubsection[{QuaZip}]{\setlength{\rightskip}{0pt plus 5cm}QuaZip::QuaZip ( -\begin{DoxyParamCaption} -\item[{QIODevice $\ast$}]{ioDevice} -\end{DoxyParamCaption} -)}\label{classQuaZip_ae52ebadd5ce64cdb49d7e198904b0b8c} - - -Constructs \doxyref{QuaZip}{p.}{classQuaZip} object associated with ZIP file represented by {\itshape ioDevice\/}. - -The IO device must be seekable, otherwise an error will occur when opening. \index{QuaZip@{QuaZip}!$\sim$QuaZip@{$\sim$QuaZip}} -\index{$\sim$QuaZip@{$\sim$QuaZip}!QuaZip@{QuaZip}} -\subsubsection[{$\sim$QuaZip}]{\setlength{\rightskip}{0pt plus 5cm}QuaZip::$\sim$QuaZip ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -)}\label{classQuaZip_af60a2d3930b90f3b25a3148baecad81e} - - -Destroys \doxyref{QuaZip}{p.}{classQuaZip} object. - -Calls \doxyref{close()}{p.}{classQuaZip_a7a4323b73e12f3b4470109f200728f9f} if necessary. - -References close(), and isOpen(). - - - -\subsection{Member Function Documentation} -\index{QuaZip@{QuaZip}!convertCaseSensitivity@{convertCaseSensitivity}} -\index{convertCaseSensitivity@{convertCaseSensitivity}!QuaZip@{QuaZip}} -\subsubsection[{convertCaseSensitivity}]{\setlength{\rightskip}{0pt plus 5cm}Qt::CaseSensitivity QuaZip::convertCaseSensitivity ( -\begin{DoxyParamCaption} -\item[{{\bf QuaZip::CaseSensitivity}}]{cs} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [static]}}\label{classQuaZip_a1d3fbd445a8e9d3449ded7371931c6b3} - - -Returns the actual case sensitivity for the specified QuaZIP one. - - -\begin{DoxyParams}{Parameters} -{\em cs} & The value to convert. \\ -\hline -\end{DoxyParams} -\begin{DoxyReturn}{Returns} -If CaseSensitivity::csDefault, then returns the default file name case sensitivity for the platform. Otherwise, just returns the appropriate value from the Qt::CaseSensitivity enum. -\end{DoxyReturn} - - -References csDefault, and csSensitive. - - - -Referenced by QuaZipDir::exists(), and setCurrentFile(). - -\index{QuaZip@{QuaZip}!open@{open}} -\index{open@{open}!QuaZip@{QuaZip}} -\subsubsection[{open}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZip::open ( -\begin{DoxyParamCaption} -\item[{{\bf Mode}}]{mode, } -\item[{zlib\_\-filefunc\_\-def $\ast$}]{ioApi = {\ttfamily NULL}} -\end{DoxyParamCaption} -)}\label{classQuaZip_abfa4e6018b2964a3d10a4c54e5ab3962} - - -Opens ZIP file. - -Argument {\itshape mode\/} specifies open mode of the ZIP archive. See Mode for details. Note that there is zipOpen2() function in the ZIP/UNZIP API which accepts {\itshape globalcomment\/} argument, but it does not use it anywhere, so this \doxyref{open()}{p.}{classQuaZip_abfa4e6018b2964a3d10a4c54e5ab3962} function does not have this argument. See \doxyref{setComment()}{p.}{classQuaZip_a1b5d936a203859340574d5908ffa2222} if you need to set global comment. - -If the ZIP file is accessed via explicitly set QIODevice, then this device is opened in the necessary mode. If the device was already opened by some other means, then QuaZIP checks if the open mode is compatible to the mode needed for the requested operation. If necessary, seeking is performed to position the device properly. - -\begin{DoxyReturn}{Returns} -{\ttfamily true} if successful, {\ttfamily false} otherwise. -\end{DoxyReturn} -\begin{DoxyNote}{Note} -ZIP/UNZIP API open calls do not return error code -\/ they just return {\ttfamily NULL} indicating an error. But to make things easier, \doxyref{quazip.h}{p.}{quazip_8h_source} header defines additional error code {\ttfamily UNZ\_\-ERROROPEN} and \doxyref{getZipError()}{p.}{classQuaZip_a28b91a6282ddd9382c96a069572c6fb4} will return it if the open call of the ZIP/UNZIP API returns {\ttfamily NULL}. -\end{DoxyNote} -Argument {\itshape ioApi\/} specifies IO function set for ZIP/UNZIP package to use. See unzip.h, zip.h and ioapi.h for details. Note that IO API for \doxyref{QuaZip}{p.}{classQuaZip} is different from the original package. The file path argument was changed to be of type {\ttfamily voidpf}, and \doxyref{QuaZip}{p.}{classQuaZip} passes a QIODevice pointer there. This QIODevice is either set explicitly via \doxyref{setIoDevice()}{p.}{classQuaZip_a64642948b6531ee54f5522f29e388cc6} or the \doxyref{QuaZip(QIODevice$\ast$)}{p.}{classQuaZip_ae52ebadd5ce64cdb49d7e198904b0b8c} constructor, or it is created internally when opening the archive by its file name. The default API (qioapi.cpp) just delegates everything to the QIODevice API. Not only this allows to use a QIODevice instead of file name, but also has a nice side effect of raising the file size limit from 2G to 4G (in non-\/zip64 archives). - -\begin{DoxyNote}{Note} -If the zip64 support is needed, the ioApi argument {\itshape must\/} be NULL because due to the backwards compatibility issues it can be used to provide a 32-\/bit API only. -\end{DoxyNote} -In short: just forget about the {\itshape ioApi\/} argument and you'll be fine. - -References isOpen(), mdAdd, mdAppend, mdCreate, mdUnzip, QuaZipPrivate::unzFile\_\-f, and QuaZipPrivate::zipFile\_\-f. - - - -Referenced by JlCompress::compressDir(), JlCompress::compressFile(), JlCompress::compressFiles(), JlCompress::extractDir(), JlCompress::extractFile(), JlCompress::extractFiles(), JlCompress::getFileList(), and QuaZipFile::open(). - -\index{QuaZip@{QuaZip}!close@{close}} -\index{close@{close}!QuaZip@{QuaZip}} -\subsubsection[{close}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZip::close ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -)}\label{classQuaZip_a7a4323b73e12f3b4470109f200728f9f} - - -Closes ZIP file. - -Call \doxyref{getZipError()}{p.}{classQuaZip_a28b91a6282ddd9382c96a069572c6fb4} to determine if the close was successful. - -If the file was opened by name, then the underlying QIODevice is closed and deleted. - -If the underlying QIODevice was set explicitly using \doxyref{setIoDevice()}{p.}{classQuaZip_a64642948b6531ee54f5522f29e388cc6} or the appropriate constructor, then it is closed if the auto-\/close flag is set (which it is by default). Call \doxyref{setAutoClose()}{p.}{classQuaZip_a54bfc924762774ccf9f99be075ba7b0e} to clear the auto-\/close flag if this behavior is undesirable. - -Since Qt 5.1, the QSaveFile was introduced. It breaks the QIODevice API by making \doxyref{close()}{p.}{classQuaZip_a7a4323b73e12f3b4470109f200728f9f} private and crashing the application if it is called from the base class where it is public. It is an excellent example of poor design that illustrates why you should never ever break an is-\/a relationship between the base class and a subclass. QuaZIP works around this bug by checking if the QIODevice is an instance of QSaveFile, using qobject\_\-cast$<$$>$, and if it is, calls QSaveFile::commit() instead of \doxyref{close()}{p.}{classQuaZip_a7a4323b73e12f3b4470109f200728f9f}. It is a really ugly hack, but at least it makes your programs work instead of crashing. Note that if the auto-\/close flag is cleared, then this is a non-\/issue, and commit() isn't called. - -References mdAdd, mdAppend, mdCreate, mdNotOpen, mdUnzip, QuaZipPrivate::unzFile\_\-f, and QuaZipPrivate::zipFile\_\-f. - - - -Referenced by QuaZipFile::close(), JlCompress::compressDir(), JlCompress::compressFile(), JlCompress::compressFiles(), JlCompress::extractDir(), JlCompress::extractFile(), JlCompress::extractFiles(), JlCompress::getFileList(), QuaZipFile::open(), and $\sim$QuaZip(). - -\index{QuaZip@{QuaZip}!setFileNameCodec@{setFileNameCodec}} -\index{setFileNameCodec@{setFileNameCodec}!QuaZip@{QuaZip}} -\subsubsection[{setFileNameCodec}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZip::setFileNameCodec ( -\begin{DoxyParamCaption} -\item[{QTextCodec $\ast$}]{fileNameCodec} -\end{DoxyParamCaption} -)}\label{classQuaZip_a339010b5566704ba3c9cafbfe848d8fb} - - -Sets the codec used to encode/decode file names inside archive. - -This is necessary to access files in the ZIP archive created under Windows with non-\/latin characters in file names. For example, file names with cyrillic letters will be in {\ttfamily IBM866} encoding. \index{QuaZip@{QuaZip}!setFileNameCodec@{setFileNameCodec}} -\index{setFileNameCodec@{setFileNameCodec}!QuaZip@{QuaZip}} -\subsubsection[{setFileNameCodec}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZip::setFileNameCodec ( -\begin{DoxyParamCaption} -\item[{const char $\ast$}]{fileNameCodecName} -\end{DoxyParamCaption} -)}\label{classQuaZip_a8f283519a195aa1d9076bbbb01ea0497} - - -Sets the codec used to encode/decode file names inside archive. - -This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. Equivalent to calling setFileNameCodec(QTextCodec::codecForName(codecName)); \index{QuaZip@{QuaZip}!setCommentCodec@{setCommentCodec}} -\index{setCommentCodec@{setCommentCodec}!QuaZip@{QuaZip}} -\subsubsection[{setCommentCodec}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZip::setCommentCodec ( -\begin{DoxyParamCaption} -\item[{QTextCodec $\ast$}]{commentCodec} -\end{DoxyParamCaption} -)}\label{classQuaZip_a1c81fca7215a4374f6f03872ade4885b} - - -Sets the codec used to encode/decode comments inside archive. - -This codec defaults to locale codec, which is probably ok. \index{QuaZip@{QuaZip}!setCommentCodec@{setCommentCodec}} -\index{setCommentCodec@{setCommentCodec}!QuaZip@{QuaZip}} -\subsubsection[{setCommentCodec}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZip::setCommentCodec ( -\begin{DoxyParamCaption} -\item[{const char $\ast$}]{commentCodecName} -\end{DoxyParamCaption} -)}\label{classQuaZip_a413f3c56b54a9a47258d53802cb606e7} - - -Sets the codec used to encode/decode comments inside archive. - -This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. Equivalent to calling setCommentCodec(QTextCodec::codecForName(codecName)); \index{QuaZip@{QuaZip}!getZipName@{getZipName}} -\index{getZipName@{getZipName}!QuaZip@{QuaZip}} -\subsubsection[{getZipName}]{\setlength{\rightskip}{0pt plus 5cm}QString QuaZip::getZipName ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{classQuaZip_a4f7deef08ff40aeb1a7a04bcd7f228c2} - - -Returns the name of the ZIP file. - -Returns null string if no ZIP file name has been set, for example when the \doxyref{QuaZip}{p.}{classQuaZip} instance is set up to use a QIODevice instead. \begin{DoxySeeAlso}{See also} -\doxyref{setZipName()}{p.}{classQuaZip_aa80b661de1262af905d1677dbcb008cc}, \doxyref{setIoDevice()}{p.}{classQuaZip_a64642948b6531ee54f5522f29e388cc6}, \doxyref{getIoDevice()}{p.}{classQuaZip_afd3ba12fe68748acbf8b7cc14a5a1c29} -\end{DoxySeeAlso} - - -Referenced by QuaZipFile::getZipName(). - -\index{QuaZip@{QuaZip}!setZipName@{setZipName}} -\index{setZipName@{setZipName}!QuaZip@{QuaZip}} -\subsubsection[{setZipName}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZip::setZipName ( -\begin{DoxyParamCaption} -\item[{const QString \&}]{zipName} -\end{DoxyParamCaption} -)}\label{classQuaZip_aa80b661de1262af905d1677dbcb008cc} - - -Sets the name of the ZIP file. - -Does nothing if the ZIP file is open. - -Does not reset error code returned by \doxyref{getZipError()}{p.}{classQuaZip_a28b91a6282ddd9382c96a069572c6fb4}. \begin{DoxySeeAlso}{See also} -\doxyref{setIoDevice()}{p.}{classQuaZip_a64642948b6531ee54f5522f29e388cc6}, \doxyref{getIoDevice()}{p.}{classQuaZip_afd3ba12fe68748acbf8b7cc14a5a1c29}, \doxyref{getZipName()}{p.}{classQuaZip_a4f7deef08ff40aeb1a7a04bcd7f228c2} -\end{DoxySeeAlso} - - -References isOpen(). - -\index{QuaZip@{QuaZip}!getIoDevice@{getIoDevice}} -\index{getIoDevice@{getIoDevice}!QuaZip@{QuaZip}} -\subsubsection[{getIoDevice}]{\setlength{\rightskip}{0pt plus 5cm}QIODevice $\ast$ QuaZip::getIoDevice ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{classQuaZip_afd3ba12fe68748acbf8b7cc14a5a1c29} - - -Returns the device representing this ZIP file. - -Returns null string if no device has been set explicitly, for example when opening a ZIP file by name. \begin{DoxySeeAlso}{See also} -\doxyref{setIoDevice()}{p.}{classQuaZip_a64642948b6531ee54f5522f29e388cc6}, \doxyref{getZipName()}{p.}{classQuaZip_a4f7deef08ff40aeb1a7a04bcd7f228c2}, \doxyref{setZipName()}{p.}{classQuaZip_aa80b661de1262af905d1677dbcb008cc} -\end{DoxySeeAlso} -\index{QuaZip@{QuaZip}!setIoDevice@{setIoDevice}} -\index{setIoDevice@{setIoDevice}!QuaZip@{QuaZip}} -\subsubsection[{setIoDevice}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZip::setIoDevice ( -\begin{DoxyParamCaption} -\item[{QIODevice $\ast$}]{ioDevice} -\end{DoxyParamCaption} -)}\label{classQuaZip_a64642948b6531ee54f5522f29e388cc6} - - -Sets the device representing the ZIP file. - -Does nothing if the ZIP file is open. - -Does not reset error code returned by \doxyref{getZipError()}{p.}{classQuaZip_a28b91a6282ddd9382c96a069572c6fb4}. \begin{DoxySeeAlso}{See also} -\doxyref{getIoDevice()}{p.}{classQuaZip_afd3ba12fe68748acbf8b7cc14a5a1c29}, \doxyref{getZipName()}{p.}{classQuaZip_a4f7deef08ff40aeb1a7a04bcd7f228c2}, \doxyref{setZipName()}{p.}{classQuaZip_aa80b661de1262af905d1677dbcb008cc} -\end{DoxySeeAlso} - - -References isOpen(). - -\index{QuaZip@{QuaZip}!getZipError@{getZipError}} -\index{getZipError@{getZipError}!QuaZip@{QuaZip}} -\subsubsection[{getZipError}]{\setlength{\rightskip}{0pt plus 5cm}int QuaZip::getZipError ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{classQuaZip_a28b91a6282ddd9382c96a069572c6fb4} - - -Returns the error code of the last operation. - -Returns {\ttfamily UNZ\_\-OK} if the last operation was successful. - -Error code resets to {\ttfamily UNZ\_\-OK} every time you call any function that accesses something inside ZIP archive, even if it is {\ttfamily const} (like \doxyref{getEntriesCount()}{p.}{classQuaZip_a2ea4bd1fca948637c35c2d2752bb5a80}). \doxyref{open()}{p.}{classQuaZip_abfa4e6018b2964a3d10a4c54e5ab3962} and \doxyref{close()}{p.}{classQuaZip_a7a4323b73e12f3b4470109f200728f9f} calls reset error code too. See documentation for the specific functions for details on error detection. - -Referenced by QuaZipFile::close(), JlCompress::compressDir(), JlCompress::compressFile(), JlCompress::compressFiles(), JlCompress::extractDir(), JlCompress::extractFile(), JlCompress::extractFiles(), QuaZipFile::getActualFileName(), QuaZipFile::getFileInfo(), JlCompress::getFileList(), and QuaZipFile::open(). - -\index{QuaZip@{QuaZip}!getEntriesCount@{getEntriesCount}} -\index{getEntriesCount@{getEntriesCount}!QuaZip@{QuaZip}} -\subsubsection[{getEntriesCount}]{\setlength{\rightskip}{0pt plus 5cm}int QuaZip::getEntriesCount ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{classQuaZip_a2ea4bd1fca948637c35c2d2752bb5a80} - - -Returns number of the entries in the ZIP central directory. - -Returns negative error code in the case of error. The same error code will be returned by subsequent \doxyref{getZipError()}{p.}{classQuaZip_a28b91a6282ddd9382c96a069572c6fb4} call. - -References mdUnzip, and QuaZipPrivate::unzFile\_\-f. - -\index{QuaZip@{QuaZip}!setComment@{setComment}} -\index{setComment@{setComment}!QuaZip@{QuaZip}} -\subsubsection[{setComment}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZip::setComment ( -\begin{DoxyParamCaption} -\item[{const QString \&}]{comment} -\end{DoxyParamCaption} -)}\label{classQuaZip_a1b5d936a203859340574d5908ffa2222} - - -Sets the global comment in the ZIP file. - -The comment will be written to the archive on close operation. \doxyref{QuaZip}{p.}{classQuaZip} makes a distinction between a null QByteArray() comment and an empty "" comment in the \doxyref{QuaZip::mdAdd}{p.}{classQuaZip_a47e28d4116ee716fdd6b431b821d0be4a22c745f349f06add449af523254fdaec} mode. A null comment is the default and it means "don't change the comment". An empty comment removes the original comment. - -\begin{DoxySeeAlso}{See also} -\doxyref{open()}{p.}{classQuaZip_abfa4e6018b2964a3d10a4c54e5ab3962} -\end{DoxySeeAlso} -\index{QuaZip@{QuaZip}!goToFirstFile@{goToFirstFile}} -\index{goToFirstFile@{goToFirstFile}!QuaZip@{QuaZip}} -\subsubsection[{goToFirstFile}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZip::goToFirstFile ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -)}\label{classQuaZip_a745488f9177bcec3cdb858587584e033} - - -Sets the current file to the first file in the archive. - -Returns {\ttfamily true} on success, {\ttfamily false} otherwise. Call \doxyref{getZipError()}{p.}{classQuaZip_a28b91a6282ddd9382c96a069572c6fb4} to get the error code. - -References mdUnzip, and QuaZipPrivate::unzFile\_\-f. - - - -Referenced by JlCompress::extractDir(), and JlCompress::getFileList(). - -\index{QuaZip@{QuaZip}!goToNextFile@{goToNextFile}} -\index{goToNextFile@{goToNextFile}!QuaZip@{QuaZip}} -\subsubsection[{goToNextFile}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZip::goToNextFile ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -)}\label{classQuaZip_aee6779b6cd338420c2e8c5655fa8ba97} - - -Sets the current file to the next file in the archive. - -Returns {\ttfamily true} on success, {\ttfamily false} otherwise. Call \doxyref{getZipError()}{p.}{classQuaZip_a28b91a6282ddd9382c96a069572c6fb4} to determine if there was an error. - -Should be used only in \doxyref{QuaZip::mdUnzip}{p.}{classQuaZip_a47e28d4116ee716fdd6b431b821d0be4a803a371910c2dc830d111e9ce5b58897} mode. - -\begin{DoxyNote}{Note} -If the end of file was reached, \doxyref{getZipError()}{p.}{classQuaZip_a28b91a6282ddd9382c96a069572c6fb4} will return {\ttfamily UNZ\_\-OK} instead of {\ttfamily UNZ\_\-END\_\-OF\_\-LIST\_\-OF\_\-FILE}. This is to make things like this easier: -\begin{DoxyCode} - for(bool more=zip.goToFirstFile(); more; more=zip.goToNextFile()) { - // do something - } - if(zip.getZipError()==UNZ_OK) { - // ok, there was no error - } -\end{DoxyCode} - -\end{DoxyNote} - - -References mdUnzip, and QuaZipPrivate::unzFile\_\-f. - - - -Referenced by JlCompress::extractDir(), JlCompress::getFileList(), and setCurrentFile(). - -\index{QuaZip@{QuaZip}!setCurrentFile@{setCurrentFile}} -\index{setCurrentFile@{setCurrentFile}!QuaZip@{QuaZip}} -\subsubsection[{setCurrentFile}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZip::setCurrentFile ( -\begin{DoxyParamCaption} -\item[{const QString \&}]{fileName, } -\item[{{\bf CaseSensitivity}}]{cs = {\ttfamily csDefault}} -\end{DoxyParamCaption} -)}\label{classQuaZip_a6c657bfcfccb59d728e0da24c677d899} - - -Sets current file by its name. - -Returns {\ttfamily true} if successful, {\ttfamily false} otherwise. Argument {\itshape cs\/} specifies case sensitivity of the file name. Call \doxyref{getZipError()}{p.}{classQuaZip_a28b91a6282ddd9382c96a069572c6fb4} in the case of a failure to get error code. - -This is not a wrapper to unzLocateFile() function. That is because I had to implement locale-\/specific case-\/insensitive comparison. - -Here are the differences from the original implementation: - - -\begin{DoxyItemize} -\item If the file was not found, error code is {\ttfamily UNZ\_\-OK}, not {\ttfamily UNZ\_\-END\_\-OF\_\-LIST\_\-OF\_\-FILE} (see also \doxyref{goToNextFile()}{p.}{classQuaZip_aee6779b6cd338420c2e8c5655fa8ba97}). -\item If this function fails, it unsets the current file rather than resetting it back to what it was before the call. -\end{DoxyItemize} - -If {\itshape fileName\/} is null string then this function unsets the current file and return {\ttfamily true}. Note that you should close the file first if it is open! See \doxyref{QuaZipFile::QuaZipFile(QuaZip$\ast$,QObject$\ast$)}{p.}{classQuaZipFile_a54e944a6b3d27030f64c8f30d2cc33bb} for the details. - -Should be used only in \doxyref{QuaZip::mdUnzip}{p.}{classQuaZip_a47e28d4116ee716fdd6b431b821d0be4a803a371910c2dc830d111e9ce5b58897} mode. - -\begin{DoxySeeAlso}{See also} -\doxyref{setFileNameCodec()}{p.}{classQuaZip_a339010b5566704ba3c9cafbfe848d8fb}, \doxyref{CaseSensitivity}{p.}{classQuaZip_a6053a1d249ed210a85c9d5eb7cf9cdbe} -\end{DoxySeeAlso} - - -References convertCaseSensitivity(), getCurrentFileName(), goToNextFile(), MAX\_\-FILE\_\-NAME\_\-LENGTH, mdUnzip, and QuaZipPrivate::unzFile\_\-f. - - - -Referenced by QuaZipFile::open(). - -\index{QuaZip@{QuaZip}!getCurrentFileInfo@{getCurrentFileInfo}} -\index{getCurrentFileInfo@{getCurrentFileInfo}!QuaZip@{QuaZip}} -\subsubsection[{getCurrentFileInfo}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZip::getCurrentFileInfo ( -\begin{DoxyParamCaption} -\item[{{\bf QuaZipFileInfo} $\ast$}]{info} -\end{DoxyParamCaption} -) const}\label{classQuaZip_a9c91a53ed4c2038e153c64bdc097ebe8} - - -Retrieves information about the current file. - -Fills the structure pointed by {\itshape info\/}. Returns {\ttfamily true} on success, {\ttfamily false} otherwise. In the latter case structure pointed by {\itshape info\/} remains untouched. If there was an error, \doxyref{getZipError()}{p.}{classQuaZip_a28b91a6282ddd9382c96a069572c6fb4} returns error code. - -Should be used only in \doxyref{QuaZip::mdUnzip}{p.}{classQuaZip_a47e28d4116ee716fdd6b431b821d0be4a803a371910c2dc830d111e9ce5b58897} mode. - -Does nothing and returns {\ttfamily false} in any of the following cases. -\begin{DoxyItemize} -\item ZIP is not open; -\item ZIP does not have current file. -\end{DoxyItemize} - -In both cases \doxyref{getZipError()}{p.}{classQuaZip_a28b91a6282ddd9382c96a069572c6fb4} returns {\ttfamily UNZ\_\-OK} since there is no ZIP/UNZIP API call. - -This overload doesn't support zip64, but will work OK on zip64 archives except that if one of the sizes (compressed or uncompressed) is greater than 0xFFFFFFFFu, it will be set to exactly 0xFFFFFFFFu. - -\begin{DoxySeeAlso}{See also} -\doxyref{getCurrentFileInfo(QuaZipFileInfo64$\ast$ info)const}{p.}{classQuaZip_a7ba6daf39263c308c683e7f72f74e0ae} - -\doxyref{QuaZipFileInfo64::toQuaZipFileInfo(QuaZipFileInfo\&)const}{p.}{structQuaZipFileInfo64_ada29945c7ee4c9df6fbe95864793aade} -\end{DoxySeeAlso} - - -References QuaZipFileInfo64::toQuaZipFileInfo(). - - - -Referenced by QuaZipFile::getFileInfo(), and JlCompress::getFileList(). - -\index{QuaZip@{QuaZip}!getCurrentFileInfo@{getCurrentFileInfo}} -\index{getCurrentFileInfo@{getCurrentFileInfo}!QuaZip@{QuaZip}} -\subsubsection[{getCurrentFileInfo}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZip::getCurrentFileInfo ( -\begin{DoxyParamCaption} -\item[{{\bf QuaZipFileInfo64} $\ast$}]{info} -\end{DoxyParamCaption} -) const}\label{classQuaZip_a7ba6daf39263c308c683e7f72f74e0ae} - - -Retrieves information about the current file. - -This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. This function supports zip64. If the archive doesn't use zip64, it is completely equivalent to getCurrentFileInfo(QuaZipFileInfo$\ast$ info) except for the argument type. - -\begin{DoxySeeAlso}{See also} - -\end{DoxySeeAlso} - - -References QuaZipFileInfo64::comment, QuaZipFileInfo64::compressedSize, QuaZipFileInfo64::crc, QuaZipFileInfo64::dateTime, QuaZipFileInfo64::diskNumberStart, QuaZipFileInfo64::externalAttr, QuaZipFileInfo64::extra, QuaZipFileInfo64::flags, hasCurrentFile(), QuaZipFileInfo64::internalAttr, isOpen(), mdUnzip, QuaZipFileInfo64::method, QuaZipFileInfo64::name, QuaZipFileInfo64::uncompressedSize, QuaZipPrivate::unzFile\_\-f, QuaZipFileInfo64::versionCreated, and QuaZipFileInfo64::versionNeeded. - -\index{QuaZip@{QuaZip}!getCurrentFileName@{getCurrentFileName}} -\index{getCurrentFileName@{getCurrentFileName}!QuaZip@{QuaZip}} -\subsubsection[{getCurrentFileName}]{\setlength{\rightskip}{0pt plus 5cm}QString QuaZip::getCurrentFileName ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{classQuaZip_a9783f8b4f39cd55e71e975aea78fd54a} - - -Returns the current file name. - -Equivalent to calling \doxyref{getCurrentFileInfo()}{p.}{classQuaZip_a9c91a53ed4c2038e153c64bdc097ebe8} and then getting {\ttfamily name} field of the \doxyref{QuaZipFileInfo}{p.}{structQuaZipFileInfo} structure, but faster and more convenient. - -Should be used only in \doxyref{QuaZip::mdUnzip}{p.}{classQuaZip_a47e28d4116ee716fdd6b431b821d0be4a803a371910c2dc830d111e9ce5b58897} mode. - -References hasCurrentFile(), isOpen(), MAX\_\-FILE\_\-NAME\_\-LENGTH, mdUnzip, and QuaZipPrivate::unzFile\_\-f. - - - -Referenced by JlCompress::extractDir(), QuaZipFile::getActualFileName(), and setCurrentFile(). - -\index{QuaZip@{QuaZip}!getUnzFile@{getUnzFile}} -\index{getUnzFile@{getUnzFile}!QuaZip@{QuaZip}} -\subsubsection[{getUnzFile}]{\setlength{\rightskip}{0pt plus 5cm}unzFile QuaZip::getUnzFile ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -)}\label{classQuaZip_a3b78a652f296ff4a678a791e8294e642} - - -Returns {\ttfamily unzFile} handle. - -You can use this handle to directly call UNZIP part of the ZIP/UNZIP package functions (see unzip.h). - -\begin{DoxyWarning}{Warning} -When using the handle returned by this function, please keep in mind that \doxyref{QuaZip}{p.}{classQuaZip} class is unable to detect any changes you make in the ZIP file state (e. g. changing current file, or closing the handle). So please do not do anything with this handle that is possible to do with the functions of this class. Or at least return the handle in the original state before calling some another function of this class (including implicit destructor calls and calls from the \doxyref{QuaZipFile}{p.}{classQuaZipFile} objects that refer to this \doxyref{QuaZip}{p.}{classQuaZip} instance!). So if you have changed the current file in the ZIP archive -\/ then change it back or you may experience some strange behavior or even crashes. -\end{DoxyWarning} - - -References QuaZipPrivate::unzFile\_\-f. - - - -Referenced by QuaZipFile::atEnd(), QuaZipFile::close(), QuaZipFile::csize(), QuaZipFile::open(), QuaZipFile::pos(), QuaZipFile::readData(), and QuaZipFile::usize(). - -\index{QuaZip@{QuaZip}!getZipFile@{getZipFile}} -\index{getZipFile@{getZipFile}!QuaZip@{QuaZip}} -\subsubsection[{getZipFile}]{\setlength{\rightskip}{0pt plus 5cm}zipFile QuaZip::getZipFile ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -)}\label{classQuaZip_a425043a4d7cc31e2fe2bba73d954f15c} - - -Returns {\ttfamily zipFile} handle. - -You can use this handle to directly call ZIP part of the ZIP/UNZIP package functions (see zip.h). Warnings about the \doxyref{getUnzFile()}{p.}{classQuaZip_a3b78a652f296ff4a678a791e8294e642} function also apply to this function. - -References QuaZipPrivate::zipFile\_\-f. - - - -Referenced by QuaZipFile::close(), QuaZipFile::open(), and QuaZipFile::writeData(). - -\index{QuaZip@{QuaZip}!setDataDescriptorWritingEnabled@{setDataDescriptorWritingEnabled}} -\index{setDataDescriptorWritingEnabled@{setDataDescriptorWritingEnabled}!QuaZip@{QuaZip}} -\subsubsection[{setDataDescriptorWritingEnabled}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZip::setDataDescriptorWritingEnabled ( -\begin{DoxyParamCaption} -\item[{bool}]{enabled} -\end{DoxyParamCaption} -)}\label{classQuaZip_a6c23a12af88f7ea5edd4f9c0a24b9453} - - -Changes the data descriptor writing mode. - -According to the ZIP format specification, a file inside archive may have a data descriptor immediately following the file data. This is reflected by a special flag in the local file header and in the central directory. By default, QuaZIP sets this flag and writes the data descriptor unless both method and level were set to 0, in which case it operates in 1.0-\/compatible mode and never writes data descriptors. - -By setting this flag to false, it is possible to disable data descriptor writing, thus increasing compatibility with archive readers that don't understand this feature of the ZIP file format. - -Setting this flag affects all the \doxyref{QuaZipFile}{p.}{classQuaZipFile} instances that are opened after this flag is set. - -The data descriptor writing mode is enabled by default. - - -\begin{DoxyParams}{Parameters} -{\em enabled} & If {\ttfamily true}, enable local descriptor writing, disable it otherwise.\\ -\hline -\end{DoxyParams} -\begin{DoxySeeAlso}{See also} -QuaZipFile::setDataDescriptorWritingEnabled() -\end{DoxySeeAlso} -\index{QuaZip@{QuaZip}!isDataDescriptorWritingEnabled@{isDataDescriptorWritingEnabled}} -\index{isDataDescriptorWritingEnabled@{isDataDescriptorWritingEnabled}!QuaZip@{QuaZip}} -\subsubsection[{isDataDescriptorWritingEnabled}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZip::isDataDescriptorWritingEnabled ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{classQuaZip_ae5c665a59447c2d30e63e9c6df48ebb7} - - -Returns the data descriptor default writing mode. - -\begin{DoxySeeAlso}{See also} -\doxyref{setDataDescriptorWritingEnabled()}{p.}{classQuaZip_a6c23a12af88f7ea5edd4f9c0a24b9453} -\end{DoxySeeAlso} - - -Referenced by QuaZipFile::open(). - -\index{QuaZip@{QuaZip}!getFileNameList@{getFileNameList}} -\index{getFileNameList@{getFileNameList}!QuaZip@{QuaZip}} -\subsubsection[{getFileNameList}]{\setlength{\rightskip}{0pt plus 5cm}QStringList QuaZip::getFileNameList ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{classQuaZip_abb38d8b4c9c4ae0728b48caae9dd82de} - - -Returns a list of files inside the archive. - -\begin{DoxyReturn}{Returns} -A list of file names or an empty list if there was an error or if the archive is empty (call \doxyref{getZipError()}{p.}{classQuaZip_a28b91a6282ddd9382c96a069572c6fb4} to figure out which). -\end{DoxyReturn} -\begin{DoxySeeAlso}{See also} -\doxyref{getFileInfoList()}{p.}{classQuaZip_a7486af66bede8e131db0cd2e81881387} -\end{DoxySeeAlso} -\index{QuaZip@{QuaZip}!getFileInfoList@{getFileInfoList}} -\index{getFileInfoList@{getFileInfoList}!QuaZip@{QuaZip}} -\subsubsection[{getFileInfoList}]{\setlength{\rightskip}{0pt plus 5cm}QList$<$ {\bf QuaZipFileInfo} $>$ QuaZip::getFileInfoList ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{classQuaZip_a7486af66bede8e131db0cd2e81881387} - - -Returns information list about all files inside the archive. - -\begin{DoxyReturn}{Returns} -A list of \doxyref{QuaZipFileInfo}{p.}{structQuaZipFileInfo} objects or an empty list if there was an error or if the archive is empty (call \doxyref{getZipError()}{p.}{classQuaZip_a28b91a6282ddd9382c96a069572c6fb4} to figure out which). -\end{DoxyReturn} -This function doesn't support zip64, but will still work with zip64 archives, converting results using \doxyref{QuaZipFileInfo64::toQuaZipFileInfo()}{p.}{structQuaZipFileInfo64_ada29945c7ee4c9df6fbe95864793aade}. If all file sizes are below 4 GB, it will work just fine. - -\begin{DoxySeeAlso}{See also} -\doxyref{getFileNameList()}{p.}{classQuaZip_abb38d8b4c9c4ae0728b48caae9dd82de} - -\doxyref{getFileInfoList64()}{p.}{classQuaZip_a474e66b1b696a9e00edcc067484c36ad} -\end{DoxySeeAlso} -\index{QuaZip@{QuaZip}!getFileInfoList64@{getFileInfoList64}} -\index{getFileInfoList64@{getFileInfoList64}!QuaZip@{QuaZip}} -\subsubsection[{getFileInfoList64}]{\setlength{\rightskip}{0pt plus 5cm}QList$<$ {\bf QuaZipFileInfo64} $>$ QuaZip::getFileInfoList64 ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{classQuaZip_a474e66b1b696a9e00edcc067484c36ad} - - -Returns information list about all files inside the archive. - -This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. This function supports zip64. - -\begin{DoxySeeAlso}{See also} -\doxyref{getFileNameList()}{p.}{classQuaZip_abb38d8b4c9c4ae0728b48caae9dd82de} - -\doxyref{getFileInfoList()}{p.}{classQuaZip_a7486af66bede8e131db0cd2e81881387} -\end{DoxySeeAlso} -\index{QuaZip@{QuaZip}!setZip64Enabled@{setZip64Enabled}} -\index{setZip64Enabled@{setZip64Enabled}!QuaZip@{QuaZip}} -\subsubsection[{setZip64Enabled}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZip::setZip64Enabled ( -\begin{DoxyParamCaption} -\item[{bool}]{zip64} -\end{DoxyParamCaption} -)}\label{classQuaZip_ab99a22efae02ebb4b5c9cd8eedc1c0b0} - - -Enables the zip64 mode. - - -\begin{DoxyParams}{Parameters} -{\em zip64} & If {\ttfamily true}, the zip64 mode is enabled, disabled otherwise.\\ -\hline -\end{DoxyParams} -Once this is enabled, all new files (until the mode is disabled again) will be created in the zip64 mode, thus enabling the ability to write files larger than 4 GB. By default, the zip64 mode is off due to compatibility reasons. - -Note that this does not affect the ability to read zip64 archives in any way. - -\begin{DoxySeeAlso}{See also} -\doxyref{isZip64Enabled()}{p.}{classQuaZip_a1b638566390d7599ba5982e844b151f4} -\end{DoxySeeAlso} -\index{QuaZip@{QuaZip}!isZip64Enabled@{isZip64Enabled}} -\index{isZip64Enabled@{isZip64Enabled}!QuaZip@{QuaZip}} -\subsubsection[{isZip64Enabled}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZip::isZip64Enabled ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{classQuaZip_a1b638566390d7599ba5982e844b151f4} - - -Returns whether the zip64 mode is enabled. - -\begin{DoxyReturn}{Returns} -{\ttfamily true} if and only if the zip64 mode is enabled. -\end{DoxyReturn} -\begin{DoxySeeAlso}{See also} -\doxyref{setZip64Enabled()}{p.}{classQuaZip_ab99a22efae02ebb4b5c9cd8eedc1c0b0} -\end{DoxySeeAlso} - - -Referenced by QuaZipFile::open(). - -\index{QuaZip@{QuaZip}!isAutoClose@{isAutoClose}} -\index{isAutoClose@{isAutoClose}!QuaZip@{QuaZip}} -\subsubsection[{isAutoClose}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZip::isAutoClose ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{classQuaZip_adc2cc762ab5744720ae4d33290b5f5bf} - - -Returns the auto-\/close flag. - -\begin{DoxySeeAlso}{See also} -\doxyref{setAutoClose()}{p.}{classQuaZip_a54bfc924762774ccf9f99be075ba7b0e} -\end{DoxySeeAlso} -\index{QuaZip@{QuaZip}!setAutoClose@{setAutoClose}} -\index{setAutoClose@{setAutoClose}!QuaZip@{QuaZip}} -\subsubsection[{setAutoClose}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZip::setAutoClose ( -\begin{DoxyParamCaption} -\item[{bool}]{autoClose} -\end{DoxyParamCaption} -) const}\label{classQuaZip_a54bfc924762774ccf9f99be075ba7b0e} - - -Sets or unsets the auto-\/close flag. - -By default, QuaZIP opens the underlying QIODevice when \doxyref{open()}{p.}{classQuaZip_abfa4e6018b2964a3d10a4c54e5ab3962} is called, and closes it when \doxyref{close()}{p.}{classQuaZip_a7a4323b73e12f3b4470109f200728f9f} is called. In some cases, when the device is set explicitly using \doxyref{setIoDevice()}{p.}{classQuaZip_a64642948b6531ee54f5522f29e388cc6}, it may be desirable to leave the device open. If the auto-\/close flag is unset using this method, then the device isn't closed automatically if it was set explicitly. - -If it is needed to clear this flag, it is recommended to do so before opening the archive because otherwise QuaZIP may close the device during the \doxyref{open()}{p.}{classQuaZip_abfa4e6018b2964a3d10a4c54e5ab3962} call if an error is encountered after the device is opened. - -If the device was not set explicitly, but rather the \doxyref{setZipName()}{p.}{classQuaZip_aa80b661de1262af905d1677dbcb008cc} or the appropriate constructor was used to set the ZIP file name instead, then the auto-\/close flag has no effect, and the internal device is closed nevertheless because there is no other way to close it. - -\begin{DoxySeeAlso}{See also} -\doxyref{isAutoClose()}{p.}{classQuaZip_adc2cc762ab5744720ae4d33290b5f5bf} - -\doxyref{setIoDevice()}{p.}{classQuaZip_a64642948b6531ee54f5522f29e388cc6} -\end{DoxySeeAlso} -\index{QuaZip@{QuaZip}!setDefaultFileNameCodec@{setDefaultFileNameCodec}} -\index{setDefaultFileNameCodec@{setDefaultFileNameCodec}!QuaZip@{QuaZip}} -\subsubsection[{setDefaultFileNameCodec}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZip::setDefaultFileNameCodec ( -\begin{DoxyParamCaption} -\item[{QTextCodec $\ast$}]{codec} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [static]}}\label{classQuaZip_a317f5db89d84a80417338a3ab89770da} - - -Sets the default file name codec to use. - -The default codec is used by the constructors, so calling this function won't affect the \doxyref{QuaZip}{p.}{classQuaZip} instances already created at that moment. - -The codec specified here can be overriden by calling \doxyref{setFileNameCodec()}{p.}{classQuaZip_a339010b5566704ba3c9cafbfe848d8fb}. If neither function is called, QTextCodec::codecForLocale() will be used to decode or encode file names. Use this function with caution if the application uses other libraries that depend on QuaZIP. Those libraries can either call this function by themselves, thus overriding your setting or can rely on the default encoding, thus failing mysteriously if you change it. For these reasons, it isn't recommended to use this function if you are developing a library, not an application. Instead, ask your library users to call it in case they need specific encoding. - -In most cases, using \doxyref{setFileNameCodec()}{p.}{classQuaZip_a339010b5566704ba3c9cafbfe848d8fb} instead is the right choice. However, if you depend on third-\/party code that uses QuaZIP, then the reasons stated above can actually become a reason to use this function in case the third-\/party code in question fails because it doesn't understand the encoding you need and doesn't provide a way to specify it. This applies to the \doxyref{JlCompress}{p.}{classJlCompress} class as well, as it was contributed and doesn't support explicit encoding parameters. - -In short: use \doxyref{setFileNameCodec()}{p.}{classQuaZip_a339010b5566704ba3c9cafbfe848d8fb} when you can, resort to \doxyref{setDefaultFileNameCodec()}{p.}{classQuaZip_a317f5db89d84a80417338a3ab89770da} when you don't have access to the \doxyref{QuaZip}{p.}{classQuaZip} instance. - - -\begin{DoxyParams}{Parameters} -{\em codec} & The codec to use by default. If NULL, resets to default. \\ -\hline -\end{DoxyParams} - - -Referenced by setDefaultFileNameCodec(). - -\index{QuaZip@{QuaZip}!setDefaultFileNameCodec@{setDefaultFileNameCodec}} -\index{setDefaultFileNameCodec@{setDefaultFileNameCodec}!QuaZip@{QuaZip}} -\subsubsection[{setDefaultFileNameCodec}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZip::setDefaultFileNameCodec ( -\begin{DoxyParamCaption} -\item[{const char $\ast$}]{codecName} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [static]}}\label{classQuaZip_a694af3c0ab076fab7bf619952f6fbfea} -This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. Equivalent to calling setDefltFileNameCodec(QTextCodec::codecForName(codecName)). - -References setDefaultFileNameCodec(). - - - -The documentation for this class was generated from the following files:\begin{DoxyCompactItemize} -\item -quazip/quazip.h\item -quazip/quazip.cpp\end{DoxyCompactItemize} diff --git a/hecl-gui/quazip/doc/latex/classQuaZipDir.tex b/hecl-gui/quazip/doc/latex/classQuaZipDir.tex deleted file mode 100644 index 25f369628..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaZipDir.tex +++ /dev/null @@ -1,413 +0,0 @@ -\section{QuaZipDir Class Reference} -\label{classQuaZipDir}\index{QuaZipDir@{QuaZipDir}} - - -Provides ZIP archive navigation. - - - - -{\ttfamily \#include $<$quazipdir.h$>$} - -\subsection*{Public Member Functions} -\begin{DoxyCompactItemize} -\item -{\bf QuaZipDir} (const {\bf QuaZipDir} \&that)\label{classQuaZipDir_a6c9cc8b74c52d3fe997b753370566690} - -\begin{DoxyCompactList}\small\item\em The copy constructor. \end{DoxyCompactList}\item -{\bf QuaZipDir} ({\bf QuaZip} $\ast$zip, const QString \&dir=QString()) -\begin{DoxyCompactList}\small\item\em Constructs a \doxyref{QuaZipDir}{p.}{classQuaZipDir} instance pointing to the specified directory. \end{DoxyCompactList}\item -{\bf $\sim$QuaZipDir} ()\label{classQuaZipDir_ae95d60e2c23e611723371bf8fff2b095} - -\begin{DoxyCompactList}\small\item\em Destructor. \end{DoxyCompactList}\item -bool {\bf operator==} (const {\bf QuaZipDir} \&that)\label{classQuaZipDir_a4a2e07484c7159a3f469922ba2383547} - -\begin{DoxyCompactList}\small\item\em The assignment operator. \end{DoxyCompactList}\item -bool {\bf operator!=} (const {\bf QuaZipDir} \&that) -\begin{DoxyCompactList}\small\item\em operator!= \end{DoxyCompactList}\item -{\bf QuaZipDir} \& {\bf operator=} (const {\bf QuaZipDir} \&that) -\begin{DoxyCompactList}\small\item\em operator== \end{DoxyCompactList}\item -QString {\bf operator[$\,$]} (int pos) const \label{classQuaZipDir_a9e37ef5318c44a4575c58d66110e535a} - -\begin{DoxyCompactList}\small\item\em Returns the name of the entry at the specified position. \end{DoxyCompactList}\item -{\bf QuaZip::CaseSensitivity} {\bf caseSensitivity} () const \label{classQuaZipDir_ad7ab403a8d36a3b6149da86ea37178f8} - -\begin{DoxyCompactList}\small\item\em Returns the current case sensitivity mode. \end{DoxyCompactList}\item -bool {\bf cd} (const QString \&dirName) -\begin{DoxyCompactList}\small\item\em Changes the 'current' directory. \end{DoxyCompactList}\item -bool {\bf cdUp} ()\label{classQuaZipDir_a62306db3f4c0866930fa35c7348b84b3} - -\begin{DoxyCompactList}\small\item\em Goes up. \end{DoxyCompactList}\item -uint {\bf count} () const \label{classQuaZipDir_aa3f14665e3991351f4ef94ab8e0ab29d} - -\begin{DoxyCompactList}\small\item\em Returns the number of entries in the directory. \end{DoxyCompactList}\item -QString {\bf dirName} () const -\begin{DoxyCompactList}\small\item\em Returns the current directory name. \end{DoxyCompactList}\item -QList$<$ {\bf QuaZipFileInfo} $>$ {\bf entryInfoList} (const QStringList \&nameFilters, QDir::Filters filters=QDir::NoFilter, QDir::SortFlags sort=QDir::NoSort) const -\begin{DoxyCompactList}\small\item\em Returns the list of the entries in the directory. \end{DoxyCompactList}\item -QList$<$ {\bf QuaZipFileInfo} $>$ {\bf entryInfoList} (QDir::Filters filters=QDir::NoFilter, QDir::SortFlags sort=QDir::NoSort) const -\begin{DoxyCompactList}\small\item\em Returns the list of the entries in the directory. \end{DoxyCompactList}\item -QList$<$ {\bf QuaZipFileInfo64} $>$ {\bf entryInfoList64} (const QStringList \&nameFilters, QDir::Filters filters=QDir::NoFilter, QDir::SortFlags sort=QDir::NoSort) const -\begin{DoxyCompactList}\small\item\em Returns the list of the entries in the directory with zip64 support. \end{DoxyCompactList}\item -QList$<$ {\bf QuaZipFileInfo64} $>$ {\bf entryInfoList64} (QDir::Filters filters=QDir::NoFilter, QDir::SortFlags sort=QDir::NoSort) const -\begin{DoxyCompactList}\small\item\em Returns the list of the entries in the directory with zip64 support. \end{DoxyCompactList}\item -QStringList {\bf entryList} (const QStringList \&nameFilters, QDir::Filters filters=QDir::NoFilter, QDir::SortFlags sort=QDir::NoSort) const -\begin{DoxyCompactList}\small\item\em Returns the list of the entry names in the directory. \end{DoxyCompactList}\item -QStringList {\bf entryList} (QDir::Filters filters=QDir::NoFilter, QDir::SortFlags sort=QDir::NoSort) const -\begin{DoxyCompactList}\small\item\em Returns the list of the entry names in the directory. \end{DoxyCompactList}\item -bool {\bf exists} (const QString \&fileName) const -\begin{DoxyCompactList}\small\item\em Returns {\ttfamily true} if the entry with the specified name exists. \end{DoxyCompactList}\item -bool {\bf exists} () const \label{classQuaZipDir_a22c8f63ce874f5c0e958ae5f42e6d004} - -\begin{DoxyCompactList}\small\item\em Return {\ttfamily true} if the directory pointed by this \doxyref{QuaZipDir}{p.}{classQuaZipDir} exists. \end{DoxyCompactList}\item -QString {\bf filePath} (const QString \&fileName) const -\begin{DoxyCompactList}\small\item\em Returns the full path to the specified file. \end{DoxyCompactList}\item -QDir::Filters {\bf filter} ()\label{classQuaZipDir_abeee1810c7c1c1af93364081dbf70d38} - -\begin{DoxyCompactList}\small\item\em Returns the default filter. \end{DoxyCompactList}\item -bool {\bf isRoot} () const -\begin{DoxyCompactList}\small\item\em Returns if the \doxyref{QuaZipDir}{p.}{classQuaZipDir} points to the root of the archive. \end{DoxyCompactList}\item -QStringList {\bf nameFilters} () const \label{classQuaZipDir_a00f18e23abb8cac04f975e7f31553f2e} - -\begin{DoxyCompactList}\small\item\em Return the default name filter. \end{DoxyCompactList}\item -QString {\bf path} () const -\begin{DoxyCompactList}\small\item\em Returns the path to the current dir. \end{DoxyCompactList}\item -QString {\bf relativeFilePath} (const QString \&fileName) const -\begin{DoxyCompactList}\small\item\em Returns the path to the specified file relative to the current dir. \end{DoxyCompactList}\item -void {\bf setCaseSensitivity} ({\bf QuaZip::CaseSensitivity} caseSensitivity)\label{classQuaZipDir_ad53c720975bb0c49a823355f7d518793} - -\begin{DoxyCompactList}\small\item\em Sets the default case sensitivity mode. \end{DoxyCompactList}\item -void {\bf setFilter} (QDir::Filters filters)\label{classQuaZipDir_a779a43641f0f3802678e39c9acd1fddb} - -\begin{DoxyCompactList}\small\item\em Sets the default filter. \end{DoxyCompactList}\item -void {\bf setNameFilters} (const QStringList \&nameFilters)\label{classQuaZipDir_abcf208bfd6136e14f36725ae79dce2be} - -\begin{DoxyCompactList}\small\item\em Sets the default name filter. \end{DoxyCompactList}\item -void {\bf setPath} (const QString \&path) -\begin{DoxyCompactList}\small\item\em Goes to the specified path. \end{DoxyCompactList}\item -void {\bf setSorting} (QDir::SortFlags sort)\label{classQuaZipDir_ae43e9d717e3c4b1c0d4790cf558e7451} - -\begin{DoxyCompactList}\small\item\em Sets the default sorting mode. \end{DoxyCompactList}\item -QDir::SortFlags {\bf sorting} () const \label{classQuaZipDir_a4000523c961ab9e0cad08641ff10e3fa} - -\begin{DoxyCompactList}\small\item\em Returns the default sorting mode. \end{DoxyCompactList}\end{DoxyCompactItemize} - - -\subsection{Detailed Description} -Provides ZIP archive navigation. - -This class is modelled after QDir, and is designed to provide similar features for ZIP archives. - -The only significant difference from QDir is that the root path is not '/', but an empty string since that's how the file paths are stored in the archive. However, \doxyref{QuaZipDir}{p.}{classQuaZipDir} understands the paths starting with '/'. It is important in a few places: - - -\begin{DoxyItemize} -\item In the \doxyref{cd()}{p.}{classQuaZipDir_aa829afc0243f1d307302f1167edecc7b} function. -\item In the constructor. -\item In the \doxyref{exists()}{p.}{classQuaZipDir_aacb488fec6e951ac80e5d473534fee97} function. -\item In the relativePath() function. -\end{DoxyItemize} - -Note that since ZIP uses '/' on all platforms, the '$\backslash$' separator is not supported. - -\subsection{Constructor \& Destructor Documentation} -\index{QuaZipDir@{QuaZipDir}!QuaZipDir@{QuaZipDir}} -\index{QuaZipDir@{QuaZipDir}!QuaZipDir@{QuaZipDir}} -\subsubsection[{QuaZipDir}]{\setlength{\rightskip}{0pt plus 5cm}QuaZipDir::QuaZipDir ( -\begin{DoxyParamCaption} -\item[{{\bf QuaZip} $\ast$}]{zip, } -\item[{const QString \&}]{dir = {\ttfamily QString()}} -\end{DoxyParamCaption} -)}\label{classQuaZipDir_a19e5e3a54f322ce03e7f7606a87a2ba1} - - -Constructs a \doxyref{QuaZipDir}{p.}{classQuaZipDir} instance pointing to the specified directory. - -If {\itshape dir\/} is not specified, points to the root of the archive. The same happens if the {\itshape dir\/} is "/". - -\subsection{Member Function Documentation} -\index{QuaZipDir@{QuaZipDir}!operator!=@{operator!=}} -\index{operator!=@{operator!=}!QuaZipDir@{QuaZipDir}} -\subsubsection[{operator!=}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZipDir::operator!= ( -\begin{DoxyParamCaption} -\item[{const {\bf QuaZipDir} \&}]{that} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [inline]}}\label{classQuaZipDir_a6e60d858d05774c958215ee7741eceed} - - -operator!= - -\begin{DoxyReturn}{Returns} -{\ttfamily true} if either this and {\itshape that\/} use different \doxyref{QuaZip}{p.}{classQuaZip} instances or if they point to different directories. -\end{DoxyReturn} -\index{QuaZipDir@{QuaZipDir}!operator=@{operator=}} -\index{operator=@{operator=}!QuaZipDir@{QuaZipDir}} -\subsubsection[{operator=}]{\setlength{\rightskip}{0pt plus 5cm}{\bf QuaZipDir} \& QuaZipDir::operator= ( -\begin{DoxyParamCaption} -\item[{const {\bf QuaZipDir} \&}]{that} -\end{DoxyParamCaption} -)}\label{classQuaZipDir_aa603c69be0c1597add5951b19f8bc961} - - -operator== - -\begin{DoxyReturn}{Returns} -{\ttfamily true} if both this and {\itshape that\/} use the same \doxyref{QuaZip}{p.}{classQuaZip} instance and point to the same directory. -\end{DoxyReturn} -\index{QuaZipDir@{QuaZipDir}!cd@{cd}} -\index{cd@{cd}!QuaZipDir@{QuaZipDir}} -\subsubsection[{cd}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZipDir::cd ( -\begin{DoxyParamCaption} -\item[{const QString \&}]{dirName} -\end{DoxyParamCaption} -)}\label{classQuaZipDir_aa829afc0243f1d307302f1167edecc7b} - - -Changes the 'current' directory. - -If the path starts with '/', it is interpreted as an absolute path from the root of the archive. Otherwise, it is interpreted as a path relative to the current directory as was set by the previous \doxyref{cd()}{p.}{classQuaZipDir_aa829afc0243f1d307302f1167edecc7b} or the constructor. - -Note that the subsequent \doxyref{path()}{p.}{classQuaZipDir_a68ac82ad605c0b10f9ee1a2d6d474f52} call will not return a path starting with '/' in all cases. - -References cd(), dirName(), exists(), isRoot(), and path(). - - - -Referenced by cd(), and cdUp(). - -\index{QuaZipDir@{QuaZipDir}!dirName@{dirName}} -\index{dirName@{dirName}!QuaZipDir@{QuaZipDir}} -\subsubsection[{dirName}]{\setlength{\rightskip}{0pt plus 5cm}QString QuaZipDir::dirName ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{classQuaZipDir_afd2f76410f7728a7166b7598926fbf96} - - -Returns the current directory name. - -The name doesn't include the path. - -Referenced by cd(). - -\index{QuaZipDir@{QuaZipDir}!entryInfoList@{entryInfoList}} -\index{entryInfoList@{entryInfoList}!QuaZipDir@{QuaZipDir}} -\subsubsection[{entryInfoList}]{\setlength{\rightskip}{0pt plus 5cm}QList$<$ {\bf QuaZipFileInfo} $>$ QuaZipDir::entryInfoList ( -\begin{DoxyParamCaption} -\item[{const QStringList \&}]{nameFilters, } -\item[{QDir::Filters}]{filters = {\ttfamily QDir::NoFilter}, } -\item[{QDir::SortFlags}]{sort = {\ttfamily QDir::NoSort}} -\end{DoxyParamCaption} -) const}\label{classQuaZipDir_aef966735a146fc10c9527c236aa89261} - - -Returns the list of the entries in the directory. - - -\begin{DoxyParams}{Parameters} -{\em nameFilters} & The list of file patterns to list, uses the same syntax as QDir. \\ -\hline -{\em filters} & The entry type filters, only Files and Dirs are accepted. \\ -\hline -{\em sort} & Sorting mode.\\ -\hline -\end{DoxyParams} - - -Referenced by entryInfoList(). - -\index{QuaZipDir@{QuaZipDir}!entryInfoList@{entryInfoList}} -\index{entryInfoList@{entryInfoList}!QuaZipDir@{QuaZipDir}} -\subsubsection[{entryInfoList}]{\setlength{\rightskip}{0pt plus 5cm}QList$<$ {\bf QuaZipFileInfo} $>$ QuaZipDir::entryInfoList ( -\begin{DoxyParamCaption} -\item[{QDir::Filters}]{filters = {\ttfamily QDir::NoFilter}, } -\item[{QDir::SortFlags}]{sort = {\ttfamily QDir::NoSort}} -\end{DoxyParamCaption} -) const}\label{classQuaZipDir_abec530f15597ddf8c8d1f340a333f7aa} - - -Returns the list of the entries in the directory. - -This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. The same as entryInfoList(QStringList(), filters, sort). - -References entryInfoList(). - -\index{QuaZipDir@{QuaZipDir}!entryInfoList64@{entryInfoList64}} -\index{entryInfoList64@{entryInfoList64}!QuaZipDir@{QuaZipDir}} -\subsubsection[{entryInfoList64}]{\setlength{\rightskip}{0pt plus 5cm}QList$<$ {\bf QuaZipFileInfo64} $>$ QuaZipDir::entryInfoList64 ( -\begin{DoxyParamCaption} -\item[{const QStringList \&}]{nameFilters, } -\item[{QDir::Filters}]{filters = {\ttfamily QDir::NoFilter}, } -\item[{QDir::SortFlags}]{sort = {\ttfamily QDir::NoSort}} -\end{DoxyParamCaption} -) const}\label{classQuaZipDir_ae2b5a4b251db7aeb165c6656da0e3431} - - -Returns the list of the entries in the directory with zip64 support. - - -\begin{DoxyParams}{Parameters} -{\em nameFilters} & The list of file patterns to list, uses the same syntax as QDir. \\ -\hline -{\em filters} & The entry type filters, only Files and Dirs are accepted. \\ -\hline -{\em sort} & Sorting mode. \\ -\hline -\end{DoxyParams} - - -Referenced by entryInfoList64(). - -\index{QuaZipDir@{QuaZipDir}!entryInfoList64@{entryInfoList64}} -\index{entryInfoList64@{entryInfoList64}!QuaZipDir@{QuaZipDir}} -\subsubsection[{entryInfoList64}]{\setlength{\rightskip}{0pt plus 5cm}QList$<$ {\bf QuaZipFileInfo64} $>$ QuaZipDir::entryInfoList64 ( -\begin{DoxyParamCaption} -\item[{QDir::Filters}]{filters = {\ttfamily QDir::NoFilter}, } -\item[{QDir::SortFlags}]{sort = {\ttfamily QDir::NoSort}} -\end{DoxyParamCaption} -) const}\label{classQuaZipDir_a8c38ec214c300049685cbf71486636d5} - - -Returns the list of the entries in the directory with zip64 support. - -This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. The same as entryInfoList64(QStringList(), filters, sort). - -References entryInfoList64(). - -\index{QuaZipDir@{QuaZipDir}!entryList@{entryList}} -\index{entryList@{entryList}!QuaZipDir@{QuaZipDir}} -\subsubsection[{entryList}]{\setlength{\rightskip}{0pt plus 5cm}QStringList QuaZipDir::entryList ( -\begin{DoxyParamCaption} -\item[{const QStringList \&}]{nameFilters, } -\item[{QDir::Filters}]{filters = {\ttfamily QDir::NoFilter}, } -\item[{QDir::SortFlags}]{sort = {\ttfamily QDir::NoSort}} -\end{DoxyParamCaption} -) const}\label{classQuaZipDir_a4a32faa77c4120cd3c6db4b683fa16d9} - - -Returns the list of the entry names in the directory. - -The same as entryInfoList(nameFilters, filters, sort), but only returns entry names. - -Referenced by count(), entryList(), exists(), and operator[$\,$](). - -\index{QuaZipDir@{QuaZipDir}!entryList@{entryList}} -\index{entryList@{entryList}!QuaZipDir@{QuaZipDir}} -\subsubsection[{entryList}]{\setlength{\rightskip}{0pt plus 5cm}QStringList QuaZipDir::entryList ( -\begin{DoxyParamCaption} -\item[{QDir::Filters}]{filters = {\ttfamily QDir::NoFilter}, } -\item[{QDir::SortFlags}]{sort = {\ttfamily QDir::NoSort}} -\end{DoxyParamCaption} -) const}\label{classQuaZipDir_ab20e9d3de675b74fcacc98accbc1d766} - - -Returns the list of the entry names in the directory. - -This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. The same as entryList(QStringList(), filters, sort). - -References entryList(). - -\index{QuaZipDir@{QuaZipDir}!exists@{exists}} -\index{exists@{exists}!QuaZipDir@{QuaZipDir}} -\subsubsection[{exists}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZipDir::exists ( -\begin{DoxyParamCaption} -\item[{const QString \&}]{fileName} -\end{DoxyParamCaption} -) const}\label{classQuaZipDir_aacb488fec6e951ac80e5d473534fee97} - - -Returns {\ttfamily true} if the entry with the specified name exists. - -The ".." is considered to exist if the current directory is not root. The "." and "/" are considered to always exist. Paths starting with "/" are relative to the archive root, other paths are relative to the current dir. - -References QuaZip::convertCaseSensitivity(), entryList(), filePath(), and isRoot(). - -\index{QuaZipDir@{QuaZipDir}!filePath@{filePath}} -\index{filePath@{filePath}!QuaZipDir@{QuaZipDir}} -\subsubsection[{filePath}]{\setlength{\rightskip}{0pt plus 5cm}QString QuaZipDir::filePath ( -\begin{DoxyParamCaption} -\item[{const QString \&}]{fileName} -\end{DoxyParamCaption} -) const}\label{classQuaZipDir_ae8b576a150f8d62c902067603cbc97ae} - - -Returns the full path to the specified file. - -Doesn't check if the file actually exists. - -Referenced by exists(). - -\index{QuaZipDir@{QuaZipDir}!isRoot@{isRoot}} -\index{isRoot@{isRoot}!QuaZipDir@{QuaZipDir}} -\subsubsection[{isRoot}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZipDir::isRoot ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{classQuaZipDir_a598fdf23f1b37e1876476e5969040a32} - - -Returns if the \doxyref{QuaZipDir}{p.}{classQuaZipDir} points to the root of the archive. - -Not that the root path is the empty string, not '/'. - -Referenced by cd(), and exists(). - -\index{QuaZipDir@{QuaZipDir}!path@{path}} -\index{path@{path}!QuaZipDir@{QuaZipDir}} -\subsubsection[{path}]{\setlength{\rightskip}{0pt plus 5cm}QString QuaZipDir::path ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{classQuaZipDir_a68ac82ad605c0b10f9ee1a2d6d474f52} - - -Returns the path to the current dir. - -The path never starts with '/', and the root path is an empty string. - -Referenced by cd(), and setPath(). - -\index{QuaZipDir@{QuaZipDir}!relativeFilePath@{relativeFilePath}} -\index{relativeFilePath@{relativeFilePath}!QuaZipDir@{QuaZipDir}} -\subsubsection[{relativeFilePath}]{\setlength{\rightskip}{0pt plus 5cm}QString QuaZipDir::relativeFilePath ( -\begin{DoxyParamCaption} -\item[{const QString \&}]{fileName} -\end{DoxyParamCaption} -) const}\label{classQuaZipDir_a2ae89c2b85786a0168656fc7a3faaf01} - - -Returns the path to the specified file relative to the current dir. - -This function is mostly useless, provided only for the sake of completeness. - - -\begin{DoxyParams}{Parameters} -{\em fileName} & The path to the file, should start with "/" if relative to the archive root. \\ -\hline -\end{DoxyParams} -\begin{DoxyReturn}{Returns} -Path relative to the current dir. -\end{DoxyReturn} -\index{QuaZipDir@{QuaZipDir}!setPath@{setPath}} -\index{setPath@{setPath}!QuaZipDir@{QuaZipDir}} -\subsubsection[{setPath}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZipDir::setPath ( -\begin{DoxyParamCaption} -\item[{const QString \&}]{path} -\end{DoxyParamCaption} -)}\label{classQuaZipDir_ae82d06e43856414c30583205d337c111} - - -Goes to the specified path. - -The difference from \doxyref{cd()}{p.}{classQuaZipDir_aa829afc0243f1d307302f1167edecc7b} is that this function never checks if the path actually exists and doesn't use relative paths, so it's possible to go to the root directory with setPath(""). - -Note that this function still chops the trailing and/or leading '/' and treats a single '/' as the root path (\doxyref{path()}{p.}{classQuaZipDir_a68ac82ad605c0b10f9ee1a2d6d474f52} will still return an empty string). - -References path(). - - - -The documentation for this class was generated from the following files:\begin{DoxyCompactItemize} -\item -quazip/quazipdir.h\item -quazip/quazipdir.cpp\end{DoxyCompactItemize} diff --git a/hecl-gui/quazip/doc/latex/classQuaZipFile.tex b/hecl-gui/quazip/doc/latex/classQuaZipFile.tex deleted file mode 100644 index 80f1b3ae5..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaZipFile.tex +++ /dev/null @@ -1,696 +0,0 @@ -\section{QuaZipFile Class Reference} -\label{classQuaZipFile}\index{QuaZipFile@{QuaZipFile}} - - -A file inside ZIP archive. - - - - -{\ttfamily \#include $<$quazip/quazipfile.h$>$} - - - -Collaboration diagram for QuaZipFile: -\nopagebreak -\begin{figure}[H] -\begin{center} -\leavevmode -\includegraphics[width=231pt]{classQuaZipFile__coll__graph} -\end{center} -\end{figure} -\subsection*{Public Member Functions} -\begin{DoxyCompactItemize} -\item -{\bf QuaZipFile} () -\begin{DoxyCompactList}\small\item\em Constructs a \doxyref{QuaZipFile}{p.}{classQuaZipFile} instance. \end{DoxyCompactList}\item -{\bf QuaZipFile} (QObject $\ast$parent) -\begin{DoxyCompactList}\small\item\em Constructs a \doxyref{QuaZipFile}{p.}{classQuaZipFile} instance. \end{DoxyCompactList}\item -{\bf QuaZipFile} (const QString \&zipName, QObject $\ast$parent=NULL) -\begin{DoxyCompactList}\small\item\em Constructs a \doxyref{QuaZipFile}{p.}{classQuaZipFile} instance. \end{DoxyCompactList}\item -{\bf QuaZipFile} (const QString \&zipName, const QString \&fileName, {\bf QuaZip::CaseSensitivity} cs=QuaZip::csDefault, QObject $\ast$parent=NULL) -\begin{DoxyCompactList}\small\item\em Constructs a \doxyref{QuaZipFile}{p.}{classQuaZipFile} instance. \end{DoxyCompactList}\item -{\bf QuaZipFile} ({\bf QuaZip} $\ast$zip, QObject $\ast$parent=NULL) -\begin{DoxyCompactList}\small\item\em Constructs a \doxyref{QuaZipFile}{p.}{classQuaZipFile} instance. \end{DoxyCompactList}\item -virtual {\bf $\sim$QuaZipFile} () -\begin{DoxyCompactList}\small\item\em Destroys a \doxyref{QuaZipFile}{p.}{classQuaZipFile} instance. \end{DoxyCompactList}\item -QString {\bf getZipName} () const -\begin{DoxyCompactList}\small\item\em Returns the ZIP archive file name. \end{DoxyCompactList}\item -{\bf QuaZip} $\ast$ {\bf getZip} () const -\begin{DoxyCompactList}\small\item\em Returns a pointer to the associated \doxyref{QuaZip}{p.}{classQuaZip} object. \end{DoxyCompactList}\item -QString {\bf getFileName} () const -\begin{DoxyCompactList}\small\item\em Returns file name. \end{DoxyCompactList}\item -{\bf QuaZip::CaseSensitivity} {\bf getCaseSensitivity} () const -\begin{DoxyCompactList}\small\item\em Returns case sensitivity of the file name. \end{DoxyCompactList}\item -QString {\bf getActualFileName} () const -\begin{DoxyCompactList}\small\item\em Returns the actual file name in the archive. \end{DoxyCompactList}\item -void {\bf setZipName} (const QString \&zipName) -\begin{DoxyCompactList}\small\item\em Sets the ZIP archive file name. \end{DoxyCompactList}\item -bool {\bf isRaw} () const -\begin{DoxyCompactList}\small\item\em Returns {\ttfamily true} if the file was opened in raw mode. \end{DoxyCompactList}\item -void {\bf setZip} ({\bf QuaZip} $\ast$zip) -\begin{DoxyCompactList}\small\item\em Binds to the existing \doxyref{QuaZip}{p.}{classQuaZip} instance. \end{DoxyCompactList}\item -void {\bf setFileName} (const QString \&fileName, {\bf QuaZip::CaseSensitivity} cs=QuaZip::csDefault) -\begin{DoxyCompactList}\small\item\em Sets the file name. \end{DoxyCompactList}\item -virtual bool {\bf open} (OpenMode mode) -\begin{DoxyCompactList}\small\item\em Opens a file for reading. \end{DoxyCompactList}\item -bool {\bf open} (OpenMode mode, const char $\ast$password) -\begin{DoxyCompactList}\small\item\em Opens a file for reading. \end{DoxyCompactList}\item -bool {\bf open} (OpenMode mode, int $\ast$method, int $\ast$level, bool raw, const char $\ast$password=NULL) -\begin{DoxyCompactList}\small\item\em Opens a file for reading. \end{DoxyCompactList}\item -bool {\bf open} (OpenMode mode, const {\bf QuaZipNewInfo} \&info, const char $\ast$password=NULL, quint32 crc=0, int method=Z\_\-DEFLATED, int level=Z\_\-DEFAULT\_\-COMPRESSION, bool raw=false, int windowBits=-\/MAX\_\-WBITS, int memLevel=DEF\_\-MEM\_\-LEVEL, int strategy=Z\_\-DEFAULT\_\-STRATEGY) -\begin{DoxyCompactList}\small\item\em Opens a file for writing. \end{DoxyCompactList}\item -virtual bool {\bf isSequential} () const \label{classQuaZipFile_a64430ec50820c8096f963a7e5f53001f} - -\begin{DoxyCompactList}\small\item\em Returns {\ttfamily true}, but \doxyref{beware}{p.}{classQuaZipFile_quazipfile-sequential}! \end{DoxyCompactList}\item -virtual qint64 {\bf pos} () const -\begin{DoxyCompactList}\small\item\em Returns current position in the file. \end{DoxyCompactList}\item -virtual bool {\bf atEnd} () const -\begin{DoxyCompactList}\small\item\em Returns {\ttfamily true} if the end of file was reached. \end{DoxyCompactList}\item -virtual qint64 {\bf size} () const -\begin{DoxyCompactList}\small\item\em Returns file size. \end{DoxyCompactList}\item -qint64 {\bf csize} () const -\begin{DoxyCompactList}\small\item\em Returns compressed file size. \end{DoxyCompactList}\item -qint64 {\bf usize} () const -\begin{DoxyCompactList}\small\item\em Returns uncompressed file size. \end{DoxyCompactList}\item -bool {\bf getFileInfo} ({\bf QuaZipFileInfo} $\ast$info) -\begin{DoxyCompactList}\small\item\em Gets information about current file. \end{DoxyCompactList}\item -bool {\bf getFileInfo} ({\bf QuaZipFileInfo64} $\ast$info) -\begin{DoxyCompactList}\small\item\em Gets information about current file with zip64 support. \end{DoxyCompactList}\item -virtual void {\bf close} () -\begin{DoxyCompactList}\small\item\em Closes the file. \end{DoxyCompactList}\item -int {\bf getZipError} () const \label{classQuaZipFile_a26d2ee56aad947193b73052f80597ef0} - -\begin{DoxyCompactList}\small\item\em Returns the error code returned by the last ZIP/UNZIP API call. \end{DoxyCompactList}\item -virtual qint64 {\bf bytesAvailable} () const \label{classQuaZipFile_a29fbfb34677f69394ae7c986ffd3a0c1} - -\begin{DoxyCompactList}\small\item\em Returns the number of bytes available for reading. \end{DoxyCompactList}\end{DoxyCompactItemize} -\subsection*{Protected Member Functions} -\begin{DoxyCompactItemize} -\item -qint64 {\bf readData} (char $\ast$data, qint64 maxSize)\label{classQuaZipFile_aa1f2274e1579327855a17d67a9046ec2} - -\begin{DoxyCompactList}\small\item\em Implementation of the QIODevice::readData(). \end{DoxyCompactList}\item -qint64 {\bf writeData} (const char $\ast$data, qint64 maxSize)\label{classQuaZipFile_abd07949a6fcc2ef094d2be5398bc8e7c} - -\begin{DoxyCompactList}\small\item\em Implementation of the QIODevice::writeData(). \end{DoxyCompactList}\end{DoxyCompactItemize} -\subsection*{Friends} -\begin{DoxyCompactItemize} -\item -class {\bf QuaZipFilePrivate}\label{classQuaZipFile_abeded291f2788ca39fe2256d78f95266} - -\end{DoxyCompactItemize} - - -\subsection{Detailed Description} -A file inside ZIP archive. - -This is the most interesting class. Not only it provides C++ interface to the ZIP/UNZIP package, but also integrates it with Qt by subclassing QIODevice. This makes possible to access files inside ZIP archive using QTextStream or QDataStream, for example. Actually, this is the main purpose of the whole QuaZIP library. - -You can either use existing \doxyref{QuaZip}{p.}{classQuaZip} instance to create instance of this class or pass ZIP archive file name to this class, in which case it will create internal \doxyref{QuaZip}{p.}{classQuaZip} object. See constructors' descriptions for details. Writing is only possible with the existing instance. - -Note that due to the underlying library's limitation it is not possible to use multiple \doxyref{QuaZipFile}{p.}{classQuaZipFile} instances to open several files in the same archive at the same time. If you need to write to multiple files in parallel, then you should write to temporary files first, then pack them all at once when you have finished writing. If you need to read multiple files inside the same archive in parallel, you should extract them all into a temporary directory first.\subsection{Sequential or random-\/access?}\label{classQuaZipFile_quazipfile-sequential} -At the first thought, \doxyref{QuaZipFile}{p.}{classQuaZipFile} has fixed size, the start and the end and should be therefore considered random-\/access device. But there is one major obstacle to making it random-\/access: ZIP/UNZIP API does not support seek() operation and the only way to implement it is through reopening the file and re-\/reading to the required position, but this is prohibitively slow. - -Therefore, \doxyref{QuaZipFile}{p.}{classQuaZipFile} is considered to be a sequential device. This has advantage of availability of the ungetChar() operation (QIODevice does not implement it properly for non-\/sequential devices unless they support seek()). Disadvantage is a somewhat strange behaviour of the \doxyref{size()}{p.}{classQuaZipFile_ad1a17cc690a01c3edfb82984c3a4c8f0} and \doxyref{pos()}{p.}{classQuaZipFile_a90fd55dab83eca7f95df50b2c41b7f22} functions. This should be kept in mind while using this class. - -\subsection{Constructor \& Destructor Documentation} -\index{QuaZipFile@{QuaZipFile}!QuaZipFile@{QuaZipFile}} -\index{QuaZipFile@{QuaZipFile}!QuaZipFile@{QuaZipFile}} -\subsubsection[{QuaZipFile}]{\setlength{\rightskip}{0pt plus 5cm}QuaZipFile::QuaZipFile ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -)}\label{classQuaZipFile_ad31592e0e8a9eaa009c6c0e2040a2158} - - -Constructs a \doxyref{QuaZipFile}{p.}{classQuaZipFile} instance. - -You should use \doxyref{setZipName()}{p.}{classQuaZipFile_ac8109e9a5c19bea75982ff6986b5cb1e} and \doxyref{setFileName()}{p.}{classQuaZipFile_a3732ca7704379d457b6a27db8837de95} or \doxyref{setZip()}{p.}{classQuaZipFile_ab7939a26d1e8de2f6aca54f49a12b980} before trying to call \doxyref{open()}{p.}{classQuaZipFile_a4c20c0ef00ae79c9a59eafe2906c9384} on the constructed object. \index{QuaZipFile@{QuaZipFile}!QuaZipFile@{QuaZipFile}} -\index{QuaZipFile@{QuaZipFile}!QuaZipFile@{QuaZipFile}} -\subsubsection[{QuaZipFile}]{\setlength{\rightskip}{0pt plus 5cm}QuaZipFile::QuaZipFile ( -\begin{DoxyParamCaption} -\item[{QObject $\ast$}]{parent} -\end{DoxyParamCaption} -)}\label{classQuaZipFile_a1349ad27f1947bc3e346d83dbf9586c4} - - -Constructs a \doxyref{QuaZipFile}{p.}{classQuaZipFile} instance. - -{\itshape parent\/} argument specifies this object's parent object. - -You should use \doxyref{setZipName()}{p.}{classQuaZipFile_ac8109e9a5c19bea75982ff6986b5cb1e} and \doxyref{setFileName()}{p.}{classQuaZipFile_a3732ca7704379d457b6a27db8837de95} or \doxyref{setZip()}{p.}{classQuaZipFile_ab7939a26d1e8de2f6aca54f49a12b980} before trying to call \doxyref{open()}{p.}{classQuaZipFile_a4c20c0ef00ae79c9a59eafe2906c9384} on the constructed object. \index{QuaZipFile@{QuaZipFile}!QuaZipFile@{QuaZipFile}} -\index{QuaZipFile@{QuaZipFile}!QuaZipFile@{QuaZipFile}} -\subsubsection[{QuaZipFile}]{\setlength{\rightskip}{0pt plus 5cm}QuaZipFile::QuaZipFile ( -\begin{DoxyParamCaption} -\item[{const QString \&}]{zipName, } -\item[{QObject $\ast$}]{parent = {\ttfamily NULL}} -\end{DoxyParamCaption} -)}\label{classQuaZipFile_ae614495d6b2404a6c59d7cfca5c3f6fd} - - -Constructs a \doxyref{QuaZipFile}{p.}{classQuaZipFile} instance. - -{\itshape parent\/} argument specifies this object's parent object and {\itshape zipName\/} specifies ZIP archive file name. - -You should use \doxyref{setFileName()}{p.}{classQuaZipFile_a3732ca7704379d457b6a27db8837de95} before trying to call \doxyref{open()}{p.}{classQuaZipFile_a4c20c0ef00ae79c9a59eafe2906c9384} on the constructed object. - -\doxyref{QuaZipFile}{p.}{classQuaZipFile} constructed by this constructor can be used for read only access. Use \doxyref{QuaZipFile(QuaZip$\ast$,QObject$\ast$)}{p.}{classQuaZipFile_a54e944a6b3d27030f64c8f30d2cc33bb} for writing. \index{QuaZipFile@{QuaZipFile}!QuaZipFile@{QuaZipFile}} -\index{QuaZipFile@{QuaZipFile}!QuaZipFile@{QuaZipFile}} -\subsubsection[{QuaZipFile}]{\setlength{\rightskip}{0pt plus 5cm}QuaZipFile::QuaZipFile ( -\begin{DoxyParamCaption} -\item[{const QString \&}]{zipName, } -\item[{const QString \&}]{fileName, } -\item[{{\bf QuaZip::CaseSensitivity}}]{cs = {\ttfamily QuaZip::csDefault}, } -\item[{QObject $\ast$}]{parent = {\ttfamily NULL}} -\end{DoxyParamCaption} -)}\label{classQuaZipFile_ac6e883b5a5d3a58c9c56eb497dd91220} - - -Constructs a \doxyref{QuaZipFile}{p.}{classQuaZipFile} instance. - -{\itshape parent\/} argument specifies this object's parent object, {\itshape zipName\/} specifies ZIP archive file name and {\itshape fileName\/} and {\itshape cs\/} specify a name of the file to open inside archive. - -\doxyref{QuaZipFile}{p.}{classQuaZipFile} constructed by this constructor can be used for read only access. Use \doxyref{QuaZipFile(QuaZip$\ast$,QObject$\ast$)}{p.}{classQuaZipFile_a54e944a6b3d27030f64c8f30d2cc33bb} for writing. - -\begin{DoxySeeAlso}{See also} -\doxyref{QuaZip::setCurrentFile()}{p.}{classQuaZip_a6c657bfcfccb59d728e0da24c677d899} -\end{DoxySeeAlso} -\index{QuaZipFile@{QuaZipFile}!QuaZipFile@{QuaZipFile}} -\index{QuaZipFile@{QuaZipFile}!QuaZipFile@{QuaZipFile}} -\subsubsection[{QuaZipFile}]{\setlength{\rightskip}{0pt plus 5cm}QuaZipFile::QuaZipFile ( -\begin{DoxyParamCaption} -\item[{{\bf QuaZip} $\ast$}]{zip, } -\item[{QObject $\ast$}]{parent = {\ttfamily NULL}} -\end{DoxyParamCaption} -)}\label{classQuaZipFile_a54e944a6b3d27030f64c8f30d2cc33bb} - - -Constructs a \doxyref{QuaZipFile}{p.}{classQuaZipFile} instance. - -{\itshape parent\/} argument specifies this object's parent object. - -{\itshape zip\/} is the pointer to the existing \doxyref{QuaZip}{p.}{classQuaZip} object. This \doxyref{QuaZipFile}{p.}{classQuaZipFile} object then can be used to read current file in the {\itshape zip\/} or to write to the file inside it. - -\begin{DoxyWarning}{Warning} -Using this constructor for reading current file can be tricky. Let's take the following example: -\begin{DoxyCode} - QuaZip zip("archive.zip"); - zip.open(QuaZip::mdUnzip); - zip.setCurrentFile("file-in-archive"); - QuaZipFile file(&zip); - file.open(QIODevice::ReadOnly); - // ok, now we can read from the file - file.read(somewhere, some); - zip.setCurrentFile("another-file-in-archive"); // oops... - QuaZipFile anotherFile(&zip); - anotherFile.open(QIODevice::ReadOnly); - anotherFile.read(somewhere, some); // this is still ok... - file.read(somewhere, some); // and this is NOT -\end{DoxyCode} - So, what exactly happens here? When we change current file in the {\ttfamily zip} archive, {\ttfamily file} that references it becomes invalid (actually, as far as I understand ZIP/UNZIP sources, it becomes closed, but \doxyref{QuaZipFile}{p.}{classQuaZipFile} has no means to detect it). -\end{DoxyWarning} -Summary: do not close {\ttfamily zip} object or change its current file as long as \doxyref{QuaZipFile}{p.}{classQuaZipFile} is open. Even better -\/ use another constructors which create internal \doxyref{QuaZip}{p.}{classQuaZip} instances, one per object, and therefore do not cause unnecessary trouble. This constructor may be useful, though, if you already have a \doxyref{QuaZip}{p.}{classQuaZip} instance and do not want to access several files at once. Good example: -\begin{DoxyCode} - QuaZip zip("archive.zip"); - zip.open(QuaZip::mdUnzip); - // first, we need some information about archive itself - QByteArray comment=zip.getComment(); - // and now we are going to access files inside it - QuaZipFile file(&zip); - for(bool more=zip.goToFirstFile(); more; more=zip.goToNextFile()) { - file.open(QIODevice::ReadOnly); - // do something cool with file here - file.close(); // do not forget to close! - } - zip.close(); -\end{DoxyCode} - \index{QuaZipFile@{QuaZipFile}!$\sim$QuaZipFile@{$\sim$QuaZipFile}} -\index{$\sim$QuaZipFile@{$\sim$QuaZipFile}!QuaZipFile@{QuaZipFile}} -\subsubsection[{$\sim$QuaZipFile}]{\setlength{\rightskip}{0pt plus 5cm}QuaZipFile::$\sim$QuaZipFile ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [virtual]}}\label{classQuaZipFile_aa1e5a0cf491bafae6cc73e649caa97fc} - - -Destroys a \doxyref{QuaZipFile}{p.}{classQuaZipFile} instance. - -Closes file if open, destructs internal \doxyref{QuaZip}{p.}{classQuaZip} object (if it exists and {\itshape is\/} internal, of course). - -References close(). - - - -\subsection{Member Function Documentation} -\index{QuaZipFile@{QuaZipFile}!getZipName@{getZipName}} -\index{getZipName@{getZipName}!QuaZipFile@{QuaZipFile}} -\subsubsection[{getZipName}]{\setlength{\rightskip}{0pt plus 5cm}QString QuaZipFile::getZipName ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{classQuaZipFile_a6f034a714aa94631367590de3f8f4e22} - - -Returns the ZIP archive file name. - -If this object was created by passing \doxyref{QuaZip}{p.}{classQuaZip} pointer to the constructor, this function will return that QuaZip's file name (or null string if that object does not have file name yet). - -Otherwise, returns associated ZIP archive file name or null string if there are no name set yet. - -\begin{DoxySeeAlso}{See also} -\doxyref{setZipName()}{p.}{classQuaZipFile_ac8109e9a5c19bea75982ff6986b5cb1e} \doxyref{getFileName()}{p.}{classQuaZipFile_a6999362e70a5b2396fba5cfb30095ff9} -\end{DoxySeeAlso} - - -References QuaZip::getZipName(). - -\index{QuaZipFile@{QuaZipFile}!getZip@{getZip}} -\index{getZip@{getZip}!QuaZipFile@{QuaZipFile}} -\subsubsection[{getZip}]{\setlength{\rightskip}{0pt plus 5cm}{\bf QuaZip} $\ast$ QuaZipFile::getZip ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{classQuaZipFile_a72daf8a9da14907a801a783603003205} - - -Returns a pointer to the associated \doxyref{QuaZip}{p.}{classQuaZip} object. - -Returns {\ttfamily NULL} if there is no associated \doxyref{QuaZip}{p.}{classQuaZip} or it is internal (so you will not mess with it). \index{QuaZipFile@{QuaZipFile}!getFileName@{getFileName}} -\index{getFileName@{getFileName}!QuaZipFile@{QuaZipFile}} -\subsubsection[{getFileName}]{\setlength{\rightskip}{0pt plus 5cm}QString QuaZipFile::getFileName ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{classQuaZipFile_a6999362e70a5b2396fba5cfb30095ff9} - - -Returns file name. - -This function returns file name you passed to this object either by using \doxyref{QuaZipFile(const QString\&,const QString\&,QuaZip::CaseSensitivity,QObject$\ast$)}{p.}{classQuaZipFile_ac6e883b5a5d3a58c9c56eb497dd91220} or by calling \doxyref{setFileName()}{p.}{classQuaZipFile_a3732ca7704379d457b6a27db8837de95}. Real name of the file may differ in case if you used case-\/insensitivity. - -Returns null string if there is no file name set yet. This is the case when this \doxyref{QuaZipFile}{p.}{classQuaZipFile} operates on the existing \doxyref{QuaZip}{p.}{classQuaZip} object (constructor \doxyref{QuaZipFile(QuaZip$\ast$,QObject$\ast$)}{p.}{classQuaZipFile_a54e944a6b3d27030f64c8f30d2cc33bb} or \doxyref{setZip()}{p.}{classQuaZipFile_ab7939a26d1e8de2f6aca54f49a12b980} was used). - -\begin{DoxySeeAlso}{See also} -\doxyref{getActualFileName}{p.}{classQuaZipFile_a7b8e3c39026855cd98661a1b2815c220} -\end{DoxySeeAlso} -\index{QuaZipFile@{QuaZipFile}!getCaseSensitivity@{getCaseSensitivity}} -\index{getCaseSensitivity@{getCaseSensitivity}!QuaZipFile@{QuaZipFile}} -\subsubsection[{getCaseSensitivity}]{\setlength{\rightskip}{0pt plus 5cm}{\bf QuaZip::CaseSensitivity} QuaZipFile::getCaseSensitivity ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{classQuaZipFile_a25dbfddc589bf6b69b39905f3c3bcc73} - - -Returns case sensitivity of the file name. - -This function returns case sensitivity argument you passed to this object either by using \doxyref{QuaZipFile(const QString\&,const QString\&,QuaZip::CaseSensitivity,QObject$\ast$)}{p.}{classQuaZipFile_ac6e883b5a5d3a58c9c56eb497dd91220} or by calling \doxyref{setFileName()}{p.}{classQuaZipFile_a3732ca7704379d457b6a27db8837de95}. - -Returns unpredictable value if \doxyref{getFileName()}{p.}{classQuaZipFile_a6999362e70a5b2396fba5cfb30095ff9} returns null string (this is the case when you did not used \doxyref{setFileName()}{p.}{classQuaZipFile_a3732ca7704379d457b6a27db8837de95} or constructor above). - -\begin{DoxySeeAlso}{See also} -\doxyref{getFileName}{p.}{classQuaZipFile_a6999362e70a5b2396fba5cfb30095ff9} -\end{DoxySeeAlso} -\index{QuaZipFile@{QuaZipFile}!getActualFileName@{getActualFileName}} -\index{getActualFileName@{getActualFileName}!QuaZipFile@{QuaZipFile}} -\subsubsection[{getActualFileName}]{\setlength{\rightskip}{0pt plus 5cm}QString QuaZipFile::getActualFileName ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{classQuaZipFile_a7b8e3c39026855cd98661a1b2815c220} - - -Returns the actual file name in the archive. - -This is {\itshape not\/} a ZIP archive file name, but a name of file inside archive. It is not necessary the same name that you have passed to the \doxyref{QuaZipFile(const QString\&,const QString\&,QuaZip::CaseSensitivity,QObject$\ast$)}{p.}{classQuaZipFile_ac6e883b5a5d3a58c9c56eb497dd91220}, \doxyref{setFileName()}{p.}{classQuaZipFile_a3732ca7704379d457b6a27db8837de95} or \doxyref{QuaZip::setCurrentFile()}{p.}{classQuaZip_a6c657bfcfccb59d728e0da24c677d899} -\/ this is the real file name inside archive, so it may differ in case if the file name search was case-\/insensitive. - -Equivalent to calling getCurrentFileName() on the associated \doxyref{QuaZip}{p.}{classQuaZip} object. Returns null string if there is no associated \doxyref{QuaZip}{p.}{classQuaZip} object or if it does not have a current file yet. And this is the case if you called \doxyref{setFileName()}{p.}{classQuaZipFile_a3732ca7704379d457b6a27db8837de95} but did not open the file yet. So this is perfectly fine: -\begin{DoxyCode} - QuaZipFile file("somezip.zip"); - file.setFileName("somefile"); - QString name=file.getName(); // name=="somefile" - QString actual=file.getActualFileName(); // actual is null string - file.open(QIODevice::ReadOnly); - QString actual=file.getActualFileName(); // actual can be "SoMeFiLe" on Windows -\end{DoxyCode} - - -\begin{DoxySeeAlso}{See also} -\doxyref{getZipName()}{p.}{classQuaZipFile_a6f034a714aa94631367590de3f8f4e22}, \doxyref{getFileName()}{p.}{classQuaZipFile_a6999362e70a5b2396fba5cfb30095ff9}, \doxyref{QuaZip::CaseSensitivity}{p.}{classQuaZip_a6053a1d249ed210a85c9d5eb7cf9cdbe} -\end{DoxySeeAlso} - - -References QuaZip::getCurrentFileName(), and QuaZip::getZipError(). - -\index{QuaZipFile@{QuaZipFile}!setZipName@{setZipName}} -\index{setZipName@{setZipName}!QuaZipFile@{QuaZipFile}} -\subsubsection[{setZipName}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZipFile::setZipName ( -\begin{DoxyParamCaption} -\item[{const QString \&}]{zipName} -\end{DoxyParamCaption} -)}\label{classQuaZipFile_ac8109e9a5c19bea75982ff6986b5cb1e} - - -Sets the ZIP archive file name. - -Automatically creates internal \doxyref{QuaZip}{p.}{classQuaZip} object and destroys previously created internal \doxyref{QuaZip}{p.}{classQuaZip} object, if any. - -Will do nothing if this file is already open. You must \doxyref{close()}{p.}{classQuaZipFile_a42a39b12619bccd3d419ee60bbb3fcf6} it first. \index{QuaZipFile@{QuaZipFile}!isRaw@{isRaw}} -\index{isRaw@{isRaw}!QuaZipFile@{QuaZipFile}} -\subsubsection[{isRaw}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZipFile::isRaw ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{classQuaZipFile_a0df3db94c2a34c8d17ddaa0f54fc32c1} - - -Returns {\ttfamily true} if the file was opened in raw mode. - -If the file is not open, the returned value is undefined. - -\begin{DoxySeeAlso}{See also} -\doxyref{open(OpenMode,int$\ast$,int$\ast$,bool,const char$\ast$)}{p.}{classQuaZipFile_aed75bace51f2bb4c3e4f656ab4493aac} -\end{DoxySeeAlso} - - -Referenced by close(). - -\index{QuaZipFile@{QuaZipFile}!setZip@{setZip}} -\index{setZip@{setZip}!QuaZipFile@{QuaZipFile}} -\subsubsection[{setZip}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZipFile::setZip ( -\begin{DoxyParamCaption} -\item[{{\bf QuaZip} $\ast$}]{zip} -\end{DoxyParamCaption} -)}\label{classQuaZipFile_ab7939a26d1e8de2f6aca54f49a12b980} - - -Binds to the existing \doxyref{QuaZip}{p.}{classQuaZip} instance. - -This function destroys internal \doxyref{QuaZip}{p.}{classQuaZip} object, if any, and makes this \doxyref{QuaZipFile}{p.}{classQuaZipFile} to use current file in the {\itshape zip\/} object for any further operations. See \doxyref{QuaZipFile(QuaZip$\ast$,QObject$\ast$)}{p.}{classQuaZipFile_a54e944a6b3d27030f64c8f30d2cc33bb} for the possible pitfalls. - -Will do nothing if the file is currently open. You must \doxyref{close()}{p.}{classQuaZipFile_a42a39b12619bccd3d419ee60bbb3fcf6} it first. \index{QuaZipFile@{QuaZipFile}!setFileName@{setFileName}} -\index{setFileName@{setFileName}!QuaZipFile@{QuaZipFile}} -\subsubsection[{setFileName}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZipFile::setFileName ( -\begin{DoxyParamCaption} -\item[{const QString \&}]{fileName, } -\item[{{\bf QuaZip::CaseSensitivity}}]{cs = {\ttfamily QuaZip::csDefault}} -\end{DoxyParamCaption} -)}\label{classQuaZipFile_a3732ca7704379d457b6a27db8837de95} - - -Sets the file name. - -Will do nothing if at least one of the following conditions is met: -\begin{DoxyItemize} -\item ZIP name has not been set yet (\doxyref{getZipName()}{p.}{classQuaZipFile_a6f034a714aa94631367590de3f8f4e22} returns null string). -\item This \doxyref{QuaZipFile}{p.}{classQuaZipFile} is associated with external \doxyref{QuaZip}{p.}{classQuaZip}. In this case you should call that QuaZip's setCurrentFile() function instead! -\item File is already open so setting the name is meaningless. -\end{DoxyItemize} - -\begin{DoxySeeAlso}{See also} -\doxyref{QuaZip::setCurrentFile}{p.}{classQuaZip_a6c657bfcfccb59d728e0da24c677d899} -\end{DoxySeeAlso} -\index{QuaZipFile@{QuaZipFile}!open@{open}} -\index{open@{open}!QuaZipFile@{QuaZipFile}} -\subsubsection[{open}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZipFile::open ( -\begin{DoxyParamCaption} -\item[{OpenMode}]{mode} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [virtual]}}\label{classQuaZipFile_a4c20c0ef00ae79c9a59eafe2906c9384} - - -Opens a file for reading. - -Returns {\ttfamily true} on success, {\ttfamily false} otherwise. Call \doxyref{getZipError()}{p.}{classQuaZipFile_a26d2ee56aad947193b73052f80597ef0} to get error code. - -\begin{DoxyNote}{Note} -Since ZIP/UNZIP API provides buffered reading only, \doxyref{QuaZipFile}{p.}{classQuaZipFile} does not support unbuffered reading. So do not pass QIODevice::Unbuffered flag in {\itshape mode\/}, or open will fail. -\end{DoxyNote} -\index{QuaZipFile@{QuaZipFile}!open@{open}} -\index{open@{open}!QuaZipFile@{QuaZipFile}} -\subsubsection[{open}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZipFile::open ( -\begin{DoxyParamCaption} -\item[{OpenMode}]{mode, } -\item[{const char $\ast$}]{password} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [inline]}}\label{classQuaZipFile_a0bff0d15bbcd70306dc4a553a55776b9} - - -Opens a file for reading. - -This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. Argument {\itshape password\/} specifies a password to decrypt the file. If it is NULL then this function behaves just like \doxyref{open(OpenMode)}{p.}{classQuaZipFile_a4c20c0ef00ae79c9a59eafe2906c9384}. - -References open(). - - - -Referenced by open(). - -\index{QuaZipFile@{QuaZipFile}!open@{open}} -\index{open@{open}!QuaZipFile@{QuaZipFile}} -\subsubsection[{open}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZipFile::open ( -\begin{DoxyParamCaption} -\item[{OpenMode}]{mode, } -\item[{int $\ast$}]{method, } -\item[{int $\ast$}]{level, } -\item[{bool}]{raw, } -\item[{const char $\ast$}]{password = {\ttfamily NULL}} -\end{DoxyParamCaption} -)}\label{classQuaZipFile_aed75bace51f2bb4c3e4f656ab4493aac} - - -Opens a file for reading. - -This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. Argument {\itshape password\/} specifies a password to decrypt the file. - -An integers pointed by {\itshape method\/} and {\itshape level\/} will receive codes of the compression method and level used. See unzip.h. - -If raw is {\ttfamily true} then no decompression is performed. - -{\itshape method\/} should not be {\ttfamily NULL}. {\itshape level\/} can be {\ttfamily NULL} if you don't want to know the compression level. - -References QuaZip::close(), QuaZip::getMode(), QuaZip::getUnzFile(), QuaZip::getZipError(), QuaZip::hasCurrentFile(), QuaZip::mdUnzip, QuaZip::open(), and QuaZip::setCurrentFile(). - -\index{QuaZipFile@{QuaZipFile}!open@{open}} -\index{open@{open}!QuaZipFile@{QuaZipFile}} -\subsubsection[{open}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZipFile::open ( -\begin{DoxyParamCaption} -\item[{OpenMode}]{mode, } -\item[{const {\bf QuaZipNewInfo} \&}]{info, } -\item[{const char $\ast$}]{password = {\ttfamily NULL}, } -\item[{quint32}]{crc = {\ttfamily 0}, } -\item[{int}]{method = {\ttfamily Z\_\-DEFLATED}, } -\item[{int}]{level = {\ttfamily Z\_\-DEFAULT\_\-COMPRESSION}, } -\item[{bool}]{raw = {\ttfamily false}, } -\item[{int}]{windowBits = {\ttfamily -\/MAX\_\-WBITS}, } -\item[{int}]{memLevel = {\ttfamily DEF\_\-MEM\_\-LEVEL}, } -\item[{int}]{strategy = {\ttfamily Z\_\-DEFAULT\_\-STRATEGY}} -\end{DoxyParamCaption} -)}\label{classQuaZipFile_a2429ea59c77371d7af56d739db130b18} - - -Opens a file for writing. - -{\itshape info\/} argument specifies information about file. It should at least specify a correct file name. Also, it is a good idea to specify correct timestamp (by default, current time will be used). See \doxyref{QuaZipNewInfo}{p.}{structQuaZipNewInfo}. - -The {\itshape password\/} argument specifies the password for crypting. Pass NULL if you don't need any crypting. The {\itshape crc\/} argument was supposed to be used for crypting too, but then it turned out that it's false information, so you need to set it to 0 unless you want to use the raw mode (see below). - -Arguments {\itshape method\/} and {\itshape level\/} specify compression method and level. The only method supported is Z\_\-DEFLATED, but you may also specify 0 for no compression. If all of the files in the archive use both method 0 and either level 0 is explicitly specified or data descriptor writing is disabled with \doxyref{QuaZip::setDataDescriptorWritingEnabled()}{p.}{classQuaZip_a6c23a12af88f7ea5edd4f9c0a24b9453}, then the resulting archive is supposed to be compatible with the 1.0 ZIP format version, should you need that. Except for this, {\itshape level\/} has no other effects with method 0. - -If {\itshape raw\/} is {\ttfamily true}, no compression is performed. In this case, {\itshape crc\/} and uncompressedSize field of the {\itshape info\/} are required. - -Arguments {\itshape windowBits\/}, {\itshape memLevel\/}, {\itshape strategy\/} provide zlib algorithms tuning. See deflateInit2() in zlib. - -References QuaZipNewInfo::comment, QuaZipNewInfo::dateTime, QuaZipNewInfo::externalAttr, QuaZipNewInfo::extraGlobal, QuaZipNewInfo::extraLocal, QuaZip::getCommentCodec(), QuaZip::getFileNameCodec(), QuaZip::getMode(), QuaZip::getZipFile(), QuaZipNewInfo::internalAttr, QuaZip::isDataDescriptorWritingEnabled(), QuaZip::isZip64Enabled(), QuaZip::mdAdd, QuaZip::mdAppend, QuaZip::mdCreate, QuaZipNewInfo::name, and QuaZipNewInfo::uncompressedSize. - -\index{QuaZipFile@{QuaZipFile}!pos@{pos}} -\index{pos@{pos}!QuaZipFile@{QuaZipFile}} -\subsubsection[{pos}]{\setlength{\rightskip}{0pt plus 5cm}qint64 QuaZipFile::pos ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const\hspace{0.3cm}{\ttfamily [virtual]}}\label{classQuaZipFile_a90fd55dab83eca7f95df50b2c41b7f22} - - -Returns current position in the file. - -Implementation of the QIODevice::pos(). When reading, this function is a wrapper to the ZIP/UNZIP unztell(), therefore it is unable to keep track of the ungetChar() calls (which is non-\/virtual and therefore is dangerous to reimplement). So if you are using ungetChar() feature of the QIODevice, this function reports incorrect value until you get back characters which you ungot. - -When writing, \doxyref{pos()}{p.}{classQuaZipFile_a90fd55dab83eca7f95df50b2c41b7f22} returns number of bytes already written (uncompressed unless you use raw mode). - -\begin{DoxyNote}{Note} -Although \doxyref{QuaZipFile is a sequential device}{p.}{classQuaZipFile_quazipfile-sequential} and therefore \doxyref{pos()}{p.}{classQuaZipFile_a90fd55dab83eca7f95df50b2c41b7f22} should always return zero, it does not, because it would be misguiding. Keep this in mind. -\end{DoxyNote} -This function returns -\/1 if the file or archive is not open. - -Error code returned by \doxyref{getZipError()}{p.}{classQuaZipFile_a26d2ee56aad947193b73052f80597ef0} is not affected by this function call. - -References QuaZip::getUnzFile(). - - - -Referenced by bytesAvailable(). - -\index{QuaZipFile@{QuaZipFile}!atEnd@{atEnd}} -\index{atEnd@{atEnd}!QuaZipFile@{QuaZipFile}} -\subsubsection[{atEnd}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZipFile::atEnd ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const\hspace{0.3cm}{\ttfamily [virtual]}}\label{classQuaZipFile_a1e3f4c3c075da98af426fc167440cfc3} - - -Returns {\ttfamily true} if the end of file was reached. - -This function returns {\ttfamily false} in the case of error. This means that you called this function on either not open file, or a file in the not open archive or even on a \doxyref{QuaZipFile}{p.}{classQuaZipFile} instance that does not even have \doxyref{QuaZip}{p.}{classQuaZip} instance associated. Do not do that because there is no means to determine whether {\ttfamily false} is returned because of error or because end of file was reached. Well, on the other side you may interpret {\ttfamily false} return value as \char`\"{}there is no file open to check for end of file and there is - no end of file therefore\char`\"{}. - -When writing, this function always returns {\ttfamily true} (because you are always writing to the end of file). - -Error code returned by \doxyref{getZipError()}{p.}{classQuaZipFile_a26d2ee56aad947193b73052f80597ef0} is not affected by this function call. - -References bytesAvailable(), and QuaZip::getUnzFile(). - -\index{QuaZipFile@{QuaZipFile}!size@{size}} -\index{size@{size}!QuaZipFile@{QuaZipFile}} -\subsubsection[{size}]{\setlength{\rightskip}{0pt plus 5cm}qint64 QuaZipFile::size ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const\hspace{0.3cm}{\ttfamily [virtual]}}\label{classQuaZipFile_ad1a17cc690a01c3edfb82984c3a4c8f0} - - -Returns file size. - -This function returns \doxyref{csize()}{p.}{classQuaZipFile_ac4da08e5cdec368a2a686775f7dc5639} if the file is open for reading in raw mode, \doxyref{usize()}{p.}{classQuaZipFile_a4814b5e6e39fb254737b81ea10964f50} if it is open for reading in normal mode and \doxyref{pos()}{p.}{classQuaZipFile_a90fd55dab83eca7f95df50b2c41b7f22} if it is open for writing. - -Returns -\/1 on error, call \doxyref{getZipError()}{p.}{classQuaZipFile_a26d2ee56aad947193b73052f80597ef0} to get error code. - -\begin{DoxyNote}{Note} -This function returns file size despite that \doxyref{QuaZipFile is considered to be sequential device}{p.}{classQuaZipFile_quazipfile-sequential}, for which \doxyref{size()}{p.}{classQuaZipFile_ad1a17cc690a01c3edfb82984c3a4c8f0} should return \doxyref{bytesAvailable()}{p.}{classQuaZipFile_a29fbfb34677f69394ae7c986ffd3a0c1} instead. But its name would be very misguiding otherwise, so just keep in mind this inconsistence. -\end{DoxyNote} - - -References csize(), and usize(). - - - -Referenced by bytesAvailable(). - -\index{QuaZipFile@{QuaZipFile}!csize@{csize}} -\index{csize@{csize}!QuaZipFile@{QuaZipFile}} -\subsubsection[{csize}]{\setlength{\rightskip}{0pt plus 5cm}qint64 QuaZipFile::csize ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{classQuaZipFile_ac4da08e5cdec368a2a686775f7dc5639} - - -Returns compressed file size. - -Equivalent to calling \doxyref{getFileInfo()}{p.}{classQuaZipFile_ad3f5807329321be21b12c1ba5798b359} and then getting compressedSize field, but more convenient and faster. - -File must be open for reading before calling this function. - -Returns -\/1 on error, call \doxyref{getZipError()}{p.}{classQuaZipFile_a26d2ee56aad947193b73052f80597ef0} to get error code. - -References QuaZip::getMode(), QuaZip::getUnzFile(), and QuaZip::mdUnzip. - - - -Referenced by size(). - -\index{QuaZipFile@{QuaZipFile}!usize@{usize}} -\index{usize@{usize}!QuaZipFile@{QuaZipFile}} -\subsubsection[{usize}]{\setlength{\rightskip}{0pt plus 5cm}qint64 QuaZipFile::usize ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{classQuaZipFile_a4814b5e6e39fb254737b81ea10964f50} - - -Returns uncompressed file size. - -Equivalent to calling \doxyref{getFileInfo()}{p.}{classQuaZipFile_ad3f5807329321be21b12c1ba5798b359} and then getting uncompressedSize field, but more convenient and faster. See \doxyref{getFileInfo()}{p.}{classQuaZipFile_ad3f5807329321be21b12c1ba5798b359} for a warning. - -File must be open for reading before calling this function. - -Returns -\/1 on error, call \doxyref{getZipError()}{p.}{classQuaZipFile_a26d2ee56aad947193b73052f80597ef0} to get error code. - -References QuaZip::getMode(), QuaZip::getUnzFile(), and QuaZip::mdUnzip. - - - -Referenced by size(). - -\index{QuaZipFile@{QuaZipFile}!getFileInfo@{getFileInfo}} -\index{getFileInfo@{getFileInfo}!QuaZipFile@{QuaZipFile}} -\subsubsection[{getFileInfo}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZipFile::getFileInfo ( -\begin{DoxyParamCaption} -\item[{{\bf QuaZipFileInfo} $\ast$}]{info} -\end{DoxyParamCaption} -)}\label{classQuaZipFile_ad3f5807329321be21b12c1ba5798b359} - - -Gets information about current file. - -This function does the same thing as calling \doxyref{QuaZip::getCurrentFileInfo()}{p.}{classQuaZip_a9c91a53ed4c2038e153c64bdc097ebe8} on the associated \doxyref{QuaZip}{p.}{classQuaZip} object, but you can not call getCurrentFileInfo() if the associated \doxyref{QuaZip}{p.}{classQuaZip} is internal (because you do not have access to it), while you still can call this function in that case. - -File must be open for reading before calling this function. - -\begin{DoxyReturn}{Returns} -{\ttfamily false} in the case of an error. -\end{DoxyReturn} -This function doesn't support zip64, but will still work fine on zip64 archives if file sizes are below 4 GB, otherwise the values will be set as if converted using \doxyref{QuaZipFileInfo64::toQuaZipFileInfo()}{p.}{structQuaZipFileInfo64_ada29945c7ee4c9df6fbe95864793aade}. - -\begin{DoxySeeAlso}{See also} -\doxyref{getFileInfo(QuaZipFileInfo64$\ast$)}{p.}{classQuaZipFile_af35876a5ac6e9c35234275a9e503110d} -\end{DoxySeeAlso} - - -References QuaZipFileInfo64::toQuaZipFileInfo(). - -\index{QuaZipFile@{QuaZipFile}!getFileInfo@{getFileInfo}} -\index{getFileInfo@{getFileInfo}!QuaZipFile@{QuaZipFile}} -\subsubsection[{getFileInfo}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZipFile::getFileInfo ( -\begin{DoxyParamCaption} -\item[{{\bf QuaZipFileInfo64} $\ast$}]{info} -\end{DoxyParamCaption} -)}\label{classQuaZipFile_af35876a5ac6e9c35234275a9e503110d} - - -Gets information about current file with zip64 support. - -This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. \begin{DoxySeeAlso}{See also} -\doxyref{getFileInfo(QuaZipFileInfo$\ast$)}{p.}{classQuaZipFile_ad3f5807329321be21b12c1ba5798b359} -\end{DoxySeeAlso} - - -References QuaZip::getCurrentFileInfo(), QuaZip::getMode(), QuaZip::getZipError(), and QuaZip::mdUnzip. - -\index{QuaZipFile@{QuaZipFile}!close@{close}} -\index{close@{close}!QuaZipFile@{QuaZipFile}} -\subsubsection[{close}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZipFile::close ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -)\hspace{0.3cm}{\ttfamily [virtual]}}\label{classQuaZipFile_a42a39b12619bccd3d419ee60bbb3fcf6} - - -Closes the file. - -Call \doxyref{getZipError()}{p.}{classQuaZipFile_a26d2ee56aad947193b73052f80597ef0} to determine if the close was successful. - -References QuaZip::close(), QuaZip::getUnzFile(), QuaZip::getZipError(), QuaZip::getZipFile(), QuaZip::isOpen(), and isRaw(). - - - -Referenced by $\sim$QuaZipFile(). - - - -The documentation for this class was generated from the following files:\begin{DoxyCompactItemize} -\item -quazip/quazipfile.h\item -quazip/quazipfile.cpp\end{DoxyCompactItemize} diff --git a/hecl-gui/quazip/doc/latex/classQuaZipFilePrivate.tex b/hecl-gui/quazip/doc/latex/classQuaZipFilePrivate.tex deleted file mode 100644 index 10a0ab7ae..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaZipFilePrivate.tex +++ /dev/null @@ -1,31 +0,0 @@ -\section{QuaZipFilePrivate Class Reference} -\label{classQuaZipFilePrivate}\index{QuaZipFilePrivate@{QuaZipFilePrivate}} - - -The implementation class for \doxyref{QuaZip}{p.}{classQuaZip}. - - - - -Collaboration diagram for QuaZipFilePrivate: -\nopagebreak -\begin{figure}[H] -\begin{center} -\leavevmode -\includegraphics[width=231pt]{classQuaZipFilePrivate__coll__graph} -\end{center} -\end{figure} -\subsection*{Friends} -\begin{DoxyCompactItemize} -\item -class {\bf QuaZipFile}\label{classQuaZipFilePrivate_a40bd4ccb6d2d00726e1de81329ebaa7a} - -\end{DoxyCompactItemize} - - -\subsection{Detailed Description} -The implementation class for \doxyref{QuaZip}{p.}{classQuaZip}. - -The documentation for this class was generated from the following file:\begin{DoxyCompactItemize} -\item -quazip/quazipfile.cpp\end{DoxyCompactItemize} diff --git a/hecl-gui/quazip/doc/latex/classQuaZipFilePrivate__coll__graph.eps b/hecl-gui/quazip/doc/latex/classQuaZipFilePrivate__coll__graph.eps deleted file mode 100644 index 1b69254f3..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaZipFilePrivate__coll__graph.eps +++ /dev/null @@ -1,414 +0,0 @@ -%!PS-Adobe-3.0 -%%Creator: graphviz version 2.28.0 (20110507.0327) -%%Title: G -%%Pages: (atend) -%%BoundingBox: (atend) -%%EndComments -save -%%BeginProlog -/DotDict 200 dict def -DotDict begin - -/setupLatin1 { -mark -/EncodingVector 256 array def - EncodingVector 0 - -ISOLatin1Encoding 0 255 getinterval putinterval -EncodingVector 45 /hyphen put - -% Set up ISO Latin 1 character encoding -/starnetISO { - dup dup findfont dup length dict begin - { 1 index /FID ne { def }{ pop pop } ifelse - } forall - /Encoding EncodingVector def - currentdict end definefont -} def -/Times-Roman starnetISO def -/Times-Italic starnetISO def -/Times-Bold starnetISO def -/Times-BoldItalic starnetISO def -/Helvetica starnetISO def -/Helvetica-Oblique starnetISO def -/Helvetica-Bold starnetISO def -/Helvetica-BoldOblique starnetISO def -/Courier starnetISO def -/Courier-Oblique starnetISO def -/Courier-Bold starnetISO def -/Courier-BoldOblique starnetISO def -cleartomark -} bind def - -%%BeginResource: procset graphviz 0 0 -/coord-font-family /Times-Roman def -/default-font-family /Times-Roman def -/coordfont coord-font-family findfont 8 scalefont def - -/InvScaleFactor 1.0 def -/set_scale { - dup 1 exch div /InvScaleFactor exch def - scale -} bind def - -% styles -/solid { [] 0 setdash } bind def -/dashed { [9 InvScaleFactor mul dup ] 0 setdash } bind def -/dotted { [1 InvScaleFactor mul 6 InvScaleFactor mul] 0 setdash } bind def -/invis {/fill {newpath} def /stroke {newpath} def /show {pop newpath} def} bind def -/bold { 2 setlinewidth } bind def -/filled { } bind def -/unfilled { } bind def -/rounded { } bind def -/diagonals { } bind def - -% hooks for setting color -/nodecolor { sethsbcolor } bind def -/edgecolor { sethsbcolor } bind def -/graphcolor { sethsbcolor } bind def -/nopcolor {pop pop pop} bind def - -/beginpage { % i j npages - /npages exch def - /j exch def - /i exch def - /str 10 string def - npages 1 gt { - gsave - coordfont setfont - 0 0 moveto - (\() show i str cvs show (,) show j str cvs show (\)) show - grestore - } if -} bind def - -/set_font { - findfont exch - scalefont setfont -} def - -% draw text fitted to its expected width -/alignedtext { % width text - /text exch def - /width exch def - gsave - width 0 gt { - [] 0 setdash - text stringwidth pop width exch sub text length div 0 text ashow - } if - grestore -} def - -/boxprim { % xcorner ycorner xsize ysize - 4 2 roll - moveto - 2 copy - exch 0 rlineto - 0 exch rlineto - pop neg 0 rlineto - closepath -} bind def - -/ellipse_path { - /ry exch def - /rx exch def - /y exch def - /x exch def - matrix currentmatrix - newpath - x y translate - rx ry scale - 0 0 1 0 360 arc - setmatrix -} bind def - -/endpage { showpage } bind def -/showpage { } def - -/layercolorseq - [ % layer color sequence - darkest to lightest - [0 0 0] - [.2 .8 .8] - [.4 .8 .8] - [.6 .8 .8] - [.8 .8 .8] - ] -def - -/layerlen layercolorseq length def - -/setlayer {/maxlayer exch def /curlayer exch def - layercolorseq curlayer 1 sub layerlen mod get - aload pop sethsbcolor - /nodecolor {nopcolor} def - /edgecolor {nopcolor} def - /graphcolor {nopcolor} def -} bind def - -/onlayer { curlayer ne {invis} if } def - -/onlayers { - /myupper exch def - /mylower exch def - curlayer mylower lt - curlayer myupper gt - or - {invis} if -} def - -/curlayer 0 def - -%%EndResource -%%EndProlog -%%BeginSetup -14 default-font-family set_font -1 setmiterlimit -% /arrowlength 10 def -% /arrowwidth 5 def - -% make sure pdfmark is harmless for PS-interpreters other than Distiller -/pdfmark where {pop} {userdict /pdfmark /cleartomark load put} ifelse -% make '<<' and '>>' safe on PS Level 1 devices -/languagelevel where {pop languagelevel}{1} ifelse -2 lt { - userdict (<<) cvn ([) cvn load put - userdict (>>) cvn ([) cvn load put -} if - -%%EndSetup -setupLatin1 -%%Page: 1 1 -%%PageBoundingBox: 36 36 231 200 -%%PageOrientation: Portrait -0 0 1 beginpage -gsave -36 36 195 164 boxprim clip newpath -1 1 set_scale 0 rotate 40 41 translate -% Node1 -gsave -0 0 0.74902 nodecolor -newpath 0 68.5 moveto -0 87.5 lineto -92 87.5 lineto -92 68.5 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath 0 68.5 moveto -0 87.5 lineto -92 87.5 lineto -92 68.5 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -8 75.5 moveto 76 (QuaZipFilePrivate) alignedtext -grestore -% Node4 -gsave -[ /Rect [ 14.5 0 77 20 ] - /Border [ 0 0 0 ] - /Action << /Subtype /URI /URI ($classQuaZipFile.html) >> - /Subtype /Link -/ANN pdfmark -0 0 1 nodecolor -newpath 14.5 .5 moveto -14.5 19.5 lineto -77.5 19.5 lineto -77.5 .5 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath 14.5 .5 moveto -14.5 19.5 lineto -77.5 19.5 lineto -77.5 .5 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -22.5 7.5 moveto 47 (QuaZipFile) alignedtext -grestore -% Node1->Node4 -gsave -1 setlinewidth -dashed -0.77647 0.75294 0.80392 edgecolor -newpath 37.93 58.6 moveto -35.99 52.14 34.78 44.79 36 38 curveto -37.13 31.7 39.63 24.95 41.85 19.78 curveto -stroke -0.77647 0.75294 0.80392 edgecolor -newpath 34.82 60.27 moveto -41.6 68.41 lineto -41.37 57.81 lineto -closepath fill -1 setlinewidth -solid -0.77647 0.75294 0.80392 edgecolor -newpath 34.82 60.27 moveto -41.6 68.41 lineto -41.37 57.81 lineto -closepath stroke -0 0 0 edgecolor -10 /Helvetica set_font -36 41.5 moveto 6 (p) alignedtext -grestore -% Node2 -gsave -[ /Rect [ 96.5 136 143 156 ] - /Border [ 0 0 0 ] - /Action << /Subtype /URI /URI ($classQuaZip.html) >> - /Subtype /Link -/ANN pdfmark -0 0 1 nodecolor -newpath 96.5 136.5 moveto -96.5 155.5 lineto -143.5 155.5 lineto -143.5 136.5 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath 96.5 136.5 moveto -96.5 155.5 lineto -143.5 155.5 lineto -143.5 136.5 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -104.5 143.5 moveto 31 (QuaZip) alignedtext -grestore -% Node2->Node1 -gsave -1 setlinewidth -dashed -0.77647 0.75294 0.80392 edgecolor -newpath 102.52 129.41 moveto -87.99 116.45 67.81 98.46 55.91 87.84 curveto -stroke -0.77647 0.75294 0.80392 edgecolor -newpath 100.53 132.33 moveto -110.33 136.37 lineto -105.19 127.1 lineto -closepath fill -1 setlinewidth -solid -0.77647 0.75294 0.80392 edgecolor -newpath 100.53 132.33 moveto -110.33 136.37 lineto -105.19 127.1 lineto -closepath stroke -0 0 0 edgecolor -10 /Helvetica set_font -90 109.5 moveto 13 (zip) alignedtext -grestore -% Node3 -gsave -[ /Rect [ 110.5 68 187 88 ] - /Border [ 0 0 0 ] - /Action << /Subtype /URI /URI ($classQuaZipPrivate.html) >> - /Subtype /Link -/ANN pdfmark -0 0 1 nodecolor -newpath 110.5 68.5 moveto -110.5 87.5 lineto -187.5 87.5 lineto -187.5 68.5 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath 110.5 68.5 moveto -110.5 87.5 lineto -187.5 87.5 lineto -187.5 68.5 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -118.5 75.5 moveto 61 (QuaZipPrivate) alignedtext -grestore -% Node2->Node3 -gsave -1 setlinewidth -dashed -0.77647 0.75294 0.80392 edgecolor -newpath 119.52 126.1 moveto -119.97 119.5 121.2 112.2 124 106 curveto -127.21 98.9 133.04 92.43 138.26 87.61 curveto -stroke -0.77647 0.75294 0.80392 edgecolor -newpath 116.02 126.17 moveto -119.35 136.23 lineto -123.02 126.29 lineto -closepath fill -1 setlinewidth -solid -0.77647 0.75294 0.80392 edgecolor -newpath 116.02 126.17 moveto -119.35 136.23 lineto -123.02 126.29 lineto -closepath stroke -0 0 0 edgecolor -10 /Helvetica set_font -124 109.5 moveto 6 (q) alignedtext -grestore -% Node3->Node2 -gsave -1 setlinewidth -dashed -0.77647 0.75294 0.80392 edgecolor -newpath 141.05 97.09 moveto -135.43 109.87 128.15 126.45 123.79 136.37 curveto -stroke -0.77647 0.75294 0.80392 edgecolor -newpath 144.3 98.4 moveto -145.12 87.84 lineto -137.89 95.59 lineto -closepath fill -1 setlinewidth -solid -0.77647 0.75294 0.80392 edgecolor -newpath 144.3 98.4 moveto -145.12 87.84 lineto -137.89 95.59 lineto -closepath stroke -0 0 0 edgecolor -10 /Helvetica set_font -138 109.5 moveto 6 (p) alignedtext -grestore -% Node4->Node1 -gsave -1 setlinewidth -dashed -0.77647 0.75294 0.80392 edgecolor -newpath 46 29.85 moveto -46 42.53 46 58.64 46 68.37 curveto -stroke -0.77647 0.75294 0.80392 edgecolor -newpath 49.5 29.84 moveto -46 19.84 lineto -42.5 29.84 lineto -closepath fill -1 setlinewidth -solid -0.77647 0.75294 0.80392 edgecolor -newpath 49.5 29.84 moveto -46 19.84 lineto -42.5 29.84 lineto -closepath stroke -0 0 0 edgecolor -10 /Helvetica set_font -46 41.5 moveto 6 (q) alignedtext -grestore -endpage -showpage -grestore -%%PageTrailer -%%EndPage: 1 -%%Trailer -%%Pages: 1 -%%BoundingBox: 36 36 231 200 -end -restore -%%EOF diff --git a/hecl-gui/quazip/doc/latex/classQuaZipFilePrivate__coll__graph.md5 b/hecl-gui/quazip/doc/latex/classQuaZipFilePrivate__coll__graph.md5 deleted file mode 100644 index 74bb2c1ec..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaZipFilePrivate__coll__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -1f8ac6d56acdc49496bc99c52404e6a3 \ No newline at end of file diff --git a/hecl-gui/quazip/doc/latex/classQuaZipFile__coll__graph.eps b/hecl-gui/quazip/doc/latex/classQuaZipFile__coll__graph.eps deleted file mode 100644 index 813051b16..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaZipFile__coll__graph.eps +++ /dev/null @@ -1,414 +0,0 @@ -%!PS-Adobe-3.0 -%%Creator: graphviz version 2.28.0 (20110507.0327) -%%Title: G -%%Pages: (atend) -%%BoundingBox: (atend) -%%EndComments -save -%%BeginProlog -/DotDict 200 dict def -DotDict begin - -/setupLatin1 { -mark -/EncodingVector 256 array def - EncodingVector 0 - -ISOLatin1Encoding 0 255 getinterval putinterval -EncodingVector 45 /hyphen put - -% Set up ISO Latin 1 character encoding -/starnetISO { - dup dup findfont dup length dict begin - { 1 index /FID ne { def }{ pop pop } ifelse - } forall - /Encoding EncodingVector def - currentdict end definefont -} def -/Times-Roman starnetISO def -/Times-Italic starnetISO def -/Times-Bold starnetISO def -/Times-BoldItalic starnetISO def -/Helvetica starnetISO def -/Helvetica-Oblique starnetISO def -/Helvetica-Bold starnetISO def -/Helvetica-BoldOblique starnetISO def -/Courier starnetISO def -/Courier-Oblique starnetISO def -/Courier-Bold starnetISO def -/Courier-BoldOblique starnetISO def -cleartomark -} bind def - -%%BeginResource: procset graphviz 0 0 -/coord-font-family /Times-Roman def -/default-font-family /Times-Roman def -/coordfont coord-font-family findfont 8 scalefont def - -/InvScaleFactor 1.0 def -/set_scale { - dup 1 exch div /InvScaleFactor exch def - scale -} bind def - -% styles -/solid { [] 0 setdash } bind def -/dashed { [9 InvScaleFactor mul dup ] 0 setdash } bind def -/dotted { [1 InvScaleFactor mul 6 InvScaleFactor mul] 0 setdash } bind def -/invis {/fill {newpath} def /stroke {newpath} def /show {pop newpath} def} bind def -/bold { 2 setlinewidth } bind def -/filled { } bind def -/unfilled { } bind def -/rounded { } bind def -/diagonals { } bind def - -% hooks for setting color -/nodecolor { sethsbcolor } bind def -/edgecolor { sethsbcolor } bind def -/graphcolor { sethsbcolor } bind def -/nopcolor {pop pop pop} bind def - -/beginpage { % i j npages - /npages exch def - /j exch def - /i exch def - /str 10 string def - npages 1 gt { - gsave - coordfont setfont - 0 0 moveto - (\() show i str cvs show (,) show j str cvs show (\)) show - grestore - } if -} bind def - -/set_font { - findfont exch - scalefont setfont -} def - -% draw text fitted to its expected width -/alignedtext { % width text - /text exch def - /width exch def - gsave - width 0 gt { - [] 0 setdash - text stringwidth pop width exch sub text length div 0 text ashow - } if - grestore -} def - -/boxprim { % xcorner ycorner xsize ysize - 4 2 roll - moveto - 2 copy - exch 0 rlineto - 0 exch rlineto - pop neg 0 rlineto - closepath -} bind def - -/ellipse_path { - /ry exch def - /rx exch def - /y exch def - /x exch def - matrix currentmatrix - newpath - x y translate - rx ry scale - 0 0 1 0 360 arc - setmatrix -} bind def - -/endpage { showpage } bind def -/showpage { } def - -/layercolorseq - [ % layer color sequence - darkest to lightest - [0 0 0] - [.2 .8 .8] - [.4 .8 .8] - [.6 .8 .8] - [.8 .8 .8] - ] -def - -/layerlen layercolorseq length def - -/setlayer {/maxlayer exch def /curlayer exch def - layercolorseq curlayer 1 sub layerlen mod get - aload pop sethsbcolor - /nodecolor {nopcolor} def - /edgecolor {nopcolor} def - /graphcolor {nopcolor} def -} bind def - -/onlayer { curlayer ne {invis} if } def - -/onlayers { - /myupper exch def - /mylower exch def - curlayer mylower lt - curlayer myupper gt - or - {invis} if -} def - -/curlayer 0 def - -%%EndResource -%%EndProlog -%%BeginSetup -14 default-font-family set_font -1 setmiterlimit -% /arrowlength 10 def -% /arrowwidth 5 def - -% make sure pdfmark is harmless for PS-interpreters other than Distiller -/pdfmark where {pop} {userdict /pdfmark /cleartomark load put} ifelse -% make '<<' and '>>' safe on PS Level 1 devices -/languagelevel where {pop languagelevel}{1} ifelse -2 lt { - userdict (<<) cvn ([) cvn load put - userdict (>>) cvn ([) cvn load put -} if - -%%EndSetup -setupLatin1 -%%Page: 1 1 -%%PageBoundingBox: 36 36 231 132 -%%PageOrientation: Portrait -0 0 1 beginpage -gsave -36 36 195 96 boxprim clip newpath -1 1 set_scale 0 rotate 40 41 translate -% Node1 -gsave -0 0 0.74902 nodecolor -newpath 2.5 68.5 moveto -2.5 87.5 lineto -65.5 87.5 lineto -65.5 68.5 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath 2.5 68.5 moveto -2.5 87.5 lineto -65.5 87.5 lineto -65.5 68.5 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -10.5 75.5 moveto 47 (QuaZipFile) alignedtext -grestore -% Node2 -gsave -[ /Rect [ 0 0 92 20 ] - /Border [ 0 0 0 ] - /Action << /Subtype /URI /URI ($classQuaZipFilePrivate.html) >> - /Subtype /Link -/ANN pdfmark -0 0 1 nodecolor -newpath 0 .5 moveto -0 19.5 lineto -92 19.5 lineto -92 .5 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath 0 .5 moveto -0 19.5 lineto -92 19.5 lineto -92 .5 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -8 7.5 moveto 76 (QuaZipFilePrivate) alignedtext -grestore -% Node1->Node2 -gsave -1 setlinewidth -dashed -0.77647 0.75294 0.80392 edgecolor -newpath 28.58 58.5 moveto -27.46 51.93 27.11 44.55 29 38 curveto -30.9 31.4 34.95 24.86 38.62 19.87 curveto -stroke -0.77647 0.75294 0.80392 edgecolor -newpath 25.24 59.56 moveto -30.96 68.48 lineto -32.05 57.94 lineto -closepath fill -1 setlinewidth -solid -0.77647 0.75294 0.80392 edgecolor -newpath 25.24 59.56 moveto -30.96 68.48 lineto -32.05 57.94 lineto -closepath stroke -0 0 0 edgecolor -10 /Helvetica set_font -29 41.5 moveto 6 (q) alignedtext -grestore -% Node2->Node1 -gsave -1 setlinewidth -dashed -0.77647 0.75294 0.80392 edgecolor -newpath 42.57 29.85 moveto -40.27 42.53 37.34 58.64 35.57 68.37 curveto -stroke -0.77647 0.75294 0.80392 edgecolor -newpath 46.05 30.31 moveto -44.39 19.84 lineto -39.16 29.05 lineto -closepath fill -1 setlinewidth -solid -0.77647 0.75294 0.80392 edgecolor -newpath 46.05 30.31 moveto -44.39 19.84 lineto -39.16 29.05 lineto -closepath stroke -0 0 0 edgecolor -10 /Helvetica set_font -42 41.5 moveto 6 (p) alignedtext -grestore -% Node3 -gsave -[ /Rect [ 96.5 68 143 88 ] - /Border [ 0 0 0 ] - /Action << /Subtype /URI /URI ($classQuaZip.html) >> - /Subtype /Link -/ANN pdfmark -0 0 1 nodecolor -newpath 96.5 68.5 moveto -96.5 87.5 lineto -143.5 87.5 lineto -143.5 68.5 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath 96.5 68.5 moveto -96.5 87.5 lineto -143.5 87.5 lineto -143.5 68.5 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -104.5 75.5 moveto 31 (QuaZip) alignedtext -grestore -% Node3->Node2 -gsave -1 setlinewidth -dashed -0.77647 0.75294 0.80392 edgecolor -newpath 102.52 61.41 moveto -87.99 48.45 67.81 30.46 55.91 19.84 curveto -stroke -0.77647 0.75294 0.80392 edgecolor -newpath 100.53 64.33 moveto -110.33 68.37 lineto -105.19 59.1 lineto -closepath fill -1 setlinewidth -solid -0.77647 0.75294 0.80392 edgecolor -newpath 100.53 64.33 moveto -110.33 68.37 lineto -105.19 59.1 lineto -closepath stroke -0 0 0 edgecolor -10 /Helvetica set_font -90 41.5 moveto 13 (zip) alignedtext -grestore -% Node4 -gsave -[ /Rect [ 110.5 0 187 20 ] - /Border [ 0 0 0 ] - /Action << /Subtype /URI /URI ($classQuaZipPrivate.html) >> - /Subtype /Link -/ANN pdfmark -0 0 1 nodecolor -newpath 110.5 .5 moveto -110.5 19.5 lineto -187.5 19.5 lineto -187.5 .5 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath 110.5 .5 moveto -110.5 19.5 lineto -187.5 19.5 lineto -187.5 .5 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -118.5 7.5 moveto 61 (QuaZipPrivate) alignedtext -grestore -% Node3->Node4 -gsave -1 setlinewidth -dashed -0.77647 0.75294 0.80392 edgecolor -newpath 119.52 58.1 moveto -119.97 51.5 121.2 44.2 124 38 curveto -127.21 30.9 133.04 24.43 138.26 19.61 curveto -stroke -0.77647 0.75294 0.80392 edgecolor -newpath 116.02 58.17 moveto -119.35 68.23 lineto -123.02 58.29 lineto -closepath fill -1 setlinewidth -solid -0.77647 0.75294 0.80392 edgecolor -newpath 116.02 58.17 moveto -119.35 68.23 lineto -123.02 58.29 lineto -closepath stroke -0 0 0 edgecolor -10 /Helvetica set_font -124 41.5 moveto 6 (q) alignedtext -grestore -% Node4->Node3 -gsave -1 setlinewidth -dashed -0.77647 0.75294 0.80392 edgecolor -newpath 141.05 29.09 moveto -135.43 41.87 128.15 58.45 123.79 68.37 curveto -stroke -0.77647 0.75294 0.80392 edgecolor -newpath 144.3 30.4 moveto -145.12 19.84 lineto -137.89 27.59 lineto -closepath fill -1 setlinewidth -solid -0.77647 0.75294 0.80392 edgecolor -newpath 144.3 30.4 moveto -145.12 19.84 lineto -137.89 27.59 lineto -closepath stroke -0 0 0 edgecolor -10 /Helvetica set_font -138 41.5 moveto 6 (p) alignedtext -grestore -endpage -showpage -grestore -%%PageTrailer -%%EndPage: 1 -%%Trailer -%%Pages: 1 -%%BoundingBox: 36 36 231 132 -end -restore -%%EOF diff --git a/hecl-gui/quazip/doc/latex/classQuaZipFile__coll__graph.md5 b/hecl-gui/quazip/doc/latex/classQuaZipFile__coll__graph.md5 deleted file mode 100644 index 7db5e126b..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaZipFile__coll__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -d4c12e105f1f89650e643227b7eb6b67 \ No newline at end of file diff --git a/hecl-gui/quazip/doc/latex/classQuaZipPrivate.tex b/hecl-gui/quazip/doc/latex/classQuaZipPrivate.tex deleted file mode 100644 index 452b38383..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaZipPrivate.tex +++ /dev/null @@ -1,31 +0,0 @@ -\section{QuaZipPrivate Class Reference} -\label{classQuaZipPrivate}\index{QuaZipPrivate@{QuaZipPrivate}} - - -All the internal stuff for the \doxyref{QuaZip}{p.}{classQuaZip} class. - - - - -Collaboration diagram for QuaZipPrivate: -\nopagebreak -\begin{figure}[H] -\begin{center} -\leavevmode -\includegraphics[width=120pt]{classQuaZipPrivate__coll__graph} -\end{center} -\end{figure} -\subsection*{Friends} -\begin{DoxyCompactItemize} -\item -class {\bf QuaZip}\label{classQuaZipPrivate_a913fb7bbd3527119ebb8052d57132af2} - -\end{DoxyCompactItemize} - - -\subsection{Detailed Description} -All the internal stuff for the \doxyref{QuaZip}{p.}{classQuaZip} class. - -The documentation for this class was generated from the following file:\begin{DoxyCompactItemize} -\item -quazip/quazip.cpp\end{DoxyCompactItemize} diff --git a/hecl-gui/quazip/doc/latex/classQuaZipPrivate__coll__graph.eps b/hecl-gui/quazip/doc/latex/classQuaZipPrivate__coll__graph.eps deleted file mode 100644 index f9f939f12..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaZipPrivate__coll__graph.eps +++ /dev/null @@ -1,291 +0,0 @@ -%!PS-Adobe-3.0 -%%Creator: graphviz version 2.28.0 (20110507.0327) -%%Title: G -%%Pages: (atend) -%%BoundingBox: (atend) -%%EndComments -save -%%BeginProlog -/DotDict 200 dict def -DotDict begin - -/setupLatin1 { -mark -/EncodingVector 256 array def - EncodingVector 0 - -ISOLatin1Encoding 0 255 getinterval putinterval -EncodingVector 45 /hyphen put - -% Set up ISO Latin 1 character encoding -/starnetISO { - dup dup findfont dup length dict begin - { 1 index /FID ne { def }{ pop pop } ifelse - } forall - /Encoding EncodingVector def - currentdict end definefont -} def -/Times-Roman starnetISO def -/Times-Italic starnetISO def -/Times-Bold starnetISO def -/Times-BoldItalic starnetISO def -/Helvetica starnetISO def -/Helvetica-Oblique starnetISO def -/Helvetica-Bold starnetISO def -/Helvetica-BoldOblique starnetISO def -/Courier starnetISO def -/Courier-Oblique starnetISO def -/Courier-Bold starnetISO def -/Courier-BoldOblique starnetISO def -cleartomark -} bind def - -%%BeginResource: procset graphviz 0 0 -/coord-font-family /Times-Roman def -/default-font-family /Times-Roman def -/coordfont coord-font-family findfont 8 scalefont def - -/InvScaleFactor 1.0 def -/set_scale { - dup 1 exch div /InvScaleFactor exch def - scale -} bind def - -% styles -/solid { [] 0 setdash } bind def -/dashed { [9 InvScaleFactor mul dup ] 0 setdash } bind def -/dotted { [1 InvScaleFactor mul 6 InvScaleFactor mul] 0 setdash } bind def -/invis {/fill {newpath} def /stroke {newpath} def /show {pop newpath} def} bind def -/bold { 2 setlinewidth } bind def -/filled { } bind def -/unfilled { } bind def -/rounded { } bind def -/diagonals { } bind def - -% hooks for setting color -/nodecolor { sethsbcolor } bind def -/edgecolor { sethsbcolor } bind def -/graphcolor { sethsbcolor } bind def -/nopcolor {pop pop pop} bind def - -/beginpage { % i j npages - /npages exch def - /j exch def - /i exch def - /str 10 string def - npages 1 gt { - gsave - coordfont setfont - 0 0 moveto - (\() show i str cvs show (,) show j str cvs show (\)) show - grestore - } if -} bind def - -/set_font { - findfont exch - scalefont setfont -} def - -% draw text fitted to its expected width -/alignedtext { % width text - /text exch def - /width exch def - gsave - width 0 gt { - [] 0 setdash - text stringwidth pop width exch sub text length div 0 text ashow - } if - grestore -} def - -/boxprim { % xcorner ycorner xsize ysize - 4 2 roll - moveto - 2 copy - exch 0 rlineto - 0 exch rlineto - pop neg 0 rlineto - closepath -} bind def - -/ellipse_path { - /ry exch def - /rx exch def - /y exch def - /x exch def - matrix currentmatrix - newpath - x y translate - rx ry scale - 0 0 1 0 360 arc - setmatrix -} bind def - -/endpage { showpage } bind def -/showpage { } def - -/layercolorseq - [ % layer color sequence - darkest to lightest - [0 0 0] - [.2 .8 .8] - [.4 .8 .8] - [.6 .8 .8] - [.8 .8 .8] - ] -def - -/layerlen layercolorseq length def - -/setlayer {/maxlayer exch def /curlayer exch def - layercolorseq curlayer 1 sub layerlen mod get - aload pop sethsbcolor - /nodecolor {nopcolor} def - /edgecolor {nopcolor} def - /graphcolor {nopcolor} def -} bind def - -/onlayer { curlayer ne {invis} if } def - -/onlayers { - /myupper exch def - /mylower exch def - curlayer mylower lt - curlayer myupper gt - or - {invis} if -} def - -/curlayer 0 def - -%%EndResource -%%EndProlog -%%BeginSetup -14 default-font-family set_font -1 setmiterlimit -% /arrowlength 10 def -% /arrowwidth 5 def - -% make sure pdfmark is harmless for PS-interpreters other than Distiller -/pdfmark where {pop} {userdict /pdfmark /cleartomark load put} ifelse -% make '<<' and '>>' safe on PS Level 1 devices -/languagelevel where {pop languagelevel}{1} ifelse -2 lt { - userdict (<<) cvn ([) cvn load put - userdict (>>) cvn ([) cvn load put -} if - -%%EndSetup -setupLatin1 -%%Page: 1 1 -%%PageBoundingBox: 36 36 120 132 -%%PageOrientation: Portrait -0 0 1 beginpage -gsave -36 36 84 96 boxprim clip newpath -1 1 set_scale 0 rotate 40 41 translate -% Node1 -gsave -0 0 0.74902 nodecolor -newpath -.5 68.5 moveto --.5 87.5 lineto -76.5 87.5 lineto -76.5 68.5 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath -.5 68.5 moveto --.5 87.5 lineto -76.5 87.5 lineto -76.5 68.5 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -7.5 75.5 moveto 61 (QuaZipPrivate) alignedtext -grestore -% Node2 -gsave -[ /Rect [ 14.5 0 61 20 ] - /Border [ 0 0 0 ] - /Action << /Subtype /URI /URI ($classQuaZip.html) >> - /Subtype /Link -/ANN pdfmark -0 0 1 nodecolor -newpath 14.5 .5 moveto -14.5 19.5 lineto -61.5 19.5 lineto -61.5 .5 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath 14.5 .5 moveto -14.5 19.5 lineto -61.5 19.5 lineto -61.5 .5 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -22.5 7.5 moveto 31 (QuaZip) alignedtext -grestore -% Node1->Node2 -gsave -1 setlinewidth -dashed -0.77647 0.75294 0.80392 edgecolor -newpath 30.23 58.65 moveto -29.3 55.8 28.51 52.85 28 50 curveto -26.1 39.4 30.11 27.44 33.6 19.59 curveto -stroke -0.77647 0.75294 0.80392 edgecolor -newpath 27.03 60.11 moveto -33.85 68.22 lineto -33.58 57.63 lineto -closepath fill -1 setlinewidth -solid -0.77647 0.75294 0.80392 edgecolor -newpath 27.03 60.11 moveto -33.85 68.22 lineto -33.58 57.63 lineto -closepath stroke -0 0 0 edgecolor -10 /Helvetica set_font -28 41.5 moveto 6 (p) alignedtext -grestore -% Node2->Node1 -gsave -1 setlinewidth -dashed -0.77647 0.75294 0.80392 edgecolor -newpath 38 29.85 moveto -38 42.53 38 58.64 38 68.37 curveto -stroke -0.77647 0.75294 0.80392 edgecolor -newpath 41.5 29.84 moveto -38 19.84 lineto -34.5 29.84 lineto -closepath fill -1 setlinewidth -solid -0.77647 0.75294 0.80392 edgecolor -newpath 41.5 29.84 moveto -38 19.84 lineto -34.5 29.84 lineto -closepath stroke -0 0 0 edgecolor -10 /Helvetica set_font -38 41.5 moveto 6 (q) alignedtext -grestore -endpage -showpage -grestore -%%PageTrailer -%%EndPage: 1 -%%Trailer -%%Pages: 1 -%%BoundingBox: 36 36 120 132 -end -restore -%%EOF diff --git a/hecl-gui/quazip/doc/latex/classQuaZipPrivate__coll__graph.md5 b/hecl-gui/quazip/doc/latex/classQuaZipPrivate__coll__graph.md5 deleted file mode 100644 index 04f81a03f..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaZipPrivate__coll__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -03e89dfdd147054460a64a46c1bdc9c2 \ No newline at end of file diff --git a/hecl-gui/quazip/doc/latex/classQuaZip__coll__graph.eps b/hecl-gui/quazip/doc/latex/classQuaZip__coll__graph.eps deleted file mode 100644 index ede81572f..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaZip__coll__graph.eps +++ /dev/null @@ -1,291 +0,0 @@ -%!PS-Adobe-3.0 -%%Creator: graphviz version 2.28.0 (20110507.0327) -%%Title: G -%%Pages: (atend) -%%BoundingBox: (atend) -%%EndComments -save -%%BeginProlog -/DotDict 200 dict def -DotDict begin - -/setupLatin1 { -mark -/EncodingVector 256 array def - EncodingVector 0 - -ISOLatin1Encoding 0 255 getinterval putinterval -EncodingVector 45 /hyphen put - -% Set up ISO Latin 1 character encoding -/starnetISO { - dup dup findfont dup length dict begin - { 1 index /FID ne { def }{ pop pop } ifelse - } forall - /Encoding EncodingVector def - currentdict end definefont -} def -/Times-Roman starnetISO def -/Times-Italic starnetISO def -/Times-Bold starnetISO def -/Times-BoldItalic starnetISO def -/Helvetica starnetISO def -/Helvetica-Oblique starnetISO def -/Helvetica-Bold starnetISO def -/Helvetica-BoldOblique starnetISO def -/Courier starnetISO def -/Courier-Oblique starnetISO def -/Courier-Bold starnetISO def -/Courier-BoldOblique starnetISO def -cleartomark -} bind def - -%%BeginResource: procset graphviz 0 0 -/coord-font-family /Times-Roman def -/default-font-family /Times-Roman def -/coordfont coord-font-family findfont 8 scalefont def - -/InvScaleFactor 1.0 def -/set_scale { - dup 1 exch div /InvScaleFactor exch def - scale -} bind def - -% styles -/solid { [] 0 setdash } bind def -/dashed { [9 InvScaleFactor mul dup ] 0 setdash } bind def -/dotted { [1 InvScaleFactor mul 6 InvScaleFactor mul] 0 setdash } bind def -/invis {/fill {newpath} def /stroke {newpath} def /show {pop newpath} def} bind def -/bold { 2 setlinewidth } bind def -/filled { } bind def -/unfilled { } bind def -/rounded { } bind def -/diagonals { } bind def - -% hooks for setting color -/nodecolor { sethsbcolor } bind def -/edgecolor { sethsbcolor } bind def -/graphcolor { sethsbcolor } bind def -/nopcolor {pop pop pop} bind def - -/beginpage { % i j npages - /npages exch def - /j exch def - /i exch def - /str 10 string def - npages 1 gt { - gsave - coordfont setfont - 0 0 moveto - (\() show i str cvs show (,) show j str cvs show (\)) show - grestore - } if -} bind def - -/set_font { - findfont exch - scalefont setfont -} def - -% draw text fitted to its expected width -/alignedtext { % width text - /text exch def - /width exch def - gsave - width 0 gt { - [] 0 setdash - text stringwidth pop width exch sub text length div 0 text ashow - } if - grestore -} def - -/boxprim { % xcorner ycorner xsize ysize - 4 2 roll - moveto - 2 copy - exch 0 rlineto - 0 exch rlineto - pop neg 0 rlineto - closepath -} bind def - -/ellipse_path { - /ry exch def - /rx exch def - /y exch def - /x exch def - matrix currentmatrix - newpath - x y translate - rx ry scale - 0 0 1 0 360 arc - setmatrix -} bind def - -/endpage { showpage } bind def -/showpage { } def - -/layercolorseq - [ % layer color sequence - darkest to lightest - [0 0 0] - [.2 .8 .8] - [.4 .8 .8] - [.6 .8 .8] - [.8 .8 .8] - ] -def - -/layerlen layercolorseq length def - -/setlayer {/maxlayer exch def /curlayer exch def - layercolorseq curlayer 1 sub layerlen mod get - aload pop sethsbcolor - /nodecolor {nopcolor} def - /edgecolor {nopcolor} def - /graphcolor {nopcolor} def -} bind def - -/onlayer { curlayer ne {invis} if } def - -/onlayers { - /myupper exch def - /mylower exch def - curlayer mylower lt - curlayer myupper gt - or - {invis} if -} def - -/curlayer 0 def - -%%EndResource -%%EndProlog -%%BeginSetup -14 default-font-family set_font -1 setmiterlimit -% /arrowlength 10 def -% /arrowwidth 5 def - -% make sure pdfmark is harmless for PS-interpreters other than Distiller -/pdfmark where {pop} {userdict /pdfmark /cleartomark load put} ifelse -% make '<<' and '>>' safe on PS Level 1 devices -/languagelevel where {pop languagelevel}{1} ifelse -2 lt { - userdict (<<) cvn ([) cvn load put - userdict (>>) cvn ([) cvn load put -} if - -%%EndSetup -setupLatin1 -%%Page: 1 1 -%%PageBoundingBox: 36 36 120 132 -%%PageOrientation: Portrait -0 0 1 beginpage -gsave -36 36 84 96 boxprim clip newpath -1 1 set_scale 0 rotate 40 41 translate -% Node1 -gsave -0 0 0.74902 nodecolor -newpath 14.5 68.5 moveto -14.5 87.5 lineto -61.5 87.5 lineto -61.5 68.5 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath 14.5 68.5 moveto -14.5 87.5 lineto -61.5 87.5 lineto -61.5 68.5 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -22.5 75.5 moveto 31 (QuaZip) alignedtext -grestore -% Node2 -gsave -[ /Rect [ -.5 0 76 20 ] - /Border [ 0 0 0 ] - /Action << /Subtype /URI /URI ($classQuaZipPrivate.html) >> - /Subtype /Link -/ANN pdfmark -0 0 1 nodecolor -newpath -.5 .5 moveto --.5 19.5 lineto -76.5 19.5 lineto -76.5 .5 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath -.5 .5 moveto --.5 19.5 lineto -76.5 19.5 lineto -76.5 .5 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -7.5 7.5 moveto 61 (QuaZipPrivate) alignedtext -grestore -% Node1->Node2 -gsave -1 setlinewidth -dashed -0.77647 0.75294 0.80392 edgecolor -newpath 30.23 58.65 moveto -29.3 55.8 28.51 52.85 28 50 curveto -26.1 39.4 30.11 27.44 33.6 19.59 curveto -stroke -0.77647 0.75294 0.80392 edgecolor -newpath 27.03 60.11 moveto -33.85 68.22 lineto -33.58 57.63 lineto -closepath fill -1 setlinewidth -solid -0.77647 0.75294 0.80392 edgecolor -newpath 27.03 60.11 moveto -33.85 68.22 lineto -33.58 57.63 lineto -closepath stroke -0 0 0 edgecolor -10 /Helvetica set_font -28 41.5 moveto 6 (q) alignedtext -grestore -% Node2->Node1 -gsave -1 setlinewidth -dashed -0.77647 0.75294 0.80392 edgecolor -newpath 38 29.85 moveto -38 42.53 38 58.64 38 68.37 curveto -stroke -0.77647 0.75294 0.80392 edgecolor -newpath 41.5 29.84 moveto -38 19.84 lineto -34.5 29.84 lineto -closepath fill -1 setlinewidth -solid -0.77647 0.75294 0.80392 edgecolor -newpath 41.5 29.84 moveto -38 19.84 lineto -34.5 29.84 lineto -closepath stroke -0 0 0 edgecolor -10 /Helvetica set_font -38 41.5 moveto 6 (p) alignedtext -grestore -endpage -showpage -grestore -%%PageTrailer -%%EndPage: 1 -%%Trailer -%%Pages: 1 -%%BoundingBox: 36 36 120 132 -end -restore -%%EOF diff --git a/hecl-gui/quazip/doc/latex/classQuaZip__coll__graph.md5 b/hecl-gui/quazip/doc/latex/classQuaZip__coll__graph.md5 deleted file mode 100644 index 303660b1a..000000000 --- a/hecl-gui/quazip/doc/latex/classQuaZip__coll__graph.md5 +++ /dev/null @@ -1 +0,0 @@ -285ae05030356ab7fd5c5be4e423dbb5 \ No newline at end of file diff --git a/hecl-gui/quazip/doc/latex/dir_63f4af0f6084a51244f9f3a16a2e698d.tex b/hecl-gui/quazip/doc/latex/dir_63f4af0f6084a51244f9f3a16a2e698d.tex deleted file mode 100644 index c9139bf14..000000000 --- a/hecl-gui/quazip/doc/latex/dir_63f4af0f6084a51244f9f3a16a2e698d.tex +++ /dev/null @@ -1,59 +0,0 @@ -\section{quazip/ Directory Reference} -\label{dir_63f4af0f6084a51244f9f3a16a2e698d}\index{quazip/ Directory Reference@{quazip/ Directory Reference}} -Directory dependency graph for quazip/: -\nopagebreak -\begin{figure}[H] -\begin{center} -\leavevmode -\includegraphics[width=98pt]{dir_63f4af0f6084a51244f9f3a16a2e698d_dep} -\end{center} -\end{figure} -\subsection*{Files} -\begin{DoxyCompactItemize} -\item -file {\bfseries JlCompress.cpp} -\item -file {\bfseries JlCompress.h} -\item -file {\bfseries qioapi.cpp} -\item -file {\bfseries quaadler32.cpp} -\item -file {\bfseries quaadler32.h} -\item -file {\bfseries quachecksum32.h} -\item -file {\bfseries quacrc32.cpp} -\item -file {\bfseries quacrc32.h} -\item -file {\bfseries quagzipfile.cpp} -\item -file {\bfseries quagzipfile.h} -\item -file {\bfseries quaziodevice.cpp} -\item -file {\bfseries quaziodevice.h} -\item -file {\bfseries quazip.cpp} -\item -file {\bfseries quazip.h} -\item -file {\bfseries quazip\_\-global.h} -\item -file {\bfseries quazipdir.cpp} -\item -file {\bfseries quazipdir.h} -\item -file {\bfseries quazipfile.cpp} -\item -file {\bfseries quazipfile.h} -\item -file {\bfseries quazipfileinfo.cpp} -\item -file {\bfseries quazipfileinfo.h} -\item -file {\bfseries quazipnewinfo.cpp} -\item -file {\bfseries quazipnewinfo.h} -\end{DoxyCompactItemize} diff --git a/hecl-gui/quazip/doc/latex/dir_63f4af0f6084a51244f9f3a16a2e698d_dep.eps b/hecl-gui/quazip/doc/latex/dir_63f4af0f6084a51244f9f3a16a2e698d_dep.eps deleted file mode 100644 index 30d2b8e46..000000000 --- a/hecl-gui/quazip/doc/latex/dir_63f4af0f6084a51244f9f3a16a2e698d_dep.eps +++ /dev/null @@ -1,222 +0,0 @@ -%!PS-Adobe-3.0 -%%Creator: graphviz version 2.28.0 (20110507.0327) -%%Title: G -%%Pages: (atend) -%%BoundingBox: (atend) -%%EndComments -save -%%BeginProlog -/DotDict 200 dict def -DotDict begin - -/setupLatin1 { -mark -/EncodingVector 256 array def - EncodingVector 0 - -ISOLatin1Encoding 0 255 getinterval putinterval -EncodingVector 45 /hyphen put - -% Set up ISO Latin 1 character encoding -/starnetISO { - dup dup findfont dup length dict begin - { 1 index /FID ne { def }{ pop pop } ifelse - } forall - /Encoding EncodingVector def - currentdict end definefont -} def -/Times-Roman starnetISO def -/Times-Italic starnetISO def -/Times-Bold starnetISO def -/Times-BoldItalic starnetISO def -/Helvetica starnetISO def -/Helvetica-Oblique starnetISO def -/Helvetica-Bold starnetISO def -/Helvetica-BoldOblique starnetISO def -/Courier starnetISO def -/Courier-Oblique starnetISO def -/Courier-Bold starnetISO def -/Courier-BoldOblique starnetISO def -cleartomark -} bind def - -%%BeginResource: procset graphviz 0 0 -/coord-font-family /Times-Roman def -/default-font-family /Times-Roman def -/coordfont coord-font-family findfont 8 scalefont def - -/InvScaleFactor 1.0 def -/set_scale { - dup 1 exch div /InvScaleFactor exch def - scale -} bind def - -% styles -/solid { [] 0 setdash } bind def -/dashed { [9 InvScaleFactor mul dup ] 0 setdash } bind def -/dotted { [1 InvScaleFactor mul 6 InvScaleFactor mul] 0 setdash } bind def -/invis {/fill {newpath} def /stroke {newpath} def /show {pop newpath} def} bind def -/bold { 2 setlinewidth } bind def -/filled { } bind def -/unfilled { } bind def -/rounded { } bind def -/diagonals { } bind def - -% hooks for setting color -/nodecolor { sethsbcolor } bind def -/edgecolor { sethsbcolor } bind def -/graphcolor { sethsbcolor } bind def -/nopcolor {pop pop pop} bind def - -/beginpage { % i j npages - /npages exch def - /j exch def - /i exch def - /str 10 string def - npages 1 gt { - gsave - coordfont setfont - 0 0 moveto - (\() show i str cvs show (,) show j str cvs show (\)) show - grestore - } if -} bind def - -/set_font { - findfont exch - scalefont setfont -} def - -% draw text fitted to its expected width -/alignedtext { % width text - /text exch def - /width exch def - gsave - width 0 gt { - [] 0 setdash - text stringwidth pop width exch sub text length div 0 text ashow - } if - grestore -} def - -/boxprim { % xcorner ycorner xsize ysize - 4 2 roll - moveto - 2 copy - exch 0 rlineto - 0 exch rlineto - pop neg 0 rlineto - closepath -} bind def - -/ellipse_path { - /ry exch def - /rx exch def - /y exch def - /x exch def - matrix currentmatrix - newpath - x y translate - rx ry scale - 0 0 1 0 360 arc - setmatrix -} bind def - -/endpage { showpage } bind def -/showpage { } def - -/layercolorseq - [ % layer color sequence - darkest to lightest - [0 0 0] - [.2 .8 .8] - [.4 .8 .8] - [.6 .8 .8] - [.8 .8 .8] - ] -def - -/layerlen layercolorseq length def - -/setlayer {/maxlayer exch def /curlayer exch def - layercolorseq curlayer 1 sub layerlen mod get - aload pop sethsbcolor - /nodecolor {nopcolor} def - /edgecolor {nopcolor} def - /graphcolor {nopcolor} def -} bind def - -/onlayer { curlayer ne {invis} if } def - -/onlayers { - /myupper exch def - /mylower exch def - curlayer mylower lt - curlayer myupper gt - or - {invis} if -} def - -/curlayer 0 def - -%%EndResource -%%EndProlog -%%BeginSetup -14 default-font-family set_font -1 setmiterlimit -% /arrowlength 10 def -% /arrowwidth 5 def - -% make sure pdfmark is harmless for PS-interpreters other than Distiller -/pdfmark where {pop} {userdict /pdfmark /cleartomark load put} ifelse -% make '<<' and '>>' safe on PS Level 1 devices -/languagelevel where {pop languagelevel}{1} ifelse -2 lt { - userdict (<<) cvn ([) cvn load put - userdict (>>) cvn ([) cvn load put -} if - -%%EndSetup -setupLatin1 -%%Page: 1 1 -%%PageBoundingBox: 36 36 98 80 -%%PageOrientation: Portrait -0 0 1 beginpage -gsave -36 36 62 44 boxprim clip newpath -1 1 set_scale 0 rotate 40 41 translate -% dir_63f4af0f6084a51244f9f3a16a2e698d -gsave -[ /Rect [ 0 0 54 36 ] - /Border [ 0 0 0 ] - /Action << /Subtype /URI /URI (dir_63f4af0f6084a51244f9f3a16a2e698d.html) >> - /Subtype /Link -/ANN pdfmark -0.66667 0.066667 1 nodecolor -newpath 54 36 moveto -0 36 lineto -0 0 lineto -54 0 lineto -closepath fill -1 setlinewidth -filled -0 0 0 nodecolor -newpath 54 36 moveto -0 36 lineto -0 0 lineto -54 0 lineto -closepath stroke -0 0 0 nodecolor -10 /Helvetica set_font -12.5 15.5 moveto 29 (quazip) alignedtext -grestore -endpage -showpage -grestore -%%PageTrailer -%%EndPage: 1 -%%Trailer -%%Pages: 1 -%%BoundingBox: 36 36 98 80 -end -restore -%%EOF diff --git a/hecl-gui/quazip/doc/latex/dir_63f4af0f6084a51244f9f3a16a2e698d_dep.md5 b/hecl-gui/quazip/doc/latex/dir_63f4af0f6084a51244f9f3a16a2e698d_dep.md5 deleted file mode 100644 index 987fe35a4..000000000 --- a/hecl-gui/quazip/doc/latex/dir_63f4af0f6084a51244f9f3a16a2e698d_dep.md5 +++ /dev/null @@ -1 +0,0 @@ -68fb1d4fbd418e78b1d377097ebdf8bb \ No newline at end of file diff --git a/hecl-gui/quazip/doc/latex/dirs.tex b/hecl-gui/quazip/doc/latex/dirs.tex deleted file mode 100644 index 16346b8a3..000000000 --- a/hecl-gui/quazip/doc/latex/dirs.tex +++ /dev/null @@ -1,4 +0,0 @@ -\section{Directories} -This directory hierarchy is sorted roughly, but not completely, alphabetically:\begin{DoxyCompactList} -\item \contentsline{section}{quazip}{\pageref{dir_63f4af0f6084a51244f9f3a16a2e698d}}{} -\end{DoxyCompactList} diff --git a/hecl-gui/quazip/doc/latex/doxygen.sty b/hecl-gui/quazip/doc/latex/doxygen.sty deleted file mode 100644 index 3c6903d4f..000000000 --- a/hecl-gui/quazip/doc/latex/doxygen.sty +++ /dev/null @@ -1,416 +0,0 @@ -\NeedsTeXFormat{LaTeX2e} -\ProvidesPackage{doxygen} - -% Packages used by this style file -\RequirePackage{alltt} -\RequirePackage{array} -\RequirePackage{calc} -\RequirePackage{color} -\RequirePackage{fancyhdr} -\RequirePackage{longtable} -\RequirePackage{verbatim} -\RequirePackage{ifthen} -\RequirePackage[table]{xcolor} - -% Use helvetica font instead of times roman -\RequirePackage{helvet} -\RequirePackage{sectsty} -\RequirePackage{tocloft} -\providecommand{\rmdefault}{phv} -\providecommand{\bfdefault}{bc} - - -% Setup fancy headings -\pagestyle{fancyplain} -\newcommand{\clearemptydoublepage}{% - \newpage{\pagestyle{empty}\cleardoublepage}% -} -\renewcommand{\chaptermark}[1]{% - \markboth{#1}{}% -} -\renewcommand{\sectionmark}[1]{% - \markright{\thesection\ #1}% -} -\fancyhead[LE]{\fancyplain{}{\bfseries\thepage}} -\fancyhead[CE]{\fancyplain{}{}} -\fancyhead[RE]{\fancyplain{}{\bfseries\leftmark}} -\fancyhead[LO]{\fancyplain{}{\bfseries\rightmark}} -\fancyhead[CO]{\fancyplain{}{}} -\fancyhead[RO]{\fancyplain{}{\bfseries\thepage}} -\fancyfoot[LE]{\fancyplain{}{}} -\fancyfoot[CE]{\fancyplain{}{}} -\fancyfoot[RE]{\fancyplain{}{\bfseries\scriptsize Generated on Sun Feb 9 2014 20:17:03 for QuaZIP by Doxygen }} -\fancyfoot[LO]{\fancyplain{}{\bfseries\scriptsize Generated on Sun Feb 9 2014 20:17:03 for QuaZIP by Doxygen }} -\fancyfoot[CO]{\fancyplain{}{}} -\fancyfoot[RO]{\fancyplain{}{}} -%---------- Internal commands used in this style file ---------------- - -% Generic environment used by all paragraph-based environments defined -% below. Note that the command \title{...} needs to be defined inside -% those environments! -\newenvironment{DoxyDesc}[1]{% - \begin{list}{}% - {% - \settowidth{\labelwidth}{40pt}% - \setlength{\leftmargin}{\labelwidth}% - \setlength{\parsep}{0pt}% - \setlength{\itemsep}{-4pt}% - \renewcommand{\makelabel}{\entrylabel}% - }% - \item[#1]% -}{% - \end{list}% -} - -%---------- Commands used by doxygen LaTeX output generator ---------- - -% Used by
 ... 
-\newenvironment{DoxyPre}{% - \small% - \begin{alltt}% -}{% - \end{alltt}% - \normalsize% -} - -% Used by @code ... @endcode -\newenvironment{DoxyCode}{% - \footnotesize% - \verbatim% -}{% - \endverbatim% - \normalsize% -} - -% Used by @example, @include, @includelineno and @dontinclude -\newenvironment{DoxyCodeInclude}{% - \DoxyCode% -}{% - \endDoxyCode% -} - -% Used by @verbatim ... @endverbatim -\newenvironment{DoxyVerb}{% - \footnotesize% - \verbatim% -}{% - \endverbatim% - \normalsize% -} - -% Used by @verbinclude -\newenvironment{DoxyVerbInclude}{% - \DoxyVerb% -}{% - \endDoxyVerb% -} - -% Used by numbered lists (using '-#' or
    ...
) -\newenvironment{DoxyEnumerate}{% - \enumerate% -}{% - \endenumerate% -} - -% Used by bullet lists (using '-', @li, @arg, or
    ...
) -\newenvironment{DoxyItemize}{% - \itemize% -}{% - \enditemize% -} - -% Used by description lists (using
...
) -\newenvironment{DoxyDescription}{% - \description% -}{% - \enddescription% -} - -% Used by @image, @dotfile, and @dot ... @enddot -% (only if caption is specified) -\newenvironment{DoxyImage}{% - \begin{figure}[H]% - \begin{center}% -}{% - \end{center}% - \end{figure}% -} - -% Used by @image, @dotfile, @dot ... @enddot, and @msc ... @endmsc -% (only if no caption is specified) -\newenvironment{DoxyImageNoCaption}{% -}{% -} - -% Used by @attention -\newenvironment{DoxyAttention}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @author and @authors -\newenvironment{DoxyAuthor}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @date -\newenvironment{DoxyDate}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @invariant -\newenvironment{DoxyInvariant}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @note -\newenvironment{DoxyNote}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @post -\newenvironment{DoxyPostcond}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @pre -\newenvironment{DoxyPrecond}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @remark -\newenvironment{DoxyRemark}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @return -\newenvironment{DoxyReturn}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @since -\newenvironment{DoxySince}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @see -\newenvironment{DoxySeeAlso}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @version -\newenvironment{DoxyVersion}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @warning -\newenvironment{DoxyWarning}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @internal -\newenvironment{DoxyInternal}[1]{% - \paragraph*{#1}% -}{% -} - -% Used by @par and @paragraph -\newenvironment{DoxyParagraph}[1]{% - \begin{list}{}% - {% - \settowidth{\labelwidth}{40pt}% - \setlength{\leftmargin}{\labelwidth}% - \setlength{\parsep}{0pt}% - \setlength{\itemsep}{-4pt}% - \renewcommand{\makelabel}{\entrylabel}% - }% - \item[#1]% -}{% - \end{list}% -} - -% Used by parameter lists -\newenvironment{DoxyParams}[2][]{% - \begin{DoxyDesc}{#2}% - \begin{description}% - \item[] \hspace{\fill} \vspace{-25pt}% - \definecolor{tableShade}{HTML}{F8F8F8}% - \rowcolors{1}{white}{tableShade}% - \arrayrulecolor{gray}% - \setlength{\tabcolsep}{0.01\textwidth}% - \ifthenelse{\equal{#1}{}} - {\begin{longtable}{|>{\raggedleft\hspace{0pt}}p{0.15\textwidth}|% - p{0.87\textwidth}|}}% - {\ifthenelse{\equal{#1}{1}}% - {\begin{longtable}{|>{\centering}p{0.10\textwidth}|% - >{\raggedleft\hspace{0pt}}p{0.15\textwidth}|% - p{0.75\textwidth}|}}% - {\begin{longtable}{|>{\centering}p{0.10\textwidth}|% - >{\centering\hspace{0pt}}p{0.15\textwidth}|% - >{\raggedleft\hspace{0pt}}p{0.15\textwidth}|% - p{0.58\textwidth}|}}% - }\hline% -}{% - \end{longtable}% - \end{description}% - \end{DoxyDesc}% -} - -% is used for parameters within a detailed function description -\newenvironment{DoxyParamCaption}{% - \renewcommand{\item}[2][]{##1 {\em ##2}}% - }{% -} - -% Used by return value lists -\newenvironment{DoxyRetVals}[1]{% - \begin{DoxyDesc}{#1}% - \begin{description}% - \item[] \hspace{\fill} \vspace{-25pt}% - \definecolor{tableShade}{HTML}{F8F8F8}% - \rowcolors{1}{white}{tableShade}% - \arrayrulecolor{gray}% - \setlength{\tabcolsep}{0.01\textwidth}% - \begin{longtable}{|>{\raggedleft\hspace{0pt}}p{0.25\textwidth}|% - p{0.77\textwidth}|}% - \hline% -}{% - \end{longtable}% - \end{description}% - \end{DoxyDesc}% -} - -% Used by exception lists -\newenvironment{DoxyExceptions}[1]{% - \begin{DoxyDesc}{#1}% - \begin{description}% - \item[] \hspace{\fill} \vspace{-25pt}% - \definecolor{tableShade}{HTML}{F8F8F8}% - \rowcolors{1}{white}{tableShade}% - \arrayrulecolor{gray}% - \setlength{\tabcolsep}{0.01\textwidth}% - \begin{longtable}{|>{\raggedleft\hspace{0pt}}p{0.25\textwidth}|% - p{0.77\textwidth}|}% - \hline% -}{% - \end{longtable}% - \end{description}% - \end{DoxyDesc}% -} - -% Used by template parameter lists -\newenvironment{DoxyTemplParams}[1]{% - \begin{DoxyDesc}{#1}% - \begin{description}% - \item[] \hspace{\fill} \vspace{-25pt}% - \definecolor{tableShade}{HTML}{F8F8F8}% - \rowcolors{1}{white}{tableShade}% - \arrayrulecolor{gray}% - \setlength{\tabcolsep}{0.01\textwidth}% - \begin{longtable}{|>{\raggedleft\hspace{0pt}}p{0.25\textwidth}|% - p{0.77\textwidth}|}% - \hline% -}{% - \end{longtable}% - \end{description}% - \end{DoxyDesc}% -} - -\newcommand{\doxyref}[3]{\textbf{#1} (\textnormal{#2}\,\pageref{#3})} -\newenvironment{DoxyCompactList} -{\begin{list}{}{ - \setlength{\leftmargin}{0.5cm} - \setlength{\itemsep}{0pt} - \setlength{\parsep}{0pt} - \setlength{\topsep}{0pt} - \renewcommand{\makelabel}{\hfill}}} -{\end{list}} -\newenvironment{DoxyCompactItemize} -{ - \begin{itemize} - \setlength{\itemsep}{-3pt} - \setlength{\parsep}{0pt} - \setlength{\topsep}{0pt} - \setlength{\partopsep}{0pt} -} -{\end{itemize}} -\newcommand{\PBS}[1]{\let\temp=\\#1\let\\=\temp} -\newlength{\tmplength} -\newenvironment{TabularC}[1] -{ -\setlength{\tmplength} - {\linewidth/(#1)-\tabcolsep*2-\arrayrulewidth*(#1+1)/(#1)} - \par\begin{tabular*}{\linewidth} - {*{#1}{|>{\PBS\raggedright\hspace{0pt}}p{\the\tmplength}}|} -} -{\end{tabular*}\par} -\newcommand{\entrylabel}[1]{ - {\parbox[b]{\labelwidth-4pt}{\makebox[0pt][l]{\textbf{#1}}\vspace{1.5\baselineskip}}}} -\newenvironment{Desc} -{\begin{list}{} - { - \settowidth{\labelwidth}{40pt} - \setlength{\leftmargin}{\labelwidth} - \setlength{\parsep}{0pt} - \setlength{\itemsep}{-4pt} - \renewcommand{\makelabel}{\entrylabel} - } -} -{\end{list}} -\newenvironment{Indent} - {\begin{list}{}{\setlength{\leftmargin}{0.5cm}} - \item[]\ignorespaces} - {\unskip\end{list}} -\setlength{\parindent}{0cm} -\setlength{\parskip}{0.2cm} -\addtocounter{secnumdepth}{2} -\usepackage[T1]{fontenc} -\makeatletter -\renewcommand{\paragraph}{\@startsection{paragraph}{4}{0ex}% - {-1.0ex}% - {1.0ex}% - {\usefont{OT1}{phv}{bc}{n}\color{darkgray}}} -\renewcommand{\subparagraph}{\@startsection{subparagraph}{5}{0ex}% - {-1.0ex}% - {1.0ex}% - {\usefont{OT1}{phv}{bc}{n}\color{darkgray}}} -\makeatother -\allsectionsfont{\usefont{OT1}{phv}{bc}{n}\selectfont\color{darkgray}} -\stepcounter{secnumdepth} -\stepcounter{tocdepth} -\definecolor{comment}{rgb}{0.5,0.0,0.0} -\definecolor{keyword}{rgb}{0.0,0.5,0.0} -\definecolor{keywordtype}{rgb}{0.38,0.25,0.125} -\definecolor{keywordflow}{rgb}{0.88,0.5,0.0} -\definecolor{preprocessor}{rgb}{0.5,0.38,0.125} -\definecolor{stringliteral}{rgb}{0.0,0.125,0.25} -\definecolor{charliteral}{rgb}{0.0,0.5,0.5} -\definecolor{vhdldigit}{rgb}{1.0,0.0,1.0} -\definecolor{vhdlkeyword}{rgb}{0.43,0.0,0.43} -\definecolor{vhdllogic}{rgb}{1.0,0.0,0.0} -\definecolor{vhdlchar}{rgb}{0.0,0.0,0.0} diff --git a/hecl-gui/quazip/doc/latex/faq.tex b/hecl-gui/quazip/doc/latex/faq.tex deleted file mode 100644 index 77a4ed41d..000000000 --- a/hecl-gui/quazip/doc/latex/faq.tex +++ /dev/null @@ -1,14 +0,0 @@ -\label{faq_faq-non-QIODevice} - Q. Is there any way to use \doxyref{QuaZipFile}{p.}{classQuaZipFile} in Qt where you are supposed to use normal (non-\/zipped) file, but not through QIODevice API? - -A. Usually not. For example, if you are passing file name to some database driver (like SQLite), Qt usually just passes this name down to the 3rd-\/party library, which is usually does not know anything about QIODevice and therefore there is no way to pass \doxyref{QuaZipFile}{p.}{classQuaZipFile} as normal file. However, if we are talking about some place where you pass file name, and then indirectly use QFile to open it, then it is a good idea to make overloaded method, which accepts a QIODevice pointer. Then you would be able to pass \doxyref{QuaZipFile}{p.}{classQuaZipFile} as well as many other nice things such as QBuffer or QProcess. - -\label{faq_faq-zip64} - Q. Can QuaZIP handle files larger than 4GB? What about zip64 standard? - -A. Starting with version 0.6, QuaZIP uses Minizip 1.1 with zip64 support which should handle large files perfectly. The zip64 support in Minizip looks like it's not 100\% conforming to the standard, but 3rd party tools seem to have no problem with the resulting archives. - -\label{faq_faq-seekable} - Q. Can QuaZIP write archives to a sequential QIODevice like QTcpSocket? - -A. Not yet. It is not supported by vanilla Minizip (the back-\/end QuaZIP uses), although theoretically possible according to the ZIP standard. It would require some Minizip modifications that would allow it to detect non-\/seekable I/O and produce necessary output structures. QuaZIP already writes data descriptor which is necessary for non-\/seekable I/O. The only thing that is apparently left is to make Minizip fill local headers with correct values and forget about seeking after closing the file. \ No newline at end of file diff --git a/hecl-gui/quazip/doc/latex/hierarchy.tex b/hecl-gui/quazip/doc/latex/hierarchy.tex deleted file mode 100644 index 5a0fdfea9..000000000 --- a/hecl-gui/quazip/doc/latex/hierarchy.tex +++ /dev/null @@ -1,19 +0,0 @@ -\section{Class Hierarchy} -This inheritance list is sorted roughly, but not completely, alphabetically:\begin{DoxyCompactList} -\item \contentsline{section}{JlCompress}{\pageref{classJlCompress}}{} -\item \contentsline{section}{QuaChecksum32}{\pageref{classQuaChecksum32}}{} -\begin{DoxyCompactList} -\item \contentsline{section}{QuaAdler32}{\pageref{classQuaAdler32}}{} -\item \contentsline{section}{QuaCrc32}{\pageref{classQuaCrc32}}{} -\end{DoxyCompactList} -\item \contentsline{section}{QuaGzipFile}{\pageref{classQuaGzipFile}}{} -\item \contentsline{section}{QuaZIODevice}{\pageref{classQuaZIODevice}}{} -\item \contentsline{section}{QuaZip}{\pageref{classQuaZip}}{} -\item \contentsline{section}{QuaZipDir}{\pageref{classQuaZipDir}}{} -\item \contentsline{section}{QuaZipFile}{\pageref{classQuaZipFile}}{} -\item \contentsline{section}{QuaZipFileInfo}{\pageref{structQuaZipFileInfo}}{} -\item \contentsline{section}{QuaZipFileInfo64}{\pageref{structQuaZipFileInfo64}}{} -\item \contentsline{section}{QuaZipFilePrivate}{\pageref{classQuaZipFilePrivate}}{} -\item \contentsline{section}{QuaZipNewInfo}{\pageref{structQuaZipNewInfo}}{} -\item \contentsline{section}{QuaZipPrivate}{\pageref{classQuaZipPrivate}}{} -\end{DoxyCompactList} diff --git a/hecl-gui/quazip/doc/latex/index.tex b/hecl-gui/quazip/doc/latex/index.tex deleted file mode 100644 index 22608aef4..000000000 --- a/hecl-gui/quazip/doc/latex/index.tex +++ /dev/null @@ -1,89 +0,0 @@ - \section{Overview}\label{index_overview} -QuaZIP is a simple C++ wrapper over {\tt Gilles Vollant's ZIP/UNZIP package} that can be used to access ZIP archives. It uses {\tt the Qt toolkit}. - -If you do not know what Qt is, you have two options: -\begin{DoxyItemize} -\item Just forget about QuaZIP. -\item Learn more about Qt by downloading it and/or reading the excellent {\tt official Qt documentation} -\end{DoxyItemize} - -The choice is yours, but if you are really interested in cross-\/platform (Windows/Linux/BSD/UNIX/Mac/Others) software development, I would definitely recommend you the latter $^\wedge$\_\-$^\wedge$ - -QuaZIP allows you to access files inside ZIP archives using QIODevice API, and -\/ yes! -\/ that means that you can also use QTextStream, QDataStream or whatever you would like to use on your zipped files. - -QuaZIP provides complete abstraction of the ZIP/UNZIP API, for both reading from and writing to ZIP archives.\section{Download QuaZIP}\label{index_download} -Downloads are available from {\tt QuaZIP project's page at SourceForge.net}.\section{Platforms supported}\label{index_platforms} -QuaZIP has been currently tested on the following platforms: -\begin{DoxyItemize} -\item linux-\/g++ (Ubuntu 11.10, Qt 4.7.4) -\item freebsd-\/g++ (Qt 4.0.0 -\item hpux-\/acc (HP-\/UX 11.11) -\item hpux-\/g++ (HP-\/UX 11.11) -\item win32-\/g++ (MinGW) -\item win32-\/msvc2010 (MS VS 2010 Express, Qt 4.8.4) -\item win32-\/msvc2010 (Qt Creator, Qt 5.0.1) -\item win32-\/msvc2012 (Qt Creator, Qt 5.2.0) -\item some Symbian version, reportedly -\end{DoxyItemize} - -No testing has been officially done on other systems. Of course, patches to make it work on any platform that it currently does not work on are always welcome!\section{What is new in this version of QuaZIP?}\label{index_whats-new} -See the NEWS.txt file supplied with the distribution.\section{Requirements}\label{index_Requirements} -Just {\tt zlib} and Qt 4/5. Well, Qt 4 depends on zlib anyway, but you will need zlib headers to compile QuaZIP. With Qt5 sometimes you need the zlib library as well (on Windows, for example).\section{Building, testing and installing}\label{index_building} -\begin{DoxyNote}{Note} -Instructions given in this section assume that you are using some UNIX dialect, but the build process should be very similar on win32-\/g++ platform too. On other platforms it's essentially the same process, maybe with some qmake adjustments not specific to QuaZIP itself. -\end{DoxyNote} -To build the library, run: \begin{DoxyVerb} -$ cd /wherever/quazip/source/is/quazip-x.y.z/quazip -$ qmake [PREFIX=where-to-install] -$ make -\end{DoxyVerb} - - -Make sure that you have Qt 4/5 installed with all required headers and utilities (that is, including the 'dev' or 'devel' package on Linux) and that you run qmake utility of the Qt 4, not some other version you may have already installed (you may need to type full path to qmake like /usr/local/qt4/bin/qmake). - -To reconfigure (with another PREFIX, for example), just run qmake with appropriate arguments again. - -If you need to specify additional include path or libraries, use qmake features (see qmake reference in the Qt documentation). For example: - -\begin{DoxyVerb} -$ qmake LIBS+=-L/usr/local/zlib/lib INCLUDEPATH+=/usr/local/zlib/include -\end{DoxyVerb} - (note abscence of \char`\"{}-\/I\char`\"{} before the include path and the presence of \char`\"{}-\/L\char`\"{} before the lib path) - -Also note that you may or may not need to define ZLIB\_\-WINAPI (qmake DEFINES+=ZLIB\_\-WINAPI) when linking to zlib on Windows, depending on how zlib was built (generally, if using zlibwapi.dll, this define is needed). - -To install compiled library: \begin{DoxyVerb} -$ make install -\end{DoxyVerb} - - -By default, QuaZIP compiles as a DLL/SO, but you have other options: -\begin{DoxyItemize} -\item Just copy appropriate source files to your project and use them, but you need to define QUAZIP\_\-STATIC before including any QuaZIP headers (best done as a compiler option). This will save you from possible side effects of importing/exporting QuaZIP symbols. -\item Compile it as a static library using CONFIG += staticlib qmake option. QUAZIP\_\-STATIC is defined automatically by qmake in this case. -\end{DoxyItemize} - -Binary compatibility is guaranteed between minor releases starting with version 0.5, thanks to the Pimpl idiom. That is, the next binary incompatible version will be 1.x.\section{Testing}\label{index_test} -To check if QuaZIP's basic features work OK on your platform, you may wish to compile the test suite provided in test directory: \begin{DoxyVerb} -$ cd /wherever/quazip/source/is/quazip-x.y.z/qztest -$ qmake -$ make -$ ./qztest -\end{DoxyVerb} - - -Note that the test suite looks for the quazip library in the \char`\"{}quazip\char`\"{} folder of the project (\char`\"{}../quazip\char`\"{}), but you may wish to use LIBS for some systems (Windows often puts the library in the separate \char`\"{}debug\char`\"{} or \char`\"{}release\char`\"{} directory). If you wish to use the quazip version that's already installed, provide the appropriate path. - -On some systems you may need to set PATH, LD\_\-LIBRARY\_\-PATH or SHLIB\_\-PATH to get \char`\"{}qztest\char`\"{} to actually run. - -If everything went fine, the test suite should report a lot of PASS messages. If something goes wrong, it will provide details and a warning that some tests failed.\section{Using}\label{index_using} -See \doxyref{usage page}{p.}{usage}.\section{Authors and contacts}\label{index_contacts} -This wrapper has been written by Sergey A. Tachenov, AKA Alqualos. This is my first open source project, so it may suck, but I did not find anything like that, so I just had no other choice but to write it. - -If you have anything to say to me about QuaZIP library, feel free to do so (read the \doxyref{QuaZip FAQ}{p.}{faq} first, though). I can not promise, though, that I fix all the bugs you report in, add any features you want, or respond to your critics, or respond to your feedback at all. I may be busy, I may be tired of working on QuaZIP, I may be even dead already (you never know...). - -To report bugs or to post ideas about what should be done, use SourceForge.net's {\tt trackers}. If you want to send me a private message, use my e-\/mail address {\tt stachenov@gmail.com}. - -Do not use e-\/mail to report bugs, please. Reporting bugs and problems with the SourceForge.net's bug report system has that advantage that it is visible to public, and I can always search for open tickets that were created long ago. It is highly unlikely that I will search my mail for that kind of stuff, so if a bug reported by mail isn't fixed immediately, it will likely be forgotten forever. - -Copyright (C) 2005-\/2014 Sergey A. Tachenov and contributors \ No newline at end of file diff --git a/hecl-gui/quazip/doc/latex/refman.tex b/hecl-gui/quazip/doc/latex/refman.tex deleted file mode 100644 index ad44b3689..000000000 --- a/hecl-gui/quazip/doc/latex/refman.tex +++ /dev/null @@ -1,72 +0,0 @@ -\documentclass[a4paper]{book} -\usepackage{makeidx} -\usepackage{graphicx} -\usepackage{multicol} -\usepackage{float} -\usepackage{listings} -\usepackage{color} -\usepackage{ifthen} -\usepackage[table]{xcolor} -\usepackage{textcomp} -\usepackage{alltt} -\usepackage[utf8]{inputenc} -\usepackage{mathptmx} -\usepackage[scaled=.90]{helvet} -\usepackage{courier} -\usepackage{sectsty} -\usepackage[titles]{tocloft} -\usepackage{doxygen} -\lstset{language=C++,inputencoding=utf8,basicstyle=\footnotesize,breaklines=true,breakatwhitespace=true,tabsize=8,numbers=left } -\makeindex -\setcounter{tocdepth}{3} -\renewcommand{\footrulewidth}{0.4pt} -\renewcommand{\familydefault}{\sfdefault} -\begin{document} -\begin{titlepage} -\vspace*{7cm} -\begin{center} -{\Large QuaZIP \\[1ex]\large quazip-\/0-\/6-\/2 }\\ -\vspace*{1cm} -{\large Generated by Doxygen 1.7.4}\\ -\vspace*{0.5cm} -{\small Sun Feb 9 2014 20:17:03}\\ -\end{center} -\end{titlepage} -\clearemptydoublepage -\pagenumbering{roman} -\tableofcontents -\clearemptydoublepage -\pagenumbering{arabic} -\chapter{QuaZIP -\/ Qt/C++ wrapper for ZIP/UNZIP package} -\label{index}\input{index} -\chapter{QuaZip FAQ} -\label{faq} -\input{faq} -\chapter{Usage} -\label{usage} -\input{usage} -\chapter{Directory Hierarchy} -\input{dirs} -\chapter{Class Index} -\input{hierarchy} -\chapter{Class Index} -\input{annotated} -\chapter{Directory Documentation} -\input{dir_63f4af0f6084a51244f9f3a16a2e698d} -\chapter{Class Documentation} -\input{classJlCompress} -\input{classQuaAdler32} -\input{classQuaChecksum32} -\input{classQuaCrc32} -\input{classQuaGzipFile} -\input{classQuaZIODevice} -\input{classQuaZip} -\input{classQuaZipDir} -\input{classQuaZipFile} -\input{structQuaZipFileInfo} -\input{structQuaZipFileInfo64} -\input{classQuaZipFilePrivate} -\input{structQuaZipNewInfo} -\input{classQuaZipPrivate} -\printindex -\end{document} diff --git a/hecl-gui/quazip/doc/latex/structQuaZipFileInfo.tex b/hecl-gui/quazip/doc/latex/structQuaZipFileInfo.tex deleted file mode 100644 index c84887d19..000000000 --- a/hecl-gui/quazip/doc/latex/structQuaZipFileInfo.tex +++ /dev/null @@ -1,86 +0,0 @@ -\section{QuaZipFileInfo Struct Reference} -\label{structQuaZipFileInfo}\index{QuaZipFileInfo@{QuaZipFileInfo}} - - -Information about a file inside archive. - - - - -{\ttfamily \#include $<$quazipfileinfo.h$>$} - -\subsection*{Public Member Functions} -\begin{DoxyCompactItemize} -\item -QFile::Permissions {\bf getPermissions} () const -\begin{DoxyCompactList}\small\item\em Get the file permissions. \end{DoxyCompactList}\end{DoxyCompactItemize} -\subsection*{Public Attributes} -\begin{DoxyCompactItemize} -\item -QString {\bf name}\label{structQuaZipFileInfo_a16ac323965deccf0232bfae69d933a84} - -\begin{DoxyCompactList}\small\item\em File name. \end{DoxyCompactList}\item -quint16 {\bf versionCreated}\label{structQuaZipFileInfo_a52f3f1d960ebaa2acbc2a86458fa3e6e} - -\begin{DoxyCompactList}\small\item\em Version created by. \end{DoxyCompactList}\item -quint16 {\bf versionNeeded}\label{structQuaZipFileInfo_a8b73982808bded49e88e624a65e1a94f} - -\begin{DoxyCompactList}\small\item\em Version needed to extract. \end{DoxyCompactList}\item -quint16 {\bf flags}\label{structQuaZipFileInfo_a56d36f777e4fc892c71e22d080622e2c} - -\begin{DoxyCompactList}\small\item\em General purpose flags. \end{DoxyCompactList}\item -quint16 {\bf method}\label{structQuaZipFileInfo_af5c1bbda7f5dec2c358e7a543564de4c} - -\begin{DoxyCompactList}\small\item\em Compression method. \end{DoxyCompactList}\item -QDateTime {\bf dateTime}\label{structQuaZipFileInfo_ad6993d099436813a27fd31aebe42911a} - -\begin{DoxyCompactList}\small\item\em Last modification date and time. \end{DoxyCompactList}\item -quint32 {\bf crc}\label{structQuaZipFileInfo_aceee045c9ebce0b9724f40d342bc99ea} - -\begin{DoxyCompactList}\small\item\em CRC. \end{DoxyCompactList}\item -quint32 {\bf compressedSize}\label{structQuaZipFileInfo_af6116eaac1f36b2a4b3a6a39851a85cc} - -\begin{DoxyCompactList}\small\item\em Compressed file size. \end{DoxyCompactList}\item -quint32 {\bf uncompressedSize}\label{structQuaZipFileInfo_a0eb908e1b1ea637d1f1f4d6aa31db07f} - -\begin{DoxyCompactList}\small\item\em Uncompressed file size. \end{DoxyCompactList}\item -quint16 {\bf diskNumberStart}\label{structQuaZipFileInfo_aa70157fdc2bd8de10405055b4233050b} - -\begin{DoxyCompactList}\small\item\em Disk number start. \end{DoxyCompactList}\item -quint16 {\bf internalAttr}\label{structQuaZipFileInfo_a36e681a93b041617addee78cb939c93d} - -\begin{DoxyCompactList}\small\item\em Internal file attributes. \end{DoxyCompactList}\item -quint32 {\bf externalAttr}\label{structQuaZipFileInfo_afeb65ffdacc4fc0ba7848d4b37f62ecf} - -\begin{DoxyCompactList}\small\item\em External file attributes. \end{DoxyCompactList}\item -QString {\bf comment}\label{structQuaZipFileInfo_adc2aad7bbd87ce3415e2a19851266bfc} - -\begin{DoxyCompactList}\small\item\em Comment. \end{DoxyCompactList}\item -QByteArray {\bf extra}\label{structQuaZipFileInfo_affc7b097de2c3c2ef5801c60f96adc72} - -\begin{DoxyCompactList}\small\item\em Extra field. \end{DoxyCompactList}\end{DoxyCompactItemize} - - -\subsection{Detailed Description} -Information about a file inside archive. - -Call \doxyref{QuaZip::getCurrentFileInfo()}{p.}{classQuaZip_a9c91a53ed4c2038e153c64bdc097ebe8} or \doxyref{QuaZipFile::getFileInfo()}{p.}{classQuaZipFile_ad3f5807329321be21b12c1ba5798b359} to fill this structure. - -\subsection{Member Function Documentation} -\index{QuaZipFileInfo@{QuaZipFileInfo}!getPermissions@{getPermissions}} -\index{getPermissions@{getPermissions}!QuaZipFileInfo@{QuaZipFileInfo}} -\subsubsection[{getPermissions}]{\setlength{\rightskip}{0pt plus 5cm}QFile::Permissions QuaZipFileInfo::getPermissions ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{structQuaZipFileInfo_af87f96a64d7c02b002622f81d13accdb} - - -Get the file permissions. - -Returns the high 16 bits of external attributes converted to QFile::Permissions. - -The documentation for this struct was generated from the following files:\begin{DoxyCompactItemize} -\item -quazip/quazipfileinfo.h\item -quazip/quazipfileinfo.cpp\end{DoxyCompactItemize} diff --git a/hecl-gui/quazip/doc/latex/structQuaZipFileInfo64.tex b/hecl-gui/quazip/doc/latex/structQuaZipFileInfo64.tex deleted file mode 100644 index 903a29c1f..000000000 --- a/hecl-gui/quazip/doc/latex/structQuaZipFileInfo64.tex +++ /dev/null @@ -1,209 +0,0 @@ -\section{QuaZipFileInfo64 Struct Reference} -\label{structQuaZipFileInfo64}\index{QuaZipFileInfo64@{QuaZipFileInfo64}} - - -Information about a file inside archive (with zip64 support). - - - - -{\ttfamily \#include $<$quazipfileinfo.h$>$} - -\subsection*{Public Member Functions} -\begin{DoxyCompactItemize} -\item -QFile::Permissions {\bf getPermissions} () const -\begin{DoxyCompactList}\small\item\em Get the file permissions. \end{DoxyCompactList}\item -bool {\bf toQuaZipFileInfo} ({\bf QuaZipFileInfo} \&info) const -\begin{DoxyCompactList}\small\item\em Converts to \doxyref{QuaZipFileInfo}{p.}{structQuaZipFileInfo}. \end{DoxyCompactList}\item -QDateTime {\bf getNTFSmTime} (int $\ast$fineTicks=NULL) const -\begin{DoxyCompactList}\small\item\em Returns the NTFS modification time. \end{DoxyCompactList}\item -QDateTime {\bf getNTFSaTime} (int $\ast$fineTicks=NULL) const -\begin{DoxyCompactList}\small\item\em Returns the NTFS access time. \end{DoxyCompactList}\item -QDateTime {\bf getNTFScTime} (int $\ast$fineTicks=NULL) const -\begin{DoxyCompactList}\small\item\em Returns the NTFS creation time. \end{DoxyCompactList}\end{DoxyCompactItemize} -\subsection*{Public Attributes} -\begin{DoxyCompactItemize} -\item -QString {\bf name}\label{structQuaZipFileInfo64_a2cadad4cb9a765e90b5422dae2388762} - -\begin{DoxyCompactList}\small\item\em File name. \end{DoxyCompactList}\item -quint16 {\bf versionCreated}\label{structQuaZipFileInfo64_a95aeb06b080e483fde874ba2d06f203c} - -\begin{DoxyCompactList}\small\item\em Version created by. \end{DoxyCompactList}\item -quint16 {\bf versionNeeded}\label{structQuaZipFileInfo64_a27654f5ce3a75331e9c9a7900b407169} - -\begin{DoxyCompactList}\small\item\em Version needed to extract. \end{DoxyCompactList}\item -quint16 {\bf flags}\label{structQuaZipFileInfo64_a6aa533dd4e02f52459e1e1a0df31e992} - -\begin{DoxyCompactList}\small\item\em General purpose flags. \end{DoxyCompactList}\item -quint16 {\bf method}\label{structQuaZipFileInfo64_a445967ecbb5a3dd2a9d516db3e14a34a} - -\begin{DoxyCompactList}\small\item\em Compression method. \end{DoxyCompactList}\item -QDateTime {\bf dateTime} -\begin{DoxyCompactList}\small\item\em Last modification date and time. \end{DoxyCompactList}\item -quint32 {\bf crc}\label{structQuaZipFileInfo64_aeb7b2757a0efa814b196b5280d000a14} - -\begin{DoxyCompactList}\small\item\em CRC. \end{DoxyCompactList}\item -quint64 {\bf compressedSize}\label{structQuaZipFileInfo64_add8733946ea4af23aa32d85f10955b0f} - -\begin{DoxyCompactList}\small\item\em Compressed file size. \end{DoxyCompactList}\item -quint64 {\bf uncompressedSize}\label{structQuaZipFileInfo64_a571ca077fe282c908e57b0bc82528d49} - -\begin{DoxyCompactList}\small\item\em Uncompressed file size. \end{DoxyCompactList}\item -quint16 {\bf diskNumberStart}\label{structQuaZipFileInfo64_ac8945cf1ff54d39d28e755685b91e941} - -\begin{DoxyCompactList}\small\item\em Disk number start. \end{DoxyCompactList}\item -quint16 {\bf internalAttr}\label{structQuaZipFileInfo64_aeb895613e76a4cc63f861b010c9e92c0} - -\begin{DoxyCompactList}\small\item\em Internal file attributes. \end{DoxyCompactList}\item -quint32 {\bf externalAttr}\label{structQuaZipFileInfo64_a3a8bc40f1aa0cb0985c4e2f8a9678430} - -\begin{DoxyCompactList}\small\item\em External file attributes. \end{DoxyCompactList}\item -QString {\bf comment}\label{structQuaZipFileInfo64_aba3f5b982087c3e0343bb61e8814c7d1} - -\begin{DoxyCompactList}\small\item\em Comment. \end{DoxyCompactList}\item -QByteArray {\bf extra}\label{structQuaZipFileInfo64_acf0b1b97f377208847c6912cd1bf1332} - -\begin{DoxyCompactList}\small\item\em Extra field. \end{DoxyCompactList}\end{DoxyCompactItemize} - - -\subsection{Detailed Description} -Information about a file inside archive (with zip64 support). - -Call \doxyref{QuaZip::getCurrentFileInfo()}{p.}{classQuaZip_a9c91a53ed4c2038e153c64bdc097ebe8} or \doxyref{QuaZipFile::getFileInfo()}{p.}{classQuaZipFile_ad3f5807329321be21b12c1ba5798b359} to fill this structure. - -\subsection{Member Function Documentation} -\index{QuaZipFileInfo64@{QuaZipFileInfo64}!getPermissions@{getPermissions}} -\index{getPermissions@{getPermissions}!QuaZipFileInfo64@{QuaZipFileInfo64}} -\subsubsection[{getPermissions}]{\setlength{\rightskip}{0pt plus 5cm}QFile::Permissions QuaZipFileInfo64::getPermissions ( -\begin{DoxyParamCaption} -{} -\end{DoxyParamCaption} -) const}\label{structQuaZipFileInfo64_a099216bd8991a983168d91c06a689f61} - - -Get the file permissions. - -Returns the high 16 bits of external attributes converted to QFile::Permissions. \index{QuaZipFileInfo64@{QuaZipFileInfo64}!toQuaZipFileInfo@{toQuaZipFileInfo}} -\index{toQuaZipFileInfo@{toQuaZipFileInfo}!QuaZipFileInfo64@{QuaZipFileInfo64}} -\subsubsection[{toQuaZipFileInfo}]{\setlength{\rightskip}{0pt plus 5cm}bool QuaZipFileInfo64::toQuaZipFileInfo ( -\begin{DoxyParamCaption} -\item[{{\bf QuaZipFileInfo} \&}]{info} -\end{DoxyParamCaption} -) const}\label{structQuaZipFileInfo64_ada29945c7ee4c9df6fbe95864793aade} - - -Converts to \doxyref{QuaZipFileInfo}{p.}{structQuaZipFileInfo}. - -If any of the fields are greater than 0xFFFFFFFFu, they are set to 0xFFFFFFFFu exactly, not just truncated. This function should be mainly used for compatibility with the old code expecting \doxyref{QuaZipFileInfo}{p.}{structQuaZipFileInfo}, in the cases when it's impossible or otherwise unadvisable (due to ABI compatibility reasons, for example) to modify that old code to use \doxyref{QuaZipFileInfo64}{p.}{structQuaZipFileInfo64}. - -\begin{DoxyReturn}{Returns} -{\ttfamily true} if all fields converted correctly, {\ttfamily false} if an overflow occured. -\end{DoxyReturn} - - -References comment, QuaZipFileInfo::comment, QuaZipFileInfo::compressedSize, compressedSize, crc, QuaZipFileInfo::crc, dateTime, QuaZipFileInfo::dateTime, diskNumberStart, QuaZipFileInfo::diskNumberStart, externalAttr, QuaZipFileInfo::externalAttr, extra, QuaZipFileInfo::extra, flags, QuaZipFileInfo::flags, internalAttr, QuaZipFileInfo::internalAttr, method, QuaZipFileInfo::method, name, QuaZipFileInfo::name, QuaZipFileInfo::uncompressedSize, uncompressedSize, versionCreated, QuaZipFileInfo::versionCreated, versionNeeded, and QuaZipFileInfo::versionNeeded. - - - -Referenced by QuaZip::getCurrentFileInfo(), and QuaZipFile::getFileInfo(). - -\index{QuaZipFileInfo64@{QuaZipFileInfo64}!getNTFSmTime@{getNTFSmTime}} -\index{getNTFSmTime@{getNTFSmTime}!QuaZipFileInfo64@{QuaZipFileInfo64}} -\subsubsection[{getNTFSmTime}]{\setlength{\rightskip}{0pt plus 5cm}QDateTime QuaZipFileInfo64::getNTFSmTime ( -\begin{DoxyParamCaption} -\item[{int $\ast$}]{fineTicks = {\ttfamily NULL}} -\end{DoxyParamCaption} -) const}\label{structQuaZipFileInfo64_af4b19399367cf5bf24026344e0631ccb} - - -Returns the NTFS modification time. - -The getNTFS$\ast$Time() functions only work if there is an NTFS extra field present. Otherwise, they all return invalid null timestamps. -\begin{DoxyParams}{Parameters} -{\em fineTicks} & If not NULL, the fractional part of milliseconds returned there, measured in 100-\/nanosecond ticks. Will be set to zero if there is no NTFS extra field. \\ -\hline -\end{DoxyParams} -\begin{DoxySeeAlso}{See also} -\doxyref{dateTime}{p.}{structQuaZipFileInfo64_a4d77c6aa6076703e858c938efeb551e4} - -\doxyref{getNTFSaTime()}{p.}{structQuaZipFileInfo64_afe4c454de7d067a0095da0223f0cbec2} - -\doxyref{getNTFScTime()}{p.}{structQuaZipFileInfo64_a409dcbbe1ecd88dadb51be1aec48819d} -\end{DoxySeeAlso} -\begin{DoxyReturn}{Returns} -The NTFS modification time, UTC -\end{DoxyReturn} -\index{QuaZipFileInfo64@{QuaZipFileInfo64}!getNTFSaTime@{getNTFSaTime}} -\index{getNTFSaTime@{getNTFSaTime}!QuaZipFileInfo64@{QuaZipFileInfo64}} -\subsubsection[{getNTFSaTime}]{\setlength{\rightskip}{0pt plus 5cm}QDateTime QuaZipFileInfo64::getNTFSaTime ( -\begin{DoxyParamCaption} -\item[{int $\ast$}]{fineTicks = {\ttfamily NULL}} -\end{DoxyParamCaption} -) const}\label{structQuaZipFileInfo64_afe4c454de7d067a0095da0223f0cbec2} - - -Returns the NTFS access time. - -The getNTFS$\ast$Time() functions only work if there is an NTFS extra field present. Otherwise, they all return invalid null timestamps. -\begin{DoxyParams}{Parameters} -{\em fineTicks} & If not NULL, the fractional part of milliseconds returned there, measured in 100-\/nanosecond ticks. Will be set to zero if there is no NTFS extra field. \\ -\hline -\end{DoxyParams} -\begin{DoxySeeAlso}{See also} -\doxyref{dateTime}{p.}{structQuaZipFileInfo64_a4d77c6aa6076703e858c938efeb551e4} - -\doxyref{getNTFSmTime()}{p.}{structQuaZipFileInfo64_af4b19399367cf5bf24026344e0631ccb} - -\doxyref{getNTFScTime()}{p.}{structQuaZipFileInfo64_a409dcbbe1ecd88dadb51be1aec48819d} -\end{DoxySeeAlso} -\begin{DoxyReturn}{Returns} -The NTFS access time, UTC -\end{DoxyReturn} -\index{QuaZipFileInfo64@{QuaZipFileInfo64}!getNTFScTime@{getNTFScTime}} -\index{getNTFScTime@{getNTFScTime}!QuaZipFileInfo64@{QuaZipFileInfo64}} -\subsubsection[{getNTFScTime}]{\setlength{\rightskip}{0pt plus 5cm}QDateTime QuaZipFileInfo64::getNTFScTime ( -\begin{DoxyParamCaption} -\item[{int $\ast$}]{fineTicks = {\ttfamily NULL}} -\end{DoxyParamCaption} -) const}\label{structQuaZipFileInfo64_a409dcbbe1ecd88dadb51be1aec48819d} - - -Returns the NTFS creation time. - -The getNTFS$\ast$Time() functions only work if there is an NTFS extra field present. Otherwise, they all return invalid null timestamps. -\begin{DoxyParams}{Parameters} -{\em fineTicks} & If not NULL, the fractional part of milliseconds returned there, measured in 100-\/nanosecond ticks. Will be set to zero if there is no NTFS extra field. \\ -\hline -\end{DoxyParams} -\begin{DoxySeeAlso}{See also} -\doxyref{dateTime}{p.}{structQuaZipFileInfo64_a4d77c6aa6076703e858c938efeb551e4} - -\doxyref{getNTFSmTime()}{p.}{structQuaZipFileInfo64_af4b19399367cf5bf24026344e0631ccb} - -\doxyref{getNTFSaTime()}{p.}{structQuaZipFileInfo64_afe4c454de7d067a0095da0223f0cbec2} -\end{DoxySeeAlso} -\begin{DoxyReturn}{Returns} -The NTFS creation time, UTC -\end{DoxyReturn} - - -\subsection{Member Data Documentation} -\index{QuaZipFileInfo64@{QuaZipFileInfo64}!dateTime@{dateTime}} -\index{dateTime@{dateTime}!QuaZipFileInfo64@{QuaZipFileInfo64}} -\subsubsection[{dateTime}]{\setlength{\rightskip}{0pt plus 5cm}QDateTime {\bf QuaZipFileInfo64::dateTime}}\label{structQuaZipFileInfo64_a4d77c6aa6076703e858c938efeb551e4} - - -Last modification date and time. - -This is the time stored in the standard ZIP header. This format only allows to store time with 2-\/second precision, so the seconds will always be even and the milliseconds will always be zero. If you need more precise date and time, you can try to call the \doxyref{getNTFSmTime()}{p.}{structQuaZipFileInfo64_af4b19399367cf5bf24026344e0631ccb} function or its siblings, provided that the archive itself contains these NTFS times. - -Referenced by QuaZip::getCurrentFileInfo(), and toQuaZipFileInfo(). - - - -The documentation for this struct was generated from the following files:\begin{DoxyCompactItemize} -\item -quazip/quazipfileinfo.h\item -quazip/quazipfileinfo.cpp\end{DoxyCompactItemize} diff --git a/hecl-gui/quazip/doc/latex/structQuaZipNewInfo.tex b/hecl-gui/quazip/doc/latex/structQuaZipNewInfo.tex deleted file mode 100644 index ef274216d..000000000 --- a/hecl-gui/quazip/doc/latex/structQuaZipNewInfo.tex +++ /dev/null @@ -1,360 +0,0 @@ -\section{QuaZipNewInfo Struct Reference} -\label{structQuaZipNewInfo}\index{QuaZipNewInfo@{QuaZipNewInfo}} - - -Information about a file to be created. - - - - -{\ttfamily \#include $<$quazipnewinfo.h$>$} - -\subsection*{Public Member Functions} -\begin{DoxyCompactItemize} -\item -{\bf QuaZipNewInfo} (const QString \&{\bf name}) -\begin{DoxyCompactList}\small\item\em Constructs \doxyref{QuaZipNewInfo}{p.}{structQuaZipNewInfo} instance. \end{DoxyCompactList}\item -{\bf QuaZipNewInfo} (const QString \&{\bf name}, const QString \&file) -\begin{DoxyCompactList}\small\item\em Constructs \doxyref{QuaZipNewInfo}{p.}{structQuaZipNewInfo} instance. \end{DoxyCompactList}\item -{\bf QuaZipNewInfo} (const {\bf QuaZipFileInfo} \&existing) -\begin{DoxyCompactList}\small\item\em Initializes the new instance from existing file info. \end{DoxyCompactList}\item -{\bf QuaZipNewInfo} (const {\bf QuaZipFileInfo64} \&existing) -\begin{DoxyCompactList}\small\item\em Initializes the new instance from existing file info. \end{DoxyCompactList}\item -void {\bf setFileDateTime} (const QString \&file) -\begin{DoxyCompactList}\small\item\em Sets the file timestamp from the existing file. \end{DoxyCompactList}\item -void {\bf setFilePermissions} (const QString \&file) -\begin{DoxyCompactList}\small\item\em Sets the file permissions from the existing file. \end{DoxyCompactList}\item -void {\bf setPermissions} (QFile::Permissions permissions) -\begin{DoxyCompactList}\small\item\em Sets the file permissions. \end{DoxyCompactList}\item -void {\bf setFileNTFSTimes} (const QString \&fileName) -\begin{DoxyCompactList}\small\item\em Sets the NTFS times from an existing file. \end{DoxyCompactList}\item -void {\bf setFileNTFSmTime} (const QDateTime \&mTime, int fineTicks=0) -\begin{DoxyCompactList}\small\item\em Sets the NTFS modification time. \end{DoxyCompactList}\item -void {\bf setFileNTFSaTime} (const QDateTime \&aTime, int fineTicks=0) -\begin{DoxyCompactList}\small\item\em Sets the NTFS access time. \end{DoxyCompactList}\item -void {\bf setFileNTFScTime} (const QDateTime \&cTime, int fineTicks=0) -\begin{DoxyCompactList}\small\item\em Sets the NTFS creation time. \end{DoxyCompactList}\end{DoxyCompactItemize} -\subsection*{Public Attributes} -\begin{DoxyCompactItemize} -\item -QString {\bf name} -\begin{DoxyCompactList}\small\item\em File name. \end{DoxyCompactList}\item -QDateTime {\bf dateTime} -\begin{DoxyCompactList}\small\item\em File timestamp. \end{DoxyCompactList}\item -quint16 {\bf internalAttr}\label{structQuaZipNewInfo_a59ce9776c2ac7547ade8cb4c404c77ab} - -\begin{DoxyCompactList}\small\item\em File internal attributes. \end{DoxyCompactList}\item -quint32 {\bf externalAttr} -\begin{DoxyCompactList}\small\item\em File external attributes. \end{DoxyCompactList}\item -QString {\bf comment} -\begin{DoxyCompactList}\small\item\em File comment. \end{DoxyCompactList}\item -QByteArray {\bf extraLocal}\label{structQuaZipNewInfo_ab377a81c51cf495c7aeee4f19340a43f} - -\begin{DoxyCompactList}\small\item\em File local extra field. \end{DoxyCompactList}\item -QByteArray {\bf extraGlobal}\label{structQuaZipNewInfo_abda207eb3949db3a88761c1b06e6bd58} - -\begin{DoxyCompactList}\small\item\em File global extra field. \end{DoxyCompactList}\item -ulong {\bf uncompressedSize} -\begin{DoxyCompactList}\small\item\em Uncompressed file size. \end{DoxyCompactList}\end{DoxyCompactItemize} - - -\subsection{Detailed Description} -Information about a file to be created. - -This structure holds information about a file to be created inside ZIP archive. At least name should be set to something correct before passing this structure to QuaZipFile::open(OpenMode,const QuaZipNewInfo\&,int,int,bool). - -Zip64 support of this structure is slightly limited: in the raw mode (when a pre-\/compressed file is written into a ZIP file as-\/is), it is necessary to specify the uncompressed file size and the appropriate field is 32 bit. Since the raw mode is used extremely rare, there is no real need to have a separate QuaZipNewInfo64 structure like \doxyref{QuaZipFileInfo64}{p.}{structQuaZipFileInfo64}. It may be added in the future though, if there is a demand for the raw mode with zip64 archives. - -\subsection{Constructor \& Destructor Documentation} -\index{QuaZipNewInfo@{QuaZipNewInfo}!QuaZipNewInfo@{QuaZipNewInfo}} -\index{QuaZipNewInfo@{QuaZipNewInfo}!QuaZipNewInfo@{QuaZipNewInfo}} -\subsubsection[{QuaZipNewInfo}]{\setlength{\rightskip}{0pt plus 5cm}QuaZipNewInfo::QuaZipNewInfo ( -\begin{DoxyParamCaption} -\item[{const QString \&}]{name} -\end{DoxyParamCaption} -)}\label{structQuaZipNewInfo_a46c0f551cf9e6b2131929beb39187aac} - - -Constructs \doxyref{QuaZipNewInfo}{p.}{structQuaZipNewInfo} instance. - -Initializes name with {\itshape name\/}, dateTime with current date and time. Attributes are initialized with zeros, comment and extra field with null values. \index{QuaZipNewInfo@{QuaZipNewInfo}!QuaZipNewInfo@{QuaZipNewInfo}} -\index{QuaZipNewInfo@{QuaZipNewInfo}!QuaZipNewInfo@{QuaZipNewInfo}} -\subsubsection[{QuaZipNewInfo}]{\setlength{\rightskip}{0pt plus 5cm}QuaZipNewInfo::QuaZipNewInfo ( -\begin{DoxyParamCaption} -\item[{const QString \&}]{name, } -\item[{const QString \&}]{file} -\end{DoxyParamCaption} -)}\label{structQuaZipNewInfo_ad47cf11f4277edcb09a8ba2b2963f2a9} - - -Constructs \doxyref{QuaZipNewInfo}{p.}{structQuaZipNewInfo} instance. - -Initializes name with {\itshape name\/}. Timestamp and permissions are taken from the specified file. If the {\itshape file\/} does not exists or its timestamp is inaccessible (e. g. you do not have read permission for the directory file in), uses current time and zero permissions. Other attributes are initialized with zeros, comment and extra field with null values. - -\begin{DoxySeeAlso}{See also} -\doxyref{setFileDateTime()}{p.}{structQuaZipNewInfo_a2b18b554d056877a2f33ffb9d241ed85} -\end{DoxySeeAlso} - - -References dateTime. - -\index{QuaZipNewInfo@{QuaZipNewInfo}!QuaZipNewInfo@{QuaZipNewInfo}} -\index{QuaZipNewInfo@{QuaZipNewInfo}!QuaZipNewInfo@{QuaZipNewInfo}} -\subsubsection[{QuaZipNewInfo}]{\setlength{\rightskip}{0pt plus 5cm}QuaZipNewInfo::QuaZipNewInfo ( -\begin{DoxyParamCaption} -\item[{const {\bf QuaZipFileInfo} \&}]{existing} -\end{DoxyParamCaption} -)}\label{structQuaZipNewInfo_a5f1a867f3b0d29d076f9014f70b59e5a} - - -Initializes the new instance from existing file info. - -Mainly used when copying files between archives. - -Both extra fields are initialized to existing.extra. \doxyref{QuaZipNewInfo}{p.}{structQuaZipNewInfo} -\begin{DoxyParams}{Parameters} -{\em existing} & \\ -\hline -\end{DoxyParams} -\index{QuaZipNewInfo@{QuaZipNewInfo}!QuaZipNewInfo@{QuaZipNewInfo}} -\index{QuaZipNewInfo@{QuaZipNewInfo}!QuaZipNewInfo@{QuaZipNewInfo}} -\subsubsection[{QuaZipNewInfo}]{\setlength{\rightskip}{0pt plus 5cm}QuaZipNewInfo::QuaZipNewInfo ( -\begin{DoxyParamCaption} -\item[{const {\bf QuaZipFileInfo64} \&}]{existing} -\end{DoxyParamCaption} -)}\label{structQuaZipNewInfo_a4afa2e8c282a801fc216f79026c2d062} - - -Initializes the new instance from existing file info. - -Mainly used when copying files between archives. - -Both extra fields are initialized to existing.extra. \doxyref{QuaZipNewInfo}{p.}{structQuaZipNewInfo} -\begin{DoxyParams}{Parameters} -{\em existing} & \\ -\hline -\end{DoxyParams} - - -\subsection{Member Function Documentation} -\index{QuaZipNewInfo@{QuaZipNewInfo}!setFileDateTime@{setFileDateTime}} -\index{setFileDateTime@{setFileDateTime}!QuaZipNewInfo@{QuaZipNewInfo}} -\subsubsection[{setFileDateTime}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZipNewInfo::setFileDateTime ( -\begin{DoxyParamCaption} -\item[{const QString \&}]{file} -\end{DoxyParamCaption} -)}\label{structQuaZipNewInfo_a2b18b554d056877a2f33ffb9d241ed85} - - -Sets the file timestamp from the existing file. - -Use this function to set the file timestamp from the existing file. Use it like this: -\begin{DoxyCode} - QuaZipFile zipFile(&zip); - QFile file("file-to-add"); - file.open(QIODevice::ReadOnly); - QuaZipNewInfo info("file-name-in-archive"); - info.setFileDateTime("file-to-add"); // take the timestamp from file - zipFile.open(QIODevice::WriteOnly, info); -\end{DoxyCode} - - -This function does not change dateTime if some error occured (e. g. file is inaccessible). - -References dateTime. - -\index{QuaZipNewInfo@{QuaZipNewInfo}!setFilePermissions@{setFilePermissions}} -\index{setFilePermissions@{setFilePermissions}!QuaZipNewInfo@{QuaZipNewInfo}} -\subsubsection[{setFilePermissions}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZipNewInfo::setFilePermissions ( -\begin{DoxyParamCaption} -\item[{const QString \&}]{file} -\end{DoxyParamCaption} -)}\label{structQuaZipNewInfo_a08bee5211eb0b49da260c7a9e7a266b8} - - -Sets the file permissions from the existing file. - -Takes permissions from the file and sets the high 16 bits of external attributes. Uses QFileInfo to get permissions on all platforms. \index{QuaZipNewInfo@{QuaZipNewInfo}!setPermissions@{setPermissions}} -\index{setPermissions@{setPermissions}!QuaZipNewInfo@{QuaZipNewInfo}} -\subsubsection[{setPermissions}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZipNewInfo::setPermissions ( -\begin{DoxyParamCaption} -\item[{QFile::Permissions}]{permissions} -\end{DoxyParamCaption} -)}\label{structQuaZipNewInfo_aed68dc20f7dc42b5056491cf3c1d2d20} - - -Sets the file permissions. - -Modifies the highest 16 bits of external attributes. The type part is set to dir if the name ends with a slash, and to regular file otherwise. - -References name. - -\index{QuaZipNewInfo@{QuaZipNewInfo}!setFileNTFSTimes@{setFileNTFSTimes}} -\index{setFileNTFSTimes@{setFileNTFSTimes}!QuaZipNewInfo@{QuaZipNewInfo}} -\subsubsection[{setFileNTFSTimes}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZipNewInfo::setFileNTFSTimes ( -\begin{DoxyParamCaption} -\item[{const QString \&}]{fileName} -\end{DoxyParamCaption} -)}\label{structQuaZipNewInfo_a663a37c5a7a2d18900ba8b0199617eff} - - -Sets the NTFS times from an existing file. - -If the file doesn't exist, a warning is printed to the stderr and nothing is done. Otherwise, all three times, as reported by QFileInfo::lastModified(), QFileInfo::lastRead() and QFileInfo::created(), are written to the NTFS extra field record. - -The NTFS record is written to both the local and the global extra fields, updating the existing record if there is one, or creating a new one and appending it to the end of each extra field. - -The microseconds will be zero, as they aren't reported by QFileInfo. -\begin{DoxyParams}{Parameters} -{\em fileName} & \\ -\hline -\end{DoxyParams} - - -References setFileNTFSaTime(), setFileNTFScTime(), and setFileNTFSmTime(). - -\index{QuaZipNewInfo@{QuaZipNewInfo}!setFileNTFSmTime@{setFileNTFSmTime}} -\index{setFileNTFSmTime@{setFileNTFSmTime}!QuaZipNewInfo@{QuaZipNewInfo}} -\subsubsection[{setFileNTFSmTime}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZipNewInfo::setFileNTFSmTime ( -\begin{DoxyParamCaption} -\item[{const QDateTime \&}]{mTime, } -\item[{int}]{fineTicks = {\ttfamily 0}} -\end{DoxyParamCaption} -)}\label{structQuaZipNewInfo_a3af07365df1d67502ab1d0ca0d45df79} - - -Sets the NTFS modification time. - -The time is written into the NTFS record in both the local and the global extra fields, updating the existing record if there is one, or creating a new one and appending it to the end of each extra field. When updating an existing record, all other fields are left intact. -\begin{DoxyParams}{Parameters} -{\em mTime} & The new modification time. \\ -\hline -{\em fineTicks} & The fractional part of milliseconds, in 100-\/nanosecond ticks (i. e. 9999 ticks = 999.9 microsecond). Values greater than 9999 will add milliseconds or even seconds, but this can be confusing and therefore is discouraged. \\ -\hline -\end{DoxyParams} - - -References extraGlobal, and extraLocal. - - - -Referenced by setFileNTFSTimes(). - -\index{QuaZipNewInfo@{QuaZipNewInfo}!setFileNTFSaTime@{setFileNTFSaTime}} -\index{setFileNTFSaTime@{setFileNTFSaTime}!QuaZipNewInfo@{QuaZipNewInfo}} -\subsubsection[{setFileNTFSaTime}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZipNewInfo::setFileNTFSaTime ( -\begin{DoxyParamCaption} -\item[{const QDateTime \&}]{aTime, } -\item[{int}]{fineTicks = {\ttfamily 0}} -\end{DoxyParamCaption} -)}\label{structQuaZipNewInfo_a1042ac3d55a9deed760eb357aaa8284c} - - -Sets the NTFS access time. - -The time is written into the NTFS record in both the local and the global extra fields, updating the existing record if there is one, or creating a new one and appending it to the end of each extra field. When updating an existing record, all other fields are left intact. -\begin{DoxyParams}{Parameters} -{\em aTime} & The new access time. \\ -\hline -{\em fineTicks} & The fractional part of milliseconds, in 100-\/nanosecond ticks (i. e. 9999 ticks = 999.9 microsecond). Values greater than 9999 will add milliseconds or even seconds, but this can be confusing and therefore is discouraged. \\ -\hline -\end{DoxyParams} - - -References extraGlobal, and extraLocal. - - - -Referenced by setFileNTFSTimes(). - -\index{QuaZipNewInfo@{QuaZipNewInfo}!setFileNTFScTime@{setFileNTFScTime}} -\index{setFileNTFScTime@{setFileNTFScTime}!QuaZipNewInfo@{QuaZipNewInfo}} -\subsubsection[{setFileNTFScTime}]{\setlength{\rightskip}{0pt plus 5cm}void QuaZipNewInfo::setFileNTFScTime ( -\begin{DoxyParamCaption} -\item[{const QDateTime \&}]{cTime, } -\item[{int}]{fineTicks = {\ttfamily 0}} -\end{DoxyParamCaption} -)}\label{structQuaZipNewInfo_a44675ac1e306eddefcaa35972c294d15} - - -Sets the NTFS creation time. - -The time is written into the NTFS record in both the local and the global extra fields, updating the existing record if there is one, or creating a new one and appending it to the end of each extra field. When updating an existing record, all other fields are left intact. -\begin{DoxyParams}{Parameters} -{\em cTime} & The new creation time. \\ -\hline -{\em fineTicks} & The fractional part of milliseconds, in 100-\/nanosecond ticks (i. e. 9999 ticks = 999.9 microsecond). Values greater than 9999 will add milliseconds or even seconds, but this can be confusing and therefore is discouraged. \\ -\hline -\end{DoxyParams} - - -References extraGlobal, and extraLocal. - - - -Referenced by setFileNTFSTimes(). - - - -\subsection{Member Data Documentation} -\index{QuaZipNewInfo@{QuaZipNewInfo}!name@{name}} -\index{name@{name}!QuaZipNewInfo@{QuaZipNewInfo}} -\subsubsection[{name}]{\setlength{\rightskip}{0pt plus 5cm}QString {\bf QuaZipNewInfo::name}}\label{structQuaZipNewInfo_a2bdef01b6ac3326e48598e32bfa5fbe8} - - -File name. - -This field holds file name inside archive, including path relative to archive root. - -Referenced by QuaZipFile::open(), and setPermissions(). - -\index{QuaZipNewInfo@{QuaZipNewInfo}!dateTime@{dateTime}} -\index{dateTime@{dateTime}!QuaZipNewInfo@{QuaZipNewInfo}} -\subsubsection[{dateTime}]{\setlength{\rightskip}{0pt plus 5cm}QDateTime {\bf QuaZipNewInfo::dateTime}}\label{structQuaZipNewInfo_aec7f3ac72c72a2e10b82ad64c2fa3453} - - -File timestamp. - -This is the last file modification date and time. Will be stored in the archive central directory. It is a good practice to set it to the source file timestamp instead of archive creating time. Use \doxyref{setFileDateTime()}{p.}{structQuaZipNewInfo_a2b18b554d056877a2f33ffb9d241ed85} or \doxyref{QuaZipNewInfo(const QString\&, const QString\&)}{p.}{structQuaZipNewInfo_ad47cf11f4277edcb09a8ba2b2963f2a9}. - -Referenced by QuaZipFile::open(), QuaZipNewInfo(), and setFileDateTime(). - -\index{QuaZipNewInfo@{QuaZipNewInfo}!externalAttr@{externalAttr}} -\index{externalAttr@{externalAttr}!QuaZipNewInfo@{QuaZipNewInfo}} -\subsubsection[{externalAttr}]{\setlength{\rightskip}{0pt plus 5cm}quint32 {\bf QuaZipNewInfo::externalAttr}}\label{structQuaZipNewInfo_affd1a9700d302e1395bd04f0864da7d0} - - -File external attributes. - -The highest 16 bits contain Unix file permissions and type (dir or file). The constructor \doxyref{QuaZipNewInfo(const QString\&, const QString\&)}{p.}{structQuaZipNewInfo_ad47cf11f4277edcb09a8ba2b2963f2a9} takes permissions from the provided file. - -Referenced by QuaZipFile::open(). - -\index{QuaZipNewInfo@{QuaZipNewInfo}!comment@{comment}} -\index{comment@{comment}!QuaZipNewInfo@{QuaZipNewInfo}} -\subsubsection[{comment}]{\setlength{\rightskip}{0pt plus 5cm}QString {\bf QuaZipNewInfo::comment}}\label{structQuaZipNewInfo_ae24b1d38c3550b4724862ffcf8f20924} - - -File comment. - -Will be encoded using \doxyref{QuaZip::getCommentCodec()}{p.}{classQuaZip_a008260161781d8b5d2a0a28493fddaf4}. - -Referenced by QuaZipFile::open(). - -\index{QuaZipNewInfo@{QuaZipNewInfo}!uncompressedSize@{uncompressedSize}} -\index{uncompressedSize@{uncompressedSize}!QuaZipNewInfo@{QuaZipNewInfo}} -\subsubsection[{uncompressedSize}]{\setlength{\rightskip}{0pt plus 5cm}ulong {\bf QuaZipNewInfo::uncompressedSize}}\label{structQuaZipNewInfo_a18c079b3f2f5ab6eecdd61d6dbe93be6} - - -Uncompressed file size. - -This is only needed if you are using raw file zipping mode, i. e. adding precompressed file in the zip archive. - -Referenced by QuaZipFile::open(). - - - -The documentation for this struct was generated from the following files:\begin{DoxyCompactItemize} -\item -quazip/quazipnewinfo.h\item -quazip/quazipnewinfo.cpp\end{DoxyCompactItemize} diff --git a/hecl-gui/quazip/doc/latex/usage.tex b/hecl-gui/quazip/doc/latex/usage.tex deleted file mode 100644 index f2aed82ed..000000000 --- a/hecl-gui/quazip/doc/latex/usage.tex +++ /dev/null @@ -1,22 +0,0 @@ -This page provides general information on QuaZIP usage. See classes \doxyref{QuaZip}{p.}{classQuaZip} and \doxyref{QuaZipFile}{p.}{classQuaZipFile} for the detailed documentation on what can QuaZIP do and what it can not. Also, reading comments in the zip.h and unzip.h files (taken from the original ZIP/UNZIP package) is always a good idea too. After all, QuaZIP is just a wrapper with a few convenience extensions and reimplementations. - -\doxyref{QuaZip}{p.}{classQuaZip} is a class representing ZIP archive, \doxyref{QuaZipFile}{p.}{classQuaZipFile} represents a file inside archive and subclasses QIODevice as well. One limitation is that there can be only one instance of \doxyref{QuaZipFile}{p.}{classQuaZipFile} per \doxyref{QuaZip}{p.}{classQuaZip} instance, which kind of makes it confusing why there are two classes instead of one. This is actually no more than an API design mistake.\section{Terminology}\label{usage_terminology} -\char`\"{}QuaZIP\char`\"{} means whole this library, while \char`\"{}QuaZip\char`\"{} (note the lower case) is just one class in it. - -\char`\"{}ZIP/UNZIP API\char`\"{} or \char`\"{}minizip\char`\"{} means the original API of the Gilles Vollant's ZIP/UNZIP package. It was slightly modified to better integrate with Qt. These modifications are not source or binary compatible with the official minizip release, which means you can't just drop the newer minizip version into QuaZIP sources and make it work. - -\char`\"{}ZIP\char`\"{}, \char`\"{}ZIP archive\char`\"{} or \char`\"{}ZIP file\char`\"{} means any ZIP archive. Typically this is a plain file with \char`\"{}.zip\char`\"{} (or \char`\"{}.ZIP\char`\"{}) file name suffix, but it can also be any seekable QIODevice (say, QBuffer, but not QTcpSocket). - -\char`\"{}A file inside archive\char`\"{}, \char`\"{}a file inside ZIP\char`\"{} or something like that means file either being read or written from/to some ZIP archive.\section{Error handling}\label{usage_error-handling} -Almost any call to ZIP/UNZIP API return some error code. Most of the original API's error checking could be done in this wrapper as well, but it would cause unnecessary code bloating without any benefit. So, QuaZIP only checks for situations that ZIP/UNZIP API can not check for. For example, ZIP/UNZIP API has no \char`\"{}ZIP open mode\char`\"{} concept because read and write modes are completely separated. On the other hand, to avoid creating classes like \char`\"{}QuaZipReader\char`\"{}, \char`\"{}QuaZipWriter\char`\"{} or something like that, QuaZIP introduces \char`\"{}ZIP open mode\char`\"{} concept instead, thus making it possible to use one class (\doxyref{QuaZip}{p.}{classQuaZip}) for both reading and writing. But this leads to additional open mode checks which are not done in ZIP/UNZIP package. - -Therefore, error checking is two-\/level (QuaZIP's level and ZIP/UNZIP API level), which sometimes can be confusing, so here are some advices on how the error checking should be properly done: - - -\begin{DoxyItemize} -\item Both \doxyref{QuaZip}{p.}{classQuaZip} and \doxyref{QuaZipFile}{p.}{classQuaZipFile} have getZipError() function, which return error code of the last ZIP/UNZIP API call. Most function calls reset error code to UNZ\_\-OK on success and set error code on failure. Some functions do not reset error code. Most of them are {\ttfamily const} and do not access ZIP archive in any way. Some, on the other hand, {\itshape do\/} access ZIP archive, but do not reset or set error code. For example, \doxyref{QuaZipFile::pos()}{p.}{classQuaZipFile_a90fd55dab83eca7f95df50b2c41b7f22} function. Such functions are explicitly marked in the documentation. -\item Most functions have their own way to report errors, by returning a null string, negative value or {\ttfamily false}. If such a function returns error value, call getZipError() to get more information about error. See \char`\"{}zip.h\char`\"{} and \char`\"{}unzip.h\char`\"{} of the ZIP/UNZIP package for error codes. -\item If the function returns error-\/stating value (like {\ttfamily false}), but getZipError() returns UNZ\_\-OK, it means that you did something obviously wrong. For example, tried to write in the archive open for reading or not open at all. You better just not do that! Most functions also issue a warning using qWarning() function in such cases. See documentation for a specific function for details on when it should not be called. -\end{DoxyItemize} - -I know that this is somewhat messy, but I could not find a better way to do all the error handling. \ No newline at end of file diff --git a/hecl-gui/quazip/quazip/CMakeLists.txt b/hecl-gui/quazip/quazip/CMakeLists.txt index 94ed80b05..d16377800 100644 --- a/hecl-gui/quazip/quazip/CMakeLists.txt +++ b/hecl-gui/quazip/quazip/CMakeLists.txt @@ -1,22 +1,36 @@ -# set all include directories for in and out of source builds -include_directories( - ${CMAKE_CURRENT_SOURCE_DIR} - ${CMAKE_CURRENT_BINARY_DIR} - ${ZLIB_INCLUDE_DIR} -) - -file(GLOB SRCS "*.c" "*.cpp") -file(GLOB PUBLIC_HEADERS "*.h") - -# Must be added to enable export macro -ADD_DEFINITIONS(-DQUAZIP_BUILD) - -qt5_wrap_cpp(MOC_SRCS ${PUBLIC_HEADERS}) -set(SRCS ${SRCS} ${MOC_SRCS}) - -add_library(quazip SHARED ${SRCS}) -set_target_properties(quazip PROPERTIES VERSION 1.0.0 SOVERSION 1) -target_link_libraries(quazip Qt5::Core ${ZLIB_LIBRARY}) - -install(FILES ${PUBLIC_HEADERS} DESTINATION include/quazip) -install(TARGETS quazip LIBRARY DESTINATION ${LIB_DESTINATION} ARCHIVE DESTINATION ${LIB_DESTINATION} RUNTIME DESTINATION ${LIB_DESTINATION}) +file(GLOB SRCS "*.c" "*.cpp") +file(GLOB PUBLIC_HEADERS "*.h") + +set(QUAZIP_LIB_VERSION 1.0.0) +set(QUAZIP_LIB_SOVERSION 1) + +# Must be added to enable export macro +ADD_DEFINITIONS(-DQUAZIP_BUILD) + +qt_wrap_cpp(MOC_SRCS ${PUBLIC_HEADERS}) +set(SRCS ${SRCS} ${MOC_SRCS}) + +add_library(${QUAZIP_LIB_TARGET_NAME} SHARED ${SRCS}) +add_library(quazip_static STATIC ${SRCS}) + +# Windows uses .lib extension for both static and shared library +# *nix systems use different extensions for SHARED and STATIC library and by convention both libraries have the same name +if (NOT WIN32) + set_target_properties(quazip_static PROPERTIES OUTPUT_NAME quazip${QUAZIP_LIB_VERSION_SUFFIX}) +endif () + +target_include_directories(${QUAZIP_LIB_TARGET_NAME} PUBLIC ${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR} ${ZLIB_INCLUDE_DIRS}) +target_include_directories(quazip_static PUBLIC ${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR} ${ZLIB_INCLUDE_DIRS}) +set_target_properties(${QUAZIP_LIB_TARGET_NAME} quazip_static PROPERTIES VERSION ${QUAZIP_LIB_VERSION} SOVERSION ${QUAZIP_LIB_SOVERSION} DEBUG_POSTFIX d) + +# Link against ZLIB_LIBRARIES if needed (on Windows this variable is empty) +target_link_libraries(${QUAZIP_LIB_TARGET_NAME} ${QT_QTMAIN_LIBRARY} ${QTCORE_LIBRARIES} ${ZLIB_LIBRARIES}) +target_link_libraries(quazip_static ${QT_QTMAIN_LIBRARY} ${QTCORE_LIBRARIES} ${ZLIB_LIBRARIES}) + +if(UNIX AND NOT APPLE) + configure_file( ${CMAKE_SOURCE_DIR}/quazip.pc.cmakein + ${CMAKE_BINARY_DIR}/quazip.pc @ONLY) + install(FILES ${CMAKE_BINARY_DIR}/quazip.pc DESTINATION "${INSTALL_PKGCONFIG_DIR}") +endif() +install(FILES ${PUBLIC_HEADERS} DESTINATION include/quazip${QUAZIP_LIB_VERSION_SUFFIX}) +install(TARGETS ${QUAZIP_LIB_TARGET_NAME} quazip_static LIBRARY DESTINATION ${LIB_DESTINATION} ARCHIVE DESTINATION ${LIB_DESTINATION} RUNTIME DESTINATION ${LIB_DESTINATION}) diff --git a/hecl-gui/quazip/quazip/JlCompress.cpp b/hecl-gui/quazip/quazip/JlCompress.cpp index 4be77b646..c588cf93d 100644 --- a/hecl-gui/quazip/quazip/JlCompress.cpp +++ b/hecl-gui/quazip/quazip/JlCompress.cpp @@ -6,7 +6,7 @@ This file is part of QuaZIP. QuaZIP is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by -the Free Software Foundation, either version 3 of the License, or +the Free Software Foundation, either version 2.1 of the License, or (at your option) any later version. QuaZIP is distributed in the hope that it will be useful, @@ -39,17 +39,6 @@ static bool copyData(QIODevice &inFile, QIODevice &outFile) return true; } -/**OK - * Comprime il file fileName, nell'oggetto zip, con il nome fileDest. - * - * La funzione fallisce se: - * * zip==NULL; - * * l'oggetto zip e stato aperto in una modalita non compatibile con l'aggiunta di file; - * * non e possibile aprire il file d'origine; - * * non e possibile creare il file all'interno dell'oggetto zip; - * * si e rilevato un errore nella copia dei dati; - * * non e stato possibile chiudere il file all'interno dell'oggetto zip; - */ bool JlCompress::compressFile(QuaZip* zip, QString fileName, QString fileDest) { // zip: oggetto dove aggiungere il file // fileName: nome del file reale @@ -83,24 +72,7 @@ bool JlCompress::compressFile(QuaZip* zip, QString fileName, QString fileDest) { return true; } -/**OK - * Comprime la cartella dir nel file fileCompressed, se recursive e true allora - * comprime anche le sotto cartelle. I nomi dei file preceduti dal path creato - * togliendo il pat della cartella origDir al path della cartella dir. - * Se la funzione fallisce restituisce false e cancella il file che si e tentato - * di creare. - * - * La funzione fallisce se: - * * zip==NULL; - * * l'oggetto zip e stato aperto in una modalita non compatibile con l'aggiunta di file; - * * la cartella dir non esiste; - * * la compressione di una sotto cartella fallisce (1); - * * la compressione di un file fallisce; - * (1) La funzione si richiama in maniera ricorsiva per comprimere le sotto cartelle - * dunque gli errori di compressione di una sotto cartella sono gli stessi di questa - * funzione. - */ -bool JlCompress::compressSubDir(QuaZip* zip, QString dir, QString origDir, bool recursive) { +bool JlCompress::compressSubDir(QuaZip* zip, QString dir, QString origDir, bool recursive, QDir::Filters filters) { // zip: oggetto dove aggiungere il file // dir: cartella reale corrente // origDir: cartella reale originale @@ -120,7 +92,7 @@ bool JlCompress::compressSubDir(QuaZip* zip, QString dir, QString origDir, bool if (dir != origDir) { QuaZipFile dirZipFile(zip); if (!dirZipFile.open(QIODevice::WriteOnly, - QuaZipNewInfo(origDirectory.relativeFilePath(dir) + "/", dir), 0, 0, 0)) { + QuaZipNewInfo(origDirectory.relativeFilePath(dir) + QLatin1String("/"), dir), 0, 0, 0)) { return false; } dirZipFile.close(); @@ -130,16 +102,22 @@ bool JlCompress::compressSubDir(QuaZip* zip, QString dir, QString origDir, bool // Se comprimo anche le sotto cartelle if (recursive) { // Per ogni sotto cartella - QFileInfoList files = directory.entryInfoList(QDir::AllDirs|QDir::NoDotAndDotDot); - Q_FOREACH (QFileInfo file, files) { + QFileInfoList files = directory.entryInfoList(QDir::AllDirs|QDir::NoDotAndDotDot|filters); + for (int index = 0; index < files.size(); ++index ) { + const QFileInfo & file( files.at( index ) ); +#if QT_VERSION < QT_VERSION_CHECK(4, 7, 4) + if (!file.isDir()) + continue; +#endif // Comprimo la sotto cartella - if(!compressSubDir(zip,file.absoluteFilePath(),origDir,recursive)) return false; + if(!compressSubDir(zip,file.absoluteFilePath(),origDir,recursive,filters)) return false; } } // Per ogni file nella cartella - QFileInfoList files = directory.entryInfoList(QDir::Files); - Q_FOREACH (QFileInfo file, files) { + QFileInfoList files = directory.entryInfoList(QDir::Files|filters); + for (int index = 0; index < files.size(); ++index ) { + const QFileInfo & file( files.at( index ) ); // Se non e un file o e il file compresso che sto creando if(!file.isFile()||file.absoluteFilePath()==zip->getZipName()) continue; @@ -153,20 +131,6 @@ bool JlCompress::compressSubDir(QuaZip* zip, QString dir, QString origDir, bool return true; } -/**OK - * Estrae il file fileName, contenuto nell'oggetto zip, con il nome fileDest. - * Se la funzione fallisce restituisce false e cancella il file che si e tentato di estrarre. - * - * La funzione fallisce se: - * * zip==NULL; - * * l'oggetto zip e stato aperto in una modalita non compatibile con l'estrazione di file; - * * non e possibile aprire il file all'interno dell'oggetto zip; - * * non e possibile creare il file estratto; - * * si e rilevato un errore nella copia dei dati (1); - * * non e stato possibile chiudere il file all'interno dell'oggetto zip (1); - * - * (1): prima di uscire dalla funzione cancella il file estratto. - */ bool JlCompress::extractFile(QuaZip* zip, QString fileName, QString fileDest) { // zip: oggetto dove aggiungere il file // filename: nome del file reale @@ -184,7 +148,7 @@ bool JlCompress::extractFile(QuaZip* zip, QString fileName, QString fileDest) { // Controllo esistenza cartella file risultato QDir curDir; - if (fileDest.endsWith('/')) { + if (fileDest.endsWith(QLatin1String("/"))) { if (!curDir.mkpath(fileDest)) { return false; } @@ -199,7 +163,7 @@ bool JlCompress::extractFile(QuaZip* zip, QString fileName, QString fileDest) { return false; QFile::Permissions srcPerm = info.getPermissions(); - if (fileDest.endsWith('/') && QFileInfo(fileDest).isDir()) { + if (fileDest.endsWith(QLatin1String("/")) && QFileInfo(fileDest).isDir()) { if (srcPerm != 0) { QFile(fileDest).setPermissions(srcPerm); } @@ -232,12 +196,6 @@ bool JlCompress::extractFile(QuaZip* zip, QString fileName, QString fileDest) { return true; } -/** - * Rimuove i file il cui nome e specificato all'interno di listFile. - * Restituisce true se tutti i file sono stati cancellati correttamente, attenzione - * perche puo restituire false anche se alcuni file non esistevano e si e tentato - * di cancellarli. - */ bool JlCompress::removeFile(QStringList listFile) { bool ret = true; // Per ogni file @@ -248,18 +206,6 @@ bool JlCompress::removeFile(QStringList listFile) { return ret; } -//////////////////////////////////////////////////////////////////////////////// -//////////////////////////////////////////////////////////////////////////////// -/**OK - * Comprime il file fileName nel file fileCompressed. - * Se la funzione fallisce restituisce false e cancella il file che si e tentato - * di creare. - * - * La funzione fallisce se: - * * non si riesce ad aprire l'oggetto zip; - * * la compressione del file fallisce; - * * non si riesce a chiudere l'oggetto zip; - */ bool JlCompress::compressFile(QString fileCompressed, QString file) { // Creo lo zip QuaZip zip(fileCompressed); @@ -285,16 +231,6 @@ bool JlCompress::compressFile(QString fileCompressed, QString file) { return true; } -/**OK - * Comprime i file specificati in files nel file fileCompressed. - * Se la funzione fallisce restituisce false e cancella il file che si e tentato - * di creare. - * - * La funzione fallisce se: - * * non si riesce ad aprire l'oggetto zip; - * * la compressione di un file fallisce; - * * non si riesce a chiudere l'oggetto zip; - */ bool JlCompress::compressFiles(QString fileCompressed, QStringList files) { // Creo lo zip QuaZip zip(fileCompressed); @@ -306,7 +242,8 @@ bool JlCompress::compressFiles(QString fileCompressed, QStringList files) { // Comprimo i file QFileInfo info; - Q_FOREACH (QString file, files) { + for (int index = 0; index < files.size(); ++index ) { + const QString & file( files.at( index ) ); info.setFile(file); if (!info.exists() || !compressFile(&zip,file,info.fileName())) { QFile::remove(fileCompressed); @@ -324,18 +261,13 @@ bool JlCompress::compressFiles(QString fileCompressed, QStringList files) { return true; } -/**OK - * Comprime la cartella dir nel file fileCompressed, se recursive e true allora - * comprime anche le sotto cartelle. - * Se la funzione fallisce restituisce false e cancella il file che si e tentato - * di creare. - * - * La funzione fallisce se: - * * non si riesce ad aprire l'oggetto zip; - * * la compressione di un file fallisce; - * * non si riesce a chiudere l'oggetto zip; - */ bool JlCompress::compressDir(QString fileCompressed, QString dir, bool recursive) { + return compressDir(fileCompressed, dir, recursive, 0); +} + +bool JlCompress::compressDir(QString fileCompressed, QString dir, + bool recursive, QDir::Filters filters) +{ // Creo lo zip QuaZip zip(fileCompressed); QDir().mkpath(QFileInfo(fileCompressed).absolutePath()); @@ -345,7 +277,7 @@ bool JlCompress::compressDir(QString fileCompressed, QString dir, bool recursive } // Aggiungo i file e le sotto cartelle - if (!compressSubDir(&zip,dir,dir,recursive)) { + if (!compressSubDir(&zip,dir,dir,recursive, filters)) { QFile::remove(fileCompressed); return false; } @@ -360,29 +292,20 @@ bool JlCompress::compressDir(QString fileCompressed, QString dir, bool recursive return true; } -//////////////////////////////////////////////////////////////////////////////// -//////////////////////////////////////////////////////////////////////////////// -/**OK - * Estrae il file fileName, contenuto nel file fileCompressed, con il nome fileDest. - * Se fileDest = "" allora il file viene estratto con lo stesso nome con cui e - * stato compresso. - * Se la funzione fallisce cancella il file che si e tentato di estrarre. - * Restituisce il nome assoluto del file estratto. - * - * La funzione fallisce se: - * * non si riesce ad aprire l'oggetto zip; - * * l'estrazione del file fallisce; - * * non si riesce a chiudere l'oggetto zip; - */ QString JlCompress::extractFile(QString fileCompressed, QString fileName, QString fileDest) { // Apro lo zip QuaZip zip(fileCompressed); + return extractFile(zip, fileName, fileDest); +} + +QString JlCompress::extractFile(QuaZip &zip, QString fileName, QString fileDest) +{ if(!zip.open(QuaZip::mdUnzip)) { return QString(); } // Estraggo il file - if (fileDest.isEmpty()) + if (fileDest.isEmpty()) fileDest = fileName; if (!extractFile(&zip,fileName,fileDest)) { return QString(); @@ -397,21 +320,14 @@ QString JlCompress::extractFile(QString fileCompressed, QString fileName, QStrin return QFileInfo(fileDest).absoluteFilePath(); } -/**OK - * Estrae i file specificati in files, contenuti nel file fileCompressed, nella - * cartella dir. La struttura a cartelle del file compresso viene rispettata. - * Se dir = "" allora il file viene estratto nella cartella corrente. - * Se la funzione fallisce cancella i file che si e tentato di estrarre. - * Restituisce i nomi assoluti dei file estratti. - * - * La funzione fallisce se: - * * non si riesce ad aprire l'oggetto zip; - * * l'estrazione di un file fallisce; - * * non si riesce a chiudere l'oggetto zip; - */ QStringList JlCompress::extractFiles(QString fileCompressed, QStringList files, QString dir) { // Creo lo zip QuaZip zip(fileCompressed); + return extractFiles(zip, files, dir); +} + +QStringList JlCompress::extractFiles(QuaZip &zip, const QStringList &files, const QString &dir) +{ if(!zip.open(QuaZip::mdUnzip)) { return QStringList(); } @@ -437,25 +353,20 @@ QStringList JlCompress::extractFiles(QString fileCompressed, QStringList files, return extracted; } -/**OK - * Estrae il file fileCompressed nella cartella dir. - * Se dir = "" allora il file viene estratto nella cartella corrente. - * Se la funzione fallisce cancella i file che si e tentato di estrarre. - * Restituisce i nomi assoluti dei file estratti. - * - * La funzione fallisce se: - * * non si riesce ad aprire l'oggetto zip; - * * la compressione di un file fallisce; - * * non si riesce a chiudere l'oggetto zip; - */ QStringList JlCompress::extractDir(QString fileCompressed, QString dir) { // Apro lo zip QuaZip zip(fileCompressed); + return extractDir(zip, dir); +} + +QStringList JlCompress::extractDir(QuaZip &zip, const QString &dir) +{ if(!zip.open(QuaZip::mdUnzip)) { return QStringList(); } - - QDir directory(dir); + QString cleanDir = QDir::cleanPath(dir); + QDir directory(cleanDir); + QString absCleanDir = directory.absolutePath(); QStringList extracted; if (!zip.goToFirstFile()) { return QStringList(); @@ -463,7 +374,10 @@ QStringList JlCompress::extractDir(QString fileCompressed, QString dir) { do { QString name = zip.getCurrentFileName(); QString absFilePath = directory.absoluteFilePath(name); - if (!extractFile(&zip, "", absFilePath)) { + QString absCleanPath = QDir::cleanPath(absFilePath); + if (!absCleanPath.startsWith(absCleanDir + QLatin1String("/"))) + continue; + if (!extractFile(&zip, QLatin1String(""), absFilePath)) { removeFile(extracted); return QStringList(); } @@ -480,18 +394,14 @@ QStringList JlCompress::extractDir(QString fileCompressed, QString dir) { return extracted; } -/**OK - * Restituisce la lista dei file resenti nel file compresso fileCompressed. - * Se la funzione fallisce, restituisce un elenco vuoto. - * - * La funzione fallisce se: - * * non si riesce ad aprire l'oggetto zip; - * * la richiesta di informazioni di un file fallisce; - * * non si riesce a chiudere l'oggetto zip; - */ QStringList JlCompress::getFileList(QString fileCompressed) { // Apro lo zip QuaZip* zip = new QuaZip(QFileInfo(fileCompressed).absoluteFilePath()); + return getFileList(zip); +} + +QStringList JlCompress::getFileList(QuaZip *zip) +{ if(!zip->open(QuaZip::mdUnzip)) { delete zip; return QStringList(); @@ -516,7 +426,29 @@ QStringList JlCompress::getFileList(QString fileCompressed) { return QStringList(); } delete zip; - return lst; } +QStringList JlCompress::extractDir(QIODevice *ioDevice, QString dir) +{ + QuaZip zip(ioDevice); + return extractDir(zip, dir); +} + +QStringList JlCompress::getFileList(QIODevice *ioDevice) +{ + QuaZip *zip = new QuaZip(ioDevice); + return getFileList(zip); +} + +QString JlCompress::extractFile(QIODevice *ioDevice, QString fileName, QString fileDest) +{ + QuaZip zip(ioDevice); + return extractFile(zip, fileName, fileDest); +} + +QStringList JlCompress::extractFiles(QIODevice *ioDevice, QStringList files, QString dir) +{ + QuaZip zip(ioDevice); + return extractFiles(zip, files, dir); +} diff --git a/hecl-gui/quazip/quazip/JlCompress.h b/hecl-gui/quazip/quazip/JlCompress.h index 62543f778..49c50865b 100644 --- a/hecl-gui/quazip/quazip/JlCompress.h +++ b/hecl-gui/quazip/quazip/JlCompress.h @@ -3,13 +3,13 @@ /* Copyright (C) 2010 Roberto Pompermaier -Copyright (C) 2005-2014 Sergey A. Tachenov +Copyright (C) 2005-2016 Sergey A. Tachenov This file is part of QuaZIP. QuaZIP is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by -the Free Software Foundation, either version 3 of the License, or +the Free Software Foundation, either version 2.1 of the License, or (at your option) any later version. QuaZIP is distributed in the hope that it will be useful, @@ -41,6 +41,10 @@ see quazip/(un)zip.h files for details. Basically it's the zlib license. */ class QUAZIP_EXPORT JlCompress { private: + static QStringList extractDir(QuaZip &zip, const QString &dir); + static QStringList getFileList(QuaZip *zip); + static QString extractFile(QuaZip &zip, QString fileName, QString fileDest); + static QStringList extractFiles(QuaZip &zip, const QStringList &files, const QString &dir); /// Compress a single file. /** \param zip Opened zip to compress the file to. @@ -59,7 +63,8 @@ private: files. \return true if success, false otherwise. */ - static bool compressSubDir(QuaZip* parentZip, QString dir, QString parentDir, bool recursive = true); + static bool compressSubDir(QuaZip* parentZip, QString dir, QString parentDir, bool recursive, + QDir::Filters filters); /// Extract a single file. /** \param zip The opened zip archive to extract from. @@ -92,6 +97,8 @@ public: static bool compressFiles(QString fileCompressed, QStringList files); /// Compress a whole directory. /** + Does not compress hidden files. See compressDir(QString, QString, bool, QDir::Filters). + \param fileCompressed The name of the archive. \param dir The directory to compress. \param recursive Whether to pack the subdirectories as well, or @@ -99,6 +106,24 @@ public: \return true if success, false otherwise. */ static bool compressDir(QString fileCompressed, QString dir = QString(), bool recursive = true); + /** + * @brief Compress a whole directory. + * + * Unless filters are specified explicitly, packs + * only regular non-hidden files (and subdirs, if @c recursive is true). + * If filters are specified, they are OR-combined with + * %QDir::AllDirs|%QDir::NoDotAndDotDot when searching for dirs + * and with QDir::Files when searching for files. + * + * @param fileCompressed path to the resulting archive + * @param dir path to the directory being compressed + * @param recursive if true, then the subdirectories are packed as well + * @param filters what to pack, filters are applied both when searching + * for subdirs (if packing recursively) and when looking for files to pack + * @return true on success, false otherwise + */ + static bool compressDir(QString fileCompressed, QString dir, + bool recursive, QDir::Filters filters); public: /// Extract a single file. @@ -134,6 +159,39 @@ public: are present separately. */ static QStringList getFileList(QString fileCompressed); + /// Extract a single file. + /** + \param ioDevice pointer to device with compressed data. + \param fileName The file to extract. + \param fileDest The destination file, assumed to be identical to + \a file if left empty. + \return The list of the full paths of the files extracted, empty on failure. + */ + static QString extractFile(QIODevice *ioDevice, QString fileName, QString fileDest = QString()); + /// Extract a list of files. + /** + \param ioDevice pointer to device with compressed data. + \param files The file list to extract. + \param dir The directory to put the files to, the current + directory if left empty. + \return The list of the full paths of the files extracted, empty on failure. + */ + static QStringList extractFiles(QIODevice *ioDevice, QStringList files, QString dir = QString()); + /// Extract a whole archive. + /** + \param ioDevice pointer to device with compressed data. + \param dir The directory to extract to, the current directory if + left empty. + \return The list of the full paths of the files extracted, empty on failure. + */ + static QStringList extractDir(QIODevice *ioDevice, QString dir = QString()); + /// Get the file list. + /** + \return The list of the files in the archive, or, more precisely, the + list of the entries, including both files and directories if they + are present separately. + */ + static QStringList getFileList(QIODevice *ioDevice); }; #endif /* JLCOMPRESSFOLDER_H_ */ diff --git a/hecl-gui/quazip/quazip/doc/faq.dox b/hecl-gui/quazip/quazip/doc/faq.dox index d512a0758..ca6db5c51 100644 --- a/hecl-gui/quazip/quazip/doc/faq.dox +++ b/hecl-gui/quazip/quazip/doc/faq.dox @@ -1,45 +1,50 @@ -/** - * \page faq QuaZip FAQ - * - * - * - * \anchor faq-non-QIODevice Q. Is there any way to use QuaZipFile in Qt - * where you are supposed to use normal (non-zipped) file, but not - * through QIODevice API? - * - * A. Usually not. For example, if you are passing file name to some - * database driver (like SQLite), Qt usually just passes this name down - * to the 3rd-party library, which is usually does not know anything - * about QIODevice and therefore there is no way to pass QuaZipFile as - * normal file. However, if we are talking about some place where you - * pass file name, and then indirectly use QFile to open it, then it is - * a good idea to make overloaded method, which accepts a QIODevice - * pointer. Then you would be able to pass QuaZipFile as well as many - * other nice things such as QBuffer or QProcess. - * - * \anchor faq-zip64 Q. Can QuaZIP handle files larger than 4GB? What - * about zip64 standard? - * - * A. Starting with version 0.6, QuaZIP uses Minizip 1.1 with zip64 - * support which should handle large files perfectly. The zip64 support - * in Minizip looks like it's not 100% conforming to the standard, but - * 3rd party tools seem to have no problem with the resulting archives. - * - * \anchor faq-seekable Q. Can QuaZIP write archives to a sequential QIODevice like QTcpSocket? - * - * A. Not yet. It is not supported by vanilla Minizip (the back-end - * QuaZIP uses), although theoretically possible according to the ZIP - * standard. It would require some Minizip modifications that would - * allow it to detect non-seekable I/O and produce necessary output - * structures. QuaZIP already writes data descriptor which is necessary - * for non-seekable I/O. The only thing that is apparently left is to - * make Minizip fill local headers with correct values and forget about - * seeking after closing the file. - **/ +/** +\page faq QuaZIP FAQ + + + +\anchor faq-non-QIODevice Q. Is there any way to use QuaZipFile in Qt +where you are supposed to use normal (non-zipped) file, but not +through QIODevice API? + +A. Usually not. For example, if you are passing file name to some +database driver (like SQLite), Qt usually just passes this name down +to the 3rd-party library, which is usually does not know anything +about QIODevice and therefore there is no way to pass QuaZipFile as +a normal file. However, if we are talking about some place where you +pass file name, and then internally use QFile to open it, then it is +a good idea to make an overloaded method, which accepts a QIODevice +pointer. Then you would be able to pass QuaZipFile as well as many +other nice things such as QBuffer or QProcess. Of course, that's only +possible if you have control over the sources of the particular class. + +\anchor faq-zip64 Q. Can QuaZIP handle files larger than 4GB? What +about zip64 standard? + +A. Starting with version 0.6, QuaZIP uses Minizip 1.1 with zip64 +support which should handle large files perfectly. The zip64 support +in Minizip looks like it's not 100% conforming to the standard, but +3rd party tools seem to have no problem with the resulting archives. + +\anchor faq-seekable Q. Can QuaZIP write archives to a sequential QIODevice like QTcpSocket? + +A. Yes, it's possible since QuaZIP v0.7. It's only possible in +mdCreate mode, no mdAppend support. + +\anchor faq-Minizip-update Q. Can I use another version of Minizip in QuaZIP, not the bundled one? + +A. No, unfortunately not. To support reading/writing ZIP archives from/to QIODevice objects, +some modifications were needed to Minizip. Now that there is a Minizip fork on GitHub, it is +theoretically possible to backport these modifications into Minizip in a backward-compatible +manner to ensure seamless integration with QuaZIP, but it hasn't been done yet, and there +are no short-term plans, only a long-term goal. + +*/ diff --git a/hecl-gui/quazip/quazip/doc/index.dox b/hecl-gui/quazip/quazip/doc/index.dox index 001f3c888..7761b44fb 100644 --- a/hecl-gui/quazip/quazip/doc/index.dox +++ b/hecl-gui/quazip/quazip/doc/index.dox @@ -1,177 +1,195 @@ -/** - * \mainpage QuaZIP - Qt/C++ wrapper for ZIP/UNZIP package - * -\htmlonly -Powered by SourceForge.net -\endhtmlonly - * \section overview Overview - * - * QuaZIP is a simple C++ wrapper over Gilles Vollant's ZIP/UNZIP - * package that can be used to access ZIP archives. It uses the Qt toolkit. - * - * If you do not know what Qt is, you have two options: - * - Just forget about QuaZIP. - * - Learn more about Qt by downloading it and/or reading the excellent official Qt documentation - * - * The choice is yours, but if you are really interested in - * cross-platform (Windows/Linux/BSD/UNIX/Mac/Others) software - * development, I would definitely recommend you the latter ^_^ - * - * QuaZIP allows you to access files inside ZIP archives using QIODevice - * API, and - yes! - that means that you can also use QTextStream, - * QDataStream or whatever you would like to use on your zipped files. - * - * QuaZIP provides complete abstraction of the ZIP/UNZIP API, for both - * reading from and writing to ZIP archives. - * - * \section download Download QuaZIP - * - * Downloads are available from QuaZIP project's page - * at SourceForge.net. - * - * \section platforms Platforms supported - * - * QuaZIP has been currently tested on the following platforms: - * - linux-g++ (Ubuntu 11.10, Qt 4.7.4) - * - freebsd-g++ (Qt 4.0.0 - * - hpux-acc (HP-UX 11.11) - * - hpux-g++ (HP-UX 11.11) - * - win32-g++ (MinGW) - * - win32-msvc2010 (MS VS 2010 Express, Qt 4.8.4) - * - win32-msvc2010 (Qt Creator, Qt 5.0.1) - * - win32-msvc2012 (Qt Creator, Qt 5.2.0) - * - some Symbian version, reportedly - * - * No testing has been officially done on other systems. Of course, patches to - * make it work on any platform that it currently does not work on are - * always welcome! - * - * \section whats-new What is new in this version of QuaZIP? - * - * See the NEWS.txt file supplied with the distribution. - * - * \section Requirements - * - * Just zlib and Qt 4/5. Well, Qt 4 - * depends on zlib anyway, but you will need zlib headers to compile - * QuaZIP. With Qt5 sometimes you need the zlib library as well (on - * Windows, for example). - * - * \section building Building, testing and installing - * - * \note Instructions given in this section assume that you are - * using some UNIX dialect, but the build process should be very similar - * on win32-g++ platform too. On other platforms it's essentially the - * same process, maybe with some qmake adjustments not specific to - * QuaZIP itself. - * - * To build the library, run: -\verbatim -$ cd /wherever/quazip/source/is/quazip-x.y.z/quazip -$ qmake [PREFIX=where-to-install] -$ make -\endverbatim - * - * Make sure that you have Qt 4/5 installed with all required headers and - * utilities (that is, including the 'dev' or 'devel' package on Linux) - * and that you run qmake utility of the Qt 4, not some other version - * you may have already installed (you may need to type full path to - * qmake like /usr/local/qt4/bin/qmake). - * - * To reconfigure (with another PREFIX, for example), just run qmake - * with appropriate arguments again. - * - * If you need to specify additional include path or libraries, use - * qmake features (see qmake reference in the Qt documentation). For - * example: - * -\verbatim -$ qmake LIBS+=-L/usr/local/zlib/lib INCLUDEPATH+=/usr/local/zlib/include -\endverbatim - * (note abscence of "-I" before the include path and the presence of "-L" - * before the lib path) - * - * Also note that you may or may not need to define ZLIB_WINAPI (qmake - * DEFINES+=ZLIB_WINAPI) when linking to zlib on Windows, depending on - * how zlib was built (generally, if using zlibwapi.dll, this define is - * needed). - * - * To install compiled library: -\verbatim -$ make install -\endverbatim - * - * By default, QuaZIP compiles as a DLL/SO, but you have other - * options: - * - Just copy appropriate source files to your project and use them, - * but you need to define QUAZIP_STATIC before including any QuaZIP - * headers (best done as a compiler option). This will save you from - * possible side effects of importing/exporting QuaZIP symbols. - * - Compile it as a static library using CONFIG += staticlib qmake - * option. QUAZIP_STATIC is defined automatically by qmake in this case. - * - * Binary compatibility is guaranteed between minor releases starting - * with version 0.5, thanks to the Pimpl idiom. That is, the next binary - * incompatible version will be 1.x. - * - * \section test Testing - * - * To check if QuaZIP's basic features work OK on your platform, you may - * wish to compile the test suite provided in test directory: -\verbatim -$ cd /wherever/quazip/source/is/quazip-x.y.z/qztest -$ qmake -$ make -$ ./qztest -\endverbatim - * - * Note that the test suite looks for the quazip library in the "quazip" - * folder of the project ("../quazip"), but you may wish to use LIBS - * for some systems (Windows often puts the library in the separate - * "debug" or "release" directory). If you wish to use the quazip - * version that's already installed, provide the appropriate path. - * - * On some systems you may need to set PATH, LD_LIBRARY_PATH or - * SHLIB_PATH to get "qztest" to actually run. - * - * If everything went fine, the test suite should report a lot of PASS - * messages. If something goes wrong, it will provide details and a - * warning that some tests failed. - * - * \section using Using - * - * See \ref usage "usage page". - * - * \section contacts Authors and contacts - * - * This wrapper has been written by Sergey A. Tachenov, AKA Alqualos. - * This is my first open source project, so it may suck, but I did not - * find anything like that, so I just had no other choice but to write - * it. - * - * If you have anything to say to me about QuaZIP library, feel free to - * do so (read the \ref faq first, though). I can not promise, - * though, that I fix all the bugs you report in, add any features you - * want, or respond to your critics, or respond to your feedback at all. - * I may be busy, I may be tired of working on QuaZIP, I may be even - * dead already (you never know...). - * - * To report bugs or to post ideas about what should be done, use - * SourceForge.net's trackers. - * If you want to send me a private message, use my e-mail address - * stachenov@gmail.com. - * - * Do not use e-mail to report bugs, please. Reporting bugs and problems - * with the SourceForge.net's bug report system has that advantage that - * it is visible to public, and I can always search for open tickets - * that were created long ago. It is highly unlikely that I will search - * my mail for that kind of stuff, so if a bug reported by mail isn't - * fixed immediately, it will likely be forgotten forever. - * - * Copyright (C) 2005-2014 Sergey A. Tachenov and contributors - **/ +/** +\mainpage QuaZIP - Qt/C++ wrapper for Minizip + +\section overview Overview + +Minizip, or +Gilles Vollant's ZIP/UNZIP package is a simple C library +for creating, appending and reading ZIP archives. + +Qt is a very powerful cross-platform C++ +library with a lot of useful modules and classes. With %Qt, you can +create rich GUIs, perform networking activities, accessing databases +and much much more. If Java is “write once, run everywhere”, %Qt +is “write once, compile everywhere” which is not that bad either. + +One thing %Qt can't do out-of-the-box is write and read ZIP archives. +Of course, you can do it with Minizip, but Minizip has its own +interface which isn't exactly compatible with %Qt. Namely, in %Qt +there is an abstract class called QIODevice, which +is Qt-speak for “input/output stream”. There are a lot of classes +that accept QIODevice to write some useful things to it—you could +serialize XML to a QIODevice, for example. Therefore, wouldn't it +be useful if you could open a QIODevice that would write directly +to a file in a ZIP archive? Or read from one? That's exactly where +QuaZIP comes into the picture. + +Technically speaking, QuaZIP is a simple C++ wrapper around Minizip. +Or you could call it an implementation of the Adapter pattern. With +QuaZIP, both ZIP files and files inside ZIP archives can be accessed +with QIODevice API. You can even write ZIP files to a sequential devices +like TCP sockets, although some limitations apply in this case. + +\section download Download QuaZIP + +The latest downloads are available from the +GitHub page. +Downloads are in source format. The documentation you're reading +right now can be build with the “doxygen” tool if you have one +installed. Just run it from the project directory and it will +create the “doc” directory for you. If you don't have Doxygen +installed, you can still read offline docs in the “quazip/doc” +subdir and in the header files. Don't confuse those dirs: + +- “doc” in the project's root is where Doxygen \em output is. +- “quazip/doc” is where Doxygen \em input is, along with the header + files. + +Older downloads are available from +QuaZIP project's page at SourceForge.net. + +\section platforms Platforms supported + +QuaZIP is regularly tested on the following platforms: +- linux-g++ (Ubuntu 16.04 LTS, %Qt 5.5.1) +- linux-g++ (CentOS 6.9, %Qt 4.6.2) +- win32-msvc (MS VS/VC 2013 64-bit, %Qt 5.9.2) + +It should work fine on any platform supported by %Qt 4.6.2 or later. +In theory, older versions might work as well, but aren't guaranteed +to. + +\section whats-new What is new in this version of QuaZIP? + +See the NEWS.txt file supplied with the distribution. + +\section Dependencies + +Just zlib and %Qt 4/5. Sometimes +you can get away with using zlib library bundled into %Qt, but +usually you need at least its headers. + +\section building Building, testing and installing + +\note Instructions given in this section assume that you are +using some UNIX dialect, but the build process should be very similar +on win32-g++ platform too. On other platforms it's essentially the +same process, maybe with some qmake adjustments not specific to +QuaZIP itself. + +To build the library, run: +\verbatim +$ cd /wherever/quazip/source/is/quazip-x.y.z/quazip +$ qmake [PREFIX=where-to-install] +$ make +\endverbatim + +Make sure that you have %Qt 4/5 installed with all required headers and +utilities (that is, including the 'dev' or 'devel' package on Linux) +and that you run qmake utility of the %Qt 4/5, not some other version +you may have already installed (you may need to type full path to +qmake like /usr/local/qt4/bin/qmake). + +To reconfigure (with another PREFIX, for example), just run +\verbatim +qmake distclean +\endverbatim +and then qmake with the appropriate arguments again. + +Usually, it is needed to specify additional include path or libraries +in qmake args (see qmake reference in the %Qt documentation). For +example: + +\verbatim +$ qmake LIBS+=-L/usr/local/zlib/lib INCLUDEPATH+=/usr/local/zlib/include +\endverbatim +(note abscence of “-I” before the include path and the presence of “-L” +before the lib path) + +Also note that you may or may not need to define ZLIB_WINAPI (qmake +DEFINES+=ZLIB_WINAPI) when linking to zlib on Windows, depending on +how zlib was built (generally, if using zlibwapi.dll, this define is +needed). + +To install compiled library: +\verbatim +$ make install +\endverbatim + +By default, QuaZIP compiles as a DLL/SO, but you have other +options: +- Just copy appropriate source files to your project and use them, +but you need to define QUAZIP_STATIC before including any QuaZIP +headers (best done as a compiler option). This will save you from +possible side effects of importing/exporting QuaZIP symbols. +- Compile it as a static library using CONFIG += staticlib qmake +option. QUAZIP_STATIC is defined automatically by qmake in this case. + +Binary compatibility is guaranteed between minor releases starting +with version 0.5, thanks to the Pimpl idiom. That is, the next binary +incompatible version will be 1.x in the worst case. + +\section test Testing + +To check if QuaZIP's basic features work OK on your platform, you may +wish to compile the test suite provided in test directory: +\verbatim +$ cd /wherever/quazip/source/is/quazip-x.y.z/qztest +$ qmake +$ make +$ ./qztest +\endverbatim + +Note that the test suite looks for the quazip library in the “quazip” +folder of the project (“../quazip”), but you may wish to use LIBS +for some systems (Windows often puts the library in the separate +“debug” or “release” directory). If you wish to use the quazip +version that's already installed, provide the appropriate path. + +On some systems you may need to set PATH, LD_LIBRARY_PATH or +SHLIB_PATH to get “qztest” to actually run and to use the right +version. + +If everything went fine, the test suite should report a lot of PASS +messages. If something goes wrong, it will provide details and a +warning that some tests failed. + +\section using Using + +See \ref usage “usage page”. + +\section contacts Authors and contacts + +This wrapper has been written by Sergei Tachenov. +This is my first open source project, and it's pretty old, but it +works and many people are happily using it, including myself. + +If you have anything to say to me about QuaZIP library, feel free to +do so (read the \ref faq first, though). I can not promise, +though, that I fix all the bugs you report in, add any features you +want, or respond to your critics, or respond to your feedback at all. +I may be busy, I may be tired of working on QuaZIP, I may be even +dead already (you never know...). + +To report bugs or to post ideas about what should be done, use +GitHub. It's an +awesome site, where you can report bugs or register yourself an +account, fork QuaZIP (don't hesitate to do so), create a new branch, +make some changes and issue a +pull +request, which is GitHub's way of offering patches. See CONTRIBUTING.md +file for details. + +Do not use e-mail to report bugs, please. Reporting bugs and problems +with GitHub has that advantage that +it is visible to public, and I can always search for open tickets +that were created long ago. It is highly unlikely that I will search +my mail for that kind of stuff, so if a bug reported by mail isn't +fixed immediately, it will likely be forgotten forever. + +Old bugs may still be available at +SourceForge +for reference. + +Copyright (C) 2005-2018 Sergei Tachenov and contributors +*/ diff --git a/hecl-gui/quazip/quazip/doc/usage.dox b/hecl-gui/quazip/quazip/doc/usage.dox index c61ed0965..1ea653ed7 100644 --- a/hecl-gui/quazip/quazip/doc/usage.dox +++ b/hecl-gui/quazip/quazip/doc/usage.dox @@ -1,77 +1,96 @@ -/** \page usage Usage - * - * This page provides general information on QuaZIP usage. See classes - * QuaZip and QuaZipFile for the detailed documentation on what can - * QuaZIP do and what it can not. Also, reading comments in the zip.h and - * unzip.h files (taken from the original ZIP/UNZIP package) is always a - * good idea too. After all, QuaZIP is just a wrapper with a few - * convenience extensions and reimplementations. - * - * QuaZip is a class representing ZIP archive, QuaZipFile represents a - * file inside archive and subclasses QIODevice as well. One limitation - * is that there can be only one instance of QuaZipFile per QuaZip - * instance, which kind of makes it confusing why there are two classes - * instead of one. This is actually no more than an API design mistake. - * - * \section terminology Terminology - * - * "QuaZIP" means whole this library, while "QuaZip" (note the - * lower case) is just one class in it. - * - * "ZIP/UNZIP API" or "minizip" means the original API of the Gilles - * Vollant's ZIP/UNZIP package. It was slightly modified to better - * integrate with Qt. These modifications are not source or binary - * compatible with the official minizip release, which means you can't - * just drop the newer minizip version into QuaZIP sources and make it - * work. - * - * "ZIP", "ZIP archive" or "ZIP file" means any ZIP archive. Typically - * this is a plain file with ".zip" (or ".ZIP") file name suffix, but it - * can also be any seekable QIODevice (say, QBuffer, but not - * QTcpSocket). - * - * "A file inside archive", "a file inside ZIP" or something like that - * means file either being read or written from/to some ZIP archive. - * - * \section error-handling Error handling - * - * Almost any call to ZIP/UNZIP API return some error code. Most of the - * original API's error checking could be done in this wrapper as well, - * but it would cause unnecessary code bloating without any benefit. So, - * QuaZIP only checks for situations that ZIP/UNZIP API can not check - * for. For example, ZIP/UNZIP API has no "ZIP open mode" concept - * because read and write modes are completely separated. On the other - * hand, to avoid creating classes like "QuaZipReader", "QuaZipWriter" - * or something like that, QuaZIP introduces "ZIP open mode" concept - * instead, thus making it possible to use one class (QuaZip) for both - * reading and writing. But this leads to additional open mode checks - * which are not done in ZIP/UNZIP package. - * - * Therefore, error checking is two-level (QuaZIP's level and ZIP/UNZIP - * API level), which sometimes can be confusing, so here are some - * advices on how the error checking should be properly done: - * - * - Both QuaZip and QuaZipFile have getZipError() function, which return - * error code of the last ZIP/UNZIP API call. Most function calls - * reset error code to UNZ_OK on success and set error code on - * failure. Some functions do not reset error code. Most of them are - * \c const and do not access ZIP archive in any way. Some, on the - * other hand, \em do access ZIP archive, but do not reset or set - * error code. For example, QuaZipFile::pos() function. Such functions - * are explicitly marked in the documentation. - * - Most functions have their own way to report errors, by returning a - * null string, negative value or \c false. If such a function returns - * error value, call getZipError() to get more information about - * error. See "zip.h" and "unzip.h" of the ZIP/UNZIP package for error - * codes. - * - If the function returns error-stating value (like \c false), but - * getZipError() returns UNZ_OK, it means that you did something - * obviously wrong. For example, tried to write in the archive open - * for reading or not open at all. You better just not do that! - * Most functions also issue a warning using qWarning() function in - * such cases. See documentation for a specific function for details - * on when it should not be called. - * - * I know that this is somewhat messy, but I could not find a better way - * to do all the error handling. - **/ +/** \page usage Usage + +This page provides general information on QuaZIP usage. See classes +QuaZip and QuaZipFile for the detailed documentation on what can +QuaZIP do and what it can not. Also, reading comments in the zip.h and +unzip.h files (taken from the original ZIP/UNZIP package) is always a +good idea too. After all, QuaZIP is just a wrapper with a few +convenience extensions and reimplementations. + +QuaZip is a class representing ZIP archive, QuaZipFile represents a +file inside archive and subclasses QIODevice as well. One limitation +is that there can be only one instance of QuaZipFile per QuaZip +instance, which kind of makes it confusing why there are two classes +instead of one. This is actually no more than an API design mistake +kept for backwards compatibility. + +The JlCompress class provides some high-level convenience static +methods which may be very useful if all you need is just to “unzip +a file” or something like that. + +\section terminology Terminology + +“QuaZIP” means the whole library, while “QuaZip” (note the +lower case) is just one class in it. + +“ZIP/UNZIP API” or “Minizip” means the original API of the Gilles +Vollant's ZIP/UNZIP package. It was slightly modified to better +integrate with Qt. These modifications are not source or binary +compatible with the official Minizip release, which means you can't +just drop the newer Minizip version into QuaZIP sources and make it +work. + +“ZIP”, “ZIP archive” or “ZIP file” means any ZIP archive. Typically +this is a plain file with “.zip” (or “.ZIP”) file name suffix, but it +can also be any seekable QIODevice (say, QBuffer, but not +QTcpSocket). + +“A file inside archive”, “a file inside ZIP” or something like that +means file either being read or written from/to some ZIP archive. + +\section general-usage General usage + +In general, the process looks like this: + +-# Open or create an archive with a QuaZip instance. +-# Open or create a file in the archive with a QuaZipFile instance. +-# Perform reading or writing. +-# Close the QuaZipFile instance. +-# Repeat steps 2–4 for other files if needed. +-# Close the QuaZIP instance. + +See the “qztest” subdirectory for examples. TestQuaZipFile::zipUnzip() +is a good place to start. + +\section error-handling Error handling + +Almost any call to ZIP/UNZIP API return some error code. Most of the +original API's error checking could be done in this wrapper as well, +but it would cause unnecessary code bloating without any benefit. So, +QuaZIP only checks for situations that ZIP/UNZIP API can not check +for. For example, ZIP/UNZIP API has no “ZIP open mode” concept +because read and write modes are completely separated. On the other +hand, to avoid creating classes like “QuaZipReader”, “QuaZipWriter” +or something like that, QuaZIP introduces “ZIP open mode” concept +instead, thus making it possible to use one class (QuaZip) for both +reading and writing. But this leads to additional open mode checks +which are not done in ZIP/UNZIP package. + +Therefore, error checking is two-level (QuaZIP's level and ZIP/UNZIP +API level), which sometimes can be confusing, so here are some +advices on how the error checking should be properly done: + +- Both QuaZip and QuaZipFile have getZipError() function, which return + error code of the last ZIP/UNZIP API call. Most function calls + reset error code to UNZ_OK on success and set error code on + failure. Some functions do not reset error code. Most of them are + \c const and do not access ZIP archive in any way. Some, on the + other hand, \em do access ZIP archive, but do not reset or set + error code. For example, QuaZipFile::pos() function. Such functions + are explicitly marked in the documentation. +- Most functions have their own way to report errors, by returning a + null string, negative value or \c false. If such a function returns + error value, call getZipError() to get more information about + error. See “zip.h” and “unzip.h” of the ZIP/UNZIP package for error + codes. +- If the function returns error-stating value (like \c false), but + getZipError() returns UNZ_OK, it means that you did something + obviously wrong. For example, tried to write in the archive open + for reading or not open at all. You better just not do that! + Most functions also issue a warning using qWarning() function in + such cases. See documentation for a specific function for details + on when it should not be called. + +I know that this is somewhat messy, but I could not find a better way +to do all the error handling. +*/ diff --git a/hecl-gui/quazip/quazip/ioapi.h b/hecl-gui/quazip/quazip/ioapi.h index 8f14a769a..75d0aa693 100644 --- a/hecl-gui/quazip/quazip/ioapi.h +++ b/hecl-gui/quazip/quazip/ioapi.h @@ -1,205 +1,207 @@ -/* ioapi.h -- IO base function header for compress/uncompress .zip - part of the MiniZip project - ( http://www.winimage.com/zLibDll/minizip.html ) - - Copyright (C) 1998-2010 Gilles Vollant (minizip) ( http://www.winimage.com/zLibDll/minizip.html ) - - Modifications for Zip64 support - Copyright (C) 2009-2010 Mathias Svensson ( http://result42.com ) - - Modified by Sergey A. Tachenov to allow QIODevice API usage. - - For more info read MiniZip_info.txt - - Changes - - Oct-2009 - Defined ZPOS64_T to fpos_t on windows and u_int64_t on linux. (might need to find a better why for this) - Oct-2009 - Change to fseeko64, ftello64 and fopen64 so large files would work on linux. - More if/def section may be needed to support other platforms - Oct-2009 - Defined fxxxx64 calls to normal fopen/ftell/fseek so they would compile on windows. - (but you should use iowin32.c for windows instead) - -*/ - -#ifndef _ZLIBIOAPI64_H -#define _ZLIBIOAPI64_H - -#if (!defined(_WIN32)) && (!defined(WIN32)) - - // Linux needs this to support file operation on files larger then 4+GB - // But might need better if/def to select just the platforms that needs them. - - #ifndef __USE_FILE_OFFSET64 - #define __USE_FILE_OFFSET64 - #endif - #ifndef __USE_LARGEFILE64 - #define __USE_LARGEFILE64 - #endif - #ifndef _LARGEFILE64_SOURCE - #define _LARGEFILE64_SOURCE - #endif - #ifndef _FILE_OFFSET_BIT - #define _FILE_OFFSET_BIT 64 - #endif -#endif - -#include -#include -#include "zlib.h" - -#if defined(USE_FILE32API) -#define fopen64 fopen -#define ftello64 ftell -#define fseeko64 fseek -#else -#ifdef _MSC_VER - #define fopen64 fopen - #if (_MSC_VER >= 1400) && (!(defined(NO_MSCVER_FILE64_FUNC))) - #define ftello64 _ftelli64 - #define fseeko64 _fseeki64 - #else // old MSC - #define ftello64 ftell - #define fseeko64 fseek - #endif -#endif -#endif - -/* -#ifndef ZPOS64_T - #ifdef _WIN32 - #define ZPOS64_T fpos_t - #else - #include - #define ZPOS64_T uint64_t - #endif -#endif -*/ - -#ifdef HAVE_MINIZIP64_CONF_H -#include "mz64conf.h" -#endif - -/* a type choosen by DEFINE */ -#ifdef HAVE_64BIT_INT_CUSTOM -typedef 64BIT_INT_CUSTOM_TYPE ZPOS64_T; -#else -#ifdef HAS_STDINT_H -#include "stdint.h" -typedef uint64_t ZPOS64_T; -#else - - -#if defined(_MSC_VER) || defined(__BORLANDC__) -typedef unsigned __int64 ZPOS64_T; -#else -typedef unsigned long long int ZPOS64_T; -#endif -#endif -#endif - - - -#ifdef __cplusplus -extern "C" { -#endif - -#ifndef OF -#define OF _Z_OF -#endif - -#define ZLIB_FILEFUNC_SEEK_CUR (1) -#define ZLIB_FILEFUNC_SEEK_END (2) -#define ZLIB_FILEFUNC_SEEK_SET (0) - -#define ZLIB_FILEFUNC_MODE_READ (1) -#define ZLIB_FILEFUNC_MODE_WRITE (2) -#define ZLIB_FILEFUNC_MODE_READWRITEFILTER (3) - -#define ZLIB_FILEFUNC_MODE_EXISTING (4) -#define ZLIB_FILEFUNC_MODE_CREATE (8) - - -#ifndef ZCALLBACK - #if (defined(WIN32) || defined(_WIN32) || defined (WINDOWS) || defined (_WINDOWS)) && defined(CALLBACK) && defined (USEWINDOWS_CALLBACK) - #define ZCALLBACK CALLBACK - #else - #define ZCALLBACK - #endif -#endif - - - - -typedef voidpf (ZCALLBACK *open_file_func) OF((voidpf opaque, voidpf file, int mode)); -typedef uLong (ZCALLBACK *read_file_func) OF((voidpf opaque, voidpf stream, void* buf, uLong size)); -typedef uLong (ZCALLBACK *write_file_func) OF((voidpf opaque, voidpf stream, const void* buf, uLong size)); -typedef int (ZCALLBACK *close_file_func) OF((voidpf opaque, voidpf stream)); -typedef int (ZCALLBACK *testerror_file_func) OF((voidpf opaque, voidpf stream)); - -typedef uLong (ZCALLBACK *tell_file_func) OF((voidpf opaque, voidpf stream)); -typedef int (ZCALLBACK *seek_file_func) OF((voidpf opaque, voidpf stream, uLong offset, int origin)); - - -/* here is the "old" 32 bits structure structure */ -typedef struct zlib_filefunc_def_s -{ - open_file_func zopen_file; - read_file_func zread_file; - write_file_func zwrite_file; - tell_file_func ztell_file; - seek_file_func zseek_file; - close_file_func zclose_file; - testerror_file_func zerror_file; - voidpf opaque; -} zlib_filefunc_def; - -typedef ZPOS64_T (ZCALLBACK *tell64_file_func) OF((voidpf opaque, voidpf stream)); -typedef int (ZCALLBACK *seek64_file_func) OF((voidpf opaque, voidpf stream, ZPOS64_T offset, int origin)); -typedef voidpf (ZCALLBACK *open64_file_func) OF((voidpf opaque, voidpf file, int mode)); - -typedef struct zlib_filefunc64_def_s -{ - open64_file_func zopen64_file; - read_file_func zread_file; - write_file_func zwrite_file; - tell64_file_func ztell64_file; - seek64_file_func zseek64_file; - close_file_func zclose_file; - testerror_file_func zerror_file; - voidpf opaque; -} zlib_filefunc64_def; - -void fill_qiodevice64_filefunc OF((zlib_filefunc64_def* pzlib_filefunc_def)); -void fill_qiodevice_filefunc OF((zlib_filefunc_def* pzlib_filefunc_def)); - -/* now internal definition, only for zip.c and unzip.h */ -typedef struct zlib_filefunc64_32_def_s -{ - zlib_filefunc64_def zfile_func64; - open_file_func zopen32_file; - tell_file_func ztell32_file; - seek_file_func zseek32_file; -} zlib_filefunc64_32_def; - - -#define ZREAD64(filefunc,filestream,buf,size) ((*((filefunc).zfile_func64.zread_file)) ((filefunc).zfile_func64.opaque,filestream,buf,size)) -#define ZWRITE64(filefunc,filestream,buf,size) ((*((filefunc).zfile_func64.zwrite_file)) ((filefunc).zfile_func64.opaque,filestream,buf,size)) -//#define ZTELL64(filefunc,filestream) ((*((filefunc).ztell64_file)) ((filefunc).opaque,filestream)) -//#define ZSEEK64(filefunc,filestream,pos,mode) ((*((filefunc).zseek64_file)) ((filefunc).opaque,filestream,pos,mode)) -#define ZCLOSE64(filefunc,filestream) ((*((filefunc).zfile_func64.zclose_file)) ((filefunc).zfile_func64.opaque,filestream)) -#define ZERROR64(filefunc,filestream) ((*((filefunc).zfile_func64.zerror_file)) ((filefunc).zfile_func64.opaque,filestream)) - -voidpf call_zopen64 OF((const zlib_filefunc64_32_def* pfilefunc,voidpf file,int mode)); -int call_zseek64 OF((const zlib_filefunc64_32_def* pfilefunc,voidpf filestream, ZPOS64_T offset, int origin)); -ZPOS64_T call_ztell64 OF((const zlib_filefunc64_32_def* pfilefunc,voidpf filestream)); - -void fill_zlib_filefunc64_32_def_from_filefunc32(zlib_filefunc64_32_def* p_filefunc64_32,const zlib_filefunc_def* p_filefunc32); - -#define ZOPEN64(filefunc,filename,mode) (call_zopen64((&(filefunc)),(filename),(mode))) -#define ZTELL64(filefunc,filestream) (call_ztell64((&(filefunc)),(filestream))) -#define ZSEEK64(filefunc,filestream,pos,mode) (call_zseek64((&(filefunc)),(filestream),(pos),(mode))) - -#ifdef __cplusplus -} -#endif - -#endif +/* ioapi.h -- IO base function header for compress/uncompress .zip + part of the MiniZip project - ( http://www.winimage.com/zLibDll/minizip.html ) + + Copyright (C) 1998-2010 Gilles Vollant (minizip) ( http://www.winimage.com/zLibDll/minizip.html ) + + Modifications for Zip64 support + Copyright (C) 2009-2010 Mathias Svensson ( http://result42.com ) + + Modified by Sergey A. Tachenov to allow QIODevice API usage. + + For more info read MiniZip_info.txt + + Changes + + Oct-2009 - Defined ZPOS64_T to fpos_t on windows and u_int64_t on linux. (might need to find a better why for this) + Oct-2009 - Change to fseeko64, ftello64 and fopen64 so large files would work on linux. + More if/def section may be needed to support other platforms + Oct-2009 - Defined fxxxx64 calls to normal fopen/ftell/fseek so they would compile on windows. + (but you should use iowin32.c for windows instead) + +*/ + +#ifndef _ZLIBIOAPI64_H +#define _ZLIBIOAPI64_H + +#if (!defined(_WIN32)) && (!defined(WIN32)) + + // Linux needs this to support file operation on files larger then 4+GB + // But might need better if/def to select just the platforms that needs them. + + #ifndef __USE_FILE_OFFSET64 + #define __USE_FILE_OFFSET64 + #endif + #ifndef __USE_LARGEFILE64 + #define __USE_LARGEFILE64 + #endif + #ifndef _LARGEFILE64_SOURCE + #define _LARGEFILE64_SOURCE + #endif + #ifndef _FILE_OFFSET_BIT + #define _FILE_OFFSET_BIT 64 + #endif +#endif + +#include +#include +#include + +#if defined(USE_FILE32API) +#define fopen64 fopen +#define ftello64 ftell +#define fseeko64 fseek +#else +#ifdef _MSC_VER + #define fopen64 fopen + #if (_MSC_VER >= 1400) && (!(defined(NO_MSCVER_FILE64_FUNC))) + #define ftello64 _ftelli64 + #define fseeko64 _fseeki64 + #else // old MSC + #define ftello64 ftell + #define fseeko64 fseek + #endif +#endif +#endif + +/* +#ifndef ZPOS64_T + #ifdef _WIN32 + #define ZPOS64_T fpos_t + #else + #include + #define ZPOS64_T uint64_t + #endif +#endif +*/ + +#ifdef HAVE_MINIZIP64_CONF_H +#include "mz64conf.h" +#endif + +/* a type choosen by DEFINE */ +#ifdef HAVE_64BIT_INT_CUSTOM +typedef 64BIT_INT_CUSTOM_TYPE ZPOS64_T; +#else +#ifdef HAS_STDINT_H +#include "stdint.h" +typedef uint64_t ZPOS64_T; +#else + + +#if defined(_MSC_VER) || defined(__BORLANDC__) +typedef unsigned __int64 ZPOS64_T; +#else +typedef unsigned long long int ZPOS64_T; +#endif +#endif +#endif + + + +#ifdef __cplusplus +extern "C" { +#endif + +#ifndef OF +#define OF _Z_OF +#endif + +#define ZLIB_FILEFUNC_SEEK_CUR (1) +#define ZLIB_FILEFUNC_SEEK_END (2) +#define ZLIB_FILEFUNC_SEEK_SET (0) + +#define ZLIB_FILEFUNC_MODE_READ (1) +#define ZLIB_FILEFUNC_MODE_WRITE (2) +#define ZLIB_FILEFUNC_MODE_READWRITEFILTER (3) + +#define ZLIB_FILEFUNC_MODE_EXISTING (4) +#define ZLIB_FILEFUNC_MODE_CREATE (8) + + +#ifndef ZCALLBACK + #if (defined(WIN32) || defined(_WIN32) || defined (WINDOWS) || defined (_WINDOWS)) && defined(CALLBACK) && defined (USEWINDOWS_CALLBACK) + #define ZCALLBACK CALLBACK + #else + #define ZCALLBACK + #endif +#endif + + + + +typedef voidpf (ZCALLBACK *open_file_func) OF((voidpf opaque, voidpf file, int mode)); +typedef uLong (ZCALLBACK *read_file_func) OF((voidpf opaque, voidpf stream, void* buf, uLong size)); +typedef uLong (ZCALLBACK *write_file_func) OF((voidpf opaque, voidpf stream, const void* buf, uLong size)); +typedef int (ZCALLBACK *close_file_func) OF((voidpf opaque, voidpf stream)); +typedef int (ZCALLBACK *testerror_file_func) OF((voidpf opaque, voidpf stream)); + +typedef uLong (ZCALLBACK *tell_file_func) OF((voidpf opaque, voidpf stream)); +typedef int (ZCALLBACK *seek_file_func) OF((voidpf opaque, voidpf stream, uLong offset, int origin)); + + +/* here is the "old" 32 bits structure structure */ +typedef struct zlib_filefunc_def_s +{ + open_file_func zopen_file; + read_file_func zread_file; + write_file_func zwrite_file; + tell_file_func ztell_file; + seek_file_func zseek_file; + close_file_func zclose_file; + testerror_file_func zerror_file; + voidpf opaque; +} zlib_filefunc_def; + +typedef ZPOS64_T (ZCALLBACK *tell64_file_func) OF((voidpf opaque, voidpf stream)); +typedef int (ZCALLBACK *seek64_file_func) OF((voidpf opaque, voidpf stream, ZPOS64_T offset, int origin)); +typedef voidpf (ZCALLBACK *open64_file_func) OF((voidpf opaque, voidpf file, int mode)); + +typedef struct zlib_filefunc64_def_s +{ + open64_file_func zopen64_file; + read_file_func zread_file; + write_file_func zwrite_file; + tell64_file_func ztell64_file; + seek64_file_func zseek64_file; + close_file_func zclose_file; + testerror_file_func zerror_file; + voidpf opaque; + close_file_func zfakeclose_file; // for no-auto-close flag +} zlib_filefunc64_def; + +void fill_qiodevice64_filefunc OF((zlib_filefunc64_def* pzlib_filefunc_def)); +void fill_qiodevice_filefunc OF((zlib_filefunc_def* pzlib_filefunc_def)); + +/* now internal definition, only for zip.c and unzip.h */ +typedef struct zlib_filefunc64_32_def_s +{ + zlib_filefunc64_def zfile_func64; + open_file_func zopen32_file; + tell_file_func ztell32_file; + seek_file_func zseek32_file; +} zlib_filefunc64_32_def; + + +#define ZREAD64(filefunc,filestream,buf,size) ((*((filefunc).zfile_func64.zread_file)) ((filefunc).zfile_func64.opaque,filestream,buf,size)) +#define ZWRITE64(filefunc,filestream,buf,size) ((*((filefunc).zfile_func64.zwrite_file)) ((filefunc).zfile_func64.opaque,filestream,buf,size)) +//#define ZTELL64(filefunc,filestream) ((*((filefunc).ztell64_file)) ((filefunc).opaque,filestream)) +//#define ZSEEK64(filefunc,filestream,pos,mode) ((*((filefunc).zseek64_file)) ((filefunc).opaque,filestream,pos,mode)) +#define ZCLOSE64(filefunc,filestream) ((*((filefunc).zfile_func64.zclose_file)) ((filefunc).zfile_func64.opaque,filestream)) +#define ZFAKECLOSE64(filefunc,filestream) ((*((filefunc).zfile_func64.zfakeclose_file)) ((filefunc).zfile_func64.opaque,filestream)) +#define ZERROR64(filefunc,filestream) ((*((filefunc).zfile_func64.zerror_file)) ((filefunc).zfile_func64.opaque,filestream)) + +voidpf call_zopen64 OF((const zlib_filefunc64_32_def* pfilefunc,voidpf file,int mode)); +int call_zseek64 OF((const zlib_filefunc64_32_def* pfilefunc,voidpf filestream, ZPOS64_T offset, int origin)); +ZPOS64_T call_ztell64 OF((const zlib_filefunc64_32_def* pfilefunc,voidpf filestream)); + +void fill_zlib_filefunc64_32_def_from_filefunc32(zlib_filefunc64_32_def* p_filefunc64_32,const zlib_filefunc_def* p_filefunc32); + +#define ZOPEN64(filefunc,filename,mode) (call_zopen64((&(filefunc)),(filename),(mode))) +#define ZTELL64(filefunc,filestream) (call_ztell64((&(filefunc)),(filestream))) +#define ZSEEK64(filefunc,filestream,pos,mode) (call_zseek64((&(filefunc)),(filestream),(pos),(mode))) + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/hecl-gui/quazip/quazip/crypt.h b/hecl-gui/quazip/quazip/minizip_crypt.h similarity index 96% rename from hecl-gui/quazip/quazip/crypt.h rename to hecl-gui/quazip/quazip/minizip_crypt.h index 5fb9fd325..2e833f7f3 100644 --- a/hecl-gui/quazip/quazip/crypt.h +++ b/hecl-gui/quazip/quazip/minizip_crypt.h @@ -1,135 +1,135 @@ -/* crypt.h -- base code for crypt/uncrypt ZIPfile - - - Version 1.01e, February 12th, 2005 - - Copyright (C) 1998-2005 Gilles Vollant - - This code is a modified version of crypting code in Infozip distribution - - The encryption/decryption parts of this source code (as opposed to the - non-echoing password parts) were originally written in Europe. The - whole source package can be freely distributed, including from the USA. - (Prior to January 2000, re-export from the US was a violation of US law.) - - This encryption code is a direct transcription of the algorithm from - Roger Schlafly, described by Phil Katz in the file appnote.txt. This - file (appnote.txt) is distributed with the PKZIP program (even in the - version without encryption capabilities). - - If you don't need crypting in your application, just define symbols - NOCRYPT and NOUNCRYPT. - - This code support the "Traditional PKWARE Encryption". - - The new AES encryption added on Zip format by Winzip (see the page - http://www.winzip.com/aes_info.htm ) and PKWare PKZip 5.x Strong - Encryption is not supported. -*/ - -#include "quazip_global.h" - -#define CRC32(c, b) ((*(pcrc_32_tab+(((int)(c) ^ (b)) & 0xff))) ^ ((c) >> 8)) - -/*********************************************************************** - * Return the next byte in the pseudo-random sequence - */ -static int decrypt_byte(unsigned long* pkeys, const z_crc_t FAR * pcrc_32_tab UNUSED) -{ - //(void) pcrc_32_tab; /* avoid "unused parameter" warning */ - unsigned temp; /* POTENTIAL BUG: temp*(temp^1) may overflow in an - * unpredictable manner on 16-bit systems; not a problem - * with any known compiler so far, though */ - - temp = ((unsigned)(*(pkeys+2)) & 0xffff) | 2; - return (int)(((temp * (temp ^ 1)) >> 8) & 0xff); -} - -/*********************************************************************** - * Update the encryption keys with the next byte of plain text - */ -static int update_keys(unsigned long* pkeys,const z_crc_t FAR * pcrc_32_tab,int c) -{ - (*(pkeys+0)) = CRC32((*(pkeys+0)), c); - (*(pkeys+1)) += (*(pkeys+0)) & 0xff; - (*(pkeys+1)) = (*(pkeys+1)) * 134775813L + 1; - { - register int keyshift = (int)((*(pkeys+1)) >> 24); - (*(pkeys+2)) = CRC32((*(pkeys+2)), keyshift); - } - return c; -} - - -/*********************************************************************** - * Initialize the encryption keys and the random header according to - * the given password. - */ -static void init_keys(const char* passwd,unsigned long* pkeys,const z_crc_t FAR * pcrc_32_tab) -{ - *(pkeys+0) = 305419896L; - *(pkeys+1) = 591751049L; - *(pkeys+2) = 878082192L; - while (*passwd != '\0') { - update_keys(pkeys,pcrc_32_tab,(int)*passwd); - passwd++; - } -} - -#define zdecode(pkeys,pcrc_32_tab,c) \ - (update_keys(pkeys,pcrc_32_tab,c ^= decrypt_byte(pkeys,pcrc_32_tab))) - -#define zencode(pkeys,pcrc_32_tab,c,t) \ - (t=decrypt_byte(pkeys,pcrc_32_tab), update_keys(pkeys,pcrc_32_tab,c), t^(c)) - -#ifdef INCLUDECRYPTINGCODE_IFCRYPTALLOWED - -#define RAND_HEAD_LEN 12 - /* "last resort" source for second part of crypt seed pattern */ -# ifndef ZCR_SEED2 -# define ZCR_SEED2 3141592654UL /* use PI as default pattern */ -# endif - -static int crypthead(passwd, buf, bufSize, pkeys, pcrc_32_tab, crcForCrypting) - const char *passwd; /* password string */ - unsigned char *buf; /* where to write header */ - int bufSize; - unsigned long* pkeys; - const z_crc_t FAR * pcrc_32_tab; - unsigned long crcForCrypting; -{ - int n; /* index in random header */ - int t; /* temporary */ - int c; /* random byte */ - unsigned char header[RAND_HEAD_LEN-2]; /* random header */ - static unsigned calls = 0; /* ensure different random header each time */ - - if (bufSize> 7) & 0xff; - header[n] = (unsigned char)zencode(pkeys, pcrc_32_tab, c, t); - } - /* Encrypt random header (last two bytes is high word of crc) */ - init_keys(passwd, pkeys, pcrc_32_tab); - for (n = 0; n < RAND_HEAD_LEN-2; n++) - { - buf[n] = (unsigned char)zencode(pkeys, pcrc_32_tab, header[n], t); - } - buf[n++] = zencode(pkeys, pcrc_32_tab, (int)(crcForCrypting >> 16) & 0xff, t); - buf[n++] = zencode(pkeys, pcrc_32_tab, (int)(crcForCrypting >> 24) & 0xff, t); - return n; -} - -#endif +/* crypt.h -- base code for crypt/uncrypt ZIPfile + + + Version 1.01e, February 12th, 2005 + + Copyright (C) 1998-2005 Gilles Vollant + + This code is a modified version of crypting code in Infozip distribution + + The encryption/decryption parts of this source code (as opposed to the + non-echoing password parts) were originally written in Europe. The + whole source package can be freely distributed, including from the USA. + (Prior to January 2000, re-export from the US was a violation of US law.) + + This encryption code is a direct transcription of the algorithm from + Roger Schlafly, described by Phil Katz in the file appnote.txt. This + file (appnote.txt) is distributed with the PKZIP program (even in the + version without encryption capabilities). + + If you don't need crypting in your application, just define symbols + NOCRYPT and NOUNCRYPT. + + This code support the "Traditional PKWARE Encryption". + + The new AES encryption added on Zip format by Winzip (see the page + http://www.winzip.com/aes_info.htm ) and PKWare PKZip 5.x Strong + Encryption is not supported. +*/ + +#include "quazip_global.h" + +#define CRC32(c, b) ((*(pcrc_32_tab+(((int)(c) ^ (b)) & 0xff))) ^ ((c) >> 8)) + +/*********************************************************************** + * Return the next byte in the pseudo-random sequence + */ +static int decrypt_byte(unsigned long* pkeys, const z_crc_t FAR * pcrc_32_tab QUAZIP_UNUSED) +{ + //(void) pcrc_32_tab; /* avoid "unused parameter" warning */ + unsigned temp; /* POTENTIAL BUG: temp*(temp^1) may overflow in an + * unpredictable manner on 16-bit systems; not a problem + * with any known compiler so far, though */ + + temp = ((unsigned)(*(pkeys+2)) & 0xffff) | 2; + return (int)(((temp * (temp ^ 1)) >> 8) & 0xff); +} + +/*********************************************************************** + * Update the encryption keys with the next byte of plain text + */ +static int update_keys(unsigned long* pkeys,const z_crc_t FAR * pcrc_32_tab,int c) +{ + (*(pkeys+0)) = CRC32((*(pkeys+0)), c); + (*(pkeys+1)) += (*(pkeys+0)) & 0xff; + (*(pkeys+1)) = (*(pkeys+1)) * 134775813L + 1; + { + register int keyshift = (int)((*(pkeys+1)) >> 24); + (*(pkeys+2)) = CRC32((*(pkeys+2)), keyshift); + } + return c; +} + + +/*********************************************************************** + * Initialize the encryption keys and the random header according to + * the given password. + */ +static void init_keys(const char* passwd,unsigned long* pkeys,const z_crc_t FAR * pcrc_32_tab) +{ + *(pkeys+0) = 305419896L; + *(pkeys+1) = 591751049L; + *(pkeys+2) = 878082192L; + while (*passwd != '\0') { + update_keys(pkeys,pcrc_32_tab,(int)*passwd); + passwd++; + } +} + +#define zdecode(pkeys,pcrc_32_tab,c) \ + (update_keys(pkeys,pcrc_32_tab,c ^= decrypt_byte(pkeys,pcrc_32_tab))) + +#define zencode(pkeys,pcrc_32_tab,c,t) \ + (t=decrypt_byte(pkeys,pcrc_32_tab), update_keys(pkeys,pcrc_32_tab,c), t^(c)) + +#ifdef INCLUDECRYPTINGCODE_IFCRYPTALLOWED + +#define RAND_HEAD_LEN 12 + /* "last resort" source for second part of crypt seed pattern */ +# ifndef ZCR_SEED2 +# define ZCR_SEED2 3141592654UL /* use PI as default pattern */ +# endif + +static int crypthead(passwd, buf, bufSize, pkeys, pcrc_32_tab, crcForCrypting) + const char *passwd; /* password string */ + unsigned char *buf; /* where to write header */ + int bufSize; + unsigned long* pkeys; + const z_crc_t FAR * pcrc_32_tab; + unsigned long crcForCrypting; +{ + int n; /* index in random header */ + int t; /* temporary */ + int c; /* random byte */ + unsigned char header[RAND_HEAD_LEN-2]; /* random header */ + static unsigned calls = 0; /* ensure different random header each time */ + + if (bufSize> 7) & 0xff; + header[n] = (unsigned char)zencode(pkeys, pcrc_32_tab, c, t); + } + /* Encrypt random header (last two bytes is high word of crc) */ + init_keys(passwd, pkeys, pcrc_32_tab); + for (n = 0; n < RAND_HEAD_LEN-2; n++) + { + buf[n] = (unsigned char)zencode(pkeys, pcrc_32_tab, header[n], t); + } + buf[n++] = zencode(pkeys, pcrc_32_tab, (int)(crcForCrypting >> 16) & 0xff, t); + buf[n++] = zencode(pkeys, pcrc_32_tab, (int)(crcForCrypting >> 24) & 0xff, t); + return n; +} + +#endif diff --git a/hecl-gui/quazip/quazip/qioapi.cpp b/hecl-gui/quazip/quazip/qioapi.cpp index eb4e2ced3..d141191f9 100644 --- a/hecl-gui/quazip/quazip/qioapi.cpp +++ b/hecl-gui/quazip/quazip/qioapi.cpp @@ -1,279 +1,363 @@ -/* ioapi.c -- IO base function header for compress/uncompress .zip - files using zlib + zip or unzip API - - Version 1.01e, February 12th, 2005 - - Copyright (C) 1998-2005 Gilles Vollant - - Modified by Sergey A. Tachenov to integrate with Qt. -*/ - -#include -#include -#include - -#include "zlib.h" -#include "ioapi.h" -#include "quazip_global.h" -#include -#if (QT_VERSION >= 0x050100) -#define QUAZIP_QSAVEFILE_BUG_WORKAROUND -#endif -#ifdef QUAZIP_QSAVEFILE_BUG_WORKAROUND -#include -#endif - -/* I've found an old Unix (a SunOS 4.1.3_U1) without all SEEK_* defined.... */ - -#ifndef SEEK_CUR -#define SEEK_CUR 1 -#endif - -#ifndef SEEK_END -#define SEEK_END 2 -#endif - -#ifndef SEEK_SET -#define SEEK_SET 0 -#endif - -voidpf call_zopen64 (const zlib_filefunc64_32_def* pfilefunc,voidpf file,int mode) -{ - if (pfilefunc->zfile_func64.zopen64_file != NULL) - return (*(pfilefunc->zfile_func64.zopen64_file)) (pfilefunc->zfile_func64.opaque,file,mode); - else - { - return (*(pfilefunc->zopen32_file))(pfilefunc->zfile_func64.opaque,file,mode); - } -} - -int call_zseek64 (const zlib_filefunc64_32_def* pfilefunc,voidpf filestream, ZPOS64_T offset, int origin) -{ - if (pfilefunc->zfile_func64.zseek64_file != NULL) - return (*(pfilefunc->zfile_func64.zseek64_file)) (pfilefunc->zfile_func64.opaque,filestream,offset,origin); - else - { - uLong offsetTruncated = (uLong)offset; - if (offsetTruncated != offset) - return -1; - else - return (*(pfilefunc->zseek32_file))(pfilefunc->zfile_func64.opaque,filestream,offsetTruncated,origin); - } -} - -ZPOS64_T call_ztell64 (const zlib_filefunc64_32_def* pfilefunc,voidpf filestream) -{ - if (pfilefunc->zfile_func64.zseek64_file != NULL) - return (*(pfilefunc->zfile_func64.ztell64_file)) (pfilefunc->zfile_func64.opaque,filestream); - else - { - uLong tell_uLong = (*(pfilefunc->ztell32_file))(pfilefunc->zfile_func64.opaque,filestream); - if ((tell_uLong) == ((uLong)-1)) - return (ZPOS64_T)-1; - else - return tell_uLong; - } -} - -voidpf ZCALLBACK qiodevice_open_file_func ( - voidpf /*opaque UNUSED*/, - voidpf file, - int mode) -{ - QIODevice *iodevice = reinterpret_cast(file); - QIODevice::OpenMode desiredMode; - if ((mode & ZLIB_FILEFUNC_MODE_READWRITEFILTER)==ZLIB_FILEFUNC_MODE_READ) - desiredMode = QIODevice::ReadOnly; - else if (mode & ZLIB_FILEFUNC_MODE_EXISTING) - desiredMode = QIODevice::ReadWrite; - else if (mode & ZLIB_FILEFUNC_MODE_CREATE) - desiredMode = QIODevice::WriteOnly; - if (iodevice->isOpen()) { - if ((iodevice->openMode() & desiredMode) == desiredMode) { - if (iodevice->isSequential()) { - return NULL; - } else { - if ((desiredMode & QIODevice::WriteOnly) != 0) { - // open for writing, need to seek existing device - iodevice->seek(0); - } - } - return iodevice; - } else { - return NULL; - } - } - iodevice->open(desiredMode); - if (iodevice->isOpen()) { - if (iodevice->isSequential()) { - iodevice->close(); - return NULL; - } else { - return iodevice; - } - } else - return NULL; -} - - -uLong ZCALLBACK qiodevice_read_file_func ( - voidpf /*opaque UNUSED*/, - voidpf stream, - void* buf, - uLong size) -{ - uLong ret; - ret = (uLong)((QIODevice*)stream)->read((char*)buf,size); - return ret; -} - - -uLong ZCALLBACK qiodevice_write_file_func ( - voidpf /*opaque UNUSED*/, - voidpf stream, - const void* buf, - uLong size) -{ - uLong ret; - ret = (uLong)((QIODevice*)stream)->write((char*)buf,size); - return ret; -} - -uLong ZCALLBACK qiodevice_tell_file_func ( - voidpf /*opaque UNUSED*/, - voidpf stream) -{ - uLong ret; - ret = ((QIODevice*)stream)->pos(); - return ret; -} - -ZPOS64_T ZCALLBACK qiodevice64_tell_file_func ( - voidpf /*opaque UNUSED*/, - voidpf stream) -{ - qint64 ret; - ret = ((QIODevice*)stream)->pos(); - return static_cast(ret); -} - -int ZCALLBACK qiodevice_seek_file_func ( - voidpf /*opaque UNUSED*/, - voidpf stream, - uLong offset, - int origin) -{ - uLong qiodevice_seek_result=0; - int ret; - switch (origin) - { - case ZLIB_FILEFUNC_SEEK_CUR : - qiodevice_seek_result = ((QIODevice*)stream)->pos() + offset; - break; - case ZLIB_FILEFUNC_SEEK_END : - qiodevice_seek_result = ((QIODevice*)stream)->size() - offset; - break; - case ZLIB_FILEFUNC_SEEK_SET : - qiodevice_seek_result = offset; - break; - default: - return -1; - } - ret = !((QIODevice*)stream)->seek(qiodevice_seek_result); - return ret; -} - -int ZCALLBACK qiodevice64_seek_file_func ( - voidpf /*opaque UNUSED*/, - voidpf stream, - ZPOS64_T offset, - int origin) -{ - qint64 qiodevice_seek_result=0; - int ret; - switch (origin) - { - case ZLIB_FILEFUNC_SEEK_CUR : - qiodevice_seek_result = ((QIODevice*)stream)->pos() + offset; - break; - case ZLIB_FILEFUNC_SEEK_END : - qiodevice_seek_result = ((QIODevice*)stream)->size() - offset; - break; - case ZLIB_FILEFUNC_SEEK_SET : - qiodevice_seek_result = offset; - break; - default: - return -1; - } - ret = !((QIODevice*)stream)->seek(qiodevice_seek_result); - return ret; -} - -int ZCALLBACK qiodevice_close_file_func ( - voidpf /*opaque UNUSED*/, - voidpf stream) -{ - QIODevice *device = reinterpret_cast(stream); -#ifdef QUAZIP_QSAVEFILE_BUG_WORKAROUND - // QSaveFile terribly breaks the is-a idiom: - // it IS a QIODevice, but it is NOT compatible with it: close() is private - QSaveFile *file = qobject_cast(device); - if (file != NULL) { - // We have to call the ugly commit() instead: - return file->commit() ? 0 : -1; - } -#endif - device->close(); - return 0; -} - -int ZCALLBACK qiodevice_error_file_func ( - voidpf /*opaque UNUSED*/, - voidpf /*stream UNUSED*/) -{ - // can't check for error due to the QIODevice API limitation - return 0; -} - -void fill_qiodevice_filefunc ( - zlib_filefunc_def* pzlib_filefunc_def) -{ - pzlib_filefunc_def->zopen_file = qiodevice_open_file_func; - pzlib_filefunc_def->zread_file = qiodevice_read_file_func; - pzlib_filefunc_def->zwrite_file = qiodevice_write_file_func; - pzlib_filefunc_def->ztell_file = qiodevice_tell_file_func; - pzlib_filefunc_def->zseek_file = qiodevice_seek_file_func; - pzlib_filefunc_def->zclose_file = qiodevice_close_file_func; - pzlib_filefunc_def->zerror_file = qiodevice_error_file_func; - pzlib_filefunc_def->opaque = NULL; -} - -void fill_qiodevice64_filefunc ( - zlib_filefunc64_def* pzlib_filefunc_def) -{ - // Open functions are the same for Qt. - pzlib_filefunc_def->zopen64_file = qiodevice_open_file_func; - pzlib_filefunc_def->zread_file = qiodevice_read_file_func; - pzlib_filefunc_def->zwrite_file = qiodevice_write_file_func; - pzlib_filefunc_def->ztell64_file = qiodevice64_tell_file_func; - pzlib_filefunc_def->zseek64_file = qiodevice64_seek_file_func; - pzlib_filefunc_def->zclose_file = qiodevice_close_file_func; - pzlib_filefunc_def->zerror_file = qiodevice_error_file_func; - pzlib_filefunc_def->opaque = NULL; -} - -void fill_zlib_filefunc64_32_def_from_filefunc32(zlib_filefunc64_32_def* p_filefunc64_32,const zlib_filefunc_def* p_filefunc32) -{ - p_filefunc64_32->zfile_func64.zopen64_file = NULL; - p_filefunc64_32->zopen32_file = p_filefunc32->zopen_file; - p_filefunc64_32->zfile_func64.zerror_file = p_filefunc32->zerror_file; - p_filefunc64_32->zfile_func64.zread_file = p_filefunc32->zread_file; - p_filefunc64_32->zfile_func64.zwrite_file = p_filefunc32->zwrite_file; - p_filefunc64_32->zfile_func64.ztell64_file = NULL; - p_filefunc64_32->zfile_func64.zseek64_file = NULL; - p_filefunc64_32->zfile_func64.zclose_file = p_filefunc32->zclose_file; - p_filefunc64_32->zfile_func64.zerror_file = p_filefunc32->zerror_file; - p_filefunc64_32->zfile_func64.opaque = p_filefunc32->opaque; - p_filefunc64_32->zseek32_file = p_filefunc32->zseek_file; - p_filefunc64_32->ztell32_file = p_filefunc32->ztell_file; -} +/* ioapi.c -- IO base function header for compress/uncompress .zip + files using zlib + zip or unzip API + + Version 1.01e, February 12th, 2005 + + Copyright (C) 1998-2005 Gilles Vollant + + Modified by Sergey A. Tachenov to integrate with Qt. +*/ + +#include +#include +#include +#include + +#include "ioapi.h" +#include "quazip_global.h" +#include +#if (QT_VERSION >= 0x050100) +#define QUAZIP_QSAVEFILE_BUG_WORKAROUND +#endif +#ifdef QUAZIP_QSAVEFILE_BUG_WORKAROUND +#include +#endif + +/* I've found an old Unix (a SunOS 4.1.3_U1) without all SEEK_* defined.... */ + +#ifndef SEEK_CUR +#define SEEK_CUR 1 +#endif + +#ifndef SEEK_END +#define SEEK_END 2 +#endif + +#ifndef SEEK_SET +#define SEEK_SET 0 +#endif + +voidpf call_zopen64 (const zlib_filefunc64_32_def* pfilefunc,voidpf file,int mode) +{ + if (pfilefunc->zfile_func64.zopen64_file != NULL) + return (*(pfilefunc->zfile_func64.zopen64_file)) (pfilefunc->zfile_func64.opaque,file,mode); + else + { + return (*(pfilefunc->zopen32_file))(pfilefunc->zfile_func64.opaque,file,mode); + } +} + +int call_zseek64 (const zlib_filefunc64_32_def* pfilefunc,voidpf filestream, ZPOS64_T offset, int origin) +{ + if (pfilefunc->zfile_func64.zseek64_file != NULL) + return (*(pfilefunc->zfile_func64.zseek64_file)) (pfilefunc->zfile_func64.opaque,filestream,offset,origin); + else + { + uLong offsetTruncated = (uLong)offset; + if (offsetTruncated != offset) + return -1; + else + return (*(pfilefunc->zseek32_file))(pfilefunc->zfile_func64.opaque,filestream,offsetTruncated,origin); + } +} + +ZPOS64_T call_ztell64 (const zlib_filefunc64_32_def* pfilefunc,voidpf filestream) +{ + if (pfilefunc->zfile_func64.zseek64_file != NULL) + return (*(pfilefunc->zfile_func64.ztell64_file)) (pfilefunc->zfile_func64.opaque,filestream); + else + { + uLong tell_uLong = (*(pfilefunc->ztell32_file))(pfilefunc->zfile_func64.opaque,filestream); + if ((tell_uLong) == ((uLong)-1)) + return (ZPOS64_T)-1; + else + return tell_uLong; + } +} + +/// @cond internal +struct QIODevice_descriptor { + // Position only used for writing to sequential devices. + qint64 pos; + inline QIODevice_descriptor(): + pos(0) + {} +}; +/// @endcond + +voidpf ZCALLBACK qiodevice_open_file_func ( + voidpf opaque, + voidpf file, + int mode) +{ + QIODevice_descriptor *d = reinterpret_cast(opaque); + QIODevice *iodevice = reinterpret_cast(file); + QIODevice::OpenMode desiredMode; + if ((mode & ZLIB_FILEFUNC_MODE_READWRITEFILTER)==ZLIB_FILEFUNC_MODE_READ) + desiredMode = QIODevice::ReadOnly; + else if (mode & ZLIB_FILEFUNC_MODE_EXISTING) + desiredMode = QIODevice::ReadWrite; + else if (mode & ZLIB_FILEFUNC_MODE_CREATE) + desiredMode = QIODevice::WriteOnly; + if (iodevice->isOpen()) { + if ((iodevice->openMode() & desiredMode) == desiredMode) { + if (desiredMode != QIODevice::WriteOnly + && iodevice->isSequential()) { + // We can use sequential devices only for writing. + delete d; + return NULL; + } else { + if ((desiredMode & QIODevice::WriteOnly) != 0) { + // open for writing, need to seek existing device + if (!iodevice->isSequential()) { + iodevice->seek(0); + } else { + d->pos = iodevice->pos(); + } + } + } + return iodevice; + } else { + delete d; + return NULL; + } + } + iodevice->open(desiredMode); + if (iodevice->isOpen()) { + if (desiredMode != QIODevice::WriteOnly && iodevice->isSequential()) { + // We can use sequential devices only for writing. + iodevice->close(); + delete d; + return NULL; + } else { + return iodevice; + } + } else { + delete d; + return NULL; + } +} + + +uLong ZCALLBACK qiodevice_read_file_func ( + voidpf opaque, + voidpf stream, + void* buf, + uLong size) +{ + QIODevice_descriptor *d = reinterpret_cast(opaque); + QIODevice *iodevice = reinterpret_cast(stream); + qint64 ret64 = iodevice->read((char*)buf,size); + uLong ret; + ret = (uLong) ret64; + if (ret64 != -1) { + d->pos += ret64; + } + return ret; +} + + +uLong ZCALLBACK qiodevice_write_file_func ( + voidpf opaque, + voidpf stream, + const void* buf, + uLong size) +{ + QIODevice_descriptor *d = reinterpret_cast(opaque); + QIODevice *iodevice = reinterpret_cast(stream); + uLong ret; + qint64 ret64 = iodevice->write((char*)buf,size); + if (ret64 != -1) { + d->pos += ret64; + } + ret = (uLong) ret64; + return ret; +} + +uLong ZCALLBACK qiodevice_tell_file_func ( + voidpf opaque, + voidpf stream) +{ + QIODevice_descriptor *d = reinterpret_cast(opaque); + QIODevice *iodevice = reinterpret_cast(stream); + uLong ret; + qint64 ret64; + if (iodevice->isSequential()) { + ret64 = d->pos; + } else { + ret64 = iodevice->pos(); + } + ret = static_cast(ret64); + return ret; +} + +ZPOS64_T ZCALLBACK qiodevice64_tell_file_func ( + voidpf opaque, + voidpf stream) +{ + QIODevice_descriptor *d = reinterpret_cast(opaque); + QIODevice *iodevice = reinterpret_cast(stream); + qint64 ret; + if (iodevice->isSequential()) { + ret = d->pos; + } else { + ret = iodevice->pos(); + } + return static_cast(ret); +} + +int ZCALLBACK qiodevice_seek_file_func ( + voidpf /*opaque UNUSED*/, + voidpf stream, + uLong offset, + int origin) +{ + QIODevice *iodevice = reinterpret_cast(stream); + if (iodevice->isSequential()) { + if (origin == ZLIB_FILEFUNC_SEEK_END + && offset == 0) { + // sequential devices are always at end (needed in mdAppend) + return 0; + } else { + qWarning("qiodevice_seek_file_func() called for sequential device"); + return -1; + } + } + uLong qiodevice_seek_result=0; + int ret; + switch (origin) + { + case ZLIB_FILEFUNC_SEEK_CUR : + qiodevice_seek_result = ((QIODevice*)stream)->pos() + offset; + break; + case ZLIB_FILEFUNC_SEEK_END : + qiodevice_seek_result = ((QIODevice*)stream)->size() - offset; + break; + case ZLIB_FILEFUNC_SEEK_SET : + qiodevice_seek_result = offset; + break; + default: + return -1; + } + ret = !iodevice->seek(qiodevice_seek_result); + return ret; +} + +int ZCALLBACK qiodevice64_seek_file_func ( + voidpf /*opaque UNUSED*/, + voidpf stream, + ZPOS64_T offset, + int origin) +{ + QIODevice *iodevice = reinterpret_cast(stream); + if (iodevice->isSequential()) { + if (origin == ZLIB_FILEFUNC_SEEK_END + && offset == 0) { + // sequential devices are always at end (needed in mdAppend) + return 0; + } else { + qWarning("qiodevice_seek_file_func() called for sequential device"); + return -1; + } + } + qint64 qiodevice_seek_result=0; + int ret; + switch (origin) + { + case ZLIB_FILEFUNC_SEEK_CUR : + qiodevice_seek_result = ((QIODevice*)stream)->pos() + offset; + break; + case ZLIB_FILEFUNC_SEEK_END : + qiodevice_seek_result = ((QIODevice*)stream)->size() - offset; + break; + case ZLIB_FILEFUNC_SEEK_SET : + qiodevice_seek_result = offset; + break; + default: + return -1; + } + ret = !iodevice->seek(qiodevice_seek_result); + return ret; +} + +int ZCALLBACK qiodevice_close_file_func ( + voidpf opaque, + voidpf stream) +{ + QIODevice_descriptor *d = reinterpret_cast(opaque); + delete d; + QIODevice *device = reinterpret_cast(stream); +#ifdef QUAZIP_QSAVEFILE_BUG_WORKAROUND + // QSaveFile terribly breaks the is-a idiom: + // it IS a QIODevice, but it is NOT compatible with it: close() is private + QSaveFile *file = qobject_cast(device); + if (file != NULL) { + // We have to call the ugly commit() instead: + return file->commit() ? 0 : -1; + } +#endif + device->close(); + return 0; +} + +int ZCALLBACK qiodevice_fakeclose_file_func ( + voidpf opaque, + voidpf /*stream*/) +{ + QIODevice_descriptor *d = reinterpret_cast(opaque); + delete d; + return 0; +} + +int ZCALLBACK qiodevice_error_file_func ( + voidpf /*opaque UNUSED*/, + voidpf /*stream UNUSED*/) +{ + // can't check for error due to the QIODevice API limitation + return 0; +} + +void fill_qiodevice_filefunc ( + zlib_filefunc_def* pzlib_filefunc_def) +{ + pzlib_filefunc_def->zopen_file = qiodevice_open_file_func; + pzlib_filefunc_def->zread_file = qiodevice_read_file_func; + pzlib_filefunc_def->zwrite_file = qiodevice_write_file_func; + pzlib_filefunc_def->ztell_file = qiodevice_tell_file_func; + pzlib_filefunc_def->zseek_file = qiodevice_seek_file_func; + pzlib_filefunc_def->zclose_file = qiodevice_close_file_func; + pzlib_filefunc_def->zerror_file = qiodevice_error_file_func; + pzlib_filefunc_def->opaque = new QIODevice_descriptor; +} + +void fill_qiodevice64_filefunc ( + zlib_filefunc64_def* pzlib_filefunc_def) +{ + // Open functions are the same for Qt. + pzlib_filefunc_def->zopen64_file = qiodevice_open_file_func; + pzlib_filefunc_def->zread_file = qiodevice_read_file_func; + pzlib_filefunc_def->zwrite_file = qiodevice_write_file_func; + pzlib_filefunc_def->ztell64_file = qiodevice64_tell_file_func; + pzlib_filefunc_def->zseek64_file = qiodevice64_seek_file_func; + pzlib_filefunc_def->zclose_file = qiodevice_close_file_func; + pzlib_filefunc_def->zerror_file = qiodevice_error_file_func; + pzlib_filefunc_def->opaque = new QIODevice_descriptor; + pzlib_filefunc_def->zfakeclose_file = qiodevice_fakeclose_file_func; +} + +void fill_zlib_filefunc64_32_def_from_filefunc32(zlib_filefunc64_32_def* p_filefunc64_32,const zlib_filefunc_def* p_filefunc32) +{ + p_filefunc64_32->zfile_func64.zopen64_file = NULL; + p_filefunc64_32->zopen32_file = p_filefunc32->zopen_file; + p_filefunc64_32->zfile_func64.zerror_file = p_filefunc32->zerror_file; + p_filefunc64_32->zfile_func64.zread_file = p_filefunc32->zread_file; + p_filefunc64_32->zfile_func64.zwrite_file = p_filefunc32->zwrite_file; + p_filefunc64_32->zfile_func64.ztell64_file = NULL; + p_filefunc64_32->zfile_func64.zseek64_file = NULL; + p_filefunc64_32->zfile_func64.zclose_file = p_filefunc32->zclose_file; + p_filefunc64_32->zfile_func64.zerror_file = p_filefunc32->zerror_file; + p_filefunc64_32->zfile_func64.opaque = p_filefunc32->opaque; + p_filefunc64_32->zfile_func64.zfakeclose_file = NULL; + p_filefunc64_32->zseek32_file = p_filefunc32->zseek_file; + p_filefunc64_32->ztell32_file = p_filefunc32->ztell_file; +} diff --git a/hecl-gui/quazip/quazip/quaadler32.cpp b/hecl-gui/quazip/quazip/quaadler32.cpp index 8393ce117..60102ee20 100644 --- a/hecl-gui/quazip/quazip/quaadler32.cpp +++ b/hecl-gui/quazip/quazip/quaadler32.cpp @@ -6,7 +6,7 @@ This file is part of QuaZIP. QuaZIP is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by -the Free Software Foundation, either version 3 of the License, or +the Free Software Foundation, either version 2.1 of the License, or (at your option) any later version. QuaZIP is distributed in the hope that it will be useful, @@ -25,7 +25,7 @@ see quazip/(un)zip.h files for details. Basically it's the zlib license. #include "quaadler32.h" -#include "zlib.h" +#include QuaAdler32::QuaAdler32() { diff --git a/hecl-gui/quazip/quazip/quaadler32.h b/hecl-gui/quazip/quazip/quaadler32.h index 4e117e7e6..e8847f402 100644 --- a/hecl-gui/quazip/quazip/quaadler32.h +++ b/hecl-gui/quazip/quazip/quaadler32.h @@ -9,7 +9,7 @@ This file is part of QuaZIP. QuaZIP is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by -the Free Software Foundation, either version 3 of the License, or +the Free Software Foundation, either version 2.1 of the License, or (at your option) any later version. QuaZIP is distributed in the hope that it will be useful, diff --git a/hecl-gui/quazip/quazip/quachecksum32.h b/hecl-gui/quazip/quazip/quachecksum32.h index b99ef6995..40ff451f9 100644 --- a/hecl-gui/quazip/quazip/quachecksum32.h +++ b/hecl-gui/quazip/quazip/quachecksum32.h @@ -8,7 +8,7 @@ This file is part of QuaZIP. QuaZIP is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by -the Free Software Foundation, either version 3 of the License, or +the Free Software Foundation, either version 2.1 of the License, or (at your option) any later version. QuaZIP is distributed in the hope that it will be useful, diff --git a/hecl-gui/quazip/quazip/quacrc32.cpp b/hecl-gui/quazip/quazip/quacrc32.cpp index 7e1c57d5e..583477559 100644 --- a/hecl-gui/quazip/quazip/quacrc32.cpp +++ b/hecl-gui/quazip/quazip/quacrc32.cpp @@ -5,7 +5,7 @@ This file is part of QuaZIP. QuaZIP is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by -the Free Software Foundation, either version 3 of the License, or +the Free Software Foundation, either version 2.1 of the License, or (at your option) any later version. QuaZIP is distributed in the hope that it will be useful, @@ -24,7 +24,7 @@ see quazip/(un)zip.h files for details. Basically it's the zlib license. #include "quacrc32.h" -#include "zlib.h" +#include QuaCrc32::QuaCrc32() { diff --git a/hecl-gui/quazip/quazip/quacrc32.h b/hecl-gui/quazip/quazip/quacrc32.h index 2582de8c2..af7703b2d 100644 --- a/hecl-gui/quazip/quazip/quacrc32.h +++ b/hecl-gui/quazip/quazip/quacrc32.h @@ -8,7 +8,7 @@ This file is part of QuaZIP. QuaZIP is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by -the Free Software Foundation, either version 3 of the License, or +the Free Software Foundation, either version 2.1 of the License, or (at your option) any later version. QuaZIP is distributed in the hope that it will be useful, diff --git a/hecl-gui/quazip/quazip/quagzipfile.cpp b/hecl-gui/quazip/quazip/quagzipfile.cpp index 73ba554d4..bfe8f1081 100644 --- a/hecl-gui/quazip/quazip/quagzipfile.cpp +++ b/hecl-gui/quazip/quazip/quagzipfile.cpp @@ -1,172 +1,172 @@ -/* -Copyright (C) 2005-2014 Sergey A. Tachenov - -This file is part of QuaZIP. - -QuaZIP is free software: you can redistribute it and/or modify -it under the terms of the GNU Lesser General Public License as published by -the Free Software Foundation, either version 3 of the License, or -(at your option) any later version. - -QuaZIP is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU Lesser General Public License for more details. - -You should have received a copy of the GNU Lesser General Public License -along with QuaZIP. If not, see . - -See COPYING file for the full LGPL text. - -Original ZIP package is copyrighted by Gilles Vollant and contributors, -see quazip/(un)zip.h files for details. Basically it's the zlib license. -*/ - -#include - -#include "quagzipfile.h" - -/// \cond internal -class QuaGzipFilePrivate { - friend class QuaGzipFile; - QString fileName; - gzFile gzd; - inline QuaGzipFilePrivate(): gzd(NULL) {} - inline QuaGzipFilePrivate(const QString &fileName): - fileName(fileName), gzd(NULL) {} - template bool open(FileId id, - QIODevice::OpenMode mode, QString &error); - gzFile open(int fd, const char *modeString); - gzFile open(const QString &name, const char *modeString); -}; - -gzFile QuaGzipFilePrivate::open(const QString &name, const char *modeString) -{ - return gzopen(QFile::encodeName(name).constData(), modeString); -} - -gzFile QuaGzipFilePrivate::open(int fd, const char *modeString) -{ - return gzdopen(fd, modeString); -} - -template -bool QuaGzipFilePrivate::open(FileId id, QIODevice::OpenMode mode, - QString &error) -{ - char modeString[2]; - modeString[0] = modeString[1] = '\0'; - if ((mode & QIODevice::Append) != 0) { - error = QuaGzipFile::trUtf8("QIODevice::Append is not " - "supported for GZIP"); - return false; - } - if ((mode & QIODevice::ReadOnly) != 0 - && (mode & QIODevice::WriteOnly) != 0) { - error = QuaGzipFile::trUtf8("Opening gzip for both reading" - " and writing is not supported"); - return false; - } else if ((mode & QIODevice::ReadOnly) != 0) { - modeString[0] = 'r'; - } else if ((mode & QIODevice::WriteOnly) != 0) { - modeString[0] = 'w'; - } else { - error = QuaGzipFile::trUtf8("You can open a gzip either for reading" - " or for writing. Which is it?"); - return false; - } - gzd = open(id, modeString); - if (gzd == NULL) { - error = QuaGzipFile::trUtf8("Could not gzopen() file"); - return false; - } - return true; -} -/// \endcond - -QuaGzipFile::QuaGzipFile(): -d(new QuaGzipFilePrivate()) -{ -} - -QuaGzipFile::QuaGzipFile(QObject *parent): -QIODevice(parent), -d(new QuaGzipFilePrivate()) -{ -} - -QuaGzipFile::QuaGzipFile(const QString &fileName, QObject *parent): - QIODevice(parent), -d(new QuaGzipFilePrivate(fileName)) -{ -} - -QuaGzipFile::~QuaGzipFile() -{ - if (isOpen()) { - close(); - } - delete d; -} - -void QuaGzipFile::setFileName(const QString& fileName) -{ - d->fileName = fileName; -} - -QString QuaGzipFile::getFileName() const -{ - return d->fileName; -} - -bool QuaGzipFile::isSequential() const -{ - return true; -} - -bool QuaGzipFile::open(QIODevice::OpenMode mode) -{ - QString error; - if (!d->open(d->fileName, mode, error)) { - setErrorString(error); - return false; - } - return QIODevice::open(mode); -} - -bool QuaGzipFile::open(int fd, QIODevice::OpenMode mode) -{ - QString error; - if (!d->open(fd, mode, error)) { - setErrorString(error); - return false; - } - return QIODevice::open(mode); -} - -bool QuaGzipFile::flush() -{ - return gzflush(d->gzd, Z_SYNC_FLUSH) == Z_OK; -} - -void QuaGzipFile::close() -{ - QIODevice::close(); - gzclose(d->gzd); -} - -qint64 QuaGzipFile::readData(char *data, qint64 maxSize) -{ - return gzread(d->gzd, (voidp)data, (unsigned)maxSize); -} - -qint64 QuaGzipFile::writeData(const char *data, qint64 maxSize) -{ - if (maxSize == 0) - return 0; - int written = gzwrite(d->gzd, (voidp)data, (unsigned)maxSize); - if (written == 0) - return -1; - else - return written; -} +/* +Copyright (C) 2005-2014 Sergey A. Tachenov + +This file is part of QuaZIP. + +QuaZIP is free software: you can redistribute it and/or modify +it under the terms of the GNU Lesser General Public License as published by +the Free Software Foundation, either version 2.1 of the License, or +(at your option) any later version. + +QuaZIP is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU Lesser General Public License for more details. + +You should have received a copy of the GNU Lesser General Public License +along with QuaZIP. If not, see . + +See COPYING file for the full LGPL text. + +Original ZIP package is copyrighted by Gilles Vollant and contributors, +see quazip/(un)zip.h files for details. Basically it's the zlib license. +*/ + +#include + +#include "quagzipfile.h" + +/// \cond internal +class QuaGzipFilePrivate { + friend class QuaGzipFile; + QString fileName; + gzFile gzd; + inline QuaGzipFilePrivate(): gzd(NULL) {} + inline QuaGzipFilePrivate(const QString &fileName): + fileName(fileName), gzd(NULL) {} + template bool open(FileId id, + QIODevice::OpenMode mode, QString &error); + gzFile open(int fd, const char *modeString); + gzFile open(const QString &name, const char *modeString); +}; + +gzFile QuaGzipFilePrivate::open(const QString &name, const char *modeString) +{ + return gzopen(QFile::encodeName(name).constData(), modeString); +} + +gzFile QuaGzipFilePrivate::open(int fd, const char *modeString) +{ + return gzdopen(fd, modeString); +} + +template +bool QuaGzipFilePrivate::open(FileId id, QIODevice::OpenMode mode, + QString &error) +{ + char modeString[2]; + modeString[0] = modeString[1] = '\0'; + if ((mode & QIODevice::Append) != 0) { + error = QuaGzipFile::tr("QIODevice::Append is not " + "supported for GZIP"); + return false; + } + if ((mode & QIODevice::ReadOnly) != 0 + && (mode & QIODevice::WriteOnly) != 0) { + error = QuaGzipFile::tr("Opening gzip for both reading" + " and writing is not supported"); + return false; + } else if ((mode & QIODevice::ReadOnly) != 0) { + modeString[0] = 'r'; + } else if ((mode & QIODevice::WriteOnly) != 0) { + modeString[0] = 'w'; + } else { + error = QuaGzipFile::tr("You can open a gzip either for reading" + " or for writing. Which is it?"); + return false; + } + gzd = open(id, modeString); + if (gzd == NULL) { + error = QuaGzipFile::tr("Could not gzopen() file"); + return false; + } + return true; +} +/// \endcond + +QuaGzipFile::QuaGzipFile(): +d(new QuaGzipFilePrivate()) +{ +} + +QuaGzipFile::QuaGzipFile(QObject *parent): +QIODevice(parent), +d(new QuaGzipFilePrivate()) +{ +} + +QuaGzipFile::QuaGzipFile(const QString &fileName, QObject *parent): + QIODevice(parent), +d(new QuaGzipFilePrivate(fileName)) +{ +} + +QuaGzipFile::~QuaGzipFile() +{ + if (isOpen()) { + close(); + } + delete d; +} + +void QuaGzipFile::setFileName(const QString& fileName) +{ + d->fileName = fileName; +} + +QString QuaGzipFile::getFileName() const +{ + return d->fileName; +} + +bool QuaGzipFile::isSequential() const +{ + return true; +} + +bool QuaGzipFile::open(QIODevice::OpenMode mode) +{ + QString error; + if (!d->open(d->fileName, mode, error)) { + setErrorString(error); + return false; + } + return QIODevice::open(mode); +} + +bool QuaGzipFile::open(int fd, QIODevice::OpenMode mode) +{ + QString error; + if (!d->open(fd, mode, error)) { + setErrorString(error); + return false; + } + return QIODevice::open(mode); +} + +bool QuaGzipFile::flush() +{ + return gzflush(d->gzd, Z_SYNC_FLUSH) == Z_OK; +} + +void QuaGzipFile::close() +{ + QIODevice::close(); + gzclose(d->gzd); +} + +qint64 QuaGzipFile::readData(char *data, qint64 maxSize) +{ + return gzread(d->gzd, (voidp)data, (unsigned)maxSize); +} + +qint64 QuaGzipFile::writeData(const char *data, qint64 maxSize) +{ + if (maxSize == 0) + return 0; + int written = gzwrite(d->gzd, (voidp)data, (unsigned)maxSize); + if (written == 0) + return -1; + else + return written; +} diff --git a/hecl-gui/quazip/quazip/quagzipfile.h b/hecl-gui/quazip/quazip/quagzipfile.h index d6dc1af13..e2f9d9738 100644 --- a/hecl-gui/quazip/quazip/quagzipfile.h +++ b/hecl-gui/quazip/quazip/quagzipfile.h @@ -1,108 +1,108 @@ -#ifndef QUAZIP_QUAGZIPFILE_H -#define QUAZIP_QUAGZIPFILE_H - -/* -Copyright (C) 2005-2014 Sergey A. Tachenov - -This file is part of QuaZIP. - -QuaZIP is free software: you can redistribute it and/or modify -it under the terms of the GNU Lesser General Public License as published by -the Free Software Foundation, either version 3 of the License, or -(at your option) any later version. - -QuaZIP is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU Lesser General Public License for more details. - -You should have received a copy of the GNU Lesser General Public License -along with QuaZIP. If not, see . - -See COPYING file for the full LGPL text. - -Original ZIP package is copyrighted by Gilles Vollant and contributors, -see quazip/(un)zip.h files for details. Basically it's the zlib license. -*/ - -#include -#include "quazip_global.h" - -#include - -class QuaGzipFilePrivate; - -/// GZIP file -/** - This class is a wrapper around GZIP file access functions in zlib. Unlike QuaZip classes, it doesn't allow reading from a GZIP file opened as QIODevice, for example, if your GZIP file is in QBuffer. It only provides QIODevice access to a GZIP file contents, but the GZIP file itself must be identified by its name on disk or by descriptor id. - */ -class QUAZIP_EXPORT QuaGzipFile: public QIODevice { - Q_OBJECT -public: - /// Empty constructor. - /** - Must call setFileName() before trying to open. - */ - QuaGzipFile(); - /// Empty constructor with a parent. - /** - Must call setFileName() before trying to open. - \param parent The parent object, as per QObject logic. - */ - QuaGzipFile(QObject *parent); - /// Constructor. - /** - \param fileName The name of the GZIP file. - \param parent The parent object, as per QObject logic. - */ - QuaGzipFile(const QString &fileName, QObject *parent = NULL); - /// Destructor. - virtual ~QuaGzipFile(); - /// Sets the name of the GZIP file to be opened. - void setFileName(const QString& fileName); - /// Returns the name of the GZIP file. - QString getFileName() const; - /// Returns true. - /** - Strictly speaking, zlib supports seeking for GZIP files, but it is - poorly implemented, because there is no way to implement it - properly. For reading, seeking backwards is very slow, and for - writing, it is downright impossible. Therefore, QuaGzipFile does not - support seeking at all. - */ - virtual bool isSequential() const; - /// Opens the file. - /** - \param mode Can be either QIODevice::Write or QIODevice::Read. - ReadWrite and Append aren't supported. - */ - virtual bool open(QIODevice::OpenMode mode); - /// Opens the file. - /** - \overload - \param fd The file descriptor to read/write the GZIP file from/to. - \param mode Can be either QIODevice::Write or QIODevice::Read. - ReadWrite and Append aren't supported. - */ - virtual bool open(int fd, QIODevice::OpenMode mode); - /// Flushes data to file. - /** - The data is written using Z_SYNC_FLUSH mode. Doesn't make any sense - when reading. - */ - virtual bool flush(); - /// Closes the file. - virtual void close(); -protected: - /// Implementation of QIODevice::readData(). - virtual qint64 readData(char *data, qint64 maxSize); - /// Implementation of QIODevice::writeData(). - virtual qint64 writeData(const char *data, qint64 maxSize); -private: - // not implemented by design to disable copy - QuaGzipFile(const QuaGzipFile &that); - QuaGzipFile& operator=(const QuaGzipFile &that); - QuaGzipFilePrivate *d; -}; - -#endif // QUAZIP_QUAGZIPFILE_H +#ifndef QUAZIP_QUAGZIPFILE_H +#define QUAZIP_QUAGZIPFILE_H + +/* +Copyright (C) 2005-2014 Sergey A. Tachenov + +This file is part of QuaZIP. + +QuaZIP is free software: you can redistribute it and/or modify +it under the terms of the GNU Lesser General Public License as published by +the Free Software Foundation, either version 2.1 of the License, or +(at your option) any later version. + +QuaZIP is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU Lesser General Public License for more details. + +You should have received a copy of the GNU Lesser General Public License +along with QuaZIP. If not, see . + +See COPYING file for the full LGPL text. + +Original ZIP package is copyrighted by Gilles Vollant and contributors, +see quazip/(un)zip.h files for details. Basically it's the zlib license. +*/ + +#include +#include "quazip_global.h" + +#include + +class QuaGzipFilePrivate; + +/// GZIP file +/** + This class is a wrapper around GZIP file access functions in zlib. Unlike QuaZip classes, it doesn't allow reading from a GZIP file opened as QIODevice, for example, if your GZIP file is in QBuffer. It only provides QIODevice access to a GZIP file contents, but the GZIP file itself must be identified by its name on disk or by descriptor id. + */ +class QUAZIP_EXPORT QuaGzipFile: public QIODevice { + Q_OBJECT +public: + /// Empty constructor. + /** + Must call setFileName() before trying to open. + */ + QuaGzipFile(); + /// Empty constructor with a parent. + /** + Must call setFileName() before trying to open. + \param parent The parent object, as per QObject logic. + */ + QuaGzipFile(QObject *parent); + /// Constructor. + /** + \param fileName The name of the GZIP file. + \param parent The parent object, as per QObject logic. + */ + QuaGzipFile(const QString &fileName, QObject *parent = NULL); + /// Destructor. + virtual ~QuaGzipFile(); + /// Sets the name of the GZIP file to be opened. + void setFileName(const QString& fileName); + /// Returns the name of the GZIP file. + QString getFileName() const; + /// Returns true. + /** + Strictly speaking, zlib supports seeking for GZIP files, but it is + poorly implemented, because there is no way to implement it + properly. For reading, seeking backwards is very slow, and for + writing, it is downright impossible. Therefore, QuaGzipFile does not + support seeking at all. + */ + virtual bool isSequential() const; + /// Opens the file. + /** + \param mode Can be either QIODevice::Write or QIODevice::Read. + ReadWrite and Append aren't supported. + */ + virtual bool open(QIODevice::OpenMode mode); + /// Opens the file. + /** + \overload + \param fd The file descriptor to read/write the GZIP file from/to. + \param mode Can be either QIODevice::Write or QIODevice::Read. + ReadWrite and Append aren't supported. + */ + virtual bool open(int fd, QIODevice::OpenMode mode); + /// Flushes data to file. + /** + The data is written using Z_SYNC_FLUSH mode. Doesn't make any sense + when reading. + */ + virtual bool flush(); + /// Closes the file. + virtual void close(); +protected: + /// Implementation of QIODevice::readData(). + virtual qint64 readData(char *data, qint64 maxSize); + /// Implementation of QIODevice::writeData(). + virtual qint64 writeData(const char *data, qint64 maxSize); +private: + // not implemented by design to disable copy + QuaGzipFile(const QuaGzipFile &that); + QuaGzipFile& operator=(const QuaGzipFile &that); + QuaGzipFilePrivate *d; +}; + +#endif // QUAZIP_QUAGZIPFILE_H diff --git a/hecl-gui/quazip/quazip/quaziodevice.cpp b/hecl-gui/quazip/quazip/quaziodevice.cpp index 932613af1..14f6313e9 100644 --- a/hecl-gui/quazip/quazip/quaziodevice.cpp +++ b/hecl-gui/quazip/quazip/quaziodevice.cpp @@ -1,320 +1,349 @@ -/* -Copyright (C) 2005-2014 Sergey A. Tachenov - -This file is part of QuaZIP. - -QuaZIP is free software: you can redistribute it and/or modify -it under the terms of the GNU Lesser General Public License as published by -the Free Software Foundation, either version 3 of the License, or -(at your option) any later version. - -QuaZIP is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU Lesser General Public License for more details. - -You should have received a copy of the GNU Lesser General Public License -along with QuaZIP. If not, see . - -See COPYING file for the full LGPL text. - -Original ZIP package is copyrighted by Gilles Vollant and contributors, -see quazip/(un)zip.h files for details. Basically it's the zlib license. -*/ - -#include "quaziodevice.h" - -#define QUAZIO_INBUFSIZE 4096 -#define QUAZIO_OUTBUFSIZE 4096 - -/// \cond internal -class QuaZIODevicePrivate { - friend class QuaZIODevice; - QuaZIODevicePrivate(QIODevice *io); - ~QuaZIODevicePrivate(); - QIODevice *io; - z_stream zins; - z_stream zouts; - char *inBuf; - int inBufPos; - int inBufSize; - char *outBuf; - int outBufPos; - int outBufSize; - bool zBufError; - int doFlush(QString &error); -}; - -QuaZIODevicePrivate::QuaZIODevicePrivate(QIODevice *io): - io(io), - inBuf(NULL), - inBufPos(0), - inBufSize(0), - outBuf(NULL), - outBufPos(0), - outBufSize(0), - zBufError(false) -{ - zins.zalloc = (alloc_func) NULL; - zins.zfree = (free_func) NULL; - zins.opaque = NULL; - zouts.zalloc = (alloc_func) NULL; - zouts.zfree = (free_func) NULL; - zouts.opaque = NULL; - inBuf = new char[QUAZIO_INBUFSIZE]; - outBuf = new char[QUAZIO_OUTBUFSIZE]; -#ifdef QUAZIP_ZIODEVICE_DEBUG_OUTPUT - debug.setFileName("debug.out"); - debug.open(QIODevice::WriteOnly); -#endif -#ifdef QUAZIP_ZIODEVICE_DEBUG_INPUT - indebug.setFileName("debug.in"); - indebug.open(QIODevice::WriteOnly); -#endif -} - -QuaZIODevicePrivate::~QuaZIODevicePrivate() -{ -#ifdef QUAZIP_ZIODEVICE_DEBUG_OUTPUT - debug.close(); -#endif -#ifdef QUAZIP_ZIODEVICE_DEBUG_INPUT - indebug.close(); -#endif - if (inBuf != NULL) - delete[] inBuf; - if (outBuf != NULL) - delete[] outBuf; -} - -int QuaZIODevicePrivate::doFlush(QString &error) -{ - int flushed = 0; - while (outBufPos < outBufSize) { - int more = io->write(outBuf + outBufPos, outBufSize - outBufPos); - if (more == -1) { - error = io->errorString(); - return -1; - } - if (more == 0) - break; - outBufPos += more; - flushed += more; - } - if (outBufPos == outBufSize) { - outBufPos = outBufSize = 0; - } - return flushed; -} - -/// \endcond - -// #define QUAZIP_ZIODEVICE_DEBUG_OUTPUT -// #define QUAZIP_ZIODEVICE_DEBUG_INPUT -#ifdef QUAZIP_ZIODEVICE_DEBUG_OUTPUT -#include -static QFile debug; -#endif -#ifdef QUAZIP_ZIODEVICE_DEBUG_INPUT -#include -static QFile indebug; -#endif - -QuaZIODevice::QuaZIODevice(QIODevice *io, QObject *parent): - QIODevice(parent), - d(new QuaZIODevicePrivate(io)) -{ - connect(io, SIGNAL(readyRead()), SIGNAL(readyRead())); -} - -QuaZIODevice::~QuaZIODevice() -{ - if (isOpen()) - close(); - delete d; -} - -QIODevice *QuaZIODevice::getIoDevice() const -{ - return d->io; -} - -bool QuaZIODevice::open(QIODevice::OpenMode mode) -{ - if ((mode & QIODevice::Append) != 0) { - setErrorString(trUtf8("QIODevice::Append is not supported for" - " QuaZIODevice")); - return false; - } - if ((mode & QIODevice::ReadWrite) == QIODevice::ReadWrite) { - setErrorString(trUtf8("QIODevice::ReadWrite is not supported for" - " QuaZIODevice")); - return false; - } - if ((mode & QIODevice::ReadOnly) != 0) { - if (inflateInit(&d->zins) != Z_OK) { - setErrorString(d->zins.msg); - return false; - } - } - if ((mode & QIODevice::WriteOnly) != 0) { - if (deflateInit(&d->zouts, Z_DEFAULT_COMPRESSION) != Z_OK) { - setErrorString(d->zouts.msg); - return false; - } - } - return QIODevice::open(mode); -} - -void QuaZIODevice::close() -{ - if ((openMode() & QIODevice::ReadOnly) != 0) { - if (inflateEnd(&d->zins) != Z_OK) { - setErrorString(d->zins.msg); - } - } - if ((openMode() & QIODevice::WriteOnly) != 0) { - flush(); - if (deflateEnd(&d->zouts) != Z_OK) { - setErrorString(d->zouts.msg); - } - } - QIODevice::close(); -} - -qint64 QuaZIODevice::readData(char *data, qint64 maxSize) -{ - int read = 0; - while (read < maxSize) { - if (d->inBufPos == d->inBufSize) { - d->inBufPos = 0; - d->inBufSize = d->io->read(d->inBuf, QUAZIO_INBUFSIZE); - if (d->inBufSize == -1) { - d->inBufSize = 0; - setErrorString(d->io->errorString()); - return -1; - } - if (d->inBufSize == 0) - break; - } - while (read < maxSize && d->inBufPos < d->inBufSize) { - d->zins.next_in = (Bytef *) (d->inBuf + d->inBufPos); - d->zins.avail_in = d->inBufSize - d->inBufPos; - d->zins.next_out = (Bytef *) (data + read); - d->zins.avail_out = (uInt) (maxSize - read); // hope it's less than 2GB - int more = 0; - switch (inflate(&d->zins, Z_SYNC_FLUSH)) { - case Z_OK: - read = (char *) d->zins.next_out - data; - d->inBufPos = (char *) d->zins.next_in - d->inBuf; - break; - case Z_STREAM_END: - read = (char *) d->zins.next_out - data; - d->inBufPos = (char *) d->zins.next_in - d->inBuf; - return read; - case Z_BUF_ERROR: // this should never happen, but just in case - if (!d->zBufError) { - qWarning("Z_BUF_ERROR detected with %d/%d in/out, weird", - d->zins.avail_in, d->zins.avail_out); - d->zBufError = true; - } - memmove(d->inBuf, d->inBuf + d->inBufPos, d->inBufSize - d->inBufPos); - d->inBufSize -= d->inBufPos; - d->inBufPos = 0; - more = d->io->read(d->inBuf + d->inBufSize, QUAZIO_INBUFSIZE - d->inBufSize); - if (more == -1) { - setErrorString(d->io->errorString()); - return -1; - } - if (more == 0) - return read; - d->inBufSize += more; - break; - default: - setErrorString(QString::fromLocal8Bit(d->zins.msg)); - return -1; - } - } - } -#ifdef QUAZIP_ZIODEVICE_DEBUG_INPUT - indebug.write(data, read); -#endif - return read; -} - -qint64 QuaZIODevice::writeData(const char *data, qint64 maxSize) -{ - int written = 0; - QString error; - if (d->doFlush(error) == -1) { - setErrorString(error); - return -1; - } - while (written < maxSize) { - // there is some data waiting in the output buffer - if (d->outBufPos < d->outBufSize) - return written; - d->zouts.next_in = (Bytef *) (data + written); - d->zouts.avail_in = (uInt) (maxSize - written); // hope it's less than 2GB - d->zouts.next_out = (Bytef *) d->outBuf; - d->zouts.avail_out = QUAZIO_OUTBUFSIZE; - switch (deflate(&d->zouts, Z_NO_FLUSH)) { - case Z_OK: - written = (char *) d->zouts.next_in - data; - d->outBufSize = (char *) d->zouts.next_out - d->outBuf; - break; - default: - setErrorString(QString::fromLocal8Bit(d->zouts.msg)); - return -1; - } - if (d->doFlush(error) == -1) { - setErrorString(error); - return -1; - } - } -#ifdef QUAZIP_ZIODEVICE_DEBUG_OUTPUT - debug.write(data, written); -#endif - return written; -} - -bool QuaZIODevice::flush() -{ - QString error; - if (d->doFlush(error) < 0) { - setErrorString(error); - return false; - } - // can't flush buffer, some data is still waiting - if (d->outBufPos < d->outBufSize) - return true; - Bytef c = 0; - d->zouts.next_in = &c; // fake input buffer - d->zouts.avail_in = 0; // of zero size - do { - d->zouts.next_out = (Bytef *) d->outBuf; - d->zouts.avail_out = QUAZIO_OUTBUFSIZE; - switch (deflate(&d->zouts, Z_SYNC_FLUSH)) { - case Z_OK: - d->outBufSize = (char *) d->zouts.next_out - d->outBuf; - if (d->doFlush(error) < 0) { - setErrorString(error); - return false; - } - if (d->outBufPos < d->outBufSize) - return true; - break; - case Z_BUF_ERROR: // nothing to write? - return true; - default: - setErrorString(QString::fromLocal8Bit(d->zouts.msg)); - return false; - } - } while (d->zouts.avail_out == 0); - return true; -} - -bool QuaZIODevice::isSequential() const -{ - return true; -} +/* +Copyright (C) 2005-2014 Sergey A. Tachenov + +This file is part of QuaZIP. + +QuaZIP is free software: you can redistribute it and/or modify +it under the terms of the GNU Lesser General Public License as published by +the Free Software Foundation, either version 2.1 of the License, or +(at your option) any later version. + +QuaZIP is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU Lesser General Public License for more details. + +You should have received a copy of the GNU Lesser General Public License +along with QuaZIP. If not, see . + +See COPYING file for the full LGPL text. + +Original ZIP package is copyrighted by Gilles Vollant and contributors, +see quazip/(un)zip.h files for details. Basically it's the zlib license. +*/ + +#include "quaziodevice.h" + +#define QUAZIO_INBUFSIZE 4096 +#define QUAZIO_OUTBUFSIZE 4096 + +/// \cond internal +class QuaZIODevicePrivate { + friend class QuaZIODevice; + QuaZIODevicePrivate(QIODevice *io, QuaZIODevice *q); + ~QuaZIODevicePrivate(); + QIODevice *io; + QuaZIODevice *q; + z_stream zins; + z_stream zouts; + char *inBuf; + int inBufPos; + int inBufSize; + char *outBuf; + int outBufPos; + int outBufSize; + bool zBufError; + bool atEnd; + bool flush(int sync); + int doFlush(QString &error); +}; + +QuaZIODevicePrivate::QuaZIODevicePrivate(QIODevice *io, QuaZIODevice *q): + io(io), + q(q), + inBuf(NULL), + inBufPos(0), + inBufSize(0), + outBuf(NULL), + outBufPos(0), + outBufSize(0), + zBufError(false), + atEnd(false) +{ + zins.zalloc = (alloc_func) NULL; + zins.zfree = (free_func) NULL; + zins.opaque = NULL; + zouts.zalloc = (alloc_func) NULL; + zouts.zfree = (free_func) NULL; + zouts.opaque = NULL; + inBuf = new char[QUAZIO_INBUFSIZE]; + outBuf = new char[QUAZIO_OUTBUFSIZE]; +#ifdef QUAZIP_ZIODEVICE_DEBUG_OUTPUT + debug.setFileName("debug.out"); + debug.open(QIODevice::WriteOnly); +#endif +#ifdef QUAZIP_ZIODEVICE_DEBUG_INPUT + indebug.setFileName("debug.in"); + indebug.open(QIODevice::WriteOnly); +#endif +} + +QuaZIODevicePrivate::~QuaZIODevicePrivate() +{ +#ifdef QUAZIP_ZIODEVICE_DEBUG_OUTPUT + debug.close(); +#endif +#ifdef QUAZIP_ZIODEVICE_DEBUG_INPUT + indebug.close(); +#endif + if (inBuf != NULL) + delete[] inBuf; + if (outBuf != NULL) + delete[] outBuf; +} + +bool QuaZIODevicePrivate::flush(int sync) +{ + QString error; + if (doFlush(error) < 0) { + q->setErrorString(error); + return false; + } + // can't flush buffer, some data is still waiting + if (outBufPos < outBufSize) + return true; + Bytef c = 0; + zouts.next_in = &c; // fake input buffer + zouts.avail_in = 0; // of zero size + do { + zouts.next_out = (Bytef *) outBuf; + zouts.avail_out = QUAZIO_OUTBUFSIZE; + int result = deflate(&zouts, sync); + switch (result) { + case Z_OK: + case Z_STREAM_END: + outBufSize = (char *) zouts.next_out - outBuf; + if (doFlush(error) < 0) { + q->setErrorString(error); + return false; + } + if (outBufPos < outBufSize) + return true; + break; + case Z_BUF_ERROR: // nothing to write? + return true; + default: + q->setErrorString(QString::fromLocal8Bit(zouts.msg)); + return false; + } + } while (zouts.avail_out == 0); + return true; +} + +int QuaZIODevicePrivate::doFlush(QString &error) +{ + int flushed = 0; + while (outBufPos < outBufSize) { + int more = io->write(outBuf + outBufPos, outBufSize - outBufPos); + if (more == -1) { + error = io->errorString(); + return -1; + } + if (more == 0) + break; + outBufPos += more; + flushed += more; + } + if (outBufPos == outBufSize) { + outBufPos = outBufSize = 0; + } + return flushed; +} + +/// \endcond + +// #define QUAZIP_ZIODEVICE_DEBUG_OUTPUT +// #define QUAZIP_ZIODEVICE_DEBUG_INPUT +#ifdef QUAZIP_ZIODEVICE_DEBUG_OUTPUT +#include +static QFile debug; +#endif +#ifdef QUAZIP_ZIODEVICE_DEBUG_INPUT +#include +static QFile indebug; +#endif + +QuaZIODevice::QuaZIODevice(QIODevice *io, QObject *parent): + QIODevice(parent), + d(new QuaZIODevicePrivate(io, this)) +{ + connect(io, SIGNAL(readyRead()), SIGNAL(readyRead())); +} + +QuaZIODevice::~QuaZIODevice() +{ + if (isOpen()) + close(); + delete d; +} + +QIODevice *QuaZIODevice::getIoDevice() const +{ + return d->io; +} + +bool QuaZIODevice::open(QIODevice::OpenMode mode) +{ + if ((mode & QIODevice::Append) != 0) { + setErrorString(tr("QIODevice::Append is not supported for" + " QuaZIODevice")); + return false; + } + if ((mode & QIODevice::ReadWrite) == QIODevice::ReadWrite) { + setErrorString(tr("QIODevice::ReadWrite is not supported for" + " QuaZIODevice")); + return false; + } + if ((mode & QIODevice::ReadOnly) != 0) { + if (inflateInit(&d->zins) != Z_OK) { + setErrorString(QString::fromLocal8Bit(d->zins.msg)); + return false; + } + } + if ((mode & QIODevice::WriteOnly) != 0) { + if (deflateInit(&d->zouts, Z_DEFAULT_COMPRESSION) != Z_OK) { + setErrorString(QString::fromLocal8Bit(d->zouts.msg)); + return false; + } + } + return QIODevice::open(mode); +} + +void QuaZIODevice::close() +{ + if ((openMode() & QIODevice::ReadOnly) != 0) { + if (inflateEnd(&d->zins) != Z_OK) { + setErrorString(QString::fromLocal8Bit(d->zins.msg)); + } + } + if ((openMode() & QIODevice::WriteOnly) != 0) { + d->flush(Z_FINISH); + if (deflateEnd(&d->zouts) != Z_OK) { + setErrorString(QString::fromLocal8Bit(d->zouts.msg)); + } + } + QIODevice::close(); +} + +qint64 QuaZIODevice::readData(char *data, qint64 maxSize) +{ + int read = 0; + while (read < maxSize) { + if (d->inBufPos == d->inBufSize) { + d->inBufPos = 0; + d->inBufSize = d->io->read(d->inBuf, QUAZIO_INBUFSIZE); + if (d->inBufSize == -1) { + d->inBufSize = 0; + setErrorString(d->io->errorString()); + return -1; + } + if (d->inBufSize == 0) + break; + } + while (read < maxSize && d->inBufPos < d->inBufSize) { + d->zins.next_in = (Bytef *) (d->inBuf + d->inBufPos); + d->zins.avail_in = d->inBufSize - d->inBufPos; + d->zins.next_out = (Bytef *) (data + read); + d->zins.avail_out = (uInt) (maxSize - read); // hope it's less than 2GB + int more = 0; + switch (inflate(&d->zins, Z_SYNC_FLUSH)) { + case Z_OK: + read = (char *) d->zins.next_out - data; + d->inBufPos = (char *) d->zins.next_in - d->inBuf; + break; + case Z_STREAM_END: + read = (char *) d->zins.next_out - data; + d->inBufPos = (char *) d->zins.next_in - d->inBuf; + d->atEnd = true; + return read; + case Z_BUF_ERROR: // this should never happen, but just in case + if (!d->zBufError) { + qWarning("Z_BUF_ERROR detected with %d/%d in/out, weird", + d->zins.avail_in, d->zins.avail_out); + d->zBufError = true; + } + memmove(d->inBuf, d->inBuf + d->inBufPos, d->inBufSize - d->inBufPos); + d->inBufSize -= d->inBufPos; + d->inBufPos = 0; + more = d->io->read(d->inBuf + d->inBufSize, QUAZIO_INBUFSIZE - d->inBufSize); + if (more == -1) { + setErrorString(d->io->errorString()); + return -1; + } + if (more == 0) + return read; + d->inBufSize += more; + break; + default: + setErrorString(QString::fromLocal8Bit(d->zins.msg)); + return -1; + } + } + } +#ifdef QUAZIP_ZIODEVICE_DEBUG_INPUT + indebug.write(data, read); +#endif + return read; +} + +qint64 QuaZIODevice::writeData(const char *data, qint64 maxSize) +{ + int written = 0; + QString error; + if (d->doFlush(error) == -1) { + setErrorString(error); + return -1; + } + while (written < maxSize) { + // there is some data waiting in the output buffer + if (d->outBufPos < d->outBufSize) + return written; + d->zouts.next_in = (Bytef *) (data + written); + d->zouts.avail_in = (uInt) (maxSize - written); // hope it's less than 2GB + d->zouts.next_out = (Bytef *) d->outBuf; + d->zouts.avail_out = QUAZIO_OUTBUFSIZE; + switch (deflate(&d->zouts, Z_NO_FLUSH)) { + case Z_OK: + written = (char *) d->zouts.next_in - data; + d->outBufSize = (char *) d->zouts.next_out - d->outBuf; + break; + default: + setErrorString(QString::fromLocal8Bit(d->zouts.msg)); + return -1; + } + if (d->doFlush(error) == -1) { + setErrorString(error); + return -1; + } + } +#ifdef QUAZIP_ZIODEVICE_DEBUG_OUTPUT + debug.write(data, written); +#endif + return written; +} + +bool QuaZIODevice::flush() +{ + return d->flush(Z_SYNC_FLUSH); +} + +bool QuaZIODevice::isSequential() const +{ + return true; +} + +bool QuaZIODevice::atEnd() const +{ + // Here we MUST check QIODevice::bytesAvailable() because WE + // might have reached the end, but QIODevice didn't-- + // it could have simply pre-buffered all remaining data. + return (openMode() == NotOpen) || (QIODevice::bytesAvailable() == 0 && d->atEnd); +} + +qint64 QuaZIODevice::bytesAvailable() const +{ + // If we haven't recevied Z_STREAM_END, it means that + // we have at least one more input byte available. + // Plus whatever QIODevice has buffered. + return (d->atEnd ? 0 : 1) + QIODevice::bytesAvailable(); +} diff --git a/hecl-gui/quazip/quazip/quaziodevice.h b/hecl-gui/quazip/quazip/quaziodevice.h index 70b816f14..315658b40 100644 --- a/hecl-gui/quazip/quazip/quaziodevice.h +++ b/hecl-gui/quazip/quazip/quaziodevice.h @@ -1,98 +1,103 @@ -#ifndef QUAZIP_QUAZIODEVICE_H -#define QUAZIP_QUAZIODEVICE_H - -/* -Copyright (C) 2005-2014 Sergey A. Tachenov - -This file is part of QuaZIP. - -QuaZIP is free software: you can redistribute it and/or modify -it under the terms of the GNU Lesser General Public License as published by -the Free Software Foundation, either version 3 of the License, or -(at your option) any later version. - -QuaZIP is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU Lesser General Public License for more details. - -You should have received a copy of the GNU Lesser General Public License -along with QuaZIP. If not, see . - -See COPYING file for the full LGPL text. - -Original ZIP package is copyrighted by Gilles Vollant and contributors, -see quazip/(un)zip.h files for details. Basically it's the zlib license. -*/ - -#include -#include "quazip_global.h" - -#include - -class QuaZIODevicePrivate; - -/// A class to compress/decompress QIODevice. -/** - This class can be used to compress any data written to QIODevice or - decompress it back. Compressing data sent over a QTcpSocket is a good - example. - */ -class QUAZIP_EXPORT QuaZIODevice: public QIODevice { - Q_OBJECT -public: - /// Constructor. - /** - \param io The QIODevice to read/write. - \param parent The parent object, as per QObject logic. - */ - QuaZIODevice(QIODevice *io, QObject *parent = NULL); - /// Destructor. - ~QuaZIODevice(); - /// Flushes data waiting to be written. - /** - Unfortunately, as QIODevice doesn't support flush() by itself, the - only thing this method does is write the compressed data into the - device using Z_SYNC_FLUSH mode. If you need the compressed data to - actually be flushed from the buffer of the underlying QIODevice, you - need to call its flush() method as well, providing it supports it - (like QTcpSocket does). Example: - \code - QuaZIODevice dev(&sock); - dev.open(QIODevice::Write); - dev.write(yourDataGoesHere); - dev.flush(); - sock->flush(); // this actually sends data to network - \endcode - - This may change in the future versions of QuaZIP by implementing an - ugly hack: trying to cast the QIODevice using qobject_cast to known - flush()-supporting subclasses, and calling flush if the resulting - pointer is not zero. - */ - virtual bool flush(); - /// Opens the device. - /** - \param mode Neither QIODevice::ReadWrite nor QIODevice::Append are - not supported. - */ - virtual bool open(QIODevice::OpenMode mode); - /// Closes this device, but not the underlying one. - /** - The underlying QIODevice is not closed in case you want to write - something else to it. - */ - virtual void close(); - /// Returns the underlying device. - QIODevice *getIoDevice() const; - /// Returns true. - virtual bool isSequential() const; -protected: - /// Implementation of QIODevice::readData(). - virtual qint64 readData(char *data, qint64 maxSize); - /// Implementation of QIODevice::writeData(). - virtual qint64 writeData(const char *data, qint64 maxSize); -private: - QuaZIODevicePrivate *d; -}; -#endif // QUAZIP_QUAZIODEVICE_H +#ifndef QUAZIP_QUAZIODEVICE_H +#define QUAZIP_QUAZIODEVICE_H + +/* +Copyright (C) 2005-2014 Sergey A. Tachenov + +This file is part of QuaZIP. + +QuaZIP is free software: you can redistribute it and/or modify +it under the terms of the GNU Lesser General Public License as published by +the Free Software Foundation, either version 2.1 of the License, or +(at your option) any later version. + +QuaZIP is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU Lesser General Public License for more details. + +You should have received a copy of the GNU Lesser General Public License +along with QuaZIP. If not, see . + +See COPYING file for the full LGPL text. + +Original ZIP package is copyrighted by Gilles Vollant and contributors, +see quazip/(un)zip.h files for details. Basically it's the zlib license. +*/ + +#include +#include "quazip_global.h" + +#include + +class QuaZIODevicePrivate; + +/// A class to compress/decompress QIODevice. +/** + This class can be used to compress any data written to QIODevice or + decompress it back. Compressing data sent over a QTcpSocket is a good + example. + */ +class QUAZIP_EXPORT QuaZIODevice: public QIODevice { + friend class QuaZIODevicePrivate; + Q_OBJECT +public: + /// Constructor. + /** + \param io The QIODevice to read/write. + \param parent The parent object, as per QObject logic. + */ + QuaZIODevice(QIODevice *io, QObject *parent = NULL); + /// Destructor. + ~QuaZIODevice(); + /// Flushes data waiting to be written. + /** + Unfortunately, as QIODevice doesn't support flush() by itself, the + only thing this method does is write the compressed data into the + device using Z_SYNC_FLUSH mode. If you need the compressed data to + actually be flushed from the buffer of the underlying QIODevice, you + need to call its flush() method as well, providing it supports it + (like QTcpSocket does). Example: + \code + QuaZIODevice dev(&sock); + dev.open(QIODevice::Write); + dev.write(yourDataGoesHere); + dev.flush(); + sock->flush(); // this actually sends data to network + \endcode + + This may change in the future versions of QuaZIP by implementing an + ugly hack: trying to cast the QIODevice using qobject_cast to known + flush()-supporting subclasses, and calling flush if the resulting + pointer is not zero. + */ + virtual bool flush(); + /// Opens the device. + /** + \param mode Neither QIODevice::ReadWrite nor QIODevice::Append are + not supported. + */ + virtual bool open(QIODevice::OpenMode mode); + /// Closes this device, but not the underlying one. + /** + The underlying QIODevice is not closed in case you want to write + something else to it. + */ + virtual void close(); + /// Returns the underlying device. + QIODevice *getIoDevice() const; + /// Returns true. + virtual bool isSequential() const; + /// Returns true iff the end of the compressed stream is reached. + virtual bool atEnd() const; + /// Returns the number of the bytes buffered. + virtual qint64 bytesAvailable() const; +protected: + /// Implementation of QIODevice::readData(). + virtual qint64 readData(char *data, qint64 maxSize); + /// Implementation of QIODevice::writeData(). + virtual qint64 writeData(const char *data, qint64 maxSize); +private: + QuaZIODevicePrivate *d; +}; +#endif // QUAZIP_QUAZIODEVICE_H diff --git a/hecl-gui/quazip/quazip/quazip.cpp b/hecl-gui/quazip/quazip/quazip.cpp index 191758289..b6831c947 100644 --- a/hecl-gui/quazip/quazip/quazip.cpp +++ b/hecl-gui/quazip/quazip/quazip.cpp @@ -1,755 +1,846 @@ -/* -Copyright (C) 2005-2014 Sergey A. Tachenov - -This file is part of QuaZIP. - -QuaZIP is free software: you can redistribute it and/or modify -it under the terms of the GNU Lesser General Public License as published by -the Free Software Foundation, either version 3 of the License, or -(at your option) any later version. - -QuaZIP is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU Lesser General Public License for more details. - -You should have received a copy of the GNU Lesser General Public License -along with QuaZIP. If not, see . - -See COPYING file for the full LGPL text. - -Original ZIP package is copyrighted by Gilles Vollant, see -quazip/(un)zip.h files for details, basically it's zlib license. - **/ - -#include -#include -#include - -#include "quazip.h" - -/// All the internal stuff for the QuaZip class. -/** - \internal - - This class keeps all the private stuff for the QuaZip class so it can - be changed without breaking binary compatibility, according to the - Pimpl idiom. - */ -class QuaZipPrivate { - friend class QuaZip; - private: - /// The pointer to the corresponding QuaZip instance. - QuaZip *q; - /// The codec for file names. - QTextCodec *fileNameCodec; - /// The codec for comments. - QTextCodec *commentCodec; - /// The archive file name. - QString zipName; - /// The device to access the archive. - QIODevice *ioDevice; - /// The global comment. - QString comment; - /// The open mode. - QuaZip::Mode mode; - union { - /// The internal handle for UNZIP modes. - unzFile unzFile_f; - /// The internal handle for ZIP modes. - zipFile zipFile_f; - }; - /// Whether a current file is set. - bool hasCurrentFile_f; - /// The last error. - int zipError; - /// Whether \ref QuaZip::setDataDescriptorWritingEnabled() "the data descriptor writing mode" is enabled. - bool dataDescriptorWritingEnabled; - /// The zip64 mode. - bool zip64; - /// The auto-close flag. - bool autoClose; - inline QTextCodec *getDefaultFileNameCodec() - { - if (defaultFileNameCodec == NULL) { - return QTextCodec::codecForLocale(); - } else { - return defaultFileNameCodec; - } - } - /// The constructor for the corresponding QuaZip constructor. - inline QuaZipPrivate(QuaZip *q): - q(q), - fileNameCodec(getDefaultFileNameCodec()), - commentCodec(QTextCodec::codecForLocale()), - ioDevice(NULL), - mode(QuaZip::mdNotOpen), - hasCurrentFile_f(false), - zipError(UNZ_OK), - dataDescriptorWritingEnabled(true), - zip64(false), - autoClose(true) - { - lastMappedDirectoryEntry.num_of_file = 0; - lastMappedDirectoryEntry.pos_in_zip_directory = 0; - } - /// The constructor for the corresponding QuaZip constructor. - inline QuaZipPrivate(QuaZip *q, const QString &zipName): - q(q), - fileNameCodec(getDefaultFileNameCodec()), - commentCodec(QTextCodec::codecForLocale()), - zipName(zipName), - ioDevice(NULL), - mode(QuaZip::mdNotOpen), - hasCurrentFile_f(false), - zipError(UNZ_OK), - dataDescriptorWritingEnabled(true), - zip64(false), - autoClose(true) - { - lastMappedDirectoryEntry.num_of_file = 0; - lastMappedDirectoryEntry.pos_in_zip_directory = 0; - } - /// The constructor for the corresponding QuaZip constructor. - inline QuaZipPrivate(QuaZip *q, QIODevice *ioDevice): - q(q), - fileNameCodec(getDefaultFileNameCodec()), - commentCodec(QTextCodec::codecForLocale()), - ioDevice(ioDevice), - mode(QuaZip::mdNotOpen), - hasCurrentFile_f(false), - zipError(UNZ_OK), - dataDescriptorWritingEnabled(true), - zip64(false), - autoClose(true) - { - lastMappedDirectoryEntry.num_of_file = 0; - lastMappedDirectoryEntry.pos_in_zip_directory = 0; - } - /// Returns either a list of file names or a list of QuaZipFileInfo. - template - bool getFileInfoList(QList *result) const; - - /// Stores map of filenames and file locations for unzipping - inline void clearDirectoryMap(); - inline void addCurrentFileToDirectoryMap(const QString &fileName); - bool goToFirstUnmappedFile(); - QHash directoryCaseSensitive; - QHash directoryCaseInsensitive; - unz64_file_pos lastMappedDirectoryEntry; - static QTextCodec *defaultFileNameCodec; -}; - -QTextCodec *QuaZipPrivate::defaultFileNameCodec = NULL; - -void QuaZipPrivate::clearDirectoryMap() -{ - directoryCaseInsensitive.clear(); - directoryCaseSensitive.clear(); - lastMappedDirectoryEntry.num_of_file = 0; - lastMappedDirectoryEntry.pos_in_zip_directory = 0; -} - -void QuaZipPrivate::addCurrentFileToDirectoryMap(const QString &fileName) -{ - if (!hasCurrentFile_f || fileName.isEmpty()) { - return; - } - // Adds current file to filename map as fileName - unz64_file_pos fileDirectoryPos; - unzGetFilePos64(unzFile_f, &fileDirectoryPos); - directoryCaseSensitive.insert(fileName, fileDirectoryPos); - // Only add lowercase to directory map if not already there - // ensures only map the first one seen - QString lower = fileName.toLower(); - if (!directoryCaseInsensitive.contains(lower)) - directoryCaseInsensitive.insert(lower, fileDirectoryPos); - // Mark last one - if (fileDirectoryPos.pos_in_zip_directory > lastMappedDirectoryEntry.pos_in_zip_directory) - lastMappedDirectoryEntry = fileDirectoryPos; -} - -bool QuaZipPrivate::goToFirstUnmappedFile() -{ - zipError = UNZ_OK; - if (mode != QuaZip::mdUnzip) { - qWarning("QuaZipPrivate::goToNextUnmappedFile(): ZIP is not open in mdUnzip mode"); - return false; - } - // If not mapped anything, go to beginning - if (lastMappedDirectoryEntry.pos_in_zip_directory == 0) { - unzGoToFirstFile(unzFile_f); - } else { - // Goto the last one mapped, plus one - unzGoToFilePos64(unzFile_f, &lastMappedDirectoryEntry); - unzGoToNextFile(unzFile_f); - } - hasCurrentFile_f=zipError==UNZ_OK; - if(zipError==UNZ_END_OF_LIST_OF_FILE) - zipError=UNZ_OK; - return hasCurrentFile_f; -} - -QuaZip::QuaZip(): - p(new QuaZipPrivate(this)) -{ -} - -QuaZip::QuaZip(const QString& zipName): - p(new QuaZipPrivate(this, zipName)) -{ -} - -QuaZip::QuaZip(QIODevice *ioDevice): - p(new QuaZipPrivate(this, ioDevice)) -{ -} - -QuaZip::~QuaZip() -{ - if(isOpen()) - close(); - delete p; -} - -bool QuaZip::open(Mode mode, zlib_filefunc_def* ioApi) -{ - p->zipError=UNZ_OK; - if(isOpen()) { - qWarning("QuaZip::open(): ZIP already opened"); - return false; - } - QIODevice *ioDevice = p->ioDevice; - if (ioDevice == NULL) { - if (p->zipName.isEmpty()) { - qWarning("QuaZip::open(): set either ZIP file name or IO device first"); - return false; - } else { - ioDevice = new QFile(p->zipName); - } - } - switch(mode) { - case mdUnzip: - if (ioApi == NULL) { - p->unzFile_f=unzOpen2_64(ioDevice, NULL); - } else { - // QuaZIP pre-zip64 compatibility mode - p->unzFile_f=unzOpen2(ioDevice, ioApi); - } - if(p->unzFile_f!=NULL) { - p->mode=mode; - p->ioDevice = ioDevice; - return true; - } else { - p->zipError=UNZ_OPENERROR; - if (!p->zipName.isEmpty()) - delete ioDevice; - return false; - } - case mdCreate: - case mdAppend: - case mdAdd: - if (ioApi == NULL) { - p->zipFile_f=zipOpen2_64(ioDevice, - mode==mdCreate?APPEND_STATUS_CREATE: - mode==mdAppend?APPEND_STATUS_CREATEAFTER: - APPEND_STATUS_ADDINZIP, - NULL, NULL); - } else { - // QuaZIP pre-zip64 compatibility mode - p->zipFile_f=zipOpen2(ioDevice, - mode==mdCreate?APPEND_STATUS_CREATE: - mode==mdAppend?APPEND_STATUS_CREATEAFTER: - APPEND_STATUS_ADDINZIP, - NULL, - ioApi); - } - if(p->zipFile_f!=NULL) { - if (p->autoClose) { - zipSetFlags(p->zipFile_f, ZIP_AUTO_CLOSE); - } else { - zipClearFlags(p->zipFile_f, ZIP_AUTO_CLOSE); - } - p->mode=mode; - p->ioDevice = ioDevice; - return true; - } else { - p->zipError=UNZ_OPENERROR; - if (!p->zipName.isEmpty()) - delete ioDevice; - return false; - } - default: - qWarning("QuaZip::open(): unknown mode: %d", (int)mode); - if (!p->zipName.isEmpty()) - delete ioDevice; - return false; - break; - } -} - -void QuaZip::close() -{ - p->zipError=UNZ_OK; - switch(p->mode) { - case mdNotOpen: - qWarning("QuaZip::close(): ZIP is not open"); - return; - case mdUnzip: - p->zipError=unzClose(p->unzFile_f); - break; - case mdCreate: - case mdAppend: - case mdAdd: - p->zipError=zipClose(p->zipFile_f, - p->comment.isNull() ? NULL - : p->commentCodec->fromUnicode(p->comment).constData()); - break; - default: - qWarning("QuaZip::close(): unknown mode: %d", (int)p->mode); - return; - } - // opened by name, need to delete the internal IO device - if (!p->zipName.isEmpty()) { - delete p->ioDevice; - p->ioDevice = NULL; - } - p->clearDirectoryMap(); - if(p->zipError==UNZ_OK) - p->mode=mdNotOpen; -} - -void QuaZip::setZipName(const QString& zipName) -{ - if(isOpen()) { - qWarning("QuaZip::setZipName(): ZIP is already open!"); - return; - } - p->zipName=zipName; - p->ioDevice = NULL; -} - -void QuaZip::setIoDevice(QIODevice *ioDevice) -{ - if(isOpen()) { - qWarning("QuaZip::setIoDevice(): ZIP is already open!"); - return; - } - p->ioDevice = ioDevice; - p->zipName = QString(); -} - -int QuaZip::getEntriesCount()const -{ - QuaZip *fakeThis=(QuaZip*)this; // non-const - fakeThis->p->zipError=UNZ_OK; - if(p->mode!=mdUnzip) { - qWarning("QuaZip::getEntriesCount(): ZIP is not open in mdUnzip mode"); - return -1; - } - unz_global_info64 globalInfo; - if((fakeThis->p->zipError=unzGetGlobalInfo64(p->unzFile_f, &globalInfo))!=UNZ_OK) - return p->zipError; - return (int)globalInfo.number_entry; -} - -QString QuaZip::getComment()const -{ - QuaZip *fakeThis=(QuaZip*)this; // non-const - fakeThis->p->zipError=UNZ_OK; - if(p->mode!=mdUnzip) { - qWarning("QuaZip::getComment(): ZIP is not open in mdUnzip mode"); - return QString(); - } - unz_global_info64 globalInfo; - QByteArray comment; - if((fakeThis->p->zipError=unzGetGlobalInfo64(p->unzFile_f, &globalInfo))!=UNZ_OK) - return QString(); - comment.resize(globalInfo.size_comment); - if((fakeThis->p->zipError=unzGetGlobalComment(p->unzFile_f, comment.data(), comment.size())) < 0) - return QString(); - fakeThis->p->zipError = UNZ_OK; - return p->commentCodec->toUnicode(comment); -} - -bool QuaZip::setCurrentFile(const QString& fileName, CaseSensitivity cs) -{ - p->zipError=UNZ_OK; - if(p->mode!=mdUnzip) { - qWarning("QuaZip::setCurrentFile(): ZIP is not open in mdUnzip mode"); - return false; - } - if(fileName.isEmpty()) { - p->hasCurrentFile_f=false; - return true; - } - // Unicode-aware reimplementation of the unzLocateFile function - if(p->unzFile_f==NULL) { - p->zipError=UNZ_PARAMERROR; - return false; - } - if(fileName.length()>MAX_FILE_NAME_LENGTH) { - p->zipError=UNZ_PARAMERROR; - return false; - } - // Find the file by name - bool sens = convertCaseSensitivity(cs) == Qt::CaseSensitive; - QString lower, current; - if(!sens) lower=fileName.toLower(); - p->hasCurrentFile_f=false; - - // Check the appropriate Map - unz64_file_pos fileDirPos; - fileDirPos.pos_in_zip_directory = 0; - if (sens) { - if (p->directoryCaseSensitive.contains(fileName)) - fileDirPos = p->directoryCaseSensitive.value(fileName); - } else { - if (p->directoryCaseInsensitive.contains(lower)) - fileDirPos = p->directoryCaseInsensitive.value(lower); - } - - if (fileDirPos.pos_in_zip_directory != 0) { - p->zipError = unzGoToFilePos64(p->unzFile_f, &fileDirPos); - p->hasCurrentFile_f = p->zipError == UNZ_OK; - } - - if (p->hasCurrentFile_f) - return p->hasCurrentFile_f; - - // Not mapped yet, start from where we have got to so far - for(bool more=p->goToFirstUnmappedFile(); more; more=goToNextFile()) { - current=getCurrentFileName(); - if(current.isEmpty()) return false; - if(sens) { - if(current==fileName) break; - } else { - if(current.toLower()==lower) break; - } - } - return p->hasCurrentFile_f; -} - -bool QuaZip::goToFirstFile() -{ - p->zipError=UNZ_OK; - if(p->mode!=mdUnzip) { - qWarning("QuaZip::goToFirstFile(): ZIP is not open in mdUnzip mode"); - return false; - } - p->zipError=unzGoToFirstFile(p->unzFile_f); - p->hasCurrentFile_f=p->zipError==UNZ_OK; - return p->hasCurrentFile_f; -} - -bool QuaZip::goToNextFile() -{ - p->zipError=UNZ_OK; - if(p->mode!=mdUnzip) { - qWarning("QuaZip::goToFirstFile(): ZIP is not open in mdUnzip mode"); - return false; - } - p->zipError=unzGoToNextFile(p->unzFile_f); - p->hasCurrentFile_f=p->zipError==UNZ_OK; - if(p->zipError==UNZ_END_OF_LIST_OF_FILE) - p->zipError=UNZ_OK; - return p->hasCurrentFile_f; -} - -bool QuaZip::getCurrentFileInfo(QuaZipFileInfo *info)const -{ - QuaZipFileInfo64 info64; - if (info == NULL) { // Very unlikely because of the overloads - return false; - } - if (getCurrentFileInfo(&info64)) { - info64.toQuaZipFileInfo(*info); - return true; - } else { - return false; - } -} - -bool QuaZip::getCurrentFileInfo(QuaZipFileInfo64 *info)const -{ - QuaZip *fakeThis=(QuaZip*)this; // non-const - fakeThis->p->zipError=UNZ_OK; - if(p->mode!=mdUnzip) { - qWarning("QuaZip::getCurrentFileInfo(): ZIP is not open in mdUnzip mode"); - return false; - } - unz_file_info64 info_z; - QByteArray fileName; - QByteArray extra; - QByteArray comment; - if(info==NULL) return false; - if(!isOpen()||!hasCurrentFile()) return false; - if((fakeThis->p->zipError=unzGetCurrentFileInfo64(p->unzFile_f, &info_z, NULL, 0, NULL, 0, NULL, 0))!=UNZ_OK) - return false; - fileName.resize(info_z.size_filename); - extra.resize(info_z.size_file_extra); - comment.resize(info_z.size_file_comment); - if((fakeThis->p->zipError=unzGetCurrentFileInfo64(p->unzFile_f, NULL, - fileName.data(), fileName.size(), - extra.data(), extra.size(), - comment.data(), comment.size()))!=UNZ_OK) - return false; - info->versionCreated=info_z.version; - info->versionNeeded=info_z.version_needed; - info->flags=info_z.flag; - info->method=info_z.compression_method; - info->crc=info_z.crc; - info->compressedSize=info_z.compressed_size; - info->uncompressedSize=info_z.uncompressed_size; - info->diskNumberStart=info_z.disk_num_start; - info->internalAttr=info_z.internal_fa; - info->externalAttr=info_z.external_fa; - info->name=p->fileNameCodec->toUnicode(fileName); - info->comment=p->commentCodec->toUnicode(comment); - info->extra=extra; - info->dateTime=QDateTime( - QDate(info_z.tmu_date.tm_year, info_z.tmu_date.tm_mon+1, info_z.tmu_date.tm_mday), - QTime(info_z.tmu_date.tm_hour, info_z.tmu_date.tm_min, info_z.tmu_date.tm_sec)); - // Add to directory map - p->addCurrentFileToDirectoryMap(info->name); - return true; -} - -QString QuaZip::getCurrentFileName()const -{ - QuaZip *fakeThis=(QuaZip*)this; // non-const - fakeThis->p->zipError=UNZ_OK; - if(p->mode!=mdUnzip) { - qWarning("QuaZip::getCurrentFileName(): ZIP is not open in mdUnzip mode"); - return QString(); - } - if(!isOpen()||!hasCurrentFile()) return QString(); - QByteArray fileName(MAX_FILE_NAME_LENGTH, 0); - if((fakeThis->p->zipError=unzGetCurrentFileInfo64(p->unzFile_f, NULL, fileName.data(), fileName.size(), - NULL, 0, NULL, 0))!=UNZ_OK) - return QString(); - QString result = p->fileNameCodec->toUnicode(fileName.constData()); - if (result.isEmpty()) - return result; - // Add to directory map - p->addCurrentFileToDirectoryMap(result); - return result; -} - -void QuaZip::setFileNameCodec(QTextCodec *fileNameCodec) -{ - p->fileNameCodec=fileNameCodec; -} - -void QuaZip::setFileNameCodec(const char *fileNameCodecName) -{ - p->fileNameCodec=QTextCodec::codecForName(fileNameCodecName); -} - -QTextCodec *QuaZip::getFileNameCodec()const -{ - return p->fileNameCodec; -} - -void QuaZip::setCommentCodec(QTextCodec *commentCodec) -{ - p->commentCodec=commentCodec; -} - -void QuaZip::setCommentCodec(const char *commentCodecName) -{ - p->commentCodec=QTextCodec::codecForName(commentCodecName); -} - -QTextCodec *QuaZip::getCommentCodec()const -{ - return p->commentCodec; -} - -QString QuaZip::getZipName() const -{ - return p->zipName; -} - -QIODevice *QuaZip::getIoDevice() const -{ - if (!p->zipName.isEmpty()) // opened by name, using an internal QIODevice - return NULL; - return p->ioDevice; -} - -QuaZip::Mode QuaZip::getMode()const -{ - return p->mode; -} - -bool QuaZip::isOpen()const -{ - return p->mode!=mdNotOpen; -} - -int QuaZip::getZipError() const -{ - return p->zipError; -} - -void QuaZip::setComment(const QString& comment) -{ - p->comment=comment; -} - -bool QuaZip::hasCurrentFile()const -{ - return p->hasCurrentFile_f; -} - -unzFile QuaZip::getUnzFile() -{ - return p->unzFile_f; -} - -zipFile QuaZip::getZipFile() -{ - return p->zipFile_f; -} - -void QuaZip::setDataDescriptorWritingEnabled(bool enabled) -{ - p->dataDescriptorWritingEnabled = enabled; -} - -bool QuaZip::isDataDescriptorWritingEnabled() const -{ - return p->dataDescriptorWritingEnabled; -} - -template -TFileInfo QuaZip_getFileInfo(QuaZip *zip, bool *ok); - -template<> -QuaZipFileInfo QuaZip_getFileInfo(QuaZip *zip, bool *ok) -{ - QuaZipFileInfo info; - *ok = zip->getCurrentFileInfo(&info); - return info; -} - -template<> -QuaZipFileInfo64 QuaZip_getFileInfo(QuaZip *zip, bool *ok) -{ - QuaZipFileInfo64 info; - *ok = zip->getCurrentFileInfo(&info); - return info; -} - -template<> -QString QuaZip_getFileInfo(QuaZip *zip, bool *ok) -{ - QString name = zip->getCurrentFileName(); - *ok = !name.isEmpty(); - return name; -} - -template -bool QuaZipPrivate::getFileInfoList(QList *result) const -{ - QuaZipPrivate *fakeThis=const_cast(this); - fakeThis->zipError=UNZ_OK; - if (mode!=QuaZip::mdUnzip) { - qWarning("QuaZip::getFileNameList/getFileInfoList(): " - "ZIP is not open in mdUnzip mode"); - return false; - } - QString currentFile; - if (q->hasCurrentFile()) { - currentFile = q->getCurrentFileName(); - } - if (q->goToFirstFile()) { - do { - bool ok; - result->append(QuaZip_getFileInfo(q, &ok)); - if (!ok) - return false; - } while (q->goToNextFile()); - } - if (zipError != UNZ_OK) - return false; - if (currentFile.isEmpty()) { - if (!q->goToFirstFile()) - return false; - } else { - if (!q->setCurrentFile(currentFile)) - return false; - } - return true; -} - -QStringList QuaZip::getFileNameList() const -{ - QStringList list; - if (p->getFileInfoList(&list)) - return list; - else - return QStringList(); -} - -QList QuaZip::getFileInfoList() const -{ - QList list; - if (p->getFileInfoList(&list)) - return list; - else - return QList(); -} - -QList QuaZip::getFileInfoList64() const -{ - QList list; - if (p->getFileInfoList(&list)) - return list; - else - return QList(); -} - -Qt::CaseSensitivity QuaZip::convertCaseSensitivity(QuaZip::CaseSensitivity cs) -{ - if (cs == csDefault) { -#ifdef Q_WS_WIN - return Qt::CaseInsensitive; -#else - return Qt::CaseSensitive; -#endif - } else { - return cs == csSensitive ? Qt::CaseSensitive : Qt::CaseInsensitive; - } -} - -void QuaZip::setDefaultFileNameCodec(QTextCodec *codec) -{ - QuaZipPrivate::defaultFileNameCodec = codec; -} - -void QuaZip::setDefaultFileNameCodec(const char *codecName) -{ - setDefaultFileNameCodec(QTextCodec::codecForName(codecName)); -} - -void QuaZip::setZip64Enabled(bool zip64) -{ - p->zip64 = zip64; -} - -bool QuaZip::isZip64Enabled() const -{ - return p->zip64; -} - -bool QuaZip::isAutoClose() const -{ - return p->autoClose; -} - -void QuaZip::setAutoClose(bool autoClose) const -{ - p->autoClose = autoClose; -} +/* +Copyright (C) 2005-2014 Sergey A. Tachenov + +This file is part of QuaZIP. + +QuaZIP is free software: you can redistribute it and/or modify +it under the terms of the GNU Lesser General Public License as published by +the Free Software Foundation, either version 2.1 of the License, or +(at your option) any later version. + +QuaZIP is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU Lesser General Public License for more details. + +You should have received a copy of the GNU Lesser General Public License +along with QuaZIP. If not, see . + +See COPYING file for the full LGPL text. + +Original ZIP package is copyrighted by Gilles Vollant, see +quazip/(un)zip.h files for details, basically it's zlib license. + **/ + +#include +#include +#include + +#include "quazip.h" + +#define QUAZIP_OS_UNIX 3u + +/// All the internal stuff for the QuaZip class. +/** + \internal + + This class keeps all the private stuff for the QuaZip class so it can + be changed without breaking binary compatibility, according to the + Pimpl idiom. + */ +class QuaZipPrivate { + friend class QuaZip; + private: + Q_DISABLE_COPY(QuaZipPrivate) + /// The pointer to the corresponding QuaZip instance. + QuaZip *q; + /// The codec for file names (used when UTF-8 is not enabled). + QTextCodec *fileNameCodec; + /// The codec for comments (used when UTF-8 is not enabled). + QTextCodec *commentCodec; + /// The archive file name. + QString zipName; + /// The device to access the archive. + QIODevice *ioDevice; + /// The global comment. + QString comment; + /// The open mode. + QuaZip::Mode mode; + union { + /// The internal handle for UNZIP modes. + unzFile unzFile_f; + /// The internal handle for ZIP modes. + zipFile zipFile_f; + }; + /// Whether a current file is set. + bool hasCurrentFile_f; + /// The last error. + int zipError; + /// Whether \ref QuaZip::setDataDescriptorWritingEnabled() "the data descriptor writing mode" is enabled. + bool dataDescriptorWritingEnabled; + /// The zip64 mode. + bool zip64; + /// The auto-close flag. + bool autoClose; + /// The UTF-8 flag. + bool utf8; + /// The OS code. + uint osCode; + inline QTextCodec *getDefaultFileNameCodec() + { + if (defaultFileNameCodec == NULL) { + return QTextCodec::codecForLocale(); + } else { + return defaultFileNameCodec; + } + } + /// The constructor for the corresponding QuaZip constructor. + inline QuaZipPrivate(QuaZip *q): + q(q), + fileNameCodec(getDefaultFileNameCodec()), + commentCodec(QTextCodec::codecForLocale()), + ioDevice(NULL), + mode(QuaZip::mdNotOpen), + hasCurrentFile_f(false), + zipError(UNZ_OK), + dataDescriptorWritingEnabled(true), + zip64(false), + autoClose(true), + utf8(false), + osCode(defaultOsCode) + { + unzFile_f = NULL; + zipFile_f = NULL; + lastMappedDirectoryEntry.num_of_file = 0; + lastMappedDirectoryEntry.pos_in_zip_directory = 0; + } + /// The constructor for the corresponding QuaZip constructor. + inline QuaZipPrivate(QuaZip *q, const QString &zipName): + q(q), + fileNameCodec(getDefaultFileNameCodec()), + commentCodec(QTextCodec::codecForLocale()), + zipName(zipName), + ioDevice(NULL), + mode(QuaZip::mdNotOpen), + hasCurrentFile_f(false), + zipError(UNZ_OK), + dataDescriptorWritingEnabled(true), + zip64(false), + autoClose(true), + utf8(false), + osCode(defaultOsCode) + { + unzFile_f = NULL; + zipFile_f = NULL; + lastMappedDirectoryEntry.num_of_file = 0; + lastMappedDirectoryEntry.pos_in_zip_directory = 0; + } + /// The constructor for the corresponding QuaZip constructor. + inline QuaZipPrivate(QuaZip *q, QIODevice *ioDevice): + q(q), + fileNameCodec(getDefaultFileNameCodec()), + commentCodec(QTextCodec::codecForLocale()), + ioDevice(ioDevice), + mode(QuaZip::mdNotOpen), + hasCurrentFile_f(false), + zipError(UNZ_OK), + dataDescriptorWritingEnabled(true), + zip64(false), + autoClose(true), + utf8(false), + osCode(defaultOsCode) + { + unzFile_f = NULL; + zipFile_f = NULL; + lastMappedDirectoryEntry.num_of_file = 0; + lastMappedDirectoryEntry.pos_in_zip_directory = 0; + } + /// Returns either a list of file names or a list of QuaZipFileInfo. + template + bool getFileInfoList(QList *result) const; + + /// Stores map of filenames and file locations for unzipping + inline void clearDirectoryMap(); + inline void addCurrentFileToDirectoryMap(const QString &fileName); + bool goToFirstUnmappedFile(); + QHash directoryCaseSensitive; + QHash directoryCaseInsensitive; + unz64_file_pos lastMappedDirectoryEntry; + static QTextCodec *defaultFileNameCodec; + static uint defaultOsCode; +}; + +QTextCodec *QuaZipPrivate::defaultFileNameCodec = NULL; +uint QuaZipPrivate::defaultOsCode = QUAZIP_OS_UNIX; + +void QuaZipPrivate::clearDirectoryMap() +{ + directoryCaseInsensitive.clear(); + directoryCaseSensitive.clear(); + lastMappedDirectoryEntry.num_of_file = 0; + lastMappedDirectoryEntry.pos_in_zip_directory = 0; +} + +void QuaZipPrivate::addCurrentFileToDirectoryMap(const QString &fileName) +{ + if (!hasCurrentFile_f || fileName.isEmpty()) { + return; + } + // Adds current file to filename map as fileName + unz64_file_pos fileDirectoryPos; + unzGetFilePos64(unzFile_f, &fileDirectoryPos); + directoryCaseSensitive.insert(fileName, fileDirectoryPos); + // Only add lowercase to directory map if not already there + // ensures only map the first one seen + QString lower = fileName.toLower(); + if (!directoryCaseInsensitive.contains(lower)) + directoryCaseInsensitive.insert(lower, fileDirectoryPos); + // Mark last one + if (fileDirectoryPos.pos_in_zip_directory > lastMappedDirectoryEntry.pos_in_zip_directory) + lastMappedDirectoryEntry = fileDirectoryPos; +} + +bool QuaZipPrivate::goToFirstUnmappedFile() +{ + zipError = UNZ_OK; + if (mode != QuaZip::mdUnzip) { + qWarning("QuaZipPrivate::goToNextUnmappedFile(): ZIP is not open in mdUnzip mode"); + return false; + } + // If not mapped anything, go to beginning + if (lastMappedDirectoryEntry.pos_in_zip_directory == 0) { + unzGoToFirstFile(unzFile_f); + } else { + // Goto the last one mapped, plus one + unzGoToFilePos64(unzFile_f, &lastMappedDirectoryEntry); + unzGoToNextFile(unzFile_f); + } + hasCurrentFile_f=zipError==UNZ_OK; + if(zipError==UNZ_END_OF_LIST_OF_FILE) + zipError=UNZ_OK; + return hasCurrentFile_f; +} + +QuaZip::QuaZip(): + p(new QuaZipPrivate(this)) +{ +} + +QuaZip::QuaZip(const QString& zipName): + p(new QuaZipPrivate(this, zipName)) +{ +} + +QuaZip::QuaZip(QIODevice *ioDevice): + p(new QuaZipPrivate(this, ioDevice)) +{ +} + +QuaZip::~QuaZip() +{ + if(isOpen()) + close(); + delete p; +} + +bool QuaZip::open(Mode mode, zlib_filefunc_def* ioApi) +{ + p->zipError=UNZ_OK; + if(isOpen()) { + qWarning("QuaZip::open(): ZIP already opened"); + return false; + } + QIODevice *ioDevice = p->ioDevice; + if (ioDevice == NULL) { + if (p->zipName.isEmpty()) { + qWarning("QuaZip::open(): set either ZIP file name or IO device first"); + return false; + } else { + ioDevice = new QFile(p->zipName); + } + } + unsigned flags = 0; + switch(mode) { + case mdUnzip: + if (ioApi == NULL) { + if (p->autoClose) + flags |= UNZ_AUTO_CLOSE; + p->unzFile_f=unzOpenInternal(ioDevice, NULL, 1, flags); + } else { + // QuaZIP pre-zip64 compatibility mode + p->unzFile_f=unzOpen2(ioDevice, ioApi); + if (p->unzFile_f != NULL) { + if (p->autoClose) { + unzSetFlags(p->unzFile_f, UNZ_AUTO_CLOSE); + } else { + unzClearFlags(p->unzFile_f, UNZ_AUTO_CLOSE); + } + } + } + if(p->unzFile_f!=NULL) { + if (ioDevice->isSequential()) { + unzClose(p->unzFile_f); + if (!p->zipName.isEmpty()) + delete ioDevice; + qWarning("QuaZip::open(): " + "only mdCreate can be used with " + "sequential devices"); + return false; + } + p->mode=mode; + p->ioDevice = ioDevice; + return true; + } else { + p->zipError=UNZ_OPENERROR; + if (!p->zipName.isEmpty()) + delete ioDevice; + return false; + } + case mdCreate: + case mdAppend: + case mdAdd: + if (ioApi == NULL) { + if (p->autoClose) + flags |= ZIP_AUTO_CLOSE; + if (p->dataDescriptorWritingEnabled) + flags |= ZIP_WRITE_DATA_DESCRIPTOR; + if (p->utf8) + flags |= ZIP_ENCODING_UTF8; + p->zipFile_f=zipOpen3(ioDevice, + mode==mdCreate?APPEND_STATUS_CREATE: + mode==mdAppend?APPEND_STATUS_CREATEAFTER: + APPEND_STATUS_ADDINZIP, + NULL, NULL, flags); + } else { + // QuaZIP pre-zip64 compatibility mode + p->zipFile_f=zipOpen2(ioDevice, + mode==mdCreate?APPEND_STATUS_CREATE: + mode==mdAppend?APPEND_STATUS_CREATEAFTER: + APPEND_STATUS_ADDINZIP, + NULL, + ioApi); + if (p->zipFile_f != NULL) { + zipSetFlags(p->zipFile_f, flags); + } + } + if(p->zipFile_f!=NULL) { + if (ioDevice->isSequential()) { + if (mode != mdCreate) { + zipClose(p->zipFile_f, NULL); + qWarning("QuaZip::open(): " + "only mdCreate can be used with " + "sequential devices"); + if (!p->zipName.isEmpty()) + delete ioDevice; + return false; + } + zipSetFlags(p->zipFile_f, ZIP_SEQUENTIAL); + } + p->mode=mode; + p->ioDevice = ioDevice; + return true; + } else { + p->zipError=UNZ_OPENERROR; + if (!p->zipName.isEmpty()) + delete ioDevice; + return false; + } + default: + qWarning("QuaZip::open(): unknown mode: %d", (int)mode); + if (!p->zipName.isEmpty()) + delete ioDevice; + return false; + break; + } +} + +void QuaZip::close() +{ + p->zipError=UNZ_OK; + switch(p->mode) { + case mdNotOpen: + qWarning("QuaZip::close(): ZIP is not open"); + return; + case mdUnzip: + p->zipError=unzClose(p->unzFile_f); + break; + case mdCreate: + case mdAppend: + case mdAdd: + p->zipError=zipClose(p->zipFile_f, p->comment.isNull() ? NULL : isUtf8Enabled() + ? p->comment.toUtf8().constData() + : p->commentCodec->fromUnicode(p->comment).constData()); + break; + default: + qWarning("QuaZip::close(): unknown mode: %d", (int)p->mode); + return; + } + // opened by name, need to delete the internal IO device + if (!p->zipName.isEmpty()) { + delete p->ioDevice; + p->ioDevice = NULL; + } + p->clearDirectoryMap(); + if(p->zipError==UNZ_OK) + p->mode=mdNotOpen; +} + +void QuaZip::setZipName(const QString& zipName) +{ + if(isOpen()) { + qWarning("QuaZip::setZipName(): ZIP is already open!"); + return; + } + p->zipName=zipName; + p->ioDevice = NULL; +} + +void QuaZip::setIoDevice(QIODevice *ioDevice) +{ + if(isOpen()) { + qWarning("QuaZip::setIoDevice(): ZIP is already open!"); + return; + } + p->ioDevice = ioDevice; + p->zipName = QString(); +} + +int QuaZip::getEntriesCount()const +{ + QuaZip *fakeThis=(QuaZip*)this; // non-const + fakeThis->p->zipError=UNZ_OK; + if(p->mode!=mdUnzip) { + qWarning("QuaZip::getEntriesCount(): ZIP is not open in mdUnzip mode"); + return -1; + } + unz_global_info64 globalInfo; + if((fakeThis->p->zipError=unzGetGlobalInfo64(p->unzFile_f, &globalInfo))!=UNZ_OK) + return p->zipError; + return (int)globalInfo.number_entry; +} + +QString QuaZip::getComment()const +{ + QuaZip *fakeThis=(QuaZip*)this; // non-const + fakeThis->p->zipError=UNZ_OK; + if(p->mode!=mdUnzip) { + qWarning("QuaZip::getComment(): ZIP is not open in mdUnzip mode"); + return QString(); + } + unz_global_info64 globalInfo; + QByteArray comment; + if((fakeThis->p->zipError=unzGetGlobalInfo64(p->unzFile_f, &globalInfo))!=UNZ_OK) + return QString(); + comment.resize(globalInfo.size_comment); + if((fakeThis->p->zipError=unzGetGlobalComment(p->unzFile_f, comment.data(), comment.size())) < 0) + return QString(); + fakeThis->p->zipError = UNZ_OK; + unsigned flags = 0; + return (unzGetFileFlags(p->unzFile_f, &flags) == UNZ_OK) && (flags & UNZ_ENCODING_UTF8) + ? QString::fromUtf8(comment) : p->commentCodec->toUnicode(comment); +} + +bool QuaZip::setCurrentFile(const QString& fileName, CaseSensitivity cs) +{ + p->zipError=UNZ_OK; + if(p->mode!=mdUnzip) { + qWarning("QuaZip::setCurrentFile(): ZIP is not open in mdUnzip mode"); + return false; + } + if(fileName.isEmpty()) { + p->hasCurrentFile_f=false; + return true; + } + // Unicode-aware reimplementation of the unzLocateFile function + if(p->unzFile_f==NULL) { + p->zipError=UNZ_PARAMERROR; + return false; + } + if(fileName.length()>MAX_FILE_NAME_LENGTH) { + p->zipError=UNZ_PARAMERROR; + return false; + } + // Find the file by name + bool sens = convertCaseSensitivity(cs) == Qt::CaseSensitive; + QString lower, current; + if(!sens) lower=fileName.toLower(); + p->hasCurrentFile_f=false; + + // Check the appropriate Map + unz64_file_pos fileDirPos; + fileDirPos.pos_in_zip_directory = 0; + if (sens) { + if (p->directoryCaseSensitive.contains(fileName)) + fileDirPos = p->directoryCaseSensitive.value(fileName); + } else { + if (p->directoryCaseInsensitive.contains(lower)) + fileDirPos = p->directoryCaseInsensitive.value(lower); + } + + if (fileDirPos.pos_in_zip_directory != 0) { + p->zipError = unzGoToFilePos64(p->unzFile_f, &fileDirPos); + p->hasCurrentFile_f = p->zipError == UNZ_OK; + } + + if (p->hasCurrentFile_f) + return p->hasCurrentFile_f; + + // Not mapped yet, start from where we have got to so far + for(bool more=p->goToFirstUnmappedFile(); more; more=goToNextFile()) { + current=getCurrentFileName(); + if(current.isEmpty()) return false; + if(sens) { + if(current==fileName) break; + } else { + if(current.toLower()==lower) break; + } + } + return p->hasCurrentFile_f; +} + +bool QuaZip::goToFirstFile() +{ + p->zipError=UNZ_OK; + if(p->mode!=mdUnzip) { + qWarning("QuaZip::goToFirstFile(): ZIP is not open in mdUnzip mode"); + return false; + } + p->zipError=unzGoToFirstFile(p->unzFile_f); + p->hasCurrentFile_f=p->zipError==UNZ_OK; + return p->hasCurrentFile_f; +} + +bool QuaZip::goToNextFile() +{ + p->zipError=UNZ_OK; + if(p->mode!=mdUnzip) { + qWarning("QuaZip::goToFirstFile(): ZIP is not open in mdUnzip mode"); + return false; + } + p->zipError=unzGoToNextFile(p->unzFile_f); + p->hasCurrentFile_f=p->zipError==UNZ_OK; + if(p->zipError==UNZ_END_OF_LIST_OF_FILE) + p->zipError=UNZ_OK; + return p->hasCurrentFile_f; +} + +bool QuaZip::getCurrentFileInfo(QuaZipFileInfo *info)const +{ + QuaZipFileInfo64 info64; + if (info == NULL) { // Very unlikely because of the overloads + return false; + } + if (getCurrentFileInfo(&info64)) { + info64.toQuaZipFileInfo(*info); + return true; + } else { + return false; + } +} + +bool QuaZip::getCurrentFileInfo(QuaZipFileInfo64 *info)const +{ + QuaZip *fakeThis=(QuaZip*)this; // non-const + fakeThis->p->zipError=UNZ_OK; + if(p->mode!=mdUnzip) { + qWarning("QuaZip::getCurrentFileInfo(): ZIP is not open in mdUnzip mode"); + return false; + } + unz_file_info64 info_z; + QByteArray fileName; + QByteArray extra; + QByteArray comment; + if(info==NULL) return false; + if(!isOpen()||!hasCurrentFile()) return false; + if((fakeThis->p->zipError=unzGetCurrentFileInfo64(p->unzFile_f, &info_z, NULL, 0, NULL, 0, NULL, 0))!=UNZ_OK) + return false; + fileName.resize(info_z.size_filename); + extra.resize(info_z.size_file_extra); + comment.resize(info_z.size_file_comment); + if((fakeThis->p->zipError=unzGetCurrentFileInfo64(p->unzFile_f, NULL, + fileName.data(), fileName.size(), + extra.data(), extra.size(), + comment.data(), comment.size()))!=UNZ_OK) + return false; + info->versionCreated=info_z.version; + info->versionNeeded=info_z.version_needed; + info->flags=info_z.flag; + info->method=info_z.compression_method; + info->crc=info_z.crc; + info->compressedSize=info_z.compressed_size; + info->uncompressedSize=info_z.uncompressed_size; + info->diskNumberStart=info_z.disk_num_start; + info->internalAttr=info_z.internal_fa; + info->externalAttr=info_z.external_fa; + info->name=(info->flags & UNZ_ENCODING_UTF8) ? QString::fromUtf8(fileName) : p->fileNameCodec->toUnicode(fileName); + info->comment=(info->flags & UNZ_ENCODING_UTF8) ? QString::fromUtf8(comment) : p->commentCodec->toUnicode(comment); + info->extra=extra; + info->dateTime=QDateTime( + QDate(info_z.tmu_date.tm_year, info_z.tmu_date.tm_mon+1, info_z.tmu_date.tm_mday), + QTime(info_z.tmu_date.tm_hour, info_z.tmu_date.tm_min, info_z.tmu_date.tm_sec)); + // Add to directory map + p->addCurrentFileToDirectoryMap(info->name); + return true; +} + +QString QuaZip::getCurrentFileName()const +{ + QuaZip *fakeThis=(QuaZip*)this; // non-const + fakeThis->p->zipError=UNZ_OK; + if(p->mode!=mdUnzip) { + qWarning("QuaZip::getCurrentFileName(): ZIP is not open in mdUnzip mode"); + return QString(); + } + if(!isOpen()||!hasCurrentFile()) return QString(); + QByteArray fileName(MAX_FILE_NAME_LENGTH, 0); + unz_file_info64 file_info; + if((fakeThis->p->zipError=unzGetCurrentFileInfo64(p->unzFile_f, &file_info, fileName.data(), fileName.size(), + NULL, 0, NULL, 0))!=UNZ_OK) + return QString(); + fileName.resize(file_info.size_filename); + QString result = (file_info.flag & UNZ_ENCODING_UTF8) + ? QString::fromUtf8(fileName) : p->fileNameCodec->toUnicode(fileName); + if (result.isEmpty()) + return result; + // Add to directory map + p->addCurrentFileToDirectoryMap(result); + return result; +} + +void QuaZip::setFileNameCodec(QTextCodec *fileNameCodec) +{ + p->fileNameCodec=fileNameCodec; +} + +void QuaZip::setFileNameCodec(const char *fileNameCodecName) +{ + p->fileNameCodec=QTextCodec::codecForName(fileNameCodecName); +} + +void QuaZip::setOsCode(uint osCode) +{ + p->osCode = osCode; +} + +uint QuaZip::getOsCode() const +{ + return p->osCode; +} + +QTextCodec *QuaZip::getFileNameCodec()const +{ + return p->fileNameCodec; +} + +void QuaZip::setCommentCodec(QTextCodec *commentCodec) +{ + p->commentCodec=commentCodec; +} + +void QuaZip::setCommentCodec(const char *commentCodecName) +{ + p->commentCodec=QTextCodec::codecForName(commentCodecName); +} + +QTextCodec *QuaZip::getCommentCodec()const +{ + return p->commentCodec; +} + +QString QuaZip::getZipName() const +{ + return p->zipName; +} + +QIODevice *QuaZip::getIoDevice() const +{ + if (!p->zipName.isEmpty()) // opened by name, using an internal QIODevice + return NULL; + return p->ioDevice; +} + +QuaZip::Mode QuaZip::getMode()const +{ + return p->mode; +} + +bool QuaZip::isOpen()const +{ + return p->mode!=mdNotOpen; +} + +int QuaZip::getZipError() const +{ + return p->zipError; +} + +void QuaZip::setComment(const QString& comment) +{ + p->comment=comment; +} + +bool QuaZip::hasCurrentFile()const +{ + return p->hasCurrentFile_f; +} + +unzFile QuaZip::getUnzFile() +{ + return p->unzFile_f; +} + +zipFile QuaZip::getZipFile() +{ + return p->zipFile_f; +} + +void QuaZip::setDataDescriptorWritingEnabled(bool enabled) +{ + p->dataDescriptorWritingEnabled = enabled; +} + +bool QuaZip::isDataDescriptorWritingEnabled() const +{ + return p->dataDescriptorWritingEnabled; +} + +template +TFileInfo QuaZip_getFileInfo(QuaZip *zip, bool *ok); + +template<> +QuaZipFileInfo QuaZip_getFileInfo(QuaZip *zip, bool *ok) +{ + QuaZipFileInfo info; + *ok = zip->getCurrentFileInfo(&info); + return info; +} + +template<> +QuaZipFileInfo64 QuaZip_getFileInfo(QuaZip *zip, bool *ok) +{ + QuaZipFileInfo64 info; + *ok = zip->getCurrentFileInfo(&info); + return info; +} + +template<> +QString QuaZip_getFileInfo(QuaZip *zip, bool *ok) +{ + QString name = zip->getCurrentFileName(); + *ok = !name.isEmpty(); + return name; +} + +template +bool QuaZipPrivate::getFileInfoList(QList *result) const +{ + QuaZipPrivate *fakeThis=const_cast(this); + fakeThis->zipError=UNZ_OK; + if (mode!=QuaZip::mdUnzip) { + qWarning("QuaZip::getFileNameList/getFileInfoList(): " + "ZIP is not open in mdUnzip mode"); + return false; + } + QString currentFile; + if (q->hasCurrentFile()) { + currentFile = q->getCurrentFileName(); + } + if (q->goToFirstFile()) { + do { + bool ok; + result->append(QuaZip_getFileInfo(q, &ok)); + if (!ok) + return false; + } while (q->goToNextFile()); + } + if (zipError != UNZ_OK) + return false; + if (currentFile.isEmpty()) { + if (!q->goToFirstFile()) + return false; + } else { + if (!q->setCurrentFile(currentFile)) + return false; + } + return true; +} + +QStringList QuaZip::getFileNameList() const +{ + QStringList list; + if (p->getFileInfoList(&list)) + return list; + else + return QStringList(); +} + +QList QuaZip::getFileInfoList() const +{ + QList list; + if (p->getFileInfoList(&list)) + return list; + else + return QList(); +} + +QList QuaZip::getFileInfoList64() const +{ + QList list; + if (p->getFileInfoList(&list)) + return list; + else + return QList(); +} + +Qt::CaseSensitivity QuaZip::convertCaseSensitivity(QuaZip::CaseSensitivity cs) +{ + if (cs == csDefault) { +#ifdef Q_OS_WIN + return Qt::CaseInsensitive; +#else + return Qt::CaseSensitive; +#endif + } else { + return cs == csSensitive ? Qt::CaseSensitive : Qt::CaseInsensitive; + } +} + +void QuaZip::setDefaultFileNameCodec(QTextCodec *codec) +{ + QuaZipPrivate::defaultFileNameCodec = codec; +} + +void QuaZip::setDefaultFileNameCodec(const char *codecName) +{ + setDefaultFileNameCodec(QTextCodec::codecForName(codecName)); +} + +void QuaZip::setDefaultOsCode(uint osCode) +{ + QuaZipPrivate::defaultOsCode = osCode; +} + +uint QuaZip::getDefaultOsCode() +{ + return QuaZipPrivate::defaultOsCode; +} + +void QuaZip::setZip64Enabled(bool zip64) +{ + p->zip64 = zip64; +} + +bool QuaZip::isZip64Enabled() const +{ + return p->zip64; +} + +void QuaZip::setUtf8Enabled(bool utf8) +{ + p->utf8 = utf8; +} + +bool QuaZip::isUtf8Enabled() const +{ + return p->utf8; +} + +bool QuaZip::isAutoClose() const +{ + return p->autoClose; +} + +void QuaZip::setAutoClose(bool autoClose) const +{ + p->autoClose = autoClose; +} diff --git a/hecl-gui/quazip/quazip/quazip.h b/hecl-gui/quazip/quazip/quazip.h index a32ca4988..ed4a30f62 100644 --- a/hecl-gui/quazip/quazip/quazip.h +++ b/hecl-gui/quazip/quazip/quazip.h @@ -1,561 +1,611 @@ -#ifndef QUA_ZIP_H -#define QUA_ZIP_H - -/* -Copyright (C) 2005-2014 Sergey A. Tachenov - -This file is part of QuaZIP. - -QuaZIP is free software: you can redistribute it and/or modify -it under the terms of the GNU Lesser General Public License as published by -the Free Software Foundation, either version 3 of the License, or -(at your option) any later version. - -QuaZIP is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU Lesser General Public License for more details. - -You should have received a copy of the GNU Lesser General Public License -along with QuaZIP. If not, see . - -See COPYING file for the full LGPL text. - -Original ZIP package is copyrighted by Gilles Vollant, see -quazip/(un)zip.h files for details, basically it's zlib license. - **/ - -#include -#include -#include - -#include "zip.h" -#include "unzip.h" - -#include "quazip_global.h" -#include "quazipfileinfo.h" - -// just in case it will be defined in the later versions of the ZIP/UNZIP -#ifndef UNZ_OPENERROR -// define additional error code -#define UNZ_OPENERROR -1000 -#endif - -class QuaZipPrivate; - -/// ZIP archive. -/** \class QuaZip quazip.h - * This class implements basic interface to the ZIP archive. It can be - * used to read table contents of the ZIP archive and retreiving - * information about the files inside it. - * - * You can also use this class to open files inside archive by passing - * pointer to the instance of this class to the constructor of the - * QuaZipFile class. But see QuaZipFile::QuaZipFile(QuaZip*, QObject*) - * for the possible pitfalls. - * - * This class is indended to provide interface to the ZIP subpackage of - * the ZIP/UNZIP package as well as to the UNZIP subpackage. But - * currently it supports only UNZIP. - * - * The use of this class is simple - just create instance using - * constructor, then set ZIP archive file name using setFile() function - * (if you did not passed the name to the constructor), then open() and - * then use different functions to work with it! Well, if you are - * paranoid, you may also wish to call close before destructing the - * instance, to check for errors on close. - * - * You may also use getUnzFile() and getZipFile() functions to get the - * ZIP archive handle and use it with ZIP/UNZIP package API directly. - * - * This class supports localized file names inside ZIP archive, but you - * have to set up proper codec with setCodec() function. By default, - * locale codec will be used, which is probably ok for UNIX systems, but - * will almost certainly fail with ZIP archives created in Windows. This - * is because Windows ZIP programs have strange habit of using DOS - * encoding for file names in ZIP archives. For example, ZIP archive - * with cyrillic names created in Windows will have file names in \c - * IBM866 encoding instead of \c WINDOWS-1251. I think that calling one - * function is not much trouble, but for true platform independency it - * would be nice to have some mechanism for file name encoding auto - * detection using locale information. Does anyone know a good way to do - * it? - **/ -class QUAZIP_EXPORT QuaZip { - friend class QuaZipPrivate; - public: - /// Useful constants. - enum Constants { - MAX_FILE_NAME_LENGTH=256 /**< Maximum file name length. Taken from - \c UNZ_MAXFILENAMEINZIP constant in - unzip.c. */ - }; - /// Open mode of the ZIP file. - enum Mode { - mdNotOpen, ///< ZIP file is not open. This is the initial mode. - mdUnzip, ///< ZIP file is open for reading files inside it. - mdCreate, ///< ZIP file was created with open() call. - mdAppend, /**< ZIP file was opened in append mode. This refers to - * \c APPEND_STATUS_CREATEAFTER mode in ZIP/UNZIP package - * and means that zip is appended to some existing file - * what is useful when that file contains - * self-extractor code. This is obviously \em not what - * you whant to use to add files to the existing ZIP - * archive. - **/ - mdAdd ///< ZIP file was opened for adding files in the archive. - }; - /// Case sensitivity for the file names. - /** This is what you specify when accessing files in the archive. - * Works perfectly fine with any characters thanks to Qt's great - * unicode support. This is different from ZIP/UNZIP API, where - * only US-ASCII characters was supported. - **/ - enum CaseSensitivity { - csDefault=0, ///< Default for platform. Case sensitive for UNIX, not for Windows. - csSensitive=1, ///< Case sensitive. - csInsensitive=2 ///< Case insensitive. - }; - /// Returns the actual case sensitivity for the specified QuaZIP one. - /** - \param cs The value to convert. - \returns If CaseSensitivity::csDefault, then returns the default - file name case sensitivity for the platform. Otherwise, just - returns the appropriate value from the Qt::CaseSensitivity enum. - */ - static Qt::CaseSensitivity convertCaseSensitivity( - CaseSensitivity cs); - private: - QuaZipPrivate *p; - // not (and will not be) implemented - QuaZip(const QuaZip& that); - // not (and will not be) implemented - QuaZip& operator=(const QuaZip& that); - public: - /// Constructs QuaZip object. - /** Call setName() before opening constructed object. */ - QuaZip(); - /// Constructs QuaZip object associated with ZIP file \a zipName. - QuaZip(const QString& zipName); - /// Constructs QuaZip object associated with ZIP file represented by \a ioDevice. - /** The IO device must be seekable, otherwise an error will occur when opening. */ - QuaZip(QIODevice *ioDevice); - /// Destroys QuaZip object. - /** Calls close() if necessary. */ - ~QuaZip(); - /// Opens ZIP file. - /** - * Argument \a mode specifies open mode of the ZIP archive. See Mode - * for details. Note that there is zipOpen2() function in the - * ZIP/UNZIP API which accepts \a globalcomment argument, but it - * does not use it anywhere, so this open() function does not have this - * argument. See setComment() if you need to set global comment. - * - * If the ZIP file is accessed via explicitly set QIODevice, then - * this device is opened in the necessary mode. If the device was - * already opened by some other means, then QuaZIP checks if the - * open mode is compatible to the mode needed for the requested operation. - * If necessary, seeking is performed to position the device properly. - * - * \return \c true if successful, \c false otherwise. - * - * \note ZIP/UNZIP API open calls do not return error code - they - * just return \c NULL indicating an error. But to make things - * easier, quazip.h header defines additional error code \c - * UNZ_ERROROPEN and getZipError() will return it if the open call - * of the ZIP/UNZIP API returns \c NULL. - * - * Argument \a ioApi specifies IO function set for ZIP/UNZIP - * package to use. See unzip.h, zip.h and ioapi.h for details. Note - * that IO API for QuaZip is different from the original package. - * The file path argument was changed to be of type \c voidpf, and - * QuaZip passes a QIODevice pointer there. This QIODevice is either - * set explicitly via setIoDevice() or the QuaZip(QIODevice*) - * constructor, or it is created internally when opening the archive - * by its file name. The default API (qioapi.cpp) just delegates - * everything to the QIODevice API. Not only this allows to use a - * QIODevice instead of file name, but also has a nice side effect - * of raising the file size limit from 2G to 4G (in non-zip64 archives). - * - * \note If the zip64 support is needed, the ioApi argument \em must be NULL - * because due to the backwards compatibility issues it can be used to - * provide a 32-bit API only. - * - * In short: just forget about the \a ioApi argument and you'll be - * fine. - **/ - bool open(Mode mode, zlib_filefunc_def *ioApi =NULL); - /// Closes ZIP file. - /** Call getZipError() to determine if the close was successful. - * - * If the file was opened by name, then the underlying QIODevice is closed - * and deleted. - * - * If the underlying QIODevice was set explicitly using setIoDevice() or - * the appropriate constructor, then it is closed if the auto-close flag - * is set (which it is by default). Call setAutoClose() to clear the - * auto-close flag if this behavior is undesirable. - * - * Since Qt 5.1, the QSaveFile was introduced. It breaks the QIODevice API - * by making close() private and crashing the application if it is called - * from the base class where it is public. It is an excellent example - * of poor design that illustrates why you should never ever break - * an is-a relationship between the base class and a subclass. QuaZIP - * works around this bug by checking if the QIODevice is an instance - * of QSaveFile, using qobject_cast<>, and if it is, calls - * QSaveFile::commit() instead of close(). It is a really ugly hack, - * but at least it makes your programs work instead of crashing. Note that - * if the auto-close flag is cleared, then this is a non-issue, and - * commit() isn't called. - */ - void close(); - /// Sets the codec used to encode/decode file names inside archive. - /** This is necessary to access files in the ZIP archive created - * under Windows with non-latin characters in file names. For - * example, file names with cyrillic letters will be in \c IBM866 - * encoding. - **/ - void setFileNameCodec(QTextCodec *fileNameCodec); - /// Sets the codec used to encode/decode file names inside archive. - /** \overload - * Equivalent to calling setFileNameCodec(QTextCodec::codecForName(codecName)); - **/ - void setFileNameCodec(const char *fileNameCodecName); - /// Returns the codec used to encode/decode comments inside archive. - QTextCodec* getFileNameCodec() const; - /// Sets the codec used to encode/decode comments inside archive. - /** This codec defaults to locale codec, which is probably ok. - **/ - void setCommentCodec(QTextCodec *commentCodec); - /// Sets the codec used to encode/decode comments inside archive. - /** \overload - * Equivalent to calling setCommentCodec(QTextCodec::codecForName(codecName)); - **/ - void setCommentCodec(const char *commentCodecName); - /// Returns the codec used to encode/decode comments inside archive. - QTextCodec* getCommentCodec() const; - /// Returns the name of the ZIP file. - /** Returns null string if no ZIP file name has been set, for - * example when the QuaZip instance is set up to use a QIODevice - * instead. - * \sa setZipName(), setIoDevice(), getIoDevice() - **/ - QString getZipName() const; - /// Sets the name of the ZIP file. - /** Does nothing if the ZIP file is open. - * - * Does not reset error code returned by getZipError(). - * \sa setIoDevice(), getIoDevice(), getZipName() - **/ - void setZipName(const QString& zipName); - /// Returns the device representing this ZIP file. - /** Returns null string if no device has been set explicitly, for - * example when opening a ZIP file by name. - * \sa setIoDevice(), getZipName(), setZipName() - **/ - QIODevice *getIoDevice() const; - /// Sets the device representing the ZIP file. - /** Does nothing if the ZIP file is open. - * - * Does not reset error code returned by getZipError(). - * \sa getIoDevice(), getZipName(), setZipName() - **/ - void setIoDevice(QIODevice *ioDevice); - /// Returns the mode in which ZIP file was opened. - Mode getMode() const; - /// Returns \c true if ZIP file is open, \c false otherwise. - bool isOpen() const; - /// Returns the error code of the last operation. - /** Returns \c UNZ_OK if the last operation was successful. - * - * Error code resets to \c UNZ_OK every time you call any function - * that accesses something inside ZIP archive, even if it is \c - * const (like getEntriesCount()). open() and close() calls reset - * error code too. See documentation for the specific functions for - * details on error detection. - **/ - int getZipError() const; - /// Returns number of the entries in the ZIP central directory. - /** Returns negative error code in the case of error. The same error - * code will be returned by subsequent getZipError() call. - **/ - int getEntriesCount() const; - /// Returns global comment in the ZIP file. - QString getComment() const; - /// Sets the global comment in the ZIP file. - /** The comment will be written to the archive on close operation. - * QuaZip makes a distinction between a null QByteArray() comment - * and an empty "" comment in the QuaZip::mdAdd mode. - * A null comment is the default and it means "don't change - * the comment". An empty comment removes the original comment. - * - * \sa open() - **/ - void setComment(const QString& comment); - /// Sets the current file to the first file in the archive. - /** Returns \c true on success, \c false otherwise. Call - * getZipError() to get the error code. - **/ - bool goToFirstFile(); - /// Sets the current file to the next file in the archive. - /** Returns \c true on success, \c false otherwise. Call - * getZipError() to determine if there was an error. - * - * Should be used only in QuaZip::mdUnzip mode. - * - * \note If the end of file was reached, getZipError() will return - * \c UNZ_OK instead of \c UNZ_END_OF_LIST_OF_FILE. This is to make - * things like this easier: - * \code - * for(bool more=zip.goToFirstFile(); more; more=zip.goToNextFile()) { - * // do something - * } - * if(zip.getZipError()==UNZ_OK) { - * // ok, there was no error - * } - * \endcode - **/ - bool goToNextFile(); - /// Sets current file by its name. - /** Returns \c true if successful, \c false otherwise. Argument \a - * cs specifies case sensitivity of the file name. Call - * getZipError() in the case of a failure to get error code. - * - * This is not a wrapper to unzLocateFile() function. That is - * because I had to implement locale-specific case-insensitive - * comparison. - * - * Here are the differences from the original implementation: - * - * - If the file was not found, error code is \c UNZ_OK, not \c - * UNZ_END_OF_LIST_OF_FILE (see also goToNextFile()). - * - If this function fails, it unsets the current file rather than - * resetting it back to what it was before the call. - * - * If \a fileName is null string then this function unsets the - * current file and return \c true. Note that you should close the - * file first if it is open! See - * QuaZipFile::QuaZipFile(QuaZip*,QObject*) for the details. - * - * Should be used only in QuaZip::mdUnzip mode. - * - * \sa setFileNameCodec(), CaseSensitivity - **/ - bool setCurrentFile(const QString& fileName, CaseSensitivity cs =csDefault); - /// Returns \c true if the current file has been set. - bool hasCurrentFile() const; - /// Retrieves information about the current file. - /** Fills the structure pointed by \a info. Returns \c true on - * success, \c false otherwise. In the latter case structure pointed - * by \a info remains untouched. If there was an error, - * getZipError() returns error code. - * - * Should be used only in QuaZip::mdUnzip mode. - * - * Does nothing and returns \c false in any of the following cases. - * - ZIP is not open; - * - ZIP does not have current file. - * - * In both cases getZipError() returns \c UNZ_OK since there - * is no ZIP/UNZIP API call. - * - * This overload doesn't support zip64, but will work OK on zip64 archives - * except that if one of the sizes (compressed or uncompressed) is greater - * than 0xFFFFFFFFu, it will be set to exactly 0xFFFFFFFFu. - * - * \sa getCurrentFileInfo(QuaZipFileInfo64* info)const - * \sa QuaZipFileInfo64::toQuaZipFileInfo(QuaZipFileInfo&)const - **/ - bool getCurrentFileInfo(QuaZipFileInfo* info)const; - /// Retrieves information about the current file. - /** \overload - * - * This function supports zip64. If the archive doesn't use zip64, it is - * completely equivalent to getCurrentFileInfo(QuaZipFileInfo* info) - * except for the argument type. - * - * \sa - **/ - bool getCurrentFileInfo(QuaZipFileInfo64* info)const; - /// Returns the current file name. - /** Equivalent to calling getCurrentFileInfo() and then getting \c - * name field of the QuaZipFileInfo structure, but faster and more - * convenient. - * - * Should be used only in QuaZip::mdUnzip mode. - **/ - QString getCurrentFileName()const; - /// Returns \c unzFile handle. - /** You can use this handle to directly call UNZIP part of the - * ZIP/UNZIP package functions (see unzip.h). - * - * \warning When using the handle returned by this function, please - * keep in mind that QuaZip class is unable to detect any changes - * you make in the ZIP file state (e. g. changing current file, or - * closing the handle). So please do not do anything with this - * handle that is possible to do with the functions of this class. - * Or at least return the handle in the original state before - * calling some another function of this class (including implicit - * destructor calls and calls from the QuaZipFile objects that refer - * to this QuaZip instance!). So if you have changed the current - * file in the ZIP archive - then change it back or you may - * experience some strange behavior or even crashes. - **/ - unzFile getUnzFile(); - /// Returns \c zipFile handle. - /** You can use this handle to directly call ZIP part of the - * ZIP/UNZIP package functions (see zip.h). Warnings about the - * getUnzFile() function also apply to this function. - **/ - zipFile getZipFile(); - /// Changes the data descriptor writing mode. - /** - According to the ZIP format specification, a file inside archive - may have a data descriptor immediately following the file - data. This is reflected by a special flag in the local file header - and in the central directory. By default, QuaZIP sets this flag - and writes the data descriptor unless both method and level were - set to 0, in which case it operates in 1.0-compatible mode and - never writes data descriptors. - - By setting this flag to false, it is possible to disable data - descriptor writing, thus increasing compatibility with archive - readers that don't understand this feature of the ZIP file format. - - Setting this flag affects all the QuaZipFile instances that are - opened after this flag is set. - - The data descriptor writing mode is enabled by default. - - \param enabled If \c true, enable local descriptor writing, - disable it otherwise. - - \sa QuaZipFile::setDataDescriptorWritingEnabled() - */ - void setDataDescriptorWritingEnabled(bool enabled); - /// Returns the data descriptor default writing mode. - /** - \sa setDataDescriptorWritingEnabled() - */ - bool isDataDescriptorWritingEnabled() const; - /// Returns a list of files inside the archive. - /** - \return A list of file names or an empty list if there - was an error or if the archive is empty (call getZipError() to - figure out which). - \sa getFileInfoList() - */ - QStringList getFileNameList() const; - /// Returns information list about all files inside the archive. - /** - \return A list of QuaZipFileInfo objects or an empty list if there - was an error or if the archive is empty (call getZipError() to - figure out which). - - This function doesn't support zip64, but will still work with zip64 - archives, converting results using QuaZipFileInfo64::toQuaZipFileInfo(). - If all file sizes are below 4 GB, it will work just fine. - - \sa getFileNameList() - \sa getFileInfoList64() - */ - QList getFileInfoList() const; - /// Returns information list about all files inside the archive. - /** - \overload - - This function supports zip64. - - \sa getFileNameList() - \sa getFileInfoList() - */ - QList getFileInfoList64() const; - /// Enables the zip64 mode. - /** - * @param zip64 If \c true, the zip64 mode is enabled, disabled otherwise. - * - * Once this is enabled, all new files (until the mode is disabled again) - * will be created in the zip64 mode, thus enabling the ability to write - * files larger than 4 GB. By default, the zip64 mode is off due to - * compatibility reasons. - * - * Note that this does not affect the ability to read zip64 archives in any - * way. - * - * \sa isZip64Enabled() - */ - void setZip64Enabled(bool zip64); - /// Returns whether the zip64 mode is enabled. - /** - * @return \c true if and only if the zip64 mode is enabled. - * - * \sa setZip64Enabled() - */ - bool isZip64Enabled() const; - /// Returns the auto-close flag. - /** - @sa setAutoClose() - */ - bool isAutoClose() const; - /// Sets or unsets the auto-close flag. - /** - By default, QuaZIP opens the underlying QIODevice when open() is called, - and closes it when close() is called. In some cases, when the device - is set explicitly using setIoDevice(), it may be desirable to - leave the device open. If the auto-close flag is unset using this method, - then the device isn't closed automatically if it was set explicitly. - - If it is needed to clear this flag, it is recommended to do so before - opening the archive because otherwise QuaZIP may close the device - during the open() call if an error is encountered after the device - is opened. - - If the device was not set explicitly, but rather the setZipName() or - the appropriate constructor was used to set the ZIP file name instead, - then the auto-close flag has no effect, and the internal device - is closed nevertheless because there is no other way to close it. - - @sa isAutoClose() - @sa setIoDevice() - */ - void setAutoClose(bool autoClose) const; - /// Sets the default file name codec to use. - /** - * The default codec is used by the constructors, so calling this function - * won't affect the QuaZip instances already created at that moment. - * - * The codec specified here can be overriden by calling setFileNameCodec(). - * If neither function is called, QTextCodec::codecForLocale() will be used - * to decode or encode file names. Use this function with caution if - * the application uses other libraries that depend on QuaZIP. Those - * libraries can either call this function by themselves, thus overriding - * your setting or can rely on the default encoding, thus failing - * mysteriously if you change it. For these reasons, it isn't recommended - * to use this function if you are developing a library, not an application. - * Instead, ask your library users to call it in case they need specific - * encoding. - * - * In most cases, using setFileNameCodec() instead is the right choice. - * However, if you depend on third-party code that uses QuaZIP, then the - * reasons stated above can actually become a reason to use this function - * in case the third-party code in question fails because it doesn't - * understand the encoding you need and doesn't provide a way to specify it. - * This applies to the JlCompress class as well, as it was contributed and - * doesn't support explicit encoding parameters. - * - * In short: use setFileNameCodec() when you can, resort to - * setDefaultFileNameCodec() when you don't have access to the QuaZip - * instance. - * - * @param codec The codec to use by default. If NULL, resets to default. - */ - static void setDefaultFileNameCodec(QTextCodec *codec); - /** - * @overload - * Equivalent to calling - * setDefltFileNameCodec(QTextCodec::codecForName(codecName)). - */ - static void setDefaultFileNameCodec(const char *codecName); -}; - -#endif +#ifndef QUA_ZIP_H +#define QUA_ZIP_H + +/* +Copyright (C) 2005-2014 Sergey A. Tachenov + +This file is part of QuaZIP. + +QuaZIP is free software: you can redistribute it and/or modify +it under the terms of the GNU Lesser General Public License as published by +the Free Software Foundation, either version 2.1 of the License, or +(at your option) any later version. + +QuaZIP is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU Lesser General Public License for more details. + +You should have received a copy of the GNU Lesser General Public License +along with QuaZIP. If not, see . + +See COPYING file for the full LGPL text. + +Original ZIP package is copyrighted by Gilles Vollant, see +quazip/(un)zip.h files for details, basically it's zlib license. + **/ + +#include +#include +#include + +#include "zip.h" +#include "unzip.h" + +#include "quazip_global.h" +#include "quazipfileinfo.h" + +// just in case it will be defined in the later versions of the ZIP/UNZIP +#ifndef UNZ_OPENERROR +// define additional error code +#define UNZ_OPENERROR -1000 +#endif + +class QuaZipPrivate; + +/// ZIP archive. +/** \class QuaZip quazip.h + * This class implements basic interface to the ZIP archive. It can be + * used to read table contents of the ZIP archive and retreiving + * information about the files inside it. + * + * You can also use this class to open files inside archive by passing + * pointer to the instance of this class to the constructor of the + * QuaZipFile class. But see QuaZipFile::QuaZipFile(QuaZip*, QObject*) + * for the possible pitfalls. + * + * This class is indended to provide interface to the ZIP subpackage of + * the ZIP/UNZIP package as well as to the UNZIP subpackage. But + * currently it supports only UNZIP. + * + * The use of this class is simple - just create instance using + * constructor, then set ZIP archive file name using setFile() function + * (if you did not passed the name to the constructor), then open() and + * then use different functions to work with it! Well, if you are + * paranoid, you may also wish to call close before destructing the + * instance, to check for errors on close. + * + * You may also use getUnzFile() and getZipFile() functions to get the + * ZIP archive handle and use it with ZIP/UNZIP package API directly. + * + * This class supports localized file names inside ZIP archive, but you + * have to set up proper codec with setCodec() function. By default, + * locale codec will be used, which is probably ok for UNIX systems, but + * will almost certainly fail with ZIP archives created in Windows. This + * is because Windows ZIP programs have strange habit of using DOS + * encoding for file names in ZIP archives. For example, ZIP archive + * with cyrillic names created in Windows will have file names in \c + * IBM866 encoding instead of \c WINDOWS-1251. I think that calling one + * function is not much trouble, but for true platform independency it + * would be nice to have some mechanism for file name encoding auto + * detection using locale information. Does anyone know a good way to do + * it? + **/ +class QUAZIP_EXPORT QuaZip { + friend class QuaZipPrivate; + public: + /// Useful constants. + enum Constants { + MAX_FILE_NAME_LENGTH=256 /**< Maximum file name length. Taken from + \c UNZ_MAXFILENAMEINZIP constant in + unzip.c. */ + }; + /// Open mode of the ZIP file. + enum Mode { + mdNotOpen, ///< ZIP file is not open. This is the initial mode. + mdUnzip, ///< ZIP file is open for reading files inside it. + mdCreate, ///< ZIP file was created with open() call. + mdAppend, /**< ZIP file was opened in append mode. This refers to + * \c APPEND_STATUS_CREATEAFTER mode in ZIP/UNZIP package + * and means that zip is appended to some existing file + * what is useful when that file contains + * self-extractor code. This is obviously \em not what + * you whant to use to add files to the existing ZIP + * archive. + **/ + mdAdd ///< ZIP file was opened for adding files in the archive. + }; + /// Case sensitivity for the file names. + /** This is what you specify when accessing files in the archive. + * Works perfectly fine with any characters thanks to Qt's great + * unicode support. This is different from ZIP/UNZIP API, where + * only US-ASCII characters was supported. + **/ + enum CaseSensitivity { + csDefault=0, ///< Default for platform. Case sensitive for UNIX, not for Windows. + csSensitive=1, ///< Case sensitive. + csInsensitive=2 ///< Case insensitive. + }; + /// Returns the actual case sensitivity for the specified QuaZIP one. + /** + \param cs The value to convert. + \returns If CaseSensitivity::csDefault, then returns the default + file name case sensitivity for the platform. Otherwise, just + returns the appropriate value from the Qt::CaseSensitivity enum. + */ + static Qt::CaseSensitivity convertCaseSensitivity( + CaseSensitivity cs); + private: + QuaZipPrivate *p; + // not (and will not be) implemented + QuaZip(const QuaZip& that); + // not (and will not be) implemented + QuaZip& operator=(const QuaZip& that); + public: + /// Constructs QuaZip object. + /** Call setName() before opening constructed object. */ + QuaZip(); + /// Constructs QuaZip object associated with ZIP file \a zipName. + QuaZip(const QString& zipName); + /// Constructs QuaZip object associated with ZIP file represented by \a ioDevice. + /** The IO device must be seekable, otherwise an error will occur when opening. */ + QuaZip(QIODevice *ioDevice); + /// Destroys QuaZip object. + /** Calls close() if necessary. */ + ~QuaZip(); + /// Opens ZIP file. + /** + * Argument \a mode specifies open mode of the ZIP archive. See Mode + * for details. Note that there is zipOpen2() function in the + * ZIP/UNZIP API which accepts \a globalcomment argument, but it + * does not use it anywhere, so this open() function does not have this + * argument. See setComment() if you need to set global comment. + * + * If the ZIP file is accessed via explicitly set QIODevice, then + * this device is opened in the necessary mode. If the device was + * already opened by some other means, then QuaZIP checks if the + * open mode is compatible to the mode needed for the requested operation. + * If necessary, seeking is performed to position the device properly. + * + * \return \c true if successful, \c false otherwise. + * + * \note ZIP/UNZIP API open calls do not return error code - they + * just return \c NULL indicating an error. But to make things + * easier, quazip.h header defines additional error code \c + * UNZ_ERROROPEN and getZipError() will return it if the open call + * of the ZIP/UNZIP API returns \c NULL. + * + * Argument \a ioApi specifies IO function set for ZIP/UNZIP + * package to use. See unzip.h, zip.h and ioapi.h for details. Note + * that IO API for QuaZip is different from the original package. + * The file path argument was changed to be of type \c voidpf, and + * QuaZip passes a QIODevice pointer there. This QIODevice is either + * set explicitly via setIoDevice() or the QuaZip(QIODevice*) + * constructor, or it is created internally when opening the archive + * by its file name. The default API (qioapi.cpp) just delegates + * everything to the QIODevice API. Not only this allows to use a + * QIODevice instead of file name, but also has a nice side effect + * of raising the file size limit from 2G to 4G (in non-zip64 archives). + * + * \note If the zip64 support is needed, the ioApi argument \em must be NULL + * because due to the backwards compatibility issues it can be used to + * provide a 32-bit API only. + * + * \note If the \ref QuaZip::setAutoClose() "no-auto-close" feature is used, + * then the \a ioApi argument \em should be NULL because the old API + * doesn't support the 'fake close' operation, causing slight memory leaks + * and other possible troubles (like closing the output device in case + * when an error occurs during opening). + * + * In short: just forget about the \a ioApi argument and you'll be + * fine. + **/ + bool open(Mode mode, zlib_filefunc_def *ioApi =NULL); + /// Closes ZIP file. + /** Call getZipError() to determine if the close was successful. + * + * If the file was opened by name, then the underlying QIODevice is closed + * and deleted. + * + * If the underlying QIODevice was set explicitly using setIoDevice() or + * the appropriate constructor, then it is closed if the auto-close flag + * is set (which it is by default). Call setAutoClose() to clear the + * auto-close flag if this behavior is undesirable. + * + * Since Qt 5.1, the QSaveFile was introduced. It breaks the QIODevice API + * by making close() private and crashing the application if it is called + * from the base class where it is public. It is an excellent example + * of poor design that illustrates why you should never ever break + * an is-a relationship between the base class and a subclass. QuaZIP + * works around this bug by checking if the QIODevice is an instance + * of QSaveFile, using qobject_cast<>, and if it is, calls + * QSaveFile::commit() instead of close(). It is a really ugly hack, + * but at least it makes your programs work instead of crashing. Note that + * if the auto-close flag is cleared, then this is a non-issue, and + * commit() isn't called. + */ + void close(); + /// Sets the codec used to encode/decode file names inside archive. + /** This is necessary to access files in the ZIP archive created + * under Windows with non-latin characters in file names. For + * example, file names with cyrillic letters will be in \c IBM866 + * encoding. + **/ + void setFileNameCodec(QTextCodec *fileNameCodec); + /// Sets the codec used to encode/decode file names inside archive. + /** \overload + * Equivalent to calling setFileNameCodec(QTextCodec::codecForName(codecName)); + **/ + void setFileNameCodec(const char *fileNameCodecName); + /// Sets the OS code (highest 8 bits of the “version made by” field) for new files. + /** There is currently no way to specify this for each file individually, + except by calling this function before opening each file. If this function is not called, + then the default OS code will be used. The default code is set by calling + setDefaultOsCode(). The default value at the moment of QuaZip creation will be used. */ + void setOsCode(uint osCode); + /// Returns the OS code for new files. + uint getOsCode() const; + /// Returns the codec used to encode/decode comments inside archive. + QTextCodec* getFileNameCodec() const; + /// Sets the codec used to encode/decode comments inside archive. + /** This codec defaults to locale codec, which is probably ok. + **/ + void setCommentCodec(QTextCodec *commentCodec); + /// Sets the codec used to encode/decode comments inside archive. + /** \overload + * Equivalent to calling setCommentCodec(QTextCodec::codecForName(codecName)); + **/ + void setCommentCodec(const char *commentCodecName); + /// Returns the codec used to encode/decode comments inside archive. + QTextCodec* getCommentCodec() const; + /// Returns the name of the ZIP file. + /** Returns null string if no ZIP file name has been set, for + * example when the QuaZip instance is set up to use a QIODevice + * instead. + * \sa setZipName(), setIoDevice(), getIoDevice() + **/ + QString getZipName() const; + /// Sets the name of the ZIP file. + /** Does nothing if the ZIP file is open. + * + * Does not reset error code returned by getZipError(). + * \sa setIoDevice(), getIoDevice(), getZipName() + **/ + void setZipName(const QString& zipName); + /// Returns the device representing this ZIP file. + /** Returns null string if no device has been set explicitly, for + * example when opening a ZIP file by name. + * \sa setIoDevice(), getZipName(), setZipName() + **/ + QIODevice *getIoDevice() const; + /// Sets the device representing the ZIP file. + /** Does nothing if the ZIP file is open. + * + * Does not reset error code returned by getZipError(). + * \sa getIoDevice(), getZipName(), setZipName() + **/ + void setIoDevice(QIODevice *ioDevice); + /// Returns the mode in which ZIP file was opened. + Mode getMode() const; + /// Returns \c true if ZIP file is open, \c false otherwise. + bool isOpen() const; + /// Returns the error code of the last operation. + /** Returns \c UNZ_OK if the last operation was successful. + * + * Error code resets to \c UNZ_OK every time you call any function + * that accesses something inside ZIP archive, even if it is \c + * const (like getEntriesCount()). open() and close() calls reset + * error code too. See documentation for the specific functions for + * details on error detection. + **/ + int getZipError() const; + /// Returns number of the entries in the ZIP central directory. + /** Returns negative error code in the case of error. The same error + * code will be returned by subsequent getZipError() call. + **/ + int getEntriesCount() const; + /// Returns global comment in the ZIP file. + QString getComment() const; + /// Sets the global comment in the ZIP file. + /** The comment will be written to the archive on close operation. + * QuaZip makes a distinction between a null QByteArray() comment + * and an empty "" comment in the QuaZip::mdAdd mode. + * A null comment is the default and it means "don't change + * the comment". An empty comment removes the original comment. + * + * \sa open() + **/ + void setComment(const QString& comment); + /// Sets the current file to the first file in the archive. + /** Returns \c true on success, \c false otherwise. Call + * getZipError() to get the error code. + **/ + bool goToFirstFile(); + /// Sets the current file to the next file in the archive. + /** Returns \c true on success, \c false otherwise. Call + * getZipError() to determine if there was an error. + * + * Should be used only in QuaZip::mdUnzip mode. + * + * \note If the end of file was reached, getZipError() will return + * \c UNZ_OK instead of \c UNZ_END_OF_LIST_OF_FILE. This is to make + * things like this easier: + * \code + * for(bool more=zip.goToFirstFile(); more; more=zip.goToNextFile()) { + * // do something + * } + * if(zip.getZipError()==UNZ_OK) { + * // ok, there was no error + * } + * \endcode + **/ + bool goToNextFile(); + /// Sets current file by its name. + /** Returns \c true if successful, \c false otherwise. Argument \a + * cs specifies case sensitivity of the file name. Call + * getZipError() in the case of a failure to get error code. + * + * This is not a wrapper to unzLocateFile() function. That is + * because I had to implement locale-specific case-insensitive + * comparison. + * + * Here are the differences from the original implementation: + * + * - If the file was not found, error code is \c UNZ_OK, not \c + * UNZ_END_OF_LIST_OF_FILE (see also goToNextFile()). + * - If this function fails, it unsets the current file rather than + * resetting it back to what it was before the call. + * + * If \a fileName is null string then this function unsets the + * current file and return \c true. Note that you should close the + * file first if it is open! See + * QuaZipFile::QuaZipFile(QuaZip*,QObject*) for the details. + * + * Should be used only in QuaZip::mdUnzip mode. + * + * \sa setFileNameCodec(), CaseSensitivity + **/ + bool setCurrentFile(const QString& fileName, CaseSensitivity cs =csDefault); + /// Returns \c true if the current file has been set. + bool hasCurrentFile() const; + /// Retrieves information about the current file. + /** Fills the structure pointed by \a info. Returns \c true on + * success, \c false otherwise. In the latter case structure pointed + * by \a info remains untouched. If there was an error, + * getZipError() returns error code. + * + * Should be used only in QuaZip::mdUnzip mode. + * + * Does nothing and returns \c false in any of the following cases. + * - ZIP is not open; + * - ZIP does not have current file. + * + * In both cases getZipError() returns \c UNZ_OK since there + * is no ZIP/UNZIP API call. + * + * This overload doesn't support zip64, but will work OK on zip64 archives + * except that if one of the sizes (compressed or uncompressed) is greater + * than 0xFFFFFFFFu, it will be set to exactly 0xFFFFFFFFu. + * + * \sa getCurrentFileInfo(QuaZipFileInfo64* info)const + * \sa QuaZipFileInfo64::toQuaZipFileInfo(QuaZipFileInfo&)const + **/ + bool getCurrentFileInfo(QuaZipFileInfo* info)const; + /// Retrieves information about the current file. + /** \overload + * + * This function supports zip64. If the archive doesn't use zip64, it is + * completely equivalent to getCurrentFileInfo(QuaZipFileInfo* info) + * except for the argument type. + * + * \sa + **/ + bool getCurrentFileInfo(QuaZipFileInfo64* info)const; + /// Returns the current file name. + /** Equivalent to calling getCurrentFileInfo() and then getting \c + * name field of the QuaZipFileInfo structure, but faster and more + * convenient. + * + * Should be used only in QuaZip::mdUnzip mode. + **/ + QString getCurrentFileName()const; + /// Returns \c unzFile handle. + /** You can use this handle to directly call UNZIP part of the + * ZIP/UNZIP package functions (see unzip.h). + * + * \warning When using the handle returned by this function, please + * keep in mind that QuaZip class is unable to detect any changes + * you make in the ZIP file state (e. g. changing current file, or + * closing the handle). So please do not do anything with this + * handle that is possible to do with the functions of this class. + * Or at least return the handle in the original state before + * calling some another function of this class (including implicit + * destructor calls and calls from the QuaZipFile objects that refer + * to this QuaZip instance!). So if you have changed the current + * file in the ZIP archive - then change it back or you may + * experience some strange behavior or even crashes. + **/ + unzFile getUnzFile(); + /// Returns \c zipFile handle. + /** You can use this handle to directly call ZIP part of the + * ZIP/UNZIP package functions (see zip.h). Warnings about the + * getUnzFile() function also apply to this function. + **/ + zipFile getZipFile(); + /// Changes the data descriptor writing mode. + /** + According to the ZIP format specification, a file inside archive + may have a data descriptor immediately following the file + data. This is reflected by a special flag in the local file header + and in the central directory. By default, QuaZIP sets this flag + and writes the data descriptor unless both method and level were + set to 0, in which case it operates in 1.0-compatible mode and + never writes data descriptors. + + By setting this flag to false, it is possible to disable data + descriptor writing, thus increasing compatibility with archive + readers that don't understand this feature of the ZIP file format. + + Setting this flag affects all the QuaZipFile instances that are + opened after this flag is set. + + The data descriptor writing mode is enabled by default. + + Note that if the ZIP archive is written into a QIODevice for which + QIODevice::isSequential() returns \c true, then the data descriptor + is mandatory and will be written even if this flag is set to false. + + \param enabled If \c true, enable local descriptor writing, + disable it otherwise. + + \sa QuaZipFile::isDataDescriptorWritingEnabled() + */ + void setDataDescriptorWritingEnabled(bool enabled); + /// Returns the data descriptor default writing mode. + /** + \sa setDataDescriptorWritingEnabled() + */ + bool isDataDescriptorWritingEnabled() const; + /// Returns a list of files inside the archive. + /** + \return A list of file names or an empty list if there + was an error or if the archive is empty (call getZipError() to + figure out which). + \sa getFileInfoList() + */ + QStringList getFileNameList() const; + /// Returns information list about all files inside the archive. + /** + \return A list of QuaZipFileInfo objects or an empty list if there + was an error or if the archive is empty (call getZipError() to + figure out which). + + This function doesn't support zip64, but will still work with zip64 + archives, converting results using QuaZipFileInfo64::toQuaZipFileInfo(). + If all file sizes are below 4 GB, it will work just fine. + + \sa getFileNameList() + \sa getFileInfoList64() + */ + QList getFileInfoList() const; + /// Returns information list about all files inside the archive. + /** + \overload + + This function supports zip64. + + \sa getFileNameList() + \sa getFileInfoList() + */ + QList getFileInfoList64() const; + /// Enables the zip64 mode. + /** + * @param zip64 If \c true, the zip64 mode is enabled, disabled otherwise. + * + * Once this is enabled, all new files (until the mode is disabled again) + * will be created in the zip64 mode, thus enabling the ability to write + * files larger than 4 GB. By default, the zip64 mode is off due to + * compatibility reasons. + * + * Note that this does not affect the ability to read zip64 archives in any + * way. + * + * \sa isZip64Enabled() + */ + void setZip64Enabled(bool zip64); + /// Returns whether the zip64 mode is enabled. + /** + * @return \c true if and only if the zip64 mode is enabled. + * + * \sa setZip64Enabled() + */ + bool isZip64Enabled() const; + /// Enables the use of UTF-8 encoding for file names and comments text. + /** + * @param utf8 If \c true, the UTF-8 mode is enabled, disabled otherwise. + * + * Once this is enabled, the names of all new files and comments text (until + * the mode is disabled again) will be encoded in UTF-8 encoding, and the + * version to extract will be set to 6.3 (63) in ZIP header. By default, + * the UTF-8 mode is off due to compatibility reasons. + * + * Note that when extracting ZIP archives, the UTF-8 mode is determined from + * ZIP file header, not from this flag. + * + * \sa isUtf8Enabled() + */ + void setUtf8Enabled(bool utf8); + /// Returns whether the UTF-8 encoding mode is enabled. + /** + * @return \c true if and only if the UTF-8 mode is enabled. + * + * \sa setUtf8Enabled() + */ + bool isUtf8Enabled() const; + /// Returns the auto-close flag. + /** + @sa setAutoClose() + */ + bool isAutoClose() const; + /// Sets or unsets the auto-close flag. + /** + By default, QuaZIP opens the underlying QIODevice when open() is called, + and closes it when close() is called. In some cases, when the device + is set explicitly using setIoDevice(), it may be desirable to + leave the device open. If the auto-close flag is unset using this method, + then the device isn't closed automatically if it was set explicitly. + + If it is needed to clear this flag, it is recommended to do so before + opening the archive because otherwise QuaZIP may close the device + during the open() call if an error is encountered after the device + is opened. + + If the device was not set explicitly, but rather the setZipName() or + the appropriate constructor was used to set the ZIP file name instead, + then the auto-close flag has no effect, and the internal device + is closed nevertheless because there is no other way to close it. + + @sa isAutoClose() + @sa setIoDevice() + */ + void setAutoClose(bool autoClose) const; + /// Sets the default file name codec to use. + /** + * The default codec is used by the constructors, so calling this function + * won't affect the QuaZip instances already created at that moment. + * + * The codec specified here can be overriden by calling setFileNameCodec(). + * If neither function is called, QTextCodec::codecForLocale() will be used + * to decode or encode file names. Use this function with caution if + * the application uses other libraries that depend on QuaZIP. Those + * libraries can either call this function by themselves, thus overriding + * your setting or can rely on the default encoding, thus failing + * mysteriously if you change it. For these reasons, it isn't recommended + * to use this function if you are developing a library, not an application. + * Instead, ask your library users to call it in case they need specific + * encoding. + * + * In most cases, using setFileNameCodec() instead is the right choice. + * However, if you depend on third-party code that uses QuaZIP, then the + * reasons stated above can actually become a reason to use this function + * in case the third-party code in question fails because it doesn't + * understand the encoding you need and doesn't provide a way to specify it. + * This applies to the JlCompress class as well, as it was contributed and + * doesn't support explicit encoding parameters. + * + * In short: use setFileNameCodec() when you can, resort to + * setDefaultFileNameCodec() when you don't have access to the QuaZip + * instance. + * + * @param codec The codec to use by default. If NULL, resets to default. + */ + static void setDefaultFileNameCodec(QTextCodec *codec); + /** + * @overload + * Equivalent to calling + * setDefaultFileNameCodec(QTextCodec::codecForName(codecName)). + */ + static void setDefaultFileNameCodec(const char *codecName); + /// Sets default OS code. + /** + * @sa setOsCode() + */ + static void setDefaultOsCode(uint osCode); + /// Returns default OS code. + /** + * @sa getOsCode() + */ + static uint getDefaultOsCode(); +}; + +#endif diff --git a/hecl-gui/quazip/quazip/quazip.pri b/hecl-gui/quazip/quazip/quazip.pri index 1ca2ddecd..bd0637a80 100644 --- a/hecl-gui/quazip/quazip/quazip.pri +++ b/hecl-gui/quazip/quazip/quazip.pri @@ -1,33 +1,33 @@ -INCLUDEPATH += $$PWD -DEPENDPATH += $$PWD -HEADERS += \ - $$PWD/crypt.h \ - $$PWD/ioapi.h \ - $$PWD/JlCompress.h \ - $$PWD/quaadler32.h \ - $$PWD/quachecksum32.h \ - $$PWD/quacrc32.h \ - $$PWD/quagzipfile.h \ - $$PWD/quaziodevice.h \ - $$PWD/quazipdir.h \ - $$PWD/quazipfile.h \ - $$PWD/quazipfileinfo.h \ - $$PWD/quazip_global.h \ - $$PWD/quazip.h \ - $$PWD/quazipnewinfo.h \ - $$PWD/unzip.h \ - $$PWD/zip.h - -SOURCES += $$PWD/qioapi.cpp \ - $$PWD/JlCompress.cpp \ - $$PWD/quaadler32.cpp \ - $$PWD/quacrc32.cpp \ - $$PWD/quagzipfile.cpp \ - $$PWD/quaziodevice.cpp \ - $$PWD/quazip.cpp \ - $$PWD/quazipdir.cpp \ - $$PWD/quazipfile.cpp \ - $$PWD/quazipfileinfo.cpp \ - $$PWD/quazipnewinfo.cpp \ - $$PWD/unzip.c \ - $$PWD/zip.c +INCLUDEPATH += $$PWD +DEPENDPATH += $$PWD +HEADERS += \ + $$PWD/minizip_crypt.h \ + $$PWD/ioapi.h \ + $$PWD/JlCompress.h \ + $$PWD/quaadler32.h \ + $$PWD/quachecksum32.h \ + $$PWD/quacrc32.h \ + $$PWD/quagzipfile.h \ + $$PWD/quaziodevice.h \ + $$PWD/quazipdir.h \ + $$PWD/quazipfile.h \ + $$PWD/quazipfileinfo.h \ + $$PWD/quazip_global.h \ + $$PWD/quazip.h \ + $$PWD/quazipnewinfo.h \ + $$PWD/unzip.h \ + $$PWD/zip.h + +SOURCES += $$PWD/qioapi.cpp \ + $$PWD/JlCompress.cpp \ + $$PWD/quaadler32.cpp \ + $$PWD/quacrc32.cpp \ + $$PWD/quagzipfile.cpp \ + $$PWD/quaziodevice.cpp \ + $$PWD/quazip.cpp \ + $$PWD/quazipdir.cpp \ + $$PWD/quazipfile.cpp \ + $$PWD/quazipfileinfo.cpp \ + $$PWD/quazipnewinfo.cpp \ + $$PWD/unzip.c \ + $$PWD/zip.c diff --git a/hecl-gui/quazip/quazip/quazip.pro b/hecl-gui/quazip/quazip/quazip.pro index e745b84de..ca1ec7d62 100644 --- a/hecl-gui/quazip/quazip/quazip.pro +++ b/hecl-gui/quazip/quazip/quazip.pro @@ -1,57 +1,113 @@ -TEMPLATE = lib -CONFIG += qt warn_on -QT -= gui -!win32:VERSION = 1.0.0 - -DEFINES += QUAZIP_BUILD -CONFIG(staticlib): DEFINES += QUAZIP_STATIC - -# Input -include(quazip.pri) - -unix:!symbian { - headers.path=$$PREFIX/include/quazip - headers.files=$$HEADERS - target.path=$$PREFIX/lib - INSTALLS += headers target - - OBJECTS_DIR=.obj - MOC_DIR=.moc - -} - -win32 { - headers.path=$$PREFIX/include/quazip - headers.files=$$HEADERS - target.path=$$PREFIX/lib - INSTALLS += headers target - # workaround for qdatetime.h macro bug - DEFINES += NOMINMAX -} - - -symbian { - - # Note, on Symbian you may run into troubles with LGPL. - # The point is, if your application uses some version of QuaZip, - # and a newer binary compatible version of QuaZip is released, then - # the users of your application must be able to relink it with the - # new QuaZip version. For example, to take advantage of some QuaZip - # bug fixes. - - # This is probably best achieved by building QuaZip as a static - # library and providing linkable object files of your application, - # so users can relink it. - - CONFIG += staticlib - CONFIG += debug_and_release - - LIBS += -lezip - - #Export headers to SDK Epoc32/include directory - exportheaders.sources = $$HEADERS - exportheaders.path = quazip - for(header, exportheaders.sources) { - BLD_INF_RULES.prj_exports += "$$header $$exportheaders.path/$$basename(header)" - } -} +TEMPLATE = lib +CONFIG += qt warn_on +QT -= gui + +# Creating pkgconfig .pc file +CONFIG += create_prl no_install_prl create_pc + +QMAKE_PKGCONFIG_PREFIX = $$PREFIX +QMAKE_PKGCONFIG_INCDIR = $$headers.path +QMAKE_PKGCONFIG_REQUIRES = Qt5Core + +# The ABI version. + +!win32:VERSION = 1.0.0 + +# 1.0.0 is the first stable ABI. +# The next binary incompatible change will be 2.0.0 and so on. +# The existing QuaZIP policy on changing ABI requires to bump the +# major version of QuaZIP itself as well. Note that there may be +# other reasons for chaging the major version of QuaZIP, so +# in case where there is a QuaZIP major version bump but no ABI change, +# the VERSION variable will stay the same. + +# For example: + +# QuaZIP 1.0 is released after some 0.x, keeping binary compatibility. +# VERSION stays 1.0.0. +# Then some binary incompatible change is introduced. QuaZIP goes up to +# 2.0, VERSION to 2.0.0. +# And so on. + +greaterThan(QT_MAJOR_VERSION, 4) { + # disable all the Qt APIs deprecated before Qt 6.0.0 + DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000 +} + +# This one handles dllimport/dllexport directives. +DEFINES += QUAZIP_BUILD +DEFINES += QT_NO_CAST_FROM_ASCII +DEFINES += QT_NO_CAST_TO_ASCII +# You'll need to define this one manually if using a build system other +# than qmake or using QuaZIP sources directly in your project. +CONFIG(staticlib): DEFINES += QUAZIP_STATIC + +# Input +include(quazip.pri) + + +CONFIG(debug, debug|release) { + mac: TARGET = $$join(TARGET,,,_debug) + win32: TARGET = $$join(TARGET,,,d) +} + +unix:!symbian { + headers.path=$$PREFIX/include/quazip + headers.files=$$HEADERS + target.path=$$PREFIX/lib/$${LIB_ARCH} + QMAKE_PKGCONFIG_DESTDIR = pkgconfig + INSTALLS += headers target + + OBJECTS_DIR=.obj + MOC_DIR=.moc + +} + +win32 { + headers.path=$$PREFIX/include/quazip + headers.files=$$HEADERS + INSTALLS += headers target + CONFIG(staticlib){ + target.path=$$PREFIX/lib + QMAKE_PKGCONFIG_LIBDIR = $$PREFIX/lib/ + } else { + target.path=$$PREFIX/bin + QMAKE_PKGCONFIG_LIBDIR = $$PREFIX/bin/ + } + + ## odd, this path seems to be relative to the + ## target.path, so if we install the .dll into + ## the 'bin' dir, the .pc will go there as well, + ## unless have hack the needed path... + ## TODO any nicer solution? + QMAKE_PKGCONFIG_DESTDIR = ../lib/pkgconfig + # workaround for qdatetime.h macro bug + DEFINES += NOMINMAX +} + + +symbian { + + # Note, on Symbian you may run into troubles with LGPL. + # The point is, if your application uses some version of QuaZip, + # and a newer binary compatible version of QuaZip is released, then + # the users of your application must be able to relink it with the + # new QuaZip version. For example, to take advantage of some QuaZip + # bug fixes. + + # This is probably best achieved by building QuaZip as a static + # library and providing linkable object files of your application, + # so users can relink it. + + CONFIG += staticlib + CONFIG += debug_and_release + + LIBS += -lezip + + #Export headers to SDK Epoc32/include directory + exportheaders.sources = $$HEADERS + exportheaders.path = quazip + for(header, exportheaders.sources) { + BLD_INF_RULES.prj_exports += "$$header $$exportheaders.path/$$basename(header)" + } +} diff --git a/hecl-gui/quazip/quazip/quazip.vcproj b/hecl-gui/quazip/quazip/quazip.vcproj index 803400756..a23980723 100644 --- a/hecl-gui/quazip/quazip/quazip.vcproj +++ b/hecl-gui/quazip/quazip/quazip.vcproj @@ -168,7 +168,7 @@ UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}" > - + Debug Win32 + + Debug + x64 + Release Win32 + + Release + x64 + {E4AC5F56-B711-4F0E-BC83-CDE8B6CD53AD} @@ -17,30 +25,50 @@ DynamicLibrary + v120 + + + DynamicLibrary + v120 DynamicLibrary + v120 + + + DynamicLibrary + v120 - + + + + + + + + + <_ProjectFileVersion>10.0.30319.1 Debug\ Debug\ true + true Release\ Release\ true + true @@ -61,6 +89,23 @@ MachineX86 + + + Disabled + WIN32;_DEBUG;_WINDOWS;QUAZIP_BUILD;%(PreprocessorDefinitions) + EnableFastChecks + MultiThreadedDebugDLL + + + Level3 + ProgramDatabase + + + QtCored4.lib;%(AdditionalDependencies) + true + Windows + + WIN32;NDEBUG;_WINDOWS;QUAZIP_BUILD;%(PreprocessorDefinitions) @@ -71,7 +116,7 @@ ProgramDatabase - QtCore4.lib;%(AdditionalDependencies) + Qt5Core.lib;%(AdditionalDependencies) true Windows true @@ -79,8 +124,25 @@ MachineX86 + + + WIN32;NDEBUG;_WINDOWS;QUAZIP_BUILD;%(PreprocessorDefinitions) + MultiThreadedDLL + + + Level3 + ProgramDatabase + + + Qt5Core.lib;zlibwapi.lib;%(AdditionalDependencies) + true + Windows + true + true + + - + @@ -118,4 +180,4 @@ - \ No newline at end of file + diff --git a/hecl-gui/quazip/quazip/quazip.vcxproj.filters b/hecl-gui/quazip/quazip/quazip.vcxproj.filters index 68677d576..26cade116 100644 --- a/hecl-gui/quazip/quazip/quazip.vcxproj.filters +++ b/hecl-gui/quazip/quazip/quazip.vcxproj.filters @@ -15,7 +15,7 @@
- + Header Files @@ -114,4 +114,4 @@ Source Files - \ No newline at end of file + diff --git a/hecl-gui/quazip/quazip/quazip_global.h b/hecl-gui/quazip/quazip/quazip_global.h index d7788b857..0223a4994 100644 --- a/hecl-gui/quazip/quazip/quazip_global.h +++ b/hecl-gui/quazip/quazip/quazip_global.h @@ -8,7 +8,7 @@ This file is part of QuaZIP. QuaZIP is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by -the Free Software Foundation, either version 3 of the License, or +the Free Software Foundation, either version 2.1 of the License, or (at your option) any later version. QuaZIP is distributed in the hope that it will be useful, @@ -47,12 +47,10 @@ see quazip/(un)zip.h files for details. Basically it's the zlib license. #endif #endif // QUAZIP_STATIC -#ifndef UNUSED #ifdef __GNUC__ -#define UNUSED __attribute__((__unused__)) +#define QUAZIP_UNUSED __attribute__((__unused__)) #else -#define UNUSED -#endif +#define QUAZIP_UNUSED #endif #define QUAZIP_EXTRA_NTFS_MAGIC 0x000Au diff --git a/hecl-gui/quazip/quazip/quazipdir.cpp b/hecl-gui/quazip/quazip/quazipdir.cpp index 8207110bb..a3c52cf2e 100644 --- a/hecl-gui/quazip/quazip/quazipdir.cpp +++ b/hecl-gui/quazip/quazip/quazipdir.cpp @@ -1,567 +1,571 @@ -/* -Copyright (C) 2005-2014 Sergey A. Tachenov - -This file is part of QuaZIP. - -QuaZIP is free software: you can redistribute it and/or modify -it under the terms of the GNU Lesser General Public License as published by -the Free Software Foundation, either version 3 of the License, or -(at your option) any later version. - -QuaZIP is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU Lesser General Public License for more details. - -You should have received a copy of the GNU Lesser General Public License -along with QuaZIP. If not, see . - -See COPYING file for the full LGPL text. - -Original ZIP package is copyrighted by Gilles Vollant and contributors, -see quazip/(un)zip.h files for details. Basically it's the zlib license. -*/ - -#include "quazipdir.h" - -#include -#include - -/// \cond internal -class QuaZipDirPrivate: public QSharedData { - friend class QuaZipDir; -private: - QuaZipDirPrivate(QuaZip *zip, const QString &dir = QString()): - zip(zip), dir(dir), caseSensitivity(QuaZip::csDefault), - filter(QDir::NoFilter), sorting(QDir::NoSort) {} - QuaZip *zip; - QString dir; - QuaZip::CaseSensitivity caseSensitivity; - QDir::Filters filter; - QStringList nameFilters; - QDir::SortFlags sorting; - template - bool entryInfoList(QStringList nameFilters, QDir::Filters filter, - QDir::SortFlags sort, TFileInfoList &result) const; - inline QString simplePath() const {return QDir::cleanPath(dir);} -}; -/// \endcond - -QuaZipDir::QuaZipDir(const QuaZipDir &that): - d(that.d) -{ -} - -QuaZipDir::QuaZipDir(QuaZip *zip, const QString &dir): - d(new QuaZipDirPrivate(zip, dir)) -{ - if (d->dir.startsWith('/')) - d->dir = d->dir.mid(1); -} - -QuaZipDir::~QuaZipDir() -{ -} - -bool QuaZipDir::operator==(const QuaZipDir &that) -{ - return d->zip == that.d->zip && d->dir == that.d->dir; -} - -QuaZipDir& QuaZipDir::operator=(const QuaZipDir &that) -{ - this->d = that.d; - return *this; -} - -QString QuaZipDir::operator[](int pos) const -{ - return entryList().at(pos); -} - -QuaZip::CaseSensitivity QuaZipDir::caseSensitivity() const -{ - return d->caseSensitivity; -} - -bool QuaZipDir::cd(const QString &directoryName) -{ - if (directoryName == "/") { - d->dir = ""; - return true; - } - QString dirName = directoryName; - if (dirName.endsWith('/')) - dirName.chop(1); - if (dirName.contains('/')) { - QuaZipDir dir(*this); - if (dirName.startsWith('/')) { -#ifdef QUAZIP_QUAZIPDIR_DEBUG - qDebug("QuaZipDir::cd(%s): going to /", - dirName.toUtf8().constData()); -#endif - if (!dir.cd("/")) - return false; - } - QStringList path = dirName.split('/', QString::SkipEmptyParts); - for (QStringList::const_iterator i = path.constBegin(); - i != path.end(); - ++i) { - const QString &step = *i; -#ifdef QUAZIP_QUAZIPDIR_DEBUG - qDebug("QuaZipDir::cd(%s): going to %s", - dirName.toUtf8().constData(), - step.toUtf8().constData()); -#endif - if (!dir.cd(step)) - return false; - } - d->dir = dir.path(); - return true; - } else { // no '/' - if (dirName == ".") { - return true; - } else if (dirName == "..") { - if (isRoot()) { - return false; - } else { - int slashPos = d->dir.lastIndexOf('/'); - if (slashPos == -1) { - d->dir = ""; - } else { - d->dir = d->dir.left(slashPos); - } - return true; - } - } else { // a simple subdirectory - if (exists(dirName)) { - if (isRoot()) - d->dir = dirName; - else - d->dir += "/" + dirName; - return true; - } else { - return false; - } - } - } -} - -bool QuaZipDir::cdUp() -{ - return cd(".."); -} - -uint QuaZipDir::count() const -{ - return entryList().count(); -} - -QString QuaZipDir::dirName() const -{ - return QDir(d->dir).dirName(); -} - -QuaZipFileInfo64 QuaZipDir_getFileInfo(QuaZip *zip, bool *ok, - const QString &relativeName, - bool isReal) -{ - QuaZipFileInfo64 info; - if (isReal) { - *ok = zip->getCurrentFileInfo(&info); - } else { - *ok = true; - info.compressedSize = 0; - info.crc = 0; - info.diskNumberStart = 0; - info.externalAttr = 0; - info.flags = 0; - info.internalAttr = 0; - info.method = 0; - info.uncompressedSize = 0; - info.versionCreated = info.versionNeeded = 0; - } - info.name = relativeName; - return info; -} - -static void QuaZipDir_convertInfoList(const QList &from, - QList &to) -{ - to = from; -} - -static void QuaZipDir_convertInfoList(const QList &from, - QStringList &to) -{ - to.clear(); - for (QList::const_iterator i = from.constBegin(); - i != from.constEnd(); - ++i) { - to.append(i->name); - } -} - -static void QuaZipDir_convertInfoList(const QList &from, - QList &to) -{ - to.clear(); - for (QList::const_iterator i = from.constBegin(); - i != from.constEnd(); - ++i) { - QuaZipFileInfo info32; - i->toQuaZipFileInfo(info32); - to.append(info32); - } -} - -/// \cond internal -/** - An utility class to restore the current file. - */ -class QuaZipDirRestoreCurrent { -public: - inline QuaZipDirRestoreCurrent(QuaZip *zip): - zip(zip), currentFile(zip->getCurrentFileName()) {} - inline ~QuaZipDirRestoreCurrent() - { - zip->setCurrentFile(currentFile); - } -private: - QuaZip *zip; - QString currentFile; -}; -/// \endcond - -/// \cond internal -class QuaZipDirComparator -{ - private: - QDir::SortFlags sort; - static QString getExtension(const QString &name); - int compareStrings(const QString &string1, const QString &string2); - public: - inline QuaZipDirComparator(QDir::SortFlags sort): sort(sort) {} - bool operator()(const QuaZipFileInfo64 &info1, const QuaZipFileInfo64 &info2); -}; - -QString QuaZipDirComparator::getExtension(const QString &name) -{ - if (name.endsWith('.') || name.indexOf('.', 1) == -1) { - return ""; - } else { - return name.mid(name.lastIndexOf('.') + 1); - } - -} - -int QuaZipDirComparator::compareStrings(const QString &string1, - const QString &string2) -{ - if (sort & QDir::LocaleAware) { - if (sort & QDir::IgnoreCase) { - return string1.toLower().localeAwareCompare(string2.toLower()); - } else { - return string1.localeAwareCompare(string2); - } - } else { - return string1.compare(string2, (sort & QDir::IgnoreCase) - ? Qt::CaseInsensitive : Qt::CaseSensitive); - } -} - -bool QuaZipDirComparator::operator()(const QuaZipFileInfo64 &info1, - const QuaZipFileInfo64 &info2) -{ - QDir::SortFlags order = sort - & (QDir::Name | QDir::Time | QDir::Size | QDir::Type); - if ((sort & QDir::DirsFirst) == QDir::DirsFirst - || (sort & QDir::DirsLast) == QDir::DirsLast) { - if (info1.name.endsWith('/') && !info2.name.endsWith('/')) - return (sort & QDir::DirsFirst) == QDir::DirsFirst; - else if (!info1.name.endsWith('/') && info2.name.endsWith('/')) - return (sort & QDir::DirsLast) == QDir::DirsLast; - } - bool result; - int extDiff; - switch (order) { - case QDir::Name: - result = compareStrings(info1.name, info2.name) < 0; - break; - case QDir::Type: - extDiff = compareStrings(getExtension(info1.name), - getExtension(info2.name)); - if (extDiff == 0) { - result = compareStrings(info1.name, info2.name) < 0; - } else { - result = extDiff < 0; - } - break; - case QDir::Size: - if (info1.uncompressedSize == info2.uncompressedSize) { - result = compareStrings(info1.name, info2.name) < 0; - } else { - result = info1.uncompressedSize < info2.uncompressedSize; - } - break; - case QDir::Time: - if (info1.dateTime == info2.dateTime) { - result = compareStrings(info1.name, info2.name) < 0; - } else { - result = info1.dateTime < info2.dateTime; - } - break; - default: - qWarning("QuaZipDirComparator(): Invalid sort mode 0x%2X", - static_cast(sort)); - return false; - } - return (sort & QDir::Reversed) ? !result : result; -} - -template -bool QuaZipDirPrivate::entryInfoList(QStringList nameFilters, - QDir::Filters filter, QDir::SortFlags sort, TFileInfoList &result) const -{ - QString basePath = simplePath(); - if (!basePath.isEmpty()) - basePath += "/"; - int baseLength = basePath.length(); - result.clear(); - QuaZipDirRestoreCurrent saveCurrent(zip); - if (!zip->goToFirstFile()) { - return zip->getZipError() == UNZ_OK; - } - QDir::Filters fltr = filter; - if (fltr == QDir::NoFilter) - fltr = this->filter; - if (fltr == QDir::NoFilter) - fltr = QDir::AllEntries; - QStringList nmfltr = nameFilters; - if (nmfltr.isEmpty()) - nmfltr = this->nameFilters; - QSet dirsFound; - QList list; - do { - QString name = zip->getCurrentFileName(); - if (!name.startsWith(basePath)) - continue; - QString relativeName = name.mid(baseLength); - if (relativeName.isEmpty()) - continue; - bool isDir = false; - bool isReal = true; - if (relativeName.contains('/')) { - int indexOfSlash = relativeName.indexOf('/'); - // something like "subdir/" - isReal = indexOfSlash == relativeName.length() - 1; - relativeName = relativeName.left(indexOfSlash + 1); - if (dirsFound.contains(relativeName)) - continue; - isDir = true; - } - dirsFound.insert(relativeName); - if ((fltr & QDir::Dirs) == 0 && isDir) - continue; - if ((fltr & QDir::Files) == 0 && !isDir) - continue; - if (!nmfltr.isEmpty() && !QDir::match(nmfltr, relativeName)) - continue; - bool ok; - QuaZipFileInfo64 info = QuaZipDir_getFileInfo(zip, &ok, relativeName, - isReal); - if (!ok) { - return false; - } - list.append(info); - } while (zip->goToNextFile()); - QDir::SortFlags srt = sort; - if (srt == QDir::NoSort) - srt = sorting; -#ifdef QUAZIP_QUAZIPDIR_DEBUG - qDebug("QuaZipDirPrivate::entryInfoList(): before sort:"); - foreach (QuaZipFileInfo64 info, list) { - qDebug("%s\t%s", info.name.toUtf8().constData(), - info.dateTime.toString(Qt::ISODate).toUtf8().constData()); - } -#endif - if (srt != QDir::NoSort && (srt & QDir::Unsorted) != QDir::Unsorted) { - if (QuaZip::convertCaseSensitivity(caseSensitivity) - == Qt::CaseInsensitive) - srt |= QDir::IgnoreCase; - QuaZipDirComparator lessThan(srt); - qSort(list.begin(), list.end(), lessThan); - } - QuaZipDir_convertInfoList(list, result); - return true; -} - -/// \endcond - -QList QuaZipDir::entryInfoList(const QStringList &nameFilters, - QDir::Filters filters, QDir::SortFlags sort) const -{ - QList result; - if (d->entryInfoList(nameFilters, filters, sort, result)) - return result; - else - return QList(); -} - -QList QuaZipDir::entryInfoList(QDir::Filters filters, - QDir::SortFlags sort) const -{ - return entryInfoList(QStringList(), filters, sort); -} - -QList QuaZipDir::entryInfoList64(const QStringList &nameFilters, - QDir::Filters filters, QDir::SortFlags sort) const -{ - QList result; - if (d->entryInfoList(nameFilters, filters, sort, result)) - return result; - else - return QList(); -} - -QList QuaZipDir::entryInfoList64(QDir::Filters filters, - QDir::SortFlags sort) const -{ - return entryInfoList64(QStringList(), filters, sort); -} - -QStringList QuaZipDir::entryList(const QStringList &nameFilters, - QDir::Filters filters, QDir::SortFlags sort) const -{ - QStringList result; - if (d->entryInfoList(nameFilters, filters, sort, result)) - return result; - else - return QStringList(); -} - -QStringList QuaZipDir::entryList(QDir::Filters filters, - QDir::SortFlags sort) const -{ - return entryList(QStringList(), filters, sort); -} - -bool QuaZipDir::exists(const QString &filePath) const -{ - if (filePath == "/" || filePath.isEmpty()) - return true; - QString fileName = filePath; - if (fileName.endsWith('/')) - fileName.chop(1); - if (fileName.contains('/')) { - QFileInfo fileInfo(fileName); -#ifdef QUAZIP_QUAZIPDIR_DEBUG - qDebug("QuaZipDir::exists(): fileName=%s, fileInfo.fileName()=%s, " - "fileInfo.path()=%s", fileName.toUtf8().constData(), - fileInfo.fileName().toUtf8().constData(), - fileInfo.path().toUtf8().constData()); -#endif - QuaZipDir dir(*this); - return dir.cd(fileInfo.path()) && dir.exists(fileInfo.fileName()); - } else { - if (fileName == "..") { - return !isRoot(); - } else if (fileName == ".") { - return true; - } else { - QStringList entries = entryList(QDir::AllEntries, QDir::NoSort); -#ifdef QUAZIP_QUAZIPDIR_DEBUG - qDebug("QuaZipDir::exists(): looking for %s", - fileName.toUtf8().constData()); - for (QStringList::const_iterator i = entries.constBegin(); - i != entries.constEnd(); - ++i) { - qDebug("QuaZipDir::exists(): entry: %s", - i->toUtf8().constData()); - } -#endif - Qt::CaseSensitivity cs = QuaZip::convertCaseSensitivity( - d->caseSensitivity); - if (filePath.endsWith('/')) { - return entries.contains(filePath, cs); - } else { - return entries.contains(fileName, cs) - || entries.contains(fileName + "/", cs); - } - } - } -} - -bool QuaZipDir::exists() const -{ - return QuaZipDir(d->zip).exists(d->dir); -} - -QString QuaZipDir::filePath(const QString &fileName) const -{ - return QDir(d->dir).filePath(fileName); -} - -QDir::Filters QuaZipDir::filter() -{ - return d->filter; -} - -bool QuaZipDir::isRoot() const -{ - return d->simplePath().isEmpty(); -} - -QStringList QuaZipDir::nameFilters() const -{ - return d->nameFilters; -} - -QString QuaZipDir::path() const -{ - return d->dir; -} - -QString QuaZipDir::relativeFilePath(const QString &fileName) const -{ - return QDir("/" + d->dir).relativeFilePath(fileName); -} - -void QuaZipDir::setCaseSensitivity(QuaZip::CaseSensitivity caseSensitivity) -{ - d->caseSensitivity = caseSensitivity; -} - -void QuaZipDir::setFilter(QDir::Filters filters) -{ - d->filter = filters; -} - -void QuaZipDir::setNameFilters(const QStringList &nameFilters) -{ - d->nameFilters = nameFilters; -} - -void QuaZipDir::setPath(const QString &path) -{ - QString newDir = path; - if (newDir == "/") { - d->dir = ""; - } else { - if (newDir.endsWith('/')) - newDir.chop(1); - if (newDir.startsWith('/')) - newDir = newDir.mid(1); - d->dir = newDir; - } -} - -void QuaZipDir::setSorting(QDir::SortFlags sort) -{ - d->sorting = sort; -} - -QDir::SortFlags QuaZipDir::sorting() const -{ - return d->sorting; -} +/* +Copyright (C) 2005-2014 Sergey A. Tachenov + +This file is part of QuaZIP. + +QuaZIP is free software: you can redistribute it and/or modify +it under the terms of the GNU Lesser General Public License as published by +the Free Software Foundation, either version 2.1 of the License, or +(at your option) any later version. + +QuaZIP is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU Lesser General Public License for more details. + +You should have received a copy of the GNU Lesser General Public License +along with QuaZIP. If not, see . + +See COPYING file for the full LGPL text. + +Original ZIP package is copyrighted by Gilles Vollant and contributors, +see quazip/(un)zip.h files for details. Basically it's the zlib license. +*/ + +#include "quazipdir.h" + +#include +#include + +/// \cond internal +class QuaZipDirPrivate: public QSharedData { + friend class QuaZipDir; +private: + QuaZipDirPrivate(QuaZip *zip, const QString &dir = QString()): + zip(zip), dir(dir), caseSensitivity(QuaZip::csDefault), + filter(QDir::NoFilter), sorting(QDir::NoSort) {} + QuaZip *zip; + QString dir; + QuaZip::CaseSensitivity caseSensitivity; + QDir::Filters filter; + QStringList nameFilters; + QDir::SortFlags sorting; + template + bool entryInfoList(QStringList nameFilters, QDir::Filters filter, + QDir::SortFlags sort, TFileInfoList &result) const; + inline QString simplePath() const {return QDir::cleanPath(dir);} +}; +/// \endcond + +QuaZipDir::QuaZipDir(const QuaZipDir &that): + d(that.d) +{ +} + +QuaZipDir::QuaZipDir(QuaZip *zip, const QString &dir): + d(new QuaZipDirPrivate(zip, dir)) +{ + if (d->dir.startsWith(QLatin1String("/"))) + d->dir = d->dir.mid(1); +} + +QuaZipDir::~QuaZipDir() +{ +} + +bool QuaZipDir::operator==(const QuaZipDir &that) +{ + return d->zip == that.d->zip && d->dir == that.d->dir; +} + +QuaZipDir& QuaZipDir::operator=(const QuaZipDir &that) +{ + this->d = that.d; + return *this; +} + +QString QuaZipDir::operator[](int pos) const +{ + return entryList().at(pos); +} + +QuaZip::CaseSensitivity QuaZipDir::caseSensitivity() const +{ + return d->caseSensitivity; +} + +bool QuaZipDir::cd(const QString &directoryName) +{ + if (directoryName == QLatin1String("/")) { + d->dir = QLatin1String(""); + return true; + } + QString dirName = directoryName; + if (dirName.endsWith(QLatin1String("/"))) + dirName.chop(1); + if (dirName.contains(QLatin1String("/"))) { + QuaZipDir dir(*this); + if (dirName.startsWith(QLatin1String("/"))) { +#ifdef QUAZIP_QUAZIPDIR_DEBUG + qDebug("QuaZipDir::cd(%s): going to /", + dirName.toUtf8().constData()); +#endif + if (!dir.cd(QLatin1String("/"))) + return false; + } + QStringList path = dirName.split(QLatin1String("/"), QString::SkipEmptyParts); + for (QStringList::const_iterator i = path.constBegin(); + i != path.end(); + ++i) { + const QString &step = *i; +#ifdef QUAZIP_QUAZIPDIR_DEBUG + qDebug("QuaZipDir::cd(%s): going to %s", + dirName.toUtf8().constData(), + step.toUtf8().constData()); +#endif + if (!dir.cd(step)) + return false; + } + d->dir = dir.path(); + return true; + } else { // no '/' + if (dirName == QLatin1String(".")) { + return true; + } else if (dirName == QLatin1String("..")) { + if (isRoot()) { + return false; + } else { + int slashPos = d->dir.lastIndexOf(QLatin1String("/")); + if (slashPos == -1) { + d->dir = QLatin1String(""); + } else { + d->dir = d->dir.left(slashPos); + } + return true; + } + } else { // a simple subdirectory + if (exists(dirName)) { + if (isRoot()) + d->dir = dirName; + else + d->dir += QLatin1String("/") + dirName; + return true; + } else { + return false; + } + } + } +} + +bool QuaZipDir::cdUp() +{ + return cd(QLatin1String("..")); +} + +uint QuaZipDir::count() const +{ + return entryList().count(); +} + +QString QuaZipDir::dirName() const +{ + return QDir(d->dir).dirName(); +} + +QuaZipFileInfo64 QuaZipDir_getFileInfo(QuaZip *zip, bool *ok, + const QString &relativeName, + bool isReal) +{ + QuaZipFileInfo64 info; + if (isReal) { + *ok = zip->getCurrentFileInfo(&info); + } else { + *ok = true; + info.compressedSize = 0; + info.crc = 0; + info.diskNumberStart = 0; + info.externalAttr = 0; + info.flags = 0; + info.internalAttr = 0; + info.method = 0; + info.uncompressedSize = 0; + info.versionCreated = info.versionNeeded = 0; + } + info.name = relativeName; + return info; +} + +static void QuaZipDir_convertInfoList(const QList &from, + QList &to) +{ + to = from; +} + +static void QuaZipDir_convertInfoList(const QList &from, + QStringList &to) +{ + to.clear(); + for (QList::const_iterator i = from.constBegin(); + i != from.constEnd(); + ++i) { + to.append(i->name); + } +} + +static void QuaZipDir_convertInfoList(const QList &from, + QList &to) +{ + to.clear(); + for (QList::const_iterator i = from.constBegin(); + i != from.constEnd(); + ++i) { + QuaZipFileInfo info32; + i->toQuaZipFileInfo(info32); + to.append(info32); + } +} + +/// \cond internal +/** + An utility class to restore the current file. + */ +class QuaZipDirRestoreCurrent { +public: + inline QuaZipDirRestoreCurrent(QuaZip *zip): + zip(zip), currentFile(zip->getCurrentFileName()) {} + inline ~QuaZipDirRestoreCurrent() + { + zip->setCurrentFile(currentFile); + } +private: + QuaZip *zip; + QString currentFile; +}; +/// \endcond + +/// \cond internal +class QuaZipDirComparator +{ + private: + QDir::SortFlags sort; + static QString getExtension(const QString &name); + int compareStrings(const QString &string1, const QString &string2); + public: + inline QuaZipDirComparator(QDir::SortFlags sort): sort(sort) {} + bool operator()(const QuaZipFileInfo64 &info1, const QuaZipFileInfo64 &info2); +}; + +QString QuaZipDirComparator::getExtension(const QString &name) +{ + if (name.endsWith(QLatin1String(".")) || name.indexOf(QLatin1String("."), 1) == -1) { + return QLatin1String(""); + } else { + return name.mid(name.lastIndexOf(QLatin1String(".")) + 1); + } + +} + +int QuaZipDirComparator::compareStrings(const QString &string1, + const QString &string2) +{ + if (sort & QDir::LocaleAware) { + if (sort & QDir::IgnoreCase) { + return string1.toLower().localeAwareCompare(string2.toLower()); + } else { + return string1.localeAwareCompare(string2); + } + } else { + return string1.compare(string2, (sort & QDir::IgnoreCase) + ? Qt::CaseInsensitive : Qt::CaseSensitive); + } +} + +bool QuaZipDirComparator::operator()(const QuaZipFileInfo64 &info1, + const QuaZipFileInfo64 &info2) +{ + QDir::SortFlags order = sort + & (QDir::Name | QDir::Time | QDir::Size | QDir::Type); + if ((sort & QDir::DirsFirst) == QDir::DirsFirst + || (sort & QDir::DirsLast) == QDir::DirsLast) { + if (info1.name.endsWith(QLatin1String("/")) && !info2.name.endsWith(QLatin1String("/"))) + return (sort & QDir::DirsFirst) == QDir::DirsFirst; + else if (!info1.name.endsWith(QLatin1String("/")) && info2.name.endsWith(QLatin1String("/"))) + return (sort & QDir::DirsLast) == QDir::DirsLast; + } + bool result; + int extDiff; + switch (order) { + case QDir::Name: + result = compareStrings(info1.name, info2.name) < 0; + break; + case QDir::Type: + extDiff = compareStrings(getExtension(info1.name), + getExtension(info2.name)); + if (extDiff == 0) { + result = compareStrings(info1.name, info2.name) < 0; + } else { + result = extDiff < 0; + } + break; + case QDir::Size: + if (info1.uncompressedSize == info2.uncompressedSize) { + result = compareStrings(info1.name, info2.name) < 0; + } else { + result = info1.uncompressedSize < info2.uncompressedSize; + } + break; + case QDir::Time: + if (info1.dateTime == info2.dateTime) { + result = compareStrings(info1.name, info2.name) < 0; + } else { + result = info1.dateTime < info2.dateTime; + } + break; + default: + qWarning("QuaZipDirComparator(): Invalid sort mode 0x%2X", + static_cast(sort)); + return false; + } + return (sort & QDir::Reversed) ? !result : result; +} + +template +bool QuaZipDirPrivate::entryInfoList(QStringList nameFilters, + QDir::Filters filter, QDir::SortFlags sort, TFileInfoList &result) const +{ + QString basePath = simplePath(); + if (!basePath.isEmpty()) + basePath += QLatin1String("/"); + int baseLength = basePath.length(); + result.clear(); + QuaZipDirRestoreCurrent saveCurrent(zip); + if (!zip->goToFirstFile()) { + return zip->getZipError() == UNZ_OK; + } + QDir::Filters fltr = filter; + if (fltr == QDir::NoFilter) + fltr = this->filter; + if (fltr == QDir::NoFilter) + fltr = QDir::AllEntries; + QStringList nmfltr = nameFilters; + if (nmfltr.isEmpty()) + nmfltr = this->nameFilters; + QSet dirsFound; + QList list; + do { + QString name = zip->getCurrentFileName(); + if (!name.startsWith(basePath)) + continue; + QString relativeName = name.mid(baseLength); + if (relativeName.isEmpty()) + continue; + bool isDir = false; + bool isReal = true; + if (relativeName.contains(QLatin1String("/"))) { + int indexOfSlash = relativeName.indexOf(QLatin1String("/")); + // something like "subdir/" + isReal = indexOfSlash == relativeName.length() - 1; + relativeName = relativeName.left(indexOfSlash + 1); + if (dirsFound.contains(relativeName)) + continue; + isDir = true; + } + dirsFound.insert(relativeName); + if ((fltr & QDir::Dirs) == 0 && isDir) + continue; + if ((fltr & QDir::Files) == 0 && !isDir) + continue; + if (!nmfltr.isEmpty() && !QDir::match(nmfltr, relativeName)) + continue; + bool ok; + QuaZipFileInfo64 info = QuaZipDir_getFileInfo(zip, &ok, relativeName, + isReal); + if (!ok) { + return false; + } + list.append(info); + } while (zip->goToNextFile()); + QDir::SortFlags srt = sort; + if (srt == QDir::NoSort) + srt = sorting; +#ifdef QUAZIP_QUAZIPDIR_DEBUG + qDebug("QuaZipDirPrivate::entryInfoList(): before sort:"); + foreach (QuaZipFileInfo64 info, list) { + qDebug("%s\t%s", info.name.toUtf8().constData(), + info.dateTime.toString(Qt::ISODate).toUtf8().constData()); + } +#endif + if (srt != QDir::NoSort && (srt & QDir::Unsorted) != QDir::Unsorted) { + if (QuaZip::convertCaseSensitivity(caseSensitivity) + == Qt::CaseInsensitive) + srt |= QDir::IgnoreCase; + QuaZipDirComparator lessThan(srt); +#if (QT_VERSION >= QT_VERSION_CHECK(5, 2, 0)) + std::sort(list.begin(), list.end(), lessThan); +#else + qSort(list.begin(), list.end(), lessThan); +#endif + } + QuaZipDir_convertInfoList(list, result); + return true; +} + +/// \endcond + +QList QuaZipDir::entryInfoList(const QStringList &nameFilters, + QDir::Filters filters, QDir::SortFlags sort) const +{ + QList result; + if (d->entryInfoList(nameFilters, filters, sort, result)) + return result; + else + return QList(); +} + +QList QuaZipDir::entryInfoList(QDir::Filters filters, + QDir::SortFlags sort) const +{ + return entryInfoList(QStringList(), filters, sort); +} + +QList QuaZipDir::entryInfoList64(const QStringList &nameFilters, + QDir::Filters filters, QDir::SortFlags sort) const +{ + QList result; + if (d->entryInfoList(nameFilters, filters, sort, result)) + return result; + else + return QList(); +} + +QList QuaZipDir::entryInfoList64(QDir::Filters filters, + QDir::SortFlags sort) const +{ + return entryInfoList64(QStringList(), filters, sort); +} + +QStringList QuaZipDir::entryList(const QStringList &nameFilters, + QDir::Filters filters, QDir::SortFlags sort) const +{ + QStringList result; + if (d->entryInfoList(nameFilters, filters, sort, result)) + return result; + else + return QStringList(); +} + +QStringList QuaZipDir::entryList(QDir::Filters filters, + QDir::SortFlags sort) const +{ + return entryList(QStringList(), filters, sort); +} + +bool QuaZipDir::exists(const QString &filePath) const +{ + if (filePath == QLatin1String("/") || filePath.isEmpty()) + return true; + QString fileName = filePath; + if (fileName.endsWith(QLatin1String("/"))) + fileName.chop(1); + if (fileName.contains(QLatin1String("/"))) { + QFileInfo fileInfo(fileName); +#ifdef QUAZIP_QUAZIPDIR_DEBUG + qDebug("QuaZipDir::exists(): fileName=%s, fileInfo.fileName()=%s, " + "fileInfo.path()=%s", fileName.toUtf8().constData(), + fileInfo.fileName().toUtf8().constData(), + fileInfo.path().toUtf8().constData()); +#endif + QuaZipDir dir(*this); + return dir.cd(fileInfo.path()) && dir.exists(fileInfo.fileName()); + } else { + if (fileName == QLatin1String("..")) { + return !isRoot(); + } else if (fileName == QLatin1String(".")) { + return true; + } else { + QStringList entries = entryList(QDir::AllEntries, QDir::NoSort); +#ifdef QUAZIP_QUAZIPDIR_DEBUG + qDebug("QuaZipDir::exists(): looking for %s", + fileName.toUtf8().constData()); + for (QStringList::const_iterator i = entries.constBegin(); + i != entries.constEnd(); + ++i) { + qDebug("QuaZipDir::exists(): entry: %s", + i->toUtf8().constData()); + } +#endif + Qt::CaseSensitivity cs = QuaZip::convertCaseSensitivity( + d->caseSensitivity); + if (filePath.endsWith(QLatin1String("/"))) { + return entries.contains(filePath, cs); + } else { + return entries.contains(fileName, cs) + || entries.contains(fileName + QLatin1String("/"), cs); + } + } + } +} + +bool QuaZipDir::exists() const +{ + return QuaZipDir(d->zip).exists(d->dir); +} + +QString QuaZipDir::filePath(const QString &fileName) const +{ + return QDir(d->dir).filePath(fileName); +} + +QDir::Filters QuaZipDir::filter() +{ + return d->filter; +} + +bool QuaZipDir::isRoot() const +{ + return d->simplePath().isEmpty(); +} + +QStringList QuaZipDir::nameFilters() const +{ + return d->nameFilters; +} + +QString QuaZipDir::path() const +{ + return d->dir; +} + +QString QuaZipDir::relativeFilePath(const QString &fileName) const +{ + return QDir(QLatin1String("/") + d->dir).relativeFilePath(fileName); +} + +void QuaZipDir::setCaseSensitivity(QuaZip::CaseSensitivity caseSensitivity) +{ + d->caseSensitivity = caseSensitivity; +} + +void QuaZipDir::setFilter(QDir::Filters filters) +{ + d->filter = filters; +} + +void QuaZipDir::setNameFilters(const QStringList &nameFilters) +{ + d->nameFilters = nameFilters; +} + +void QuaZipDir::setPath(const QString &path) +{ + QString newDir = path; + if (newDir == QLatin1String("/")) { + d->dir = QLatin1String(""); + } else { + if (newDir.endsWith(QLatin1String("/"))) + newDir.chop(1); + if (newDir.startsWith(QLatin1String("/"))) + newDir = newDir.mid(1); + d->dir = newDir; + } +} + +void QuaZipDir::setSorting(QDir::SortFlags sort) +{ + d->sorting = sort; +} + +QDir::SortFlags QuaZipDir::sorting() const +{ + return d->sorting; +} diff --git a/hecl-gui/quazip/quazip/quazipdir.h b/hecl-gui/quazip/quazip/quazipdir.h index f2a8d31c9..4626b1718 100644 --- a/hecl-gui/quazip/quazip/quazipdir.h +++ b/hecl-gui/quazip/quazip/quazipdir.h @@ -1,223 +1,223 @@ -#ifndef QUAZIP_QUAZIPDIR_H -#define QUAZIP_QUAZIPDIR_H - -/* -Copyright (C) 2005-2014 Sergey A. Tachenov - -This file is part of QuaZIP. - -QuaZIP is free software: you can redistribute it and/or modify -it under the terms of the GNU Lesser General Public License as published by -the Free Software Foundation, either version 3 of the License, or -(at your option) any later version. - -QuaZIP is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU Lesser General Public License for more details. - -You should have received a copy of the GNU Lesser General Public License -along with QuaZIP. If not, see . - -See COPYING file for the full LGPL text. - -Original ZIP package is copyrighted by Gilles Vollant and contributors, -see quazip/(un)zip.h files for details. Basically it's the zlib license. -*/ - -class QuaZipDirPrivate; - -#include "quazip.h" -#include "quazipfileinfo.h" -#include -#include -#include - -/// Provides ZIP archive navigation. -/** -* This class is modelled after QDir, and is designed to provide similar -* features for ZIP archives. -* -* The only significant difference from QDir is that the root path is not -* '/', but an empty string since that's how the file paths are stored in -* the archive. However, QuaZipDir understands the paths starting with -* '/'. It is important in a few places: -* -* - In the cd() function. -* - In the constructor. -* - In the exists() function. -* - In the relativePath() function. -* -* Note that since ZIP uses '/' on all platforms, the '\' separator is -* not supported. -*/ -class QUAZIP_EXPORT QuaZipDir { -private: - QSharedDataPointer d; -public: - /// The copy constructor. - QuaZipDir(const QuaZipDir &that); - /// Constructs a QuaZipDir instance pointing to the specified directory. - /** - If \a dir is not specified, points to the root of the archive. - The same happens if the \a dir is "/". - */ - QuaZipDir(QuaZip *zip, const QString &dir = QString()); - /// Destructor. - ~QuaZipDir(); - /// The assignment operator. - bool operator==(const QuaZipDir &that); - /// operator!= - /** - \return \c true if either this and \a that use different QuaZip - instances or if they point to different directories. - */ - inline bool operator!=(const QuaZipDir &that) {return !operator==(that);} - /// operator== - /** - \return \c true if both this and \a that use the same QuaZip - instance and point to the same directory. - */ - QuaZipDir& operator=(const QuaZipDir &that); - /// Returns the name of the entry at the specified position. - QString operator[](int pos) const; - /// Returns the current case sensitivity mode. - QuaZip::CaseSensitivity caseSensitivity() const; - /// Changes the 'current' directory. - /** - * If the path starts with '/', it is interpreted as an absolute - * path from the root of the archive. Otherwise, it is interpreted - * as a path relative to the current directory as was set by the - * previous cd() or the constructor. - * - * Note that the subsequent path() call will not return a path - * starting with '/' in all cases. - */ - bool cd(const QString &dirName); - /// Goes up. - bool cdUp(); - /// Returns the number of entries in the directory. - uint count() const; - /// Returns the current directory name. - /** - The name doesn't include the path. - */ - QString dirName() const; - /// Returns the list of the entries in the directory. - /** - \param nameFilters The list of file patterns to list, uses the same - syntax as QDir. - \param filters The entry type filters, only Files and Dirs are - accepted. - \param sort Sorting mode. - */ - QList entryInfoList(const QStringList &nameFilters, - QDir::Filters filters = QDir::NoFilter, - QDir::SortFlags sort = QDir::NoSort) const; - /// Returns the list of the entries in the directory. - /** - \overload - - The same as entryInfoList(QStringList(), filters, sort). - */ - QList entryInfoList(QDir::Filters filters = QDir::NoFilter, - QDir::SortFlags sort = QDir::NoSort) const; - /// Returns the list of the entries in the directory with zip64 support. - /** - \param nameFilters The list of file patterns to list, uses the same - syntax as QDir. - \param filters The entry type filters, only Files and Dirs are - accepted. - \param sort Sorting mode. - */ - QList entryInfoList64(const QStringList &nameFilters, - QDir::Filters filters = QDir::NoFilter, - QDir::SortFlags sort = QDir::NoSort) const; - /// Returns the list of the entries in the directory with zip64 support. - /** - \overload - - The same as entryInfoList64(QStringList(), filters, sort). - */ - QList entryInfoList64(QDir::Filters filters = QDir::NoFilter, - QDir::SortFlags sort = QDir::NoSort) const; - /// Returns the list of the entry names in the directory. - /** - The same as entryInfoList(nameFilters, filters, sort), but only - returns entry names. - */ - QStringList entryList(const QStringList &nameFilters, - QDir::Filters filters = QDir::NoFilter, - QDir::SortFlags sort = QDir::NoSort) const; - /// Returns the list of the entry names in the directory. - /** - \overload - - The same as entryList(QStringList(), filters, sort). - */ - QStringList entryList(QDir::Filters filters = QDir::NoFilter, - QDir::SortFlags sort = QDir::NoSort) const; - /// Returns \c true if the entry with the specified name exists. - /** - The ".." is considered to exist if the current directory - is not root. The "." and "/" are considered to - always exist. Paths starting with "/" are relative to - the archive root, other paths are relative to the current dir. - */ - bool exists(const QString &fileName) const; - /// Return \c true if the directory pointed by this QuaZipDir exists. - bool exists() const; - /// Returns the full path to the specified file. - /** - Doesn't check if the file actually exists. - */ - QString filePath(const QString &fileName) const; - /// Returns the default filter. - QDir::Filters filter(); - /// Returns if the QuaZipDir points to the root of the archive. - /** - Not that the root path is the empty string, not '/'. - */ - bool isRoot() const; - /// Return the default name filter. - QStringList nameFilters() const; - /// Returns the path to the current dir. - /** - The path never starts with '/', and the root path is an empty - string. - */ - QString path() const; - /// Returns the path to the specified file relative to the current dir. - /** - * This function is mostly useless, provided only for the sake of - * completeness. - * - * @param fileName The path to the file, should start with "/" - * if relative to the archive root. - * @return Path relative to the current dir. - */ - QString relativeFilePath(const QString &fileName) const; - /// Sets the default case sensitivity mode. - void setCaseSensitivity(QuaZip::CaseSensitivity caseSensitivity); - /// Sets the default filter. - void setFilter(QDir::Filters filters); - /// Sets the default name filter. - void setNameFilters(const QStringList &nameFilters); - /// Goes to the specified path. - /** - The difference from cd() is that this function never checks if the - path actually exists and doesn't use relative paths, so it's - possible to go to the root directory with setPath(""). - - Note that this function still chops the trailing and/or leading - '/' and treats a single '/' as the root path (path() will still - return an empty string). - */ - void setPath(const QString &path); - /// Sets the default sorting mode. - void setSorting(QDir::SortFlags sort); - /// Returns the default sorting mode. - QDir::SortFlags sorting() const; -}; - -#endif // QUAZIP_QUAZIPDIR_H +#ifndef QUAZIP_QUAZIPDIR_H +#define QUAZIP_QUAZIPDIR_H + +/* +Copyright (C) 2005-2014 Sergey A. Tachenov + +This file is part of QuaZIP. + +QuaZIP is free software: you can redistribute it and/or modify +it under the terms of the GNU Lesser General Public License as published by +the Free Software Foundation, either version 2.1 of the License, or +(at your option) any later version. + +QuaZIP is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU Lesser General Public License for more details. + +You should have received a copy of the GNU Lesser General Public License +along with QuaZIP. If not, see . + +See COPYING file for the full LGPL text. + +Original ZIP package is copyrighted by Gilles Vollant and contributors, +see quazip/(un)zip.h files for details. Basically it's the zlib license. +*/ + +class QuaZipDirPrivate; + +#include "quazip.h" +#include "quazipfileinfo.h" +#include +#include +#include + +/// Provides ZIP archive navigation. +/** +* This class is modelled after QDir, and is designed to provide similar +* features for ZIP archives. +* +* The only significant difference from QDir is that the root path is not +* '/', but an empty string since that's how the file paths are stored in +* the archive. However, QuaZipDir understands the paths starting with +* '/'. It is important in a few places: +* +* - In the cd() function. +* - In the constructor. +* - In the exists() function. +* - In the relativePath() function. +* +* Note that since ZIP uses '/' on all platforms, the '\' separator is +* not supported. +*/ +class QUAZIP_EXPORT QuaZipDir { +private: + QSharedDataPointer d; +public: + /// The copy constructor. + QuaZipDir(const QuaZipDir &that); + /// Constructs a QuaZipDir instance pointing to the specified directory. + /** + If \a dir is not specified, points to the root of the archive. + The same happens if the \a dir is "/". + */ + QuaZipDir(QuaZip *zip, const QString &dir = QString()); + /// Destructor. + ~QuaZipDir(); + /// The assignment operator. + bool operator==(const QuaZipDir &that); + /// operator!= + /** + \return \c true if either this and \a that use different QuaZip + instances or if they point to different directories. + */ + inline bool operator!=(const QuaZipDir &that) {return !operator==(that);} + /// operator== + /** + \return \c true if both this and \a that use the same QuaZip + instance and point to the same directory. + */ + QuaZipDir& operator=(const QuaZipDir &that); + /// Returns the name of the entry at the specified position. + QString operator[](int pos) const; + /// Returns the current case sensitivity mode. + QuaZip::CaseSensitivity caseSensitivity() const; + /// Changes the 'current' directory. + /** + * If the path starts with '/', it is interpreted as an absolute + * path from the root of the archive. Otherwise, it is interpreted + * as a path relative to the current directory as was set by the + * previous cd() or the constructor. + * + * Note that the subsequent path() call will not return a path + * starting with '/' in all cases. + */ + bool cd(const QString &dirName); + /// Goes up. + bool cdUp(); + /// Returns the number of entries in the directory. + uint count() const; + /// Returns the current directory name. + /** + The name doesn't include the path. + */ + QString dirName() const; + /// Returns the list of the entries in the directory. + /** + \param nameFilters The list of file patterns to list, uses the same + syntax as QDir. + \param filters The entry type filters, only Files and Dirs are + accepted. + \param sort Sorting mode. + */ + QList entryInfoList(const QStringList &nameFilters, + QDir::Filters filters = QDir::NoFilter, + QDir::SortFlags sort = QDir::NoSort) const; + /// Returns the list of the entries in the directory. + /** + \overload + + The same as entryInfoList(QStringList(), filters, sort). + */ + QList entryInfoList(QDir::Filters filters = QDir::NoFilter, + QDir::SortFlags sort = QDir::NoSort) const; + /// Returns the list of the entries in the directory with zip64 support. + /** + \param nameFilters The list of file patterns to list, uses the same + syntax as QDir. + \param filters The entry type filters, only Files and Dirs are + accepted. + \param sort Sorting mode. + */ + QList entryInfoList64(const QStringList &nameFilters, + QDir::Filters filters = QDir::NoFilter, + QDir::SortFlags sort = QDir::NoSort) const; + /// Returns the list of the entries in the directory with zip64 support. + /** + \overload + + The same as entryInfoList64(QStringList(), filters, sort). + */ + QList entryInfoList64(QDir::Filters filters = QDir::NoFilter, + QDir::SortFlags sort = QDir::NoSort) const; + /// Returns the list of the entry names in the directory. + /** + The same as entryInfoList(nameFilters, filters, sort), but only + returns entry names. + */ + QStringList entryList(const QStringList &nameFilters, + QDir::Filters filters = QDir::NoFilter, + QDir::SortFlags sort = QDir::NoSort) const; + /// Returns the list of the entry names in the directory. + /** + \overload + + The same as entryList(QStringList(), filters, sort). + */ + QStringList entryList(QDir::Filters filters = QDir::NoFilter, + QDir::SortFlags sort = QDir::NoSort) const; + /// Returns \c true if the entry with the specified name exists. + /** + The ".." is considered to exist if the current directory + is not root. The "." and "/" are considered to + always exist. Paths starting with "/" are relative to + the archive root, other paths are relative to the current dir. + */ + bool exists(const QString &fileName) const; + /// Return \c true if the directory pointed by this QuaZipDir exists. + bool exists() const; + /// Returns the full path to the specified file. + /** + Doesn't check if the file actually exists. + */ + QString filePath(const QString &fileName) const; + /// Returns the default filter. + QDir::Filters filter(); + /// Returns if the QuaZipDir points to the root of the archive. + /** + Not that the root path is the empty string, not '/'. + */ + bool isRoot() const; + /// Return the default name filter. + QStringList nameFilters() const; + /// Returns the path to the current dir. + /** + The path never starts with '/', and the root path is an empty + string. + */ + QString path() const; + /// Returns the path to the specified file relative to the current dir. + /** + * This function is mostly useless, provided only for the sake of + * completeness. + * + * @param fileName The path to the file, should start with "/" + * if relative to the archive root. + * @return Path relative to the current dir. + */ + QString relativeFilePath(const QString &fileName) const; + /// Sets the default case sensitivity mode. + void setCaseSensitivity(QuaZip::CaseSensitivity caseSensitivity); + /// Sets the default filter. + void setFilter(QDir::Filters filters); + /// Sets the default name filter. + void setNameFilters(const QStringList &nameFilters); + /// Goes to the specified path. + /** + The difference from cd() is that this function never checks if the + path actually exists and doesn't use relative paths, so it's + possible to go to the root directory with setPath(""). + + Note that this function still chops the trailing and/or leading + '/' and treats a single '/' as the root path (path() will still + return an empty string). + */ + void setPath(const QString &path); + /// Sets the default sorting mode. + void setSorting(QDir::SortFlags sort); + /// Returns the default sorting mode. + QDir::SortFlags sorting() const; +}; + +#endif // QUAZIP_QUAZIPDIR_H diff --git a/hecl-gui/quazip/quazip/quazipfile.cpp b/hecl-gui/quazip/quazip/quazipfile.cpp index 77a9375d7..0bf72c30e 100644 --- a/hecl-gui/quazip/quazip/quazipfile.cpp +++ b/hecl-gui/quazip/quazip/quazipfile.cpp @@ -1,502 +1,541 @@ -/* -Copyright (C) 2005-2014 Sergey A. Tachenov - -This file is part of QuaZIP. - -QuaZIP is free software: you can redistribute it and/or modify -it under the terms of the GNU Lesser General Public License as published by -the Free Software Foundation, either version 3 of the License, or -(at your option) any later version. - -QuaZIP is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU Lesser General Public License for more details. - -You should have received a copy of the GNU Lesser General Public License -along with QuaZIP. If not, see . - -See COPYING file for the full LGPL text. - -Original ZIP package is copyrighted by Gilles Vollant, see -quazip/(un)zip.h files for details, basically it's zlib license. - **/ - -#include "quazipfile.h" - -using namespace std; - -/// The implementation class for QuaZip. -/** -\internal - -This class contains all the private stuff for the QuaZipFile class, thus -allowing to preserve binary compatibility between releases, the -technique known as the Pimpl (private implementation) idiom. -*/ -class QuaZipFilePrivate { - friend class QuaZipFile; - private: - /// The pointer to the associated QuaZipFile instance. - QuaZipFile *q; - /// The QuaZip object to work with. - QuaZip *zip; - /// The file name. - QString fileName; - /// Case sensitivity mode. - QuaZip::CaseSensitivity caseSensitivity; - /// Whether this file is opened in the raw mode. - bool raw; - /// Write position to keep track of. - /** - QIODevice::pos() is broken for non-seekable devices, so we need - our own position. - */ - qint64 writePos; - /// Uncompressed size to write along with a raw file. - quint64 uncompressedSize; - /// CRC to write along with a raw file. - quint32 crc; - /// Whether \ref zip points to an internal QuaZip instance. - /** - This is true if the archive was opened by name, rather than by - supplying an existing QuaZip instance. - */ - bool internal; - /// The last error. - int zipError; - /// Resets \ref zipError. - inline void resetZipError() const {setZipError(UNZ_OK);} - /// Sets the zip error. - /** - This function is marked as const although it changes one field. - This allows to call it from const functions that don't change - anything by themselves. - */ - void setZipError(int zipError) const; - /// The constructor for the corresponding QuaZipFile constructor. - inline QuaZipFilePrivate(QuaZipFile *q): - q(q), zip(NULL), internal(true), zipError(UNZ_OK) {} - /// The constructor for the corresponding QuaZipFile constructor. - inline QuaZipFilePrivate(QuaZipFile *q, const QString &zipName): - q(q), internal(true), zipError(UNZ_OK) - { - zip=new QuaZip(zipName); - } - /// The constructor for the corresponding QuaZipFile constructor. - inline QuaZipFilePrivate(QuaZipFile *q, const QString &zipName, const QString &fileName, - QuaZip::CaseSensitivity cs): - q(q), internal(true), zipError(UNZ_OK) - { - zip=new QuaZip(zipName); - this->fileName=fileName; - if (this->fileName.startsWith('/')) - this->fileName = this->fileName.mid(1); - this->caseSensitivity=cs; - } - /// The constructor for the QuaZipFile constructor accepting a file name. - inline QuaZipFilePrivate(QuaZipFile *q, QuaZip *zip): - q(q), zip(zip), internal(false), zipError(UNZ_OK) {} - /// The destructor. - inline ~QuaZipFilePrivate() - { - if (internal) - delete zip; - } -}; - -QuaZipFile::QuaZipFile(): - p(new QuaZipFilePrivate(this)) -{ -} - -QuaZipFile::QuaZipFile(QObject *parent): - QIODevice(parent), - p(new QuaZipFilePrivate(this)) -{ -} - -QuaZipFile::QuaZipFile(const QString& zipName, QObject *parent): - QIODevice(parent), - p(new QuaZipFilePrivate(this, zipName)) -{ -} - -QuaZipFile::QuaZipFile(const QString& zipName, const QString& fileName, - QuaZip::CaseSensitivity cs, QObject *parent): - QIODevice(parent), - p(new QuaZipFilePrivate(this, zipName, fileName, cs)) -{ -} - -QuaZipFile::QuaZipFile(QuaZip *zip, QObject *parent): - QIODevice(parent), - p(new QuaZipFilePrivate(this, zip)) -{ -} - -QuaZipFile::~QuaZipFile() -{ - if (isOpen()) - close(); - delete p; -} - -QString QuaZipFile::getZipName() const -{ - return p->zip==NULL ? QString() : p->zip->getZipName(); -} - -QuaZip *QuaZipFile::getZip() const -{ - return p->internal ? NULL : p->zip; -} - -QString QuaZipFile::getActualFileName()const -{ - p->setZipError(UNZ_OK); - if (p->zip == NULL || (openMode() & WriteOnly)) - return QString(); - QString name=p->zip->getCurrentFileName(); - if(name.isNull()) - p->setZipError(p->zip->getZipError()); - return name; -} - -void QuaZipFile::setZipName(const QString& zipName) -{ - if(isOpen()) { - qWarning("QuaZipFile::setZipName(): file is already open - can not set ZIP name"); - return; - } - if(p->zip!=NULL && p->internal) - delete p->zip; - p->zip=new QuaZip(zipName); - p->internal=true; -} - -void QuaZipFile::setZip(QuaZip *zip) -{ - if(isOpen()) { - qWarning("QuaZipFile::setZip(): file is already open - can not set ZIP"); - return; - } - if(p->zip!=NULL && p->internal) - delete p->zip; - p->zip=zip; - p->fileName=QString(); - p->internal=false; -} - -void QuaZipFile::setFileName(const QString& fileName, QuaZip::CaseSensitivity cs) -{ - if(p->zip==NULL) { - qWarning("QuaZipFile::setFileName(): call setZipName() first"); - return; - } - if(!p->internal) { - qWarning("QuaZipFile::setFileName(): should not be used when not using internal QuaZip"); - return; - } - if(isOpen()) { - qWarning("QuaZipFile::setFileName(): can not set file name for already opened file"); - return; - } - p->fileName=fileName; - if (p->fileName.startsWith('/')) - p->fileName = p->fileName.mid(1); - p->caseSensitivity=cs; -} - -void QuaZipFilePrivate::setZipError(int zipError) const -{ - QuaZipFilePrivate *fakeThis = const_cast(this); // non-const - fakeThis->zipError=zipError; - if(zipError==UNZ_OK) - q->setErrorString(QString()); - else - q->setErrorString(QuaZipFile::tr("ZIP/UNZIP API error %1").arg(zipError)); -} - -bool QuaZipFile::open(OpenMode mode) -{ - return open(mode, NULL); -} - -bool QuaZipFile::open(OpenMode mode, int *method, int *level, bool raw, const char *password) -{ - p->resetZipError(); - if(isOpen()) { - qWarning("QuaZipFile::open(): already opened"); - return false; - } - if(mode&Unbuffered) { - qWarning("QuaZipFile::open(): Unbuffered mode is not supported"); - return false; - } - if((mode&ReadOnly)&&!(mode&WriteOnly)) { - if(p->internal) { - if(!p->zip->open(QuaZip::mdUnzip)) { - p->setZipError(p->zip->getZipError()); - return false; - } - if(!p->zip->setCurrentFile(p->fileName, p->caseSensitivity)) { - p->setZipError(p->zip->getZipError()); - p->zip->close(); - return false; - } - } else { - if(p->zip==NULL) { - qWarning("QuaZipFile::open(): zip is NULL"); - return false; - } - if(p->zip->getMode()!=QuaZip::mdUnzip) { - qWarning("QuaZipFile::open(): file open mode %d incompatible with ZIP open mode %d", - (int)mode, (int)p->zip->getMode()); - return false; - } - if(!p->zip->hasCurrentFile()) { - qWarning("QuaZipFile::open(): zip does not have current file"); - return false; - } - } - p->setZipError(unzOpenCurrentFile3(p->zip->getUnzFile(), method, level, (int)raw, password)); - if(p->zipError==UNZ_OK) { - setOpenMode(mode); - p->raw=raw; - return true; - } else - return false; - } - qWarning("QuaZipFile::open(): open mode %d not supported by this function", (int)mode); - return false; -} - -bool QuaZipFile::open(OpenMode mode, const QuaZipNewInfo& info, - const char *password, quint32 crc, - int method, int level, bool raw, - int windowBits, int memLevel, int strategy) -{ - zip_fileinfo info_z; - p->resetZipError(); - if(isOpen()) { - qWarning("QuaZipFile::open(): already opened"); - return false; - } - if((mode&WriteOnly)&&!(mode&ReadOnly)) { - if(p->internal) { - qWarning("QuaZipFile::open(): write mode is incompatible with internal QuaZip approach"); - return false; - } - if(p->zip==NULL) { - qWarning("QuaZipFile::open(): zip is NULL"); - return false; - } - if(p->zip->getMode()!=QuaZip::mdCreate&&p->zip->getMode()!=QuaZip::mdAppend&&p->zip->getMode()!=QuaZip::mdAdd) { - qWarning("QuaZipFile::open(): file open mode %d incompatible with ZIP open mode %d", - (int)mode, (int)p->zip->getMode()); - return false; - } - info_z.tmz_date.tm_year=info.dateTime.date().year(); - info_z.tmz_date.tm_mon=info.dateTime.date().month() - 1; - info_z.tmz_date.tm_mday=info.dateTime.date().day(); - info_z.tmz_date.tm_hour=info.dateTime.time().hour(); - info_z.tmz_date.tm_min=info.dateTime.time().minute(); - info_z.tmz_date.tm_sec=info.dateTime.time().second(); - info_z.dosDate = 0; - info_z.internal_fa=(uLong)info.internalAttr; - info_z.external_fa=(uLong)info.externalAttr; - if (p->zip->isDataDescriptorWritingEnabled()) - zipSetFlags(p->zip->getZipFile(), ZIP_WRITE_DATA_DESCRIPTOR); - else - zipClearFlags(p->zip->getZipFile(), ZIP_WRITE_DATA_DESCRIPTOR); - p->setZipError(zipOpenNewFileInZip3_64(p->zip->getZipFile(), - p->zip->getFileNameCodec()->fromUnicode(info.name).constData(), &info_z, - info.extraLocal.constData(), info.extraLocal.length(), - info.extraGlobal.constData(), info.extraGlobal.length(), - p->zip->getCommentCodec()->fromUnicode(info.comment).constData(), - method, level, (int)raw, - windowBits, memLevel, strategy, - password, (uLong)crc, p->zip->isZip64Enabled())); - if(p->zipError==UNZ_OK) { - p->writePos=0; - setOpenMode(mode); - p->raw=raw; - if(raw) { - p->crc=crc; - p->uncompressedSize=info.uncompressedSize; - } - return true; - } else - return false; - } - qWarning("QuaZipFile::open(): open mode %d not supported by this function", (int)mode); - return false; -} - -bool QuaZipFile::isSequential()const -{ - return true; -} - -qint64 QuaZipFile::pos()const -{ - if(p->zip==NULL) { - qWarning("QuaZipFile::pos(): call setZipName() or setZip() first"); - return -1; - } - if(!isOpen()) { - qWarning("QuaZipFile::pos(): file is not open"); - return -1; - } - if(openMode()&ReadOnly) - // QIODevice::pos() is broken for sequential devices, - // but thankfully bytesAvailable() returns the number of - // bytes buffered, so we know how far ahead we are. - return unztell(p->zip->getUnzFile()) - QIODevice::bytesAvailable(); - else - return p->writePos; -} - -bool QuaZipFile::atEnd()const -{ - if(p->zip==NULL) { - qWarning("QuaZipFile::atEnd(): call setZipName() or setZip() first"); - return false; - } - if(!isOpen()) { - qWarning("QuaZipFile::atEnd(): file is not open"); - return false; - } - if(openMode()&ReadOnly) - // the same problem as with pos() - return QIODevice::bytesAvailable() == 0 - && unzeof(p->zip->getUnzFile())==1; - else - return true; -} - -qint64 QuaZipFile::size()const -{ - if(!isOpen()) { - qWarning("QuaZipFile::atEnd(): file is not open"); - return -1; - } - if(openMode()&ReadOnly) - return p->raw?csize():usize(); - else - return p->writePos; -} - -qint64 QuaZipFile::csize()const -{ - unz_file_info64 info_z; - p->setZipError(UNZ_OK); - if(p->zip==NULL||p->zip->getMode()!=QuaZip::mdUnzip) return -1; - p->setZipError(unzGetCurrentFileInfo64(p->zip->getUnzFile(), &info_z, NULL, 0, NULL, 0, NULL, 0)); - if(p->zipError!=UNZ_OK) - return -1; - return info_z.compressed_size; -} - -qint64 QuaZipFile::usize()const -{ - unz_file_info64 info_z; - p->setZipError(UNZ_OK); - if(p->zip==NULL||p->zip->getMode()!=QuaZip::mdUnzip) return -1; - p->setZipError(unzGetCurrentFileInfo64(p->zip->getUnzFile(), &info_z, NULL, 0, NULL, 0, NULL, 0)); - if(p->zipError!=UNZ_OK) - return -1; - return info_z.uncompressed_size; -} - -bool QuaZipFile::getFileInfo(QuaZipFileInfo *info) -{ - QuaZipFileInfo64 info64; - if (getFileInfo(&info64)) { - info64.toQuaZipFileInfo(*info); - return true; - } else { - return false; - } -} - -bool QuaZipFile::getFileInfo(QuaZipFileInfo64 *info) -{ - if(p->zip==NULL||p->zip->getMode()!=QuaZip::mdUnzip) return false; - p->zip->getCurrentFileInfo(info); - p->setZipError(p->zip->getZipError()); - return p->zipError==UNZ_OK; -} - -void QuaZipFile::close() -{ - p->resetZipError(); - if(p->zip==NULL||!p->zip->isOpen()) return; - if(!isOpen()) { - qWarning("QuaZipFile::close(): file isn't open"); - return; - } - if(openMode()&ReadOnly) - p->setZipError(unzCloseCurrentFile(p->zip->getUnzFile())); - else if(openMode()&WriteOnly) - if(isRaw()) p->setZipError(zipCloseFileInZipRaw64(p->zip->getZipFile(), p->uncompressedSize, p->crc)); - else p->setZipError(zipCloseFileInZip(p->zip->getZipFile())); - else { - qWarning("Wrong open mode: %d", (int)openMode()); - return; - } - if(p->zipError==UNZ_OK) setOpenMode(QIODevice::NotOpen); - else return; - if(p->internal) { - p->zip->close(); - p->setZipError(p->zip->getZipError()); - } -} - -qint64 QuaZipFile::readData(char *data, qint64 maxSize) -{ - p->setZipError(UNZ_OK); - qint64 bytesRead=unzReadCurrentFile(p->zip->getUnzFile(), data, (unsigned)maxSize); - if (bytesRead < 0) { - p->setZipError((int) bytesRead); - return -1; - } - return bytesRead; -} - -qint64 QuaZipFile::writeData(const char* data, qint64 maxSize) -{ - p->setZipError(ZIP_OK); - p->setZipError(zipWriteInFileInZip(p->zip->getZipFile(), data, (uint)maxSize)); - if(p->zipError!=ZIP_OK) return -1; - else { - p->writePos+=maxSize; - return maxSize; - } -} - -QString QuaZipFile::getFileName() const -{ - return p->fileName; -} - -QuaZip::CaseSensitivity QuaZipFile::getCaseSensitivity() const -{ - return p->caseSensitivity; -} - -bool QuaZipFile::isRaw() const -{ - return p->raw; -} - -int QuaZipFile::getZipError() const -{ - return p->zipError; -} - -qint64 QuaZipFile::bytesAvailable() const -{ - return size() - pos(); -} +/* +Copyright (C) 2005-2014 Sergey A. Tachenov + +This file is part of QuaZIP. + +QuaZIP is free software: you can redistribute it and/or modify +it under the terms of the GNU Lesser General Public License as published by +the Free Software Foundation, either version 2.1 of the License, or +(at your option) any later version. + +QuaZIP is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU Lesser General Public License for more details. + +You should have received a copy of the GNU Lesser General Public License +along with QuaZIP. If not, see . + +See COPYING file for the full LGPL text. + +Original ZIP package is copyrighted by Gilles Vollant, see +quazip/(un)zip.h files for details, basically it's zlib license. + **/ + +#include "quazipfile.h" + +using namespace std; + +#define QUAZIP_VERSION_MADE_BY 0x1Eu + +/// The implementation class for QuaZip. +/** +\internal + +This class contains all the private stuff for the QuaZipFile class, thus +allowing to preserve binary compatibility between releases, the +technique known as the Pimpl (private implementation) idiom. +*/ +class QuaZipFilePrivate { + friend class QuaZipFile; + private: + Q_DISABLE_COPY(QuaZipFilePrivate) + /// The pointer to the associated QuaZipFile instance. + QuaZipFile *q; + /// The QuaZip object to work with. + QuaZip *zip; + /// The file name. + QString fileName; + /// Case sensitivity mode. + QuaZip::CaseSensitivity caseSensitivity; + /// Whether this file is opened in the raw mode. + bool raw; + /// Write position to keep track of. + /** + QIODevice::pos() is broken for non-seekable devices, so we need + our own position. + */ + qint64 writePos; + /// Uncompressed size to write along with a raw file. + quint64 uncompressedSize; + /// CRC to write along with a raw file. + quint32 crc; + /// Whether \ref zip points to an internal QuaZip instance. + /** + This is true if the archive was opened by name, rather than by + supplying an existing QuaZip instance. + */ + bool internal; + /// The last error. + int zipError; + /// Resets \ref zipError. + inline void resetZipError() const {setZipError(UNZ_OK);} + /// Sets the zip error. + /** + This function is marked as const although it changes one field. + This allows to call it from const functions that don't change + anything by themselves. + */ + void setZipError(int zipError) const; + /// The constructor for the corresponding QuaZipFile constructor. + inline QuaZipFilePrivate(QuaZipFile *q): + q(q), + zip(NULL), + caseSensitivity(QuaZip::csDefault), + raw(false), + writePos(0), + uncompressedSize(0), + crc(0), + internal(true), + zipError(UNZ_OK) {} + /// The constructor for the corresponding QuaZipFile constructor. + inline QuaZipFilePrivate(QuaZipFile *q, const QString &zipName): + q(q), + caseSensitivity(QuaZip::csDefault), + raw(false), + writePos(0), + uncompressedSize(0), + crc(0), + internal(true), + zipError(UNZ_OK) + { + zip=new QuaZip(zipName); + } + /// The constructor for the corresponding QuaZipFile constructor. + inline QuaZipFilePrivate(QuaZipFile *q, const QString &zipName, const QString &fileName, + QuaZip::CaseSensitivity cs): + q(q), + raw(false), + writePos(0), + uncompressedSize(0), + crc(0), + internal(true), + zipError(UNZ_OK) + { + zip=new QuaZip(zipName); + this->fileName=fileName; + if (this->fileName.startsWith(QLatin1String("/"))) + this->fileName = this->fileName.mid(1); + this->caseSensitivity=cs; + } + /// The constructor for the QuaZipFile constructor accepting a file name. + inline QuaZipFilePrivate(QuaZipFile *q, QuaZip *zip): + q(q), + zip(zip), + raw(false), + writePos(0), + uncompressedSize(0), + crc(0), + internal(false), + zipError(UNZ_OK) {} + /// The destructor. + inline ~QuaZipFilePrivate() + { + if (internal) + delete zip; + } +}; + +QuaZipFile::QuaZipFile(): + p(new QuaZipFilePrivate(this)) +{ +} + +QuaZipFile::QuaZipFile(QObject *parent): + QIODevice(parent), + p(new QuaZipFilePrivate(this)) +{ +} + +QuaZipFile::QuaZipFile(const QString& zipName, QObject *parent): + QIODevice(parent), + p(new QuaZipFilePrivate(this, zipName)) +{ +} + +QuaZipFile::QuaZipFile(const QString& zipName, const QString& fileName, + QuaZip::CaseSensitivity cs, QObject *parent): + QIODevice(parent), + p(new QuaZipFilePrivate(this, zipName, fileName, cs)) +{ +} + +QuaZipFile::QuaZipFile(QuaZip *zip, QObject *parent): + QIODevice(parent), + p(new QuaZipFilePrivate(this, zip)) +{ +} + +QuaZipFile::~QuaZipFile() +{ + if (isOpen()) + close(); + delete p; +} + +QString QuaZipFile::getZipName() const +{ + return p->zip==NULL ? QString() : p->zip->getZipName(); +} + +QuaZip *QuaZipFile::getZip() const +{ + return p->internal ? NULL : p->zip; +} + +QString QuaZipFile::getActualFileName()const +{ + p->setZipError(UNZ_OK); + if (p->zip == NULL || (openMode() & WriteOnly)) + return QString(); + QString name=p->zip->getCurrentFileName(); + if(name.isNull()) + p->setZipError(p->zip->getZipError()); + return name; +} + +void QuaZipFile::setZipName(const QString& zipName) +{ + if(isOpen()) { + qWarning("QuaZipFile::setZipName(): file is already open - can not set ZIP name"); + return; + } + if(p->zip!=NULL && p->internal) + delete p->zip; + p->zip=new QuaZip(zipName); + p->internal=true; +} + +void QuaZipFile::setZip(QuaZip *zip) +{ + if(isOpen()) { + qWarning("QuaZipFile::setZip(): file is already open - can not set ZIP"); + return; + } + if(p->zip!=NULL && p->internal) + delete p->zip; + p->zip=zip; + p->fileName=QString(); + p->internal=false; +} + +void QuaZipFile::setFileName(const QString& fileName, QuaZip::CaseSensitivity cs) +{ + if(p->zip==NULL) { + qWarning("QuaZipFile::setFileName(): call setZipName() first"); + return; + } + if(!p->internal) { + qWarning("QuaZipFile::setFileName(): should not be used when not using internal QuaZip"); + return; + } + if(isOpen()) { + qWarning("QuaZipFile::setFileName(): can not set file name for already opened file"); + return; + } + p->fileName=fileName; + if (p->fileName.startsWith(QLatin1String("/"))) + p->fileName = p->fileName.mid(1); + p->caseSensitivity=cs; +} + +void QuaZipFilePrivate::setZipError(int zipError) const +{ + QuaZipFilePrivate *fakeThis = const_cast(this); // non-const + fakeThis->zipError=zipError; + if(zipError==UNZ_OK) + q->setErrorString(QString()); + else + q->setErrorString(QuaZipFile::tr("ZIP/UNZIP API error %1").arg(zipError)); +} + +bool QuaZipFile::open(OpenMode mode) +{ + return open(mode, NULL); +} + +bool QuaZipFile::open(OpenMode mode, int *method, int *level, bool raw, const char *password) +{ + p->resetZipError(); + if(isOpen()) { + qWarning("QuaZipFile::open(): already opened"); + return false; + } + if(mode&Unbuffered) { + qWarning("QuaZipFile::open(): Unbuffered mode is not supported"); + return false; + } + if((mode&ReadOnly)&&!(mode&WriteOnly)) { + if(p->internal) { + if(!p->zip->open(QuaZip::mdUnzip)) { + p->setZipError(p->zip->getZipError()); + return false; + } + if(!p->zip->setCurrentFile(p->fileName, p->caseSensitivity)) { + p->setZipError(p->zip->getZipError()); + p->zip->close(); + return false; + } + } else { + if(p->zip==NULL) { + qWarning("QuaZipFile::open(): zip is NULL"); + return false; + } + if(p->zip->getMode()!=QuaZip::mdUnzip) { + qWarning("QuaZipFile::open(): file open mode %d incompatible with ZIP open mode %d", + (int)mode, (int)p->zip->getMode()); + return false; + } + if(!p->zip->hasCurrentFile()) { + qWarning("QuaZipFile::open(): zip does not have current file"); + return false; + } + } + p->setZipError(unzOpenCurrentFile3(p->zip->getUnzFile(), method, level, (int)raw, password)); + if(p->zipError==UNZ_OK) { + setOpenMode(mode); + p->raw=raw; + return true; + } else + return false; + } + qWarning("QuaZipFile::open(): open mode %d not supported by this function", (int)mode); + return false; +} + +bool QuaZipFile::open(OpenMode mode, const QuaZipNewInfo& info, + const char *password, quint32 crc, + int method, int level, bool raw, + int windowBits, int memLevel, int strategy) +{ + zip_fileinfo info_z; + p->resetZipError(); + if(isOpen()) { + qWarning("QuaZipFile::open(): already opened"); + return false; + } + if((mode&WriteOnly)&&!(mode&ReadOnly)) { + if(p->internal) { + qWarning("QuaZipFile::open(): write mode is incompatible with internal QuaZip approach"); + return false; + } + if(p->zip==NULL) { + qWarning("QuaZipFile::open(): zip is NULL"); + return false; + } + if(p->zip->getMode()!=QuaZip::mdCreate&&p->zip->getMode()!=QuaZip::mdAppend&&p->zip->getMode()!=QuaZip::mdAdd) { + qWarning("QuaZipFile::open(): file open mode %d incompatible with ZIP open mode %d", + (int)mode, (int)p->zip->getMode()); + return false; + } + info_z.tmz_date.tm_year=info.dateTime.date().year(); + info_z.tmz_date.tm_mon=info.dateTime.date().month() - 1; + info_z.tmz_date.tm_mday=info.dateTime.date().day(); + info_z.tmz_date.tm_hour=info.dateTime.time().hour(); + info_z.tmz_date.tm_min=info.dateTime.time().minute(); + info_z.tmz_date.tm_sec=info.dateTime.time().second(); + info_z.dosDate = 0; + info_z.internal_fa=(uLong)info.internalAttr; + info_z.external_fa=(uLong)info.externalAttr; + if (p->zip->isDataDescriptorWritingEnabled()) + zipSetFlags(p->zip->getZipFile(), ZIP_WRITE_DATA_DESCRIPTOR); + else + zipClearFlags(p->zip->getZipFile(), ZIP_WRITE_DATA_DESCRIPTOR); + p->setZipError(zipOpenNewFileInZip4_64(p->zip->getZipFile(), + p->zip->isUtf8Enabled() + ? info.name.toUtf8().constData() + : p->zip->getFileNameCodec()->fromUnicode(info.name).constData(), + &info_z, + info.extraLocal.constData(), info.extraLocal.length(), + info.extraGlobal.constData(), info.extraGlobal.length(), + p->zip->isUtf8Enabled() + ? info.comment.toUtf8().constData() + : p->zip->getCommentCodec()->fromUnicode(info.comment).constData(), + method, level, (int)raw, + windowBits, memLevel, strategy, + password, (uLong)crc, + (p->zip->getOsCode() << 8) | QUAZIP_VERSION_MADE_BY, + 0, + p->zip->isZip64Enabled())); + if(p->zipError==UNZ_OK) { + p->writePos=0; + setOpenMode(mode); + p->raw=raw; + if(raw) { + p->crc=crc; + p->uncompressedSize=info.uncompressedSize; + } + return true; + } else + return false; + } + qWarning("QuaZipFile::open(): open mode %d not supported by this function", (int)mode); + return false; +} + +bool QuaZipFile::isSequential()const +{ + return true; +} + +qint64 QuaZipFile::pos()const +{ + if(p->zip==NULL) { + qWarning("QuaZipFile::pos(): call setZipName() or setZip() first"); + return -1; + } + if(!isOpen()) { + qWarning("QuaZipFile::pos(): file is not open"); + return -1; + } + if(openMode()&ReadOnly) + // QIODevice::pos() is broken for sequential devices, + // but thankfully bytesAvailable() returns the number of + // bytes buffered, so we know how far ahead we are. + return unztell64(p->zip->getUnzFile()) - QIODevice::bytesAvailable(); + else + return p->writePos; +} + +bool QuaZipFile::atEnd()const +{ + if(p->zip==NULL) { + qWarning("QuaZipFile::atEnd(): call setZipName() or setZip() first"); + return false; + } + if(!isOpen()) { + qWarning("QuaZipFile::atEnd(): file is not open"); + return false; + } + if(openMode()&ReadOnly) + // the same problem as with pos() + return QIODevice::bytesAvailable() == 0 + && unzeof(p->zip->getUnzFile())==1; + else + return true; +} + +qint64 QuaZipFile::size()const +{ + if(!isOpen()) { + qWarning("QuaZipFile::atEnd(): file is not open"); + return -1; + } + if(openMode()&ReadOnly) + return p->raw?csize():usize(); + else + return p->writePos; +} + +qint64 QuaZipFile::csize()const +{ + unz_file_info64 info_z; + p->setZipError(UNZ_OK); + if(p->zip==NULL||p->zip->getMode()!=QuaZip::mdUnzip) return -1; + p->setZipError(unzGetCurrentFileInfo64(p->zip->getUnzFile(), &info_z, NULL, 0, NULL, 0, NULL, 0)); + if(p->zipError!=UNZ_OK) + return -1; + return info_z.compressed_size; +} + +qint64 QuaZipFile::usize()const +{ + unz_file_info64 info_z; + p->setZipError(UNZ_OK); + if(p->zip==NULL||p->zip->getMode()!=QuaZip::mdUnzip) return -1; + p->setZipError(unzGetCurrentFileInfo64(p->zip->getUnzFile(), &info_z, NULL, 0, NULL, 0, NULL, 0)); + if(p->zipError!=UNZ_OK) + return -1; + return info_z.uncompressed_size; +} + +bool QuaZipFile::getFileInfo(QuaZipFileInfo *info) +{ + QuaZipFileInfo64 info64; + if (getFileInfo(&info64)) { + info64.toQuaZipFileInfo(*info); + return true; + } else { + return false; + } +} + +bool QuaZipFile::getFileInfo(QuaZipFileInfo64 *info) +{ + if(p->zip==NULL||p->zip->getMode()!=QuaZip::mdUnzip) return false; + p->zip->getCurrentFileInfo(info); + p->setZipError(p->zip->getZipError()); + return p->zipError==UNZ_OK; +} + +void QuaZipFile::close() +{ + p->resetZipError(); + if(p->zip==NULL||!p->zip->isOpen()) return; + if(!isOpen()) { + qWarning("QuaZipFile::close(): file isn't open"); + return; + } + if(openMode()&ReadOnly) + p->setZipError(unzCloseCurrentFile(p->zip->getUnzFile())); + else if(openMode()&WriteOnly) + if(isRaw()) p->setZipError(zipCloseFileInZipRaw64(p->zip->getZipFile(), p->uncompressedSize, p->crc)); + else p->setZipError(zipCloseFileInZip(p->zip->getZipFile())); + else { + qWarning("Wrong open mode: %d", (int)openMode()); + return; + } + if(p->zipError==UNZ_OK) setOpenMode(QIODevice::NotOpen); + else return; + if(p->internal) { + p->zip->close(); + p->setZipError(p->zip->getZipError()); + } +} + +qint64 QuaZipFile::readData(char *data, qint64 maxSize) +{ + p->setZipError(UNZ_OK); + qint64 bytesRead=unzReadCurrentFile(p->zip->getUnzFile(), data, (unsigned)maxSize); + if (bytesRead < 0) { + p->setZipError((int) bytesRead); + return -1; + } + return bytesRead; +} + +qint64 QuaZipFile::writeData(const char* data, qint64 maxSize) +{ + p->setZipError(ZIP_OK); + p->setZipError(zipWriteInFileInZip(p->zip->getZipFile(), data, (uint)maxSize)); + if(p->zipError!=ZIP_OK) return -1; + else { + p->writePos+=maxSize; + return maxSize; + } +} + +QString QuaZipFile::getFileName() const +{ + return p->fileName; +} + +QuaZip::CaseSensitivity QuaZipFile::getCaseSensitivity() const +{ + return p->caseSensitivity; +} + +bool QuaZipFile::isRaw() const +{ + return p->raw; +} + +int QuaZipFile::getZipError() const +{ + return p->zipError; +} + +qint64 QuaZipFile::bytesAvailable() const +{ + return size() - pos(); +} diff --git a/hecl-gui/quazip/quazip/quazipfile.h b/hecl-gui/quazip/quazip/quazipfile.h index 787822640..e27b7a4a6 100644 --- a/hecl-gui/quazip/quazip/quazipfile.h +++ b/hecl-gui/quazip/quazip/quazipfile.h @@ -1,456 +1,456 @@ -#ifndef QUA_ZIPFILE_H -#define QUA_ZIPFILE_H - -/* -Copyright (C) 2005-2014 Sergey A. Tachenov - -This file is part of QuaZIP. - -QuaZIP is free software: you can redistribute it and/or modify -it under the terms of the GNU Lesser General Public License as published by -the Free Software Foundation, either version 3 of the License, or -(at your option) any later version. - -QuaZIP is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU Lesser General Public License for more details. - -You should have received a copy of the GNU Lesser General Public License -along with QuaZIP. If not, see . - -See COPYING file for the full LGPL text. - -Original ZIP package is copyrighted by Gilles Vollant, see -quazip/(un)zip.h files for details, basically it's zlib license. - **/ - -#include - -#include "quazip_global.h" -#include "quazip.h" -#include "quazipnewinfo.h" - -class QuaZipFilePrivate; - -/// A file inside ZIP archive. -/** \class QuaZipFile quazipfile.h - * This is the most interesting class. Not only it provides C++ - * interface to the ZIP/UNZIP package, but also integrates it with Qt by - * subclassing QIODevice. This makes possible to access files inside ZIP - * archive using QTextStream or QDataStream, for example. Actually, this - * is the main purpose of the whole QuaZIP library. - * - * You can either use existing QuaZip instance to create instance of - * this class or pass ZIP archive file name to this class, in which case - * it will create internal QuaZip object. See constructors' descriptions - * for details. Writing is only possible with the existing instance. - * - * Note that due to the underlying library's limitation it is not - * possible to use multiple QuaZipFile instances to open several files - * in the same archive at the same time. If you need to write to - * multiple files in parallel, then you should write to temporary files - * first, then pack them all at once when you have finished writing. If - * you need to read multiple files inside the same archive in parallel, - * you should extract them all into a temporary directory first. - * - * \section quazipfile-sequential Sequential or random-access? - * - * At the first thought, QuaZipFile has fixed size, the start and the - * end and should be therefore considered random-access device. But - * there is one major obstacle to making it random-access: ZIP/UNZIP API - * does not support seek() operation and the only way to implement it is - * through reopening the file and re-reading to the required position, - * but this is prohibitively slow. - * - * Therefore, QuaZipFile is considered to be a sequential device. This - * has advantage of availability of the ungetChar() operation (QIODevice - * does not implement it properly for non-sequential devices unless they - * support seek()). Disadvantage is a somewhat strange behaviour of the - * size() and pos() functions. This should be kept in mind while using - * this class. - * - **/ -class QUAZIP_EXPORT QuaZipFile: public QIODevice { - friend class QuaZipFilePrivate; - Q_OBJECT - private: - QuaZipFilePrivate *p; - // these are not supported nor implemented - QuaZipFile(const QuaZipFile& that); - QuaZipFile& operator=(const QuaZipFile& that); - protected: - /// Implementation of the QIODevice::readData(). - qint64 readData(char *data, qint64 maxSize); - /// Implementation of the QIODevice::writeData(). - qint64 writeData(const char *data, qint64 maxSize); - public: - /// Constructs a QuaZipFile instance. - /** You should use setZipName() and setFileName() or setZip() before - * trying to call open() on the constructed object. - **/ - QuaZipFile(); - /// Constructs a QuaZipFile instance. - /** \a parent argument specifies this object's parent object. - * - * You should use setZipName() and setFileName() or setZip() before - * trying to call open() on the constructed object. - **/ - QuaZipFile(QObject *parent); - /// Constructs a QuaZipFile instance. - /** \a parent argument specifies this object's parent object and \a - * zipName specifies ZIP archive file name. - * - * You should use setFileName() before trying to call open() on the - * constructed object. - * - * QuaZipFile constructed by this constructor can be used for read - * only access. Use QuaZipFile(QuaZip*,QObject*) for writing. - **/ - QuaZipFile(const QString& zipName, QObject *parent =NULL); - /// Constructs a QuaZipFile instance. - /** \a parent argument specifies this object's parent object, \a - * zipName specifies ZIP archive file name and \a fileName and \a cs - * specify a name of the file to open inside archive. - * - * QuaZipFile constructed by this constructor can be used for read - * only access. Use QuaZipFile(QuaZip*,QObject*) for writing. - * - * \sa QuaZip::setCurrentFile() - **/ - QuaZipFile(const QString& zipName, const QString& fileName, - QuaZip::CaseSensitivity cs =QuaZip::csDefault, QObject *parent =NULL); - /// Constructs a QuaZipFile instance. - /** \a parent argument specifies this object's parent object. - * - * \a zip is the pointer to the existing QuaZip object. This - * QuaZipFile object then can be used to read current file in the - * \a zip or to write to the file inside it. - * - * \warning Using this constructor for reading current file can be - * tricky. Let's take the following example: - * \code - * QuaZip zip("archive.zip"); - * zip.open(QuaZip::mdUnzip); - * zip.setCurrentFile("file-in-archive"); - * QuaZipFile file(&zip); - * file.open(QIODevice::ReadOnly); - * // ok, now we can read from the file - * file.read(somewhere, some); - * zip.setCurrentFile("another-file-in-archive"); // oops... - * QuaZipFile anotherFile(&zip); - * anotherFile.open(QIODevice::ReadOnly); - * anotherFile.read(somewhere, some); // this is still ok... - * file.read(somewhere, some); // and this is NOT - * \endcode - * So, what exactly happens here? When we change current file in the - * \c zip archive, \c file that references it becomes invalid - * (actually, as far as I understand ZIP/UNZIP sources, it becomes - * closed, but QuaZipFile has no means to detect it). - * - * Summary: do not close \c zip object or change its current file as - * long as QuaZipFile is open. Even better - use another constructors - * which create internal QuaZip instances, one per object, and - * therefore do not cause unnecessary trouble. This constructor may - * be useful, though, if you already have a QuaZip instance and do - * not want to access several files at once. Good example: - * \code - * QuaZip zip("archive.zip"); - * zip.open(QuaZip::mdUnzip); - * // first, we need some information about archive itself - * QByteArray comment=zip.getComment(); - * // and now we are going to access files inside it - * QuaZipFile file(&zip); - * for(bool more=zip.goToFirstFile(); more; more=zip.goToNextFile()) { - * file.open(QIODevice::ReadOnly); - * // do something cool with file here - * file.close(); // do not forget to close! - * } - * zip.close(); - * \endcode - **/ - QuaZipFile(QuaZip *zip, QObject *parent =NULL); - /// Destroys a QuaZipFile instance. - /** Closes file if open, destructs internal QuaZip object (if it - * exists and \em is internal, of course). - **/ - virtual ~QuaZipFile(); - /// Returns the ZIP archive file name. - /** If this object was created by passing QuaZip pointer to the - * constructor, this function will return that QuaZip's file name - * (or null string if that object does not have file name yet). - * - * Otherwise, returns associated ZIP archive file name or null - * string if there are no name set yet. - * - * \sa setZipName() getFileName() - **/ - QString getZipName()const; - /// Returns a pointer to the associated QuaZip object. - /** Returns \c NULL if there is no associated QuaZip or it is - * internal (so you will not mess with it). - **/ - QuaZip* getZip()const; - /// Returns file name. - /** This function returns file name you passed to this object either - * by using - * QuaZipFile(const QString&,const QString&,QuaZip::CaseSensitivity,QObject*) - * or by calling setFileName(). Real name of the file may differ in - * case if you used case-insensitivity. - * - * Returns null string if there is no file name set yet. This is the - * case when this QuaZipFile operates on the existing QuaZip object - * (constructor QuaZipFile(QuaZip*,QObject*) or setZip() was used). - * - * \sa getActualFileName - **/ - QString getFileName() const; - /// Returns case sensitivity of the file name. - /** This function returns case sensitivity argument you passed to - * this object either by using - * QuaZipFile(const QString&,const QString&,QuaZip::CaseSensitivity,QObject*) - * or by calling setFileName(). - * - * Returns unpredictable value if getFileName() returns null string - * (this is the case when you did not used setFileName() or - * constructor above). - * - * \sa getFileName - **/ - QuaZip::CaseSensitivity getCaseSensitivity() const; - /// Returns the actual file name in the archive. - /** This is \em not a ZIP archive file name, but a name of file inside - * archive. It is not necessary the same name that you have passed - * to the - * QuaZipFile(const QString&,const QString&,QuaZip::CaseSensitivity,QObject*), - * setFileName() or QuaZip::setCurrentFile() - this is the real file - * name inside archive, so it may differ in case if the file name - * search was case-insensitive. - * - * Equivalent to calling getCurrentFileName() on the associated - * QuaZip object. Returns null string if there is no associated - * QuaZip object or if it does not have a current file yet. And this - * is the case if you called setFileName() but did not open the - * file yet. So this is perfectly fine: - * \code - * QuaZipFile file("somezip.zip"); - * file.setFileName("somefile"); - * QString name=file.getName(); // name=="somefile" - * QString actual=file.getActualFileName(); // actual is null string - * file.open(QIODevice::ReadOnly); - * QString actual=file.getActualFileName(); // actual can be "SoMeFiLe" on Windows - * \endcode - * - * \sa getZipName(), getFileName(), QuaZip::CaseSensitivity - **/ - QString getActualFileName()const; - /// Sets the ZIP archive file name. - /** Automatically creates internal QuaZip object and destroys - * previously created internal QuaZip object, if any. - * - * Will do nothing if this file is already open. You must close() it - * first. - **/ - void setZipName(const QString& zipName); - /// Returns \c true if the file was opened in raw mode. - /** If the file is not open, the returned value is undefined. - * - * \sa open(OpenMode,int*,int*,bool,const char*) - **/ - bool isRaw() const; - /// Binds to the existing QuaZip instance. - /** This function destroys internal QuaZip object, if any, and makes - * this QuaZipFile to use current file in the \a zip object for any - * further operations. See QuaZipFile(QuaZip*,QObject*) for the - * possible pitfalls. - * - * Will do nothing if the file is currently open. You must close() - * it first. - **/ - void setZip(QuaZip *zip); - /// Sets the file name. - /** Will do nothing if at least one of the following conditions is - * met: - * - ZIP name has not been set yet (getZipName() returns null - * string). - * - This QuaZipFile is associated with external QuaZip. In this - * case you should call that QuaZip's setCurrentFile() function - * instead! - * - File is already open so setting the name is meaningless. - * - * \sa QuaZip::setCurrentFile - **/ - void setFileName(const QString& fileName, QuaZip::CaseSensitivity cs =QuaZip::csDefault); - /// Opens a file for reading. - /** Returns \c true on success, \c false otherwise. - * Call getZipError() to get error code. - * - * \note Since ZIP/UNZIP API provides buffered reading only, - * QuaZipFile does not support unbuffered reading. So do not pass - * QIODevice::Unbuffered flag in \a mode, or open will fail. - **/ - virtual bool open(OpenMode mode); - /// Opens a file for reading. - /** \overload - * Argument \a password specifies a password to decrypt the file. If - * it is NULL then this function behaves just like open(OpenMode). - **/ - inline bool open(OpenMode mode, const char *password) - {return open(mode, NULL, NULL, false, password);} - /// Opens a file for reading. - /** \overload - * Argument \a password specifies a password to decrypt the file. - * - * An integers pointed by \a method and \a level will receive codes - * of the compression method and level used. See unzip.h. - * - * If raw is \c true then no decompression is performed. - * - * \a method should not be \c NULL. \a level can be \c NULL if you - * don't want to know the compression level. - **/ - bool open(OpenMode mode, int *method, int *level, bool raw, const char *password =NULL); - /// Opens a file for writing. - /** \a info argument specifies information about file. It should at - * least specify a correct file name. Also, it is a good idea to - * specify correct timestamp (by default, current time will be - * used). See QuaZipNewInfo. - * - * The \a password argument specifies the password for crypting. Pass NULL - * if you don't need any crypting. The \a crc argument was supposed - * to be used for crypting too, but then it turned out that it's - * false information, so you need to set it to 0 unless you want to - * use the raw mode (see below). - * - * Arguments \a method and \a level specify compression method and - * level. The only method supported is Z_DEFLATED, but you may also - * specify 0 for no compression. If all of the files in the archive - * use both method 0 and either level 0 is explicitly specified or - * data descriptor writing is disabled with - * QuaZip::setDataDescriptorWritingEnabled(), then the - * resulting archive is supposed to be compatible with the 1.0 ZIP - * format version, should you need that. Except for this, \a level - * has no other effects with method 0. - * - * If \a raw is \c true, no compression is performed. In this case, - * \a crc and uncompressedSize field of the \a info are required. - * - * Arguments \a windowBits, \a memLevel, \a strategy provide zlib - * algorithms tuning. See deflateInit2() in zlib. - **/ - bool open(OpenMode mode, const QuaZipNewInfo& info, - const char *password =NULL, quint32 crc =0, - int method =Z_DEFLATED, int level =Z_DEFAULT_COMPRESSION, bool raw =false, - int windowBits =-MAX_WBITS, int memLevel =DEF_MEM_LEVEL, int strategy =Z_DEFAULT_STRATEGY); - /// Returns \c true, but \ref quazipfile-sequential "beware"! - virtual bool isSequential()const; - /// Returns current position in the file. - /** Implementation of the QIODevice::pos(). When reading, this - * function is a wrapper to the ZIP/UNZIP unztell(), therefore it is - * unable to keep track of the ungetChar() calls (which is - * non-virtual and therefore is dangerous to reimplement). So if you - * are using ungetChar() feature of the QIODevice, this function - * reports incorrect value until you get back characters which you - * ungot. - * - * When writing, pos() returns number of bytes already written - * (uncompressed unless you use raw mode). - * - * \note Although - * \ref quazipfile-sequential "QuaZipFile is a sequential device" - * and therefore pos() should always return zero, it does not, - * because it would be misguiding. Keep this in mind. - * - * This function returns -1 if the file or archive is not open. - * - * Error code returned by getZipError() is not affected by this - * function call. - **/ - virtual qint64 pos()const; - /// Returns \c true if the end of file was reached. - /** This function returns \c false in the case of error. This means - * that you called this function on either not open file, or a file - * in the not open archive or even on a QuaZipFile instance that - * does not even have QuaZip instance associated. Do not do that - * because there is no means to determine whether \c false is - * returned because of error or because end of file was reached. - * Well, on the other side you may interpret \c false return value - * as "there is no file open to check for end of file and there is - * no end of file therefore". - * - * When writing, this function always returns \c true (because you - * are always writing to the end of file). - * - * Error code returned by getZipError() is not affected by this - * function call. - **/ - virtual bool atEnd()const; - /// Returns file size. - /** This function returns csize() if the file is open for reading in - * raw mode, usize() if it is open for reading in normal mode and - * pos() if it is open for writing. - * - * Returns -1 on error, call getZipError() to get error code. - * - * \note This function returns file size despite that - * \ref quazipfile-sequential "QuaZipFile is considered to be sequential device", - * for which size() should return bytesAvailable() instead. But its - * name would be very misguiding otherwise, so just keep in mind - * this inconsistence. - **/ - virtual qint64 size()const; - /// Returns compressed file size. - /** Equivalent to calling getFileInfo() and then getting - * compressedSize field, but more convenient and faster. - * - * File must be open for reading before calling this function. - * - * Returns -1 on error, call getZipError() to get error code. - **/ - qint64 csize()const; - /// Returns uncompressed file size. - /** Equivalent to calling getFileInfo() and then getting - * uncompressedSize field, but more convenient and faster. See - * getFileInfo() for a warning. - * - * File must be open for reading before calling this function. - * - * Returns -1 on error, call getZipError() to get error code. - **/ - qint64 usize()const; - /// Gets information about current file. - /** This function does the same thing as calling - * QuaZip::getCurrentFileInfo() on the associated QuaZip object, - * but you can not call getCurrentFileInfo() if the associated - * QuaZip is internal (because you do not have access to it), while - * you still can call this function in that case. - * - * File must be open for reading before calling this function. - * - * \return \c false in the case of an error. - * - * This function doesn't support zip64, but will still work fine on zip64 - * archives if file sizes are below 4 GB, otherwise the values will be set - * as if converted using QuaZipFileInfo64::toQuaZipFileInfo(). - * - * \sa getFileInfo(QuaZipFileInfo64*) - **/ - bool getFileInfo(QuaZipFileInfo *info); - /// Gets information about current file with zip64 support. - /** - * @overload - * - * \sa getFileInfo(QuaZipFileInfo*) - */ - bool getFileInfo(QuaZipFileInfo64 *info); - /// Closes the file. - /** Call getZipError() to determine if the close was successful. - **/ - virtual void close(); - /// Returns the error code returned by the last ZIP/UNZIP API call. - int getZipError() const; - /// Returns the number of bytes available for reading. - virtual qint64 bytesAvailable() const; -}; - -#endif +#ifndef QUA_ZIPFILE_H +#define QUA_ZIPFILE_H + +/* +Copyright (C) 2005-2014 Sergey A. Tachenov + +This file is part of QuaZIP. + +QuaZIP is free software: you can redistribute it and/or modify +it under the terms of the GNU Lesser General Public License as published by +the Free Software Foundation, either version 2.1 of the License, or +(at your option) any later version. + +QuaZIP is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU Lesser General Public License for more details. + +You should have received a copy of the GNU Lesser General Public License +along with QuaZIP. If not, see . + +See COPYING file for the full LGPL text. + +Original ZIP package is copyrighted by Gilles Vollant, see +quazip/(un)zip.h files for details, basically it's zlib license. + **/ + +#include + +#include "quazip_global.h" +#include "quazip.h" +#include "quazipnewinfo.h" + +class QuaZipFilePrivate; + +/// A file inside ZIP archive. +/** \class QuaZipFile quazipfile.h + * This is the most interesting class. Not only it provides C++ + * interface to the ZIP/UNZIP package, but also integrates it with Qt by + * subclassing QIODevice. This makes possible to access files inside ZIP + * archive using QTextStream or QDataStream, for example. Actually, this + * is the main purpose of the whole QuaZIP library. + * + * You can either use existing QuaZip instance to create instance of + * this class or pass ZIP archive file name to this class, in which case + * it will create internal QuaZip object. See constructors' descriptions + * for details. Writing is only possible with the existing instance. + * + * Note that due to the underlying library's limitation it is not + * possible to use multiple QuaZipFile instances to open several files + * in the same archive at the same time. If you need to write to + * multiple files in parallel, then you should write to temporary files + * first, then pack them all at once when you have finished writing. If + * you need to read multiple files inside the same archive in parallel, + * you should extract them all into a temporary directory first. + * + * \section quazipfile-sequential Sequential or random-access? + * + * At the first thought, QuaZipFile has fixed size, the start and the + * end and should be therefore considered random-access device. But + * there is one major obstacle to making it random-access: ZIP/UNZIP API + * does not support seek() operation and the only way to implement it is + * through reopening the file and re-reading to the required position, + * but this is prohibitively slow. + * + * Therefore, QuaZipFile is considered to be a sequential device. This + * has advantage of availability of the ungetChar() operation (QIODevice + * does not implement it properly for non-sequential devices unless they + * support seek()). Disadvantage is a somewhat strange behaviour of the + * size() and pos() functions. This should be kept in mind while using + * this class. + * + **/ +class QUAZIP_EXPORT QuaZipFile: public QIODevice { + friend class QuaZipFilePrivate; + Q_OBJECT + private: + QuaZipFilePrivate *p; + // these are not supported nor implemented + QuaZipFile(const QuaZipFile& that); + QuaZipFile& operator=(const QuaZipFile& that); + protected: + /// Implementation of the QIODevice::readData(). + qint64 readData(char *data, qint64 maxSize); + /// Implementation of the QIODevice::writeData(). + qint64 writeData(const char *data, qint64 maxSize); + public: + /// Constructs a QuaZipFile instance. + /** You should use setZipName() and setFileName() or setZip() before + * trying to call open() on the constructed object. + **/ + QuaZipFile(); + /// Constructs a QuaZipFile instance. + /** \a parent argument specifies this object's parent object. + * + * You should use setZipName() and setFileName() or setZip() before + * trying to call open() on the constructed object. + **/ + QuaZipFile(QObject *parent); + /// Constructs a QuaZipFile instance. + /** \a parent argument specifies this object's parent object and \a + * zipName specifies ZIP archive file name. + * + * You should use setFileName() before trying to call open() on the + * constructed object. + * + * QuaZipFile constructed by this constructor can be used for read + * only access. Use QuaZipFile(QuaZip*,QObject*) for writing. + **/ + QuaZipFile(const QString& zipName, QObject *parent =NULL); + /// Constructs a QuaZipFile instance. + /** \a parent argument specifies this object's parent object, \a + * zipName specifies ZIP archive file name and \a fileName and \a cs + * specify a name of the file to open inside archive. + * + * QuaZipFile constructed by this constructor can be used for read + * only access. Use QuaZipFile(QuaZip*,QObject*) for writing. + * + * \sa QuaZip::setCurrentFile() + **/ + QuaZipFile(const QString& zipName, const QString& fileName, + QuaZip::CaseSensitivity cs =QuaZip::csDefault, QObject *parent =NULL); + /// Constructs a QuaZipFile instance. + /** \a parent argument specifies this object's parent object. + * + * \a zip is the pointer to the existing QuaZip object. This + * QuaZipFile object then can be used to read current file in the + * \a zip or to write to the file inside it. + * + * \warning Using this constructor for reading current file can be + * tricky. Let's take the following example: + * \code + * QuaZip zip("archive.zip"); + * zip.open(QuaZip::mdUnzip); + * zip.setCurrentFile("file-in-archive"); + * QuaZipFile file(&zip); + * file.open(QIODevice::ReadOnly); + * // ok, now we can read from the file + * file.read(somewhere, some); + * zip.setCurrentFile("another-file-in-archive"); // oops... + * QuaZipFile anotherFile(&zip); + * anotherFile.open(QIODevice::ReadOnly); + * anotherFile.read(somewhere, some); // this is still ok... + * file.read(somewhere, some); // and this is NOT + * \endcode + * So, what exactly happens here? When we change current file in the + * \c zip archive, \c file that references it becomes invalid + * (actually, as far as I understand ZIP/UNZIP sources, it becomes + * closed, but QuaZipFile has no means to detect it). + * + * Summary: do not close \c zip object or change its current file as + * long as QuaZipFile is open. Even better - use another constructors + * which create internal QuaZip instances, one per object, and + * therefore do not cause unnecessary trouble. This constructor may + * be useful, though, if you already have a QuaZip instance and do + * not want to access several files at once. Good example: + * \code + * QuaZip zip("archive.zip"); + * zip.open(QuaZip::mdUnzip); + * // first, we need some information about archive itself + * QByteArray comment=zip.getComment(); + * // and now we are going to access files inside it + * QuaZipFile file(&zip); + * for(bool more=zip.goToFirstFile(); more; more=zip.goToNextFile()) { + * file.open(QIODevice::ReadOnly); + * // do something cool with file here + * file.close(); // do not forget to close! + * } + * zip.close(); + * \endcode + **/ + QuaZipFile(QuaZip *zip, QObject *parent =NULL); + /// Destroys a QuaZipFile instance. + /** Closes file if open, destructs internal QuaZip object (if it + * exists and \em is internal, of course). + **/ + virtual ~QuaZipFile(); + /// Returns the ZIP archive file name. + /** If this object was created by passing QuaZip pointer to the + * constructor, this function will return that QuaZip's file name + * (or null string if that object does not have file name yet). + * + * Otherwise, returns associated ZIP archive file name or null + * string if there are no name set yet. + * + * \sa setZipName() getFileName() + **/ + QString getZipName()const; + /// Returns a pointer to the associated QuaZip object. + /** Returns \c NULL if there is no associated QuaZip or it is + * internal (so you will not mess with it). + **/ + QuaZip* getZip()const; + /// Returns file name. + /** This function returns file name you passed to this object either + * by using + * QuaZipFile(const QString&,const QString&,QuaZip::CaseSensitivity,QObject*) + * or by calling setFileName(). Real name of the file may differ in + * case if you used case-insensitivity. + * + * Returns null string if there is no file name set yet. This is the + * case when this QuaZipFile operates on the existing QuaZip object + * (constructor QuaZipFile(QuaZip*,QObject*) or setZip() was used). + * + * \sa getActualFileName + **/ + QString getFileName() const; + /// Returns case sensitivity of the file name. + /** This function returns case sensitivity argument you passed to + * this object either by using + * QuaZipFile(const QString&,const QString&,QuaZip::CaseSensitivity,QObject*) + * or by calling setFileName(). + * + * Returns unpredictable value if getFileName() returns null string + * (this is the case when you did not used setFileName() or + * constructor above). + * + * \sa getFileName + **/ + QuaZip::CaseSensitivity getCaseSensitivity() const; + /// Returns the actual file name in the archive. + /** This is \em not a ZIP archive file name, but a name of file inside + * archive. It is not necessary the same name that you have passed + * to the + * QuaZipFile(const QString&,const QString&,QuaZip::CaseSensitivity,QObject*), + * setFileName() or QuaZip::setCurrentFile() - this is the real file + * name inside archive, so it may differ in case if the file name + * search was case-insensitive. + * + * Equivalent to calling getCurrentFileName() on the associated + * QuaZip object. Returns null string if there is no associated + * QuaZip object or if it does not have a current file yet. And this + * is the case if you called setFileName() but did not open the + * file yet. So this is perfectly fine: + * \code + * QuaZipFile file("somezip.zip"); + * file.setFileName("somefile"); + * QString name=file.getName(); // name=="somefile" + * QString actual=file.getActualFileName(); // actual is null string + * file.open(QIODevice::ReadOnly); + * QString actual=file.getActualFileName(); // actual can be "SoMeFiLe" on Windows + * \endcode + * + * \sa getZipName(), getFileName(), QuaZip::CaseSensitivity + **/ + QString getActualFileName()const; + /// Sets the ZIP archive file name. + /** Automatically creates internal QuaZip object and destroys + * previously created internal QuaZip object, if any. + * + * Will do nothing if this file is already open. You must close() it + * first. + **/ + void setZipName(const QString& zipName); + /// Returns \c true if the file was opened in raw mode. + /** If the file is not open, the returned value is undefined. + * + * \sa open(OpenMode,int*,int*,bool,const char*) + **/ + bool isRaw() const; + /// Binds to the existing QuaZip instance. + /** This function destroys internal QuaZip object, if any, and makes + * this QuaZipFile to use current file in the \a zip object for any + * further operations. See QuaZipFile(QuaZip*,QObject*) for the + * possible pitfalls. + * + * Will do nothing if the file is currently open. You must close() + * it first. + **/ + void setZip(QuaZip *zip); + /// Sets the file name. + /** Will do nothing if at least one of the following conditions is + * met: + * - ZIP name has not been set yet (getZipName() returns null + * string). + * - This QuaZipFile is associated with external QuaZip. In this + * case you should call that QuaZip's setCurrentFile() function + * instead! + * - File is already open so setting the name is meaningless. + * + * \sa QuaZip::setCurrentFile + **/ + void setFileName(const QString& fileName, QuaZip::CaseSensitivity cs =QuaZip::csDefault); + /// Opens a file for reading. + /** Returns \c true on success, \c false otherwise. + * Call getZipError() to get error code. + * + * \note Since ZIP/UNZIP API provides buffered reading only, + * QuaZipFile does not support unbuffered reading. So do not pass + * QIODevice::Unbuffered flag in \a mode, or open will fail. + **/ + virtual bool open(OpenMode mode); + /// Opens a file for reading. + /** \overload + * Argument \a password specifies a password to decrypt the file. If + * it is NULL then this function behaves just like open(OpenMode). + **/ + inline bool open(OpenMode mode, const char *password) + {return open(mode, NULL, NULL, false, password);} + /// Opens a file for reading. + /** \overload + * Argument \a password specifies a password to decrypt the file. + * + * An integers pointed by \a method and \a level will receive codes + * of the compression method and level used. See unzip.h. + * + * If raw is \c true then no decompression is performed. + * + * \a method should not be \c NULL. \a level can be \c NULL if you + * don't want to know the compression level. + **/ + bool open(OpenMode mode, int *method, int *level, bool raw, const char *password =NULL); + /// Opens a file for writing. + /** \a info argument specifies information about file. It should at + * least specify a correct file name. Also, it is a good idea to + * specify correct timestamp (by default, current time will be + * used). See QuaZipNewInfo. + * + * The \a password argument specifies the password for crypting. Pass NULL + * if you don't need any crypting. The \a crc argument was supposed + * to be used for crypting too, but then it turned out that it's + * false information, so you need to set it to 0 unless you want to + * use the raw mode (see below). + * + * Arguments \a method and \a level specify compression method and + * level. The only method supported is Z_DEFLATED, but you may also + * specify 0 for no compression. If all of the files in the archive + * use both method 0 and either level 0 is explicitly specified or + * data descriptor writing is disabled with + * QuaZip::setDataDescriptorWritingEnabled(), then the + * resulting archive is supposed to be compatible with the 1.0 ZIP + * format version, should you need that. Except for this, \a level + * has no other effects with method 0. + * + * If \a raw is \c true, no compression is performed. In this case, + * \a crc and uncompressedSize field of the \a info are required. + * + * Arguments \a windowBits, \a memLevel, \a strategy provide zlib + * algorithms tuning. See deflateInit2() in zlib. + **/ + bool open(OpenMode mode, const QuaZipNewInfo& info, + const char *password =NULL, quint32 crc =0, + int method =Z_DEFLATED, int level =Z_DEFAULT_COMPRESSION, bool raw =false, + int windowBits =-MAX_WBITS, int memLevel =DEF_MEM_LEVEL, int strategy =Z_DEFAULT_STRATEGY); + /// Returns \c true, but \ref quazipfile-sequential "beware"! + virtual bool isSequential()const; + /// Returns current position in the file. + /** Implementation of the QIODevice::pos(). When reading, this + * function is a wrapper to the ZIP/UNZIP unztell(), therefore it is + * unable to keep track of the ungetChar() calls (which is + * non-virtual and therefore is dangerous to reimplement). So if you + * are using ungetChar() feature of the QIODevice, this function + * reports incorrect value until you get back characters which you + * ungot. + * + * When writing, pos() returns number of bytes already written + * (uncompressed unless you use raw mode). + * + * \note Although + * \ref quazipfile-sequential "QuaZipFile is a sequential device" + * and therefore pos() should always return zero, it does not, + * because it would be misguiding. Keep this in mind. + * + * This function returns -1 if the file or archive is not open. + * + * Error code returned by getZipError() is not affected by this + * function call. + **/ + virtual qint64 pos()const; + /// Returns \c true if the end of file was reached. + /** This function returns \c false in the case of error. This means + * that you called this function on either not open file, or a file + * in the not open archive or even on a QuaZipFile instance that + * does not even have QuaZip instance associated. Do not do that + * because there is no means to determine whether \c false is + * returned because of error or because end of file was reached. + * Well, on the other side you may interpret \c false return value + * as "there is no file open to check for end of file and there is + * no end of file therefore". + * + * When writing, this function always returns \c true (because you + * are always writing to the end of file). + * + * Error code returned by getZipError() is not affected by this + * function call. + **/ + virtual bool atEnd()const; + /// Returns file size. + /** This function returns csize() if the file is open for reading in + * raw mode, usize() if it is open for reading in normal mode and + * pos() if it is open for writing. + * + * Returns -1 on error, call getZipError() to get error code. + * + * \note This function returns file size despite that + * \ref quazipfile-sequential "QuaZipFile is considered to be sequential device", + * for which size() should return bytesAvailable() instead. But its + * name would be very misguiding otherwise, so just keep in mind + * this inconsistence. + **/ + virtual qint64 size()const; + /// Returns compressed file size. + /** Equivalent to calling getFileInfo() and then getting + * compressedSize field, but more convenient and faster. + * + * File must be open for reading before calling this function. + * + * Returns -1 on error, call getZipError() to get error code. + **/ + qint64 csize()const; + /// Returns uncompressed file size. + /** Equivalent to calling getFileInfo() and then getting + * uncompressedSize field, but more convenient and faster. See + * getFileInfo() for a warning. + * + * File must be open for reading before calling this function. + * + * Returns -1 on error, call getZipError() to get error code. + **/ + qint64 usize()const; + /// Gets information about current file. + /** This function does the same thing as calling + * QuaZip::getCurrentFileInfo() on the associated QuaZip object, + * but you can not call getCurrentFileInfo() if the associated + * QuaZip is internal (because you do not have access to it), while + * you still can call this function in that case. + * + * File must be open for reading before calling this function. + * + * \return \c false in the case of an error. + * + * This function doesn't support zip64, but will still work fine on zip64 + * archives if file sizes are below 4 GB, otherwise the values will be set + * as if converted using QuaZipFileInfo64::toQuaZipFileInfo(). + * + * \sa getFileInfo(QuaZipFileInfo64*) + **/ + bool getFileInfo(QuaZipFileInfo *info); + /// Gets information about current file with zip64 support. + /** + * @overload + * + * \sa getFileInfo(QuaZipFileInfo*) + */ + bool getFileInfo(QuaZipFileInfo64 *info); + /// Closes the file. + /** Call getZipError() to determine if the close was successful. + **/ + virtual void close(); + /// Returns the error code returned by the last ZIP/UNZIP API call. + int getZipError() const; + /// Returns the number of bytes available for reading. + virtual qint64 bytesAvailable() const; +}; + +#endif diff --git a/hecl-gui/quazip/quazip/quazipfileinfo.cpp b/hecl-gui/quazip/quazip/quazipfileinfo.cpp index a855e0145..f11c91017 100644 --- a/hecl-gui/quazip/quazip/quazipfileinfo.cpp +++ b/hecl-gui/quazip/quazip/quazipfileinfo.cpp @@ -5,7 +5,7 @@ This file is part of QuaZIP. QuaZIP is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by -the Free Software Foundation, either version 3 of the License, or +the Free Software Foundation, either version 2.1 of the License, or (at your option) any later version. QuaZIP is distributed in the hope that it will be useful, diff --git a/hecl-gui/quazip/quazip/quazipfileinfo.h b/hecl-gui/quazip/quazip/quazipfileinfo.h index 17b125b20..4e142a4eb 100644 --- a/hecl-gui/quazip/quazip/quazipfileinfo.h +++ b/hecl-gui/quazip/quazip/quazipfileinfo.h @@ -1,172 +1,178 @@ -#ifndef QUA_ZIPFILEINFO_H -#define QUA_ZIPFILEINFO_H - -/* -Copyright (C) 2005-2014 Sergey A. Tachenov - -This file is part of QuaZIP. - -QuaZIP is free software: you can redistribute it and/or modify -it under the terms of the GNU Lesser General Public License as published by -the Free Software Foundation, either version 3 of the License, or -(at your option) any later version. - -QuaZIP is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU Lesser General Public License for more details. - -You should have received a copy of the GNU Lesser General Public License -along with QuaZIP. If not, see . - -See COPYING file for the full LGPL text. - -Original ZIP package is copyrighted by Gilles Vollant and contributors, -see quazip/(un)zip.h files for details. Basically it's the zlib license. -*/ - -#include -#include -#include - -#include "quazip_global.h" - -/// Information about a file inside archive. -/** Call QuaZip::getCurrentFileInfo() or QuaZipFile::getFileInfo() to - * fill this structure. */ -struct QUAZIP_EXPORT QuaZipFileInfo { - /// File name. - QString name; - /// Version created by. - quint16 versionCreated; - /// Version needed to extract. - quint16 versionNeeded; - /// General purpose flags. - quint16 flags; - /// Compression method. - quint16 method; - /// Last modification date and time. - QDateTime dateTime; - /// CRC. - quint32 crc; - /// Compressed file size. - quint32 compressedSize; - /// Uncompressed file size. - quint32 uncompressedSize; - /// Disk number start. - quint16 diskNumberStart; - /// Internal file attributes. - quint16 internalAttr; - /// External file attributes. - quint32 externalAttr; - /// Comment. - QString comment; - /// Extra field. - QByteArray extra; - /// Get the file permissions. - /** - Returns the high 16 bits of external attributes converted to - QFile::Permissions. - */ - QFile::Permissions getPermissions() const; -}; - -/// Information about a file inside archive (with zip64 support). -/** Call QuaZip::getCurrentFileInfo() or QuaZipFile::getFileInfo() to - * fill this structure. */ -struct QUAZIP_EXPORT QuaZipFileInfo64 { - /// File name. - QString name; - /// Version created by. - quint16 versionCreated; - /// Version needed to extract. - quint16 versionNeeded; - /// General purpose flags. - quint16 flags; - /// Compression method. - quint16 method; - /// Last modification date and time. - /** - * This is the time stored in the standard ZIP header. This format only allows - * to store time with 2-second precision, so the seconds will always be even - * and the milliseconds will always be zero. If you need more precise - * date and time, you can try to call the getNTFSmTime() function or - * its siblings, provided that the archive itself contains these NTFS times. - */ - QDateTime dateTime; - /// CRC. - quint32 crc; - /// Compressed file size. - quint64 compressedSize; - /// Uncompressed file size. - quint64 uncompressedSize; - /// Disk number start. - quint16 diskNumberStart; - /// Internal file attributes. - quint16 internalAttr; - /// External file attributes. - quint32 externalAttr; - /// Comment. - QString comment; - /// Extra field. - QByteArray extra; - /// Get the file permissions. - /** - Returns the high 16 bits of external attributes converted to - QFile::Permissions. - */ - QFile::Permissions getPermissions() const; - /// Converts to QuaZipFileInfo - /** - If any of the fields are greater than 0xFFFFFFFFu, they are set to - 0xFFFFFFFFu exactly, not just truncated. This function should be mainly used - for compatibility with the old code expecting QuaZipFileInfo, in the cases - when it's impossible or otherwise unadvisable (due to ABI compatibility - reasons, for example) to modify that old code to use QuaZipFileInfo64. - - \return \c true if all fields converted correctly, \c false if an overflow - occured. - */ - bool toQuaZipFileInfo(QuaZipFileInfo &info) const; - /// Returns the NTFS modification time - /** - * The getNTFS*Time() functions only work if there is an NTFS extra field - * present. Otherwise, they all return invalid null timestamps. - * @param fineTicks If not NULL, the fractional part of milliseconds returned - * there, measured in 100-nanosecond ticks. Will be set to - * zero if there is no NTFS extra field. - * @sa dateTime - * @sa getNTFSaTime() - * @sa getNTFScTime() - * @return The NTFS modification time, UTC - */ - QDateTime getNTFSmTime(int *fineTicks = NULL) const; - /// Returns the NTFS access time - /** - * The getNTFS*Time() functions only work if there is an NTFS extra field - * present. Otherwise, they all return invalid null timestamps. - * @param fineTicks If not NULL, the fractional part of milliseconds returned - * there, measured in 100-nanosecond ticks. Will be set to - * zero if there is no NTFS extra field. - * @sa dateTime - * @sa getNTFSmTime() - * @sa getNTFScTime() - * @return The NTFS access time, UTC - */ - QDateTime getNTFSaTime(int *fineTicks = NULL) const; - /// Returns the NTFS creation time - /** - * The getNTFS*Time() functions only work if there is an NTFS extra field - * present. Otherwise, they all return invalid null timestamps. - * @param fineTicks If not NULL, the fractional part of milliseconds returned - * there, measured in 100-nanosecond ticks. Will be set to - * zero if there is no NTFS extra field. - * @sa dateTime - * @sa getNTFSmTime() - * @sa getNTFSaTime() - * @return The NTFS creation time, UTC - */ - QDateTime getNTFScTime(int *fineTicks = NULL) const; -}; - -#endif +#ifndef QUA_ZIPFILEINFO_H +#define QUA_ZIPFILEINFO_H + +/* +Copyright (C) 2005-2014 Sergey A. Tachenov + +This file is part of QuaZIP. + +QuaZIP is free software: you can redistribute it and/or modify +it under the terms of the GNU Lesser General Public License as published by +the Free Software Foundation, either version 2.1 of the License, or +(at your option) any later version. + +QuaZIP is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU Lesser General Public License for more details. + +You should have received a copy of the GNU Lesser General Public License +along with QuaZIP. If not, see . + +See COPYING file for the full LGPL text. + +Original ZIP package is copyrighted by Gilles Vollant and contributors, +see quazip/(un)zip.h files for details. Basically it's the zlib license. +*/ + +#include +#include +#include + +#include "quazip_global.h" + +/// Information about a file inside archive. +/** + * \deprecated Use QuaZipFileInfo64 instead. Not only it supports large files, + * but also more convenience methods as well. + * + * Call QuaZip::getCurrentFileInfo() or QuaZipFile::getFileInfo() to + * fill this structure. */ +struct QUAZIP_EXPORT QuaZipFileInfo { + /// File name. + QString name; + /// Version created by. + quint16 versionCreated; + /// Version needed to extract. + quint16 versionNeeded; + /// General purpose flags. + quint16 flags; + /// Compression method. + quint16 method; + /// Last modification date and time. + QDateTime dateTime; + /// CRC. + quint32 crc; + /// Compressed file size. + quint32 compressedSize; + /// Uncompressed file size. + quint32 uncompressedSize; + /// Disk number start. + quint16 diskNumberStart; + /// Internal file attributes. + quint16 internalAttr; + /// External file attributes. + quint32 externalAttr; + /// Comment. + QString comment; + /// Extra field. + QByteArray extra; + /// Get the file permissions. + /** + Returns the high 16 bits of external attributes converted to + QFile::Permissions. + */ + QFile::Permissions getPermissions() const; +}; + +/// Information about a file inside archive (with zip64 support). +/** Call QuaZip::getCurrentFileInfo() or QuaZipFile::getFileInfo() to + * fill this structure. */ +struct QUAZIP_EXPORT QuaZipFileInfo64 { + /// File name. + QString name; + /// Version created by. + quint16 versionCreated; + /// Version needed to extract. + quint16 versionNeeded; + /// General purpose flags. + quint16 flags; + /// Compression method. + quint16 method; + /// Last modification date and time. + /** + * This is the time stored in the standard ZIP header. This format only allows + * to store time with 2-second precision, so the seconds will always be even + * and the milliseconds will always be zero. If you need more precise + * date and time, you can try to call the getNTFSmTime() function or + * its siblings, provided that the archive itself contains these NTFS times. + */ + QDateTime dateTime; + /// CRC. + quint32 crc; + /// Compressed file size. + quint64 compressedSize; + /// Uncompressed file size. + quint64 uncompressedSize; + /// Disk number start. + quint16 diskNumberStart; + /// Internal file attributes. + quint16 internalAttr; + /// External file attributes. + quint32 externalAttr; + /// Comment. + QString comment; + /// Extra field. + QByteArray extra; + /// Get the file permissions. + /** + Returns the high 16 bits of external attributes converted to + QFile::Permissions. + */ + QFile::Permissions getPermissions() const; + /// Converts to QuaZipFileInfo + /** + If any of the fields are greater than 0xFFFFFFFFu, they are set to + 0xFFFFFFFFu exactly, not just truncated. This function should be mainly used + for compatibility with the old code expecting QuaZipFileInfo, in the cases + when it's impossible or otherwise unadvisable (due to ABI compatibility + reasons, for example) to modify that old code to use QuaZipFileInfo64. + + \return \c true if all fields converted correctly, \c false if an overflow + occured. + */ + bool toQuaZipFileInfo(QuaZipFileInfo &info) const; + /// Returns the NTFS modification time + /** + * The getNTFS*Time() functions only work if there is an NTFS extra field + * present. Otherwise, they all return invalid null timestamps. + * @param fineTicks If not NULL, the fractional part of milliseconds returned + * there, measured in 100-nanosecond ticks. Will be set to + * zero if there is no NTFS extra field. + * @sa dateTime + * @sa getNTFSaTime() + * @sa getNTFScTime() + * @return The NTFS modification time, UTC + */ + QDateTime getNTFSmTime(int *fineTicks = NULL) const; + /// Returns the NTFS access time + /** + * The getNTFS*Time() functions only work if there is an NTFS extra field + * present. Otherwise, they all return invalid null timestamps. + * @param fineTicks If not NULL, the fractional part of milliseconds returned + * there, measured in 100-nanosecond ticks. Will be set to + * zero if there is no NTFS extra field. + * @sa dateTime + * @sa getNTFSmTime() + * @sa getNTFScTime() + * @return The NTFS access time, UTC + */ + QDateTime getNTFSaTime(int *fineTicks = NULL) const; + /// Returns the NTFS creation time + /** + * The getNTFS*Time() functions only work if there is an NTFS extra field + * present. Otherwise, they all return invalid null timestamps. + * @param fineTicks If not NULL, the fractional part of milliseconds returned + * there, measured in 100-nanosecond ticks. Will be set to + * zero if there is no NTFS extra field. + * @sa dateTime + * @sa getNTFSmTime() + * @sa getNTFSaTime() + * @return The NTFS creation time, UTC + */ + QDateTime getNTFScTime(int *fineTicks = NULL) const; + /// Checks whether the file is encrypted. + bool isEncrypted() const {return (flags & 1) != 0;} +}; + +#endif diff --git a/hecl-gui/quazip/quazip/quazipnewinfo.cpp b/hecl-gui/quazip/quazip/quazipnewinfo.cpp index 9bc0a56fd..753e859a8 100644 --- a/hecl-gui/quazip/quazip/quazipnewinfo.cpp +++ b/hecl-gui/quazip/quazip/quazipnewinfo.cpp @@ -1,269 +1,290 @@ -/* -Copyright (C) 2005-2014 Sergey A. Tachenov - -This file is part of QuaZIP. - -QuaZIP is free software: you can redistribute it and/or modify -it under the terms of the GNU Lesser General Public License as published by -the Free Software Foundation, either version 3 of the License, or -(at your option) any later version. - -QuaZIP is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU Lesser General Public License for more details. - -You should have received a copy of the GNU Lesser General Public License -along with QuaZIP. If not, see . - -See COPYING file for the full LGPL text. - -Original ZIP package is copyrighted by Gilles Vollant and contributors, -see quazip/(un)zip.h files for details. Basically it's the zlib license. -*/ - -#include - -#include "quazipnewinfo.h" - -#include - -static void QuaZipNewInfo_setPermissions(QuaZipNewInfo *info, - QFile::Permissions perm, bool isDir) -{ - quint32 uPerm = isDir ? 0040000 : 0100000; - if ((perm & QFile::ReadOwner) != 0) - uPerm |= 0400; - if ((perm & QFile::WriteOwner) != 0) - uPerm |= 0200; - if ((perm & QFile::ExeOwner) != 0) - uPerm |= 0100; - if ((perm & QFile::ReadGroup) != 0) - uPerm |= 0040; - if ((perm & QFile::WriteGroup) != 0) - uPerm |= 0020; - if ((perm & QFile::ExeGroup) != 0) - uPerm |= 0010; - if ((perm & QFile::ReadOther) != 0) - uPerm |= 0004; - if ((perm & QFile::WriteOther) != 0) - uPerm |= 0002; - if ((perm & QFile::ExeOther) != 0) - uPerm |= 0001; - info->externalAttr = (info->externalAttr & ~0xFFFF0000u) | (uPerm << 16); -} - -template -void QuaZipNewInfo_init(QuaZipNewInfo &self, const FileInfo &existing) -{ - self.name = existing.name; - self.dateTime = existing.dateTime; - self.internalAttr = existing.internalAttr; - self.externalAttr = existing.externalAttr; - self.comment = existing.comment; - self.extraLocal = existing.extra; - self.extraGlobal = existing.extra; - self.uncompressedSize = existing.uncompressedSize; -} - -QuaZipNewInfo::QuaZipNewInfo(const QuaZipFileInfo &existing) -{ - QuaZipNewInfo_init(*this, existing); -} - -QuaZipNewInfo::QuaZipNewInfo(const QuaZipFileInfo64 &existing) -{ - QuaZipNewInfo_init(*this, existing); -} - -QuaZipNewInfo::QuaZipNewInfo(const QString& name): - name(name), dateTime(QDateTime::currentDateTime()), internalAttr(0), externalAttr(0), - uncompressedSize(0) -{ -} - -QuaZipNewInfo::QuaZipNewInfo(const QString& name, const QString& file): - name(name), internalAttr(0), externalAttr(0), uncompressedSize(0) -{ - QFileInfo info(file); - QDateTime lm = info.lastModified(); - if (!info.exists()) { - dateTime = QDateTime::currentDateTime(); - } else { - dateTime = lm; - QuaZipNewInfo_setPermissions(this, info.permissions(), info.isDir()); - } -} - -void QuaZipNewInfo::setFileDateTime(const QString& file) -{ - QFileInfo info(file); - QDateTime lm = info.lastModified(); - if (info.exists()) - dateTime = lm; -} - -void QuaZipNewInfo::setFilePermissions(const QString &file) -{ - QFileInfo info = QFileInfo(file); - QFile::Permissions perm = info.permissions(); - QuaZipNewInfo_setPermissions(this, perm, info.isDir()); -} - -void QuaZipNewInfo::setPermissions(QFile::Permissions permissions) -{ - QuaZipNewInfo_setPermissions(this, permissions, name.endsWith('/')); -} - -void QuaZipNewInfo::setFileNTFSTimes(const QString &fileName) -{ - QFileInfo fi(fileName); - if (!fi.exists()) { - qWarning("QuaZipNewInfo::setFileNTFSTimes(): '%s' doesn't exist", - fileName.toUtf8().constData()); - return; - } - setFileNTFSmTime(fi.lastModified()); - setFileNTFSaTime(fi.lastRead()); - setFileNTFScTime(fi.created()); -} - -static void setNTFSTime(QByteArray &extra, const QDateTime &time, int position, - int fineTicks) { - int ntfsPos = -1, timesPos = -1; - unsigned ntfsLength = 0, ntfsTimesLength = 0; - for (int i = 0; i <= extra.size() - 4; ) { - unsigned type = static_cast(static_cast( - extra.at(i))) - | (static_cast(static_cast( - extra.at(i + 1))) << 8); - i += 2; - unsigned length = static_cast(static_cast( - extra.at(i))) - | (static_cast(static_cast( - extra.at(i + 1))) << 8); - i += 2; - if (type == QUAZIP_EXTRA_NTFS_MAGIC) { - ntfsPos = i - 4; // the beginning of the NTFS record - ntfsLength = length; - if (length <= 4) { - break; // no times in the NTFS record - } - i += 4; // reserved - while (i <= extra.size() - 4) { - unsigned tag = static_cast( - static_cast(extra.at(i))) - | (static_cast( - static_cast(extra.at(i + 1))) - << 8); - i += 2; - unsigned tagsize = static_cast( - static_cast(extra.at(i))) - | (static_cast( - static_cast(extra.at(i + 1))) - << 8); - i += 2; - if (tag == QUAZIP_EXTRA_NTFS_TIME_MAGIC) { - timesPos = i - 4; // the beginning of the NTFS times tag - ntfsTimesLength = tagsize; - break; - } else { - i += tagsize; - } - } - break; // I ain't going to search for yet another NTFS record! - } else { - i += length; - } - } - if (ntfsPos == -1) { - // No NTFS record, need to create one. - ntfsPos = extra.size(); - ntfsLength = 32; - extra.resize(extra.size() + 4 + ntfsLength); - // the NTFS record header - extra[ntfsPos] = static_cast(QUAZIP_EXTRA_NTFS_MAGIC); - extra[ntfsPos + 1] = static_cast(QUAZIP_EXTRA_NTFS_MAGIC >> 8); - extra[ntfsPos + 2] = 32; // the 2-byte size in LittleEndian - extra[ntfsPos + 3] = 0; - // zero the record - memset(extra.data() + ntfsPos + 4, 0, 32); - timesPos = ntfsPos + 8; - // now set the tag data - extra[timesPos] = static_cast(QUAZIP_EXTRA_NTFS_TIME_MAGIC); - extra[timesPos + 1] = static_cast(QUAZIP_EXTRA_NTFS_TIME_MAGIC - >> 8); - // the size: - extra[timesPos + 2] = 24; - extra[timesPos + 3] = 0; - ntfsTimesLength = 24; - } - if (timesPos == -1) { - // No time tag in the NTFS record, need to add one. - timesPos = ntfsPos + 4 + ntfsLength; - extra.resize(extra.size() + 28); - // Now we need to move the rest of the field - // (possibly zero bytes, but memmove() is OK with that). - // 0 ......... ntfsPos .. ntfsPos + 4 ... timesPos - //
- memmove(extra.data() + timesPos + 28, extra.data() + timesPos, - extra.size() - 28 - timesPos); - ntfsLength += 28; - // now set the tag data - extra[timesPos] = static_cast(QUAZIP_EXTRA_NTFS_TIME_MAGIC); - extra[timesPos + 1] = static_cast(QUAZIP_EXTRA_NTFS_TIME_MAGIC - >> 8); - // the size: - extra[timesPos + 2] = 24; - extra[timesPos + 3] = 0; - // zero the record - memset(extra.data() + timesPos + 4, 0, 24); - ntfsTimesLength = 24; - } - if (ntfsTimesLength < 24) { - // Broken times field. OK, this is really unlikely, but just in case... - size_t timesEnd = timesPos + 4 + ntfsTimesLength; - extra.resize(extra.size() + (24 - ntfsTimesLength)); - // Move it! - // 0 ......... timesPos .... timesPos + 4 .. timesEnd - //