├── AUTHORS ├── BUGS ├── COPYING ├── ChangeLog ├── HACKING ├── INSTALL ├── Makefile.am ├── NEWS ├── README ├── TODO ├── aclocal.m4 ├── admin ├── prat-config.py ├── prat-config.pyc ├── version.py └── version.pyc ├── autogen.sh ├── config.h.in ├── configure.in ├── debian ├── Makefile.am ├── changelog ├── control ├── copyright ├── docs └── rules ├── help ├── Makefile.am ├── Makefile.in ├── en │ ├── Makefile.am │ ├── Makefile.in │ ├── gimp-help.xml │ └── index.html ├── es │ ├── Makefile.am │ ├── gimp-help.xml │ └── index.html └── images │ ├── Makefile.am │ ├── Makefile.in │ └── wilber.png ├── po ├── ChangeLog ├── Makefile.in.in ├── POTFILES.in ├── es.po └── ru.po └── src ├── Makefile.am ├── Makefile.in ├── deskew.cc ├── deskew.h ├── formats ├── Makefile ├── gimpfact.cc └── gimpfact.h ├── interface.c ├── interface.h ├── main.c ├── main.h ├── plugin-intl.h ├── raster ├── bwfactory.h ├── bwimage.cc ├── bwimage.h ├── deskewer.cc └── deskewer.h ├── render.c ├── render.h └── util ├── bitutil.cc ├── bitutil.h └── cntptr.h /AUTHORS: -------------------------------------------------------------------------------- 1 | Karl Chen 2 | -------------------------------------------------------------------------------- /BUGS: -------------------------------------------------------------------------------- 1 | None known yet. 2 | -------------------------------------------------------------------------------- /COPYING: -------------------------------------------------------------------------------- 1 | GNU GENERAL PUBLIC LICENSE 2 | Version 2, June 1991 3 | 4 | Copyright (C) 1989, 1991 Free Software Foundation, Inc., 5 | 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 6 | Everyone is permitted to copy and distribute verbatim copies 7 | of this license document, but changing it is not allowed. 8 | 9 | Preamble 10 | 11 | The licenses for most software are designed to take away your 12 | freedom to share and change it. By contrast, the GNU General Public 13 | License is intended to guarantee your freedom to share and change free 14 | software--to make sure the software is free for all its users. This 15 | General Public License applies to most of the Free Software 16 | Foundation's software and to any other program whose authors commit to 17 | using it. (Some other Free Software Foundation software is covered by 18 | the GNU Lesser General Public License instead.) You can apply it to 19 | your programs, too. 20 | 21 | When we speak of free software, we are referring to freedom, not 22 | price. Our General Public Licenses are designed to make sure that you 23 | have the freedom to distribute copies of free software (and charge for 24 | this service if you wish), that you receive source code or can get it 25 | if you want it, that you can change the software or use pieces of it 26 | in new free programs; and that you know you can do these things. 27 | 28 | To protect your rights, we need to make restrictions that forbid 29 | anyone to deny you these rights or to ask you to surrender the rights. 30 | These restrictions translate to certain responsibilities for you if you 31 | distribute copies of the software, or if you modify it. 32 | 33 | For example, if you distribute copies of such a program, whether 34 | gratis or for a fee, you must give the recipients all the rights that 35 | you have. You must make sure that they, too, receive or can get the 36 | source code. And you must show them these terms so they know their 37 | rights. 38 | 39 | We protect your rights with two steps: (1) copyright the software, and 40 | (2) offer you this license which gives you legal permission to copy, 41 | distribute and/or modify the software. 42 | 43 | Also, for each author's protection and ours, we want to make certain 44 | that everyone understands that there is no warranty for this free 45 | software. If the software is modified by someone else and passed on, we 46 | want its recipients to know that what they have is not the original, so 47 | that any problems introduced by others will not reflect on the original 48 | authors' reputations. 49 | 50 | Finally, any free program is threatened constantly by software 51 | patents. We wish to avoid the danger that redistributors of a free 52 | program will individually obtain patent licenses, in effect making the 53 | program proprietary. To prevent this, we have made it clear that any 54 | patent must be licensed for everyone's free use or not licensed at all. 55 | 56 | The precise terms and conditions for copying, distribution and 57 | modification follow. 58 | 59 | GNU GENERAL PUBLIC LICENSE 60 | TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 61 | 62 | 0. This License applies to any program or other work which contains 63 | a notice placed by the copyright holder saying it may be distributed 64 | under the terms of this General Public License. The "Program", below, 65 | refers to any such program or work, and a "work based on the Program" 66 | means either the Program or any derivative work under copyright law: 67 | that is to say, a work containing the Program or a portion of it, 68 | either verbatim or with modifications and/or translated into another 69 | language. (Hereinafter, translation is included without limitation in 70 | the term "modification".) Each licensee is addressed as "you". 71 | 72 | Activities other than copying, distribution and modification are not 73 | covered by this License; they are outside its scope. The act of 74 | running the Program is not restricted, and the output from the Program 75 | is covered only if its contents constitute a work based on the 76 | Program (independent of having been made by running the Program). 77 | Whether that is true depends on what the Program does. 78 | 79 | 1. You may copy and distribute verbatim copies of the Program's 80 | source code as you receive it, in any medium, provided that you 81 | conspicuously and appropriately publish on each copy an appropriate 82 | copyright notice and disclaimer of warranty; keep intact all the 83 | notices that refer to this License and to the absence of any warranty; 84 | and give any other recipients of the Program a copy of this License 85 | along with the Program. 86 | 87 | You may charge a fee for the physical act of transferring a copy, and 88 | you may at your option offer warranty protection in exchange for a fee. 89 | 90 | 2. You may modify your copy or copies of the Program or any portion 91 | of it, thus forming a work based on the Program, and copy and 92 | distribute such modifications or work under the terms of Section 1 93 | above, provided that you also meet all of these conditions: 94 | 95 | a) You must cause the modified files to carry prominent notices 96 | stating that you changed the files and the date of any change. 97 | 98 | b) You must cause any work that you distribute or publish, that in 99 | whole or in part contains or is derived from the Program or any 100 | part thereof, to be licensed as a whole at no charge to all third 101 | parties under the terms of this License. 102 | 103 | c) If the modified program normally reads commands interactively 104 | when run, you must cause it, when started running for such 105 | interactive use in the most ordinary way, to print or display an 106 | announcement including an appropriate copyright notice and a 107 | notice that there is no warranty (or else, saying that you provide 108 | a warranty) and that users may redistribute the program under 109 | these conditions, and telling the user how to view a copy of this 110 | License. (Exception: if the Program itself is interactive but 111 | does not normally print such an announcement, your work based on 112 | the Program is not required to print an announcement.) 113 | 114 | These requirements apply to the modified work as a whole. If 115 | identifiable sections of that work are not derived from the Program, 116 | and can be reasonably considered independent and separate works in 117 | themselves, then this License, and its terms, do not apply to those 118 | sections when you distribute them as separate works. But when you 119 | distribute the same sections as part of a whole which is a work based 120 | on the Program, the distribution of the whole must be on the terms of 121 | this License, whose permissions for other licensees extend to the 122 | entire whole, and thus to each and every part regardless of who wrote it. 123 | 124 | Thus, it is not the intent of this section to claim rights or contest 125 | your rights to work written entirely by you; rather, the intent is to 126 | exercise the right to control the distribution of derivative or 127 | collective works based on the Program. 128 | 129 | In addition, mere aggregation of another work not based on the Program 130 | with the Program (or with a work based on the Program) on a volume of 131 | a storage or distribution medium does not bring the other work under 132 | the scope of this License. 133 | 134 | 3. You may copy and distribute the Program (or a work based on it, 135 | under Section 2) in object code or executable form under the terms of 136 | Sections 1 and 2 above provided that you also do one of the following: 137 | 138 | a) Accompany it with the complete corresponding machine-readable 139 | source code, which must be distributed under the terms of Sections 140 | 1 and 2 above on a medium customarily used for software interchange; or, 141 | 142 | b) Accompany it with a written offer, valid for at least three 143 | years, to give any third party, for a charge no more than your 144 | cost of physically performing source distribution, a complete 145 | machine-readable copy of the corresponding source code, to be 146 | distributed under the terms of Sections 1 and 2 above on a medium 147 | customarily used for software interchange; or, 148 | 149 | c) Accompany it with the information you received as to the offer 150 | to distribute corresponding source code. (This alternative is 151 | allowed only for noncommercial distribution and only if you 152 | received the program in object code or executable form with such 153 | an offer, in accord with Subsection b above.) 154 | 155 | The source code for a work means the preferred form of the work for 156 | making modifications to it. For an executable work, complete source 157 | code means all the source code for all modules it contains, plus any 158 | associated interface definition files, plus the scripts used to 159 | control compilation and installation of the executable. However, as a 160 | special exception, the source code distributed need not include 161 | anything that is normally distributed (in either source or binary 162 | form) with the major components (compiler, kernel, and so on) of the 163 | operating system on which the executable runs, unless that component 164 | itself accompanies the executable. 165 | 166 | If distribution of executable or object code is made by offering 167 | access to copy from a designated place, then offering equivalent 168 | access to copy the source code from the same place counts as 169 | distribution of the source code, even though third parties are not 170 | compelled to copy the source along with the object code. 171 | 172 | 4. You may not copy, modify, sublicense, or distribute the Program 173 | except as expressly provided under this License. Any attempt 174 | otherwise to copy, modify, sublicense or distribute the Program is 175 | void, and will automatically terminate your rights under this License. 176 | However, parties who have received copies, or rights, from you under 177 | this License will not have their licenses terminated so long as such 178 | parties remain in full compliance. 179 | 180 | 5. You are not required to accept this License, since you have not 181 | signed it. However, nothing else grants you permission to modify or 182 | distribute the Program or its derivative works. These actions are 183 | prohibited by law if you do not accept this License. Therefore, by 184 | modifying or distributing the Program (or any work based on the 185 | Program), you indicate your acceptance of this License to do so, and 186 | all its terms and conditions for copying, distributing or modifying 187 | the Program or works based on it. 188 | 189 | 6. Each time you redistribute the Program (or any work based on the 190 | Program), the recipient automatically receives a license from the 191 | original licensor to copy, distribute or modify the Program subject to 192 | these terms and conditions. You may not impose any further 193 | restrictions on the recipients' exercise of the rights granted herein. 194 | You are not responsible for enforcing compliance by third parties to 195 | this License. 196 | 197 | 7. If, as a consequence of a court judgment or allegation of patent 198 | infringement or for any other reason (not limited to patent issues), 199 | conditions are imposed on you (whether by court order, agreement or 200 | otherwise) that contradict the conditions of this License, they do not 201 | excuse you from the conditions of this License. If you cannot 202 | distribute so as to satisfy simultaneously your obligations under this 203 | License and any other pertinent obligations, then as a consequence you 204 | may not distribute the Program at all. For example, if a patent 205 | license would not permit royalty-free redistribution of the Program by 206 | all those who receive copies directly or indirectly through you, then 207 | the only way you could satisfy both it and this License would be to 208 | refrain entirely from distribution of the Program. 209 | 210 | If any portion of this section is held invalid or unenforceable under 211 | any particular circumstance, the balance of the section is intended to 212 | apply and the section as a whole is intended to apply in other 213 | circumstances. 214 | 215 | It is not the purpose of this section to induce you to infringe any 216 | patents or other property right claims or to contest validity of any 217 | such claims; this section has the sole purpose of protecting the 218 | integrity of the free software distribution system, which is 219 | implemented by public license practices. Many people have made 220 | generous contributions to the wide range of software distributed 221 | through that system in reliance on consistent application of that 222 | system; it is up to the author/donor to decide if he or she is willing 223 | to distribute software through any other system and a licensee cannot 224 | impose that choice. 225 | 226 | This section is intended to make thoroughly clear what is believed to 227 | be a consequence of the rest of this License. 228 | 229 | 8. If the distribution and/or use of the Program is restricted in 230 | certain countries either by patents or by copyrighted interfaces, the 231 | original copyright holder who places the Program under this License 232 | may add an explicit geographical distribution limitation excluding 233 | those countries, so that distribution is permitted only in or among 234 | countries not thus excluded. In such case, this License incorporates 235 | the limitation as if written in the body of this License. 236 | 237 | 9. The Free Software Foundation may publish revised and/or new versions 238 | of the General Public License from time to time. Such new versions will 239 | be similar in spirit to the present version, but may differ in detail to 240 | address new problems or concerns. 241 | 242 | Each version is given a distinguishing version number. If the Program 243 | specifies a version number of this License which applies to it and "any 244 | later version", you have the option of following the terms and conditions 245 | either of that version or of any later version published by the Free 246 | Software Foundation. If the Program does not specify a version number of 247 | this License, you may choose any version ever published by the Free Software 248 | Foundation. 249 | 250 | 10. If you wish to incorporate parts of the Program into other free 251 | programs whose distribution conditions are different, write to the author 252 | to ask for permission. For software which is copyrighted by the Free 253 | Software Foundation, write to the Free Software Foundation; we sometimes 254 | make exceptions for this. Our decision will be guided by the two goals 255 | of preserving the free status of all derivatives of our free software and 256 | of promoting the sharing and reuse of software generally. 257 | 258 | NO WARRANTY 259 | 260 | 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY 261 | FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN 262 | OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES 263 | PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED 264 | OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 265 | MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS 266 | TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE 267 | PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, 268 | REPAIR OR CORRECTION. 269 | 270 | 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING 271 | WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR 272 | REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, 273 | INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING 274 | OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED 275 | TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY 276 | YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER 277 | PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE 278 | POSSIBILITY OF SUCH DAMAGES. 279 | 280 | END OF TERMS AND CONDITIONS 281 | 282 | How to Apply These Terms to Your New Programs 283 | 284 | If you develop a new program, and you want it to be of the greatest 285 | possible use to the public, the best way to achieve this is to make it 286 | free software which everyone can redistribute and change under these terms. 287 | 288 | To do so, attach the following notices to the program. It is safest 289 | to attach them to the start of each source file to most effectively 290 | convey the exclusion of warranty; and each file should have at least 291 | the "copyright" line and a pointer to where the full notice is found. 292 | 293 | 294 | Copyright (C) 295 | 296 | This program is free software; you can redistribute it and/or modify 297 | it under the terms of the GNU General Public License as published by 298 | the Free Software Foundation; either version 2 of the License, or 299 | (at your option) any later version. 300 | 301 | This program is distributed in the hope that it will be useful, 302 | but WITHOUT ANY WARRANTY; without even the implied warranty of 303 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 304 | GNU General Public License for more details. 305 | 306 | You should have received a copy of the GNU General Public License along 307 | with this program; if not, write to the Free Software Foundation, Inc., 308 | 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. 309 | 310 | Also add information on how to contact you by electronic and paper mail. 311 | 312 | If the program is interactive, make it output a short notice like this 313 | when it starts in an interactive mode: 314 | 315 | Gnomovision version 69, Copyright (C) year name of author 316 | Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. 317 | This is free software, and you are welcome to redistribute it 318 | under certain conditions; type `show c' for details. 319 | 320 | The hypothetical commands `show w' and `show c' should show the appropriate 321 | parts of the General Public License. Of course, the commands you use may 322 | be called something other than `show w' and `show c'; they could even be 323 | mouse-clicks or menu items--whatever suits your program. 324 | 325 | You should also get your employer (if you work as a programmer) or your 326 | school, if any, to sign a "copyright disclaimer" for the program, if 327 | necessary. Here is a sample; alter the names: 328 | 329 | Yoyodyne, Inc., hereby disclaims all copyright interest in the program 330 | `Gnomovision' (which makes passes at compilers) written by James Hacker. 331 | 332 | , 1 April 1989 333 | Ty Coon, President of Vice 334 | 335 | This General Public License does not permit incorporating your program into 336 | proprietary programs. If your program is a subroutine library, you may 337 | consider it more useful to permit linking proprietary applications with the 338 | library. If this is what you want to do, use the GNU Lesser General 339 | Public License instead of this License. 340 | -------------------------------------------------------------------------------- /ChangeLog: -------------------------------------------------------------------------------- 1 | 2007-03-03 Karl Chen 2 | 3 | * v1.0 release - working deskew! 4 | * Code base started using gimp-plugin-template 5 | * Radon algorithm based on pagetools 6 | -------------------------------------------------------------------------------- /HACKING: -------------------------------------------------------------------------------- 1 | If you want to hack a gimp plugin based on the gimp-plugin-template package, 2 | it will make you life easier to have the following packages installed: 3 | 4 | - GNU autoconf >= 2.54 5 | - GNU automake >= 1.7 6 | 7 | These should be available by ftp from prep.ai.mit.edu or any of the 8 | fine GNU mirrors. Beta software can be found at alpha.gnu.org. 9 | 10 | If you are accessing gimp-plugin-template via CVS, then you will need 11 | to take several steps to get it to compile. You can do all these steps 12 | at once by running: 13 | 14 | ./autogen.sh 15 | 16 | Basically this does the following for you: 17 | 18 | aclocal; automake; autoconf 19 | 20 | The above commands create the "configure" script. Now you 21 | can run the configure script to create all the Makefiles. 22 | 23 | Before running autogen.sh or configure, make sure you have libtool in 24 | your path. Also make sure gimp-2.0.m4 is in the same --prefix relative 25 | to your automake installation. 26 | 27 | Note that autogen.sh runs configure for you. If you wish to pass 28 | options like --prefix=/usr to configure you can give those options 29 | to autogen.sh and they will be passed on to configure. 30 | -------------------------------------------------------------------------------- /INSTALL: -------------------------------------------------------------------------------- 1 | Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002 Free Software 2 | Foundation, Inc. 3 | 4 | This file is free documentation; the Free Software Foundation gives 5 | unlimited permission to copy, distribute and modify it. 6 | 7 | Basic Installation 8 | ================== 9 | 10 | These are generic installation instructions. 11 | 12 | The `configure' shell script attempts to guess correct values for 13 | various system-dependent variables used during compilation. It uses 14 | those values to create a `Makefile' in each directory of the package. 15 | It may also create one or more `.h' files containing system-dependent 16 | definitions. Finally, it creates a shell script `config.status' that 17 | you can run in the future to recreate the current configuration, and a 18 | file `config.log' containing compiler output (useful mainly for 19 | debugging `configure'). 20 | 21 | It can also use an optional file (typically called `config.cache' 22 | and enabled with `--cache-file=config.cache' or simply `-C') that saves 23 | the results of its tests to speed up reconfiguring. (Caching is 24 | disabled by default to prevent problems with accidental use of stale 25 | cache files.) 26 | 27 | If you need to do unusual things to compile the package, please try 28 | to figure out how `configure' could check whether to do them, and mail 29 | diffs or instructions to the address given in the `README' so they can 30 | be considered for the next release. If you are using the cache, and at 31 | some point `config.cache' contains results you don't want to keep, you 32 | may remove or edit it. 33 | 34 | The file `configure.ac' (or `configure.in') is used to create 35 | `configure' by a program called `autoconf'. You only need 36 | `configure.ac' if you want to change it or regenerate `configure' using 37 | a newer version of `autoconf'. 38 | 39 | The simplest way to compile this package is: 40 | 41 | 1. `cd' to the directory containing the package's source code and type 42 | `./configure' to configure the package for your system. If you're 43 | using `csh' on an old version of System V, you might need to type 44 | `sh ./configure' instead to prevent `csh' from trying to execute 45 | `configure' itself. 46 | 47 | Running `configure' takes awhile. While running, it prints some 48 | messages telling which features it is checking for. 49 | 50 | 2. Type `make' to compile the package. 51 | 52 | 3. Optionally, type `make check' to run any self-tests that come with 53 | the package. 54 | 55 | 4. Type `make install' to install the programs and any data files and 56 | documentation. 57 | 58 | 5. You can remove the program binaries and object files from the 59 | source code directory by typing `make clean'. To also remove the 60 | files that `configure' created (so you can compile the package for 61 | a different kind of computer), type `make distclean'. There is 62 | also a `make maintainer-clean' target, but that is intended mainly 63 | for the package's developers. If you use it, you may have to get 64 | all sorts of other programs in order to regenerate files that came 65 | with the distribution. 66 | 67 | Compilers and Options 68 | ===================== 69 | 70 | Some systems require unusual options for compilation or linking that 71 | the `configure' script does not know about. Run `./configure --help' 72 | for details on some of the pertinent environment variables. 73 | 74 | You can give `configure' initial values for configuration parameters 75 | by setting variables in the command line or in the environment. Here 76 | is an example: 77 | 78 | ./configure CC=c89 CFLAGS=-O2 LIBS=-lposix 79 | 80 | *Note Defining Variables::, for more details. 81 | 82 | Compiling For Multiple Architectures 83 | ==================================== 84 | 85 | You can compile the package for more than one kind of computer at the 86 | same time, by placing the object files for each architecture in their 87 | own directory. To do this, you must use a version of `make' that 88 | supports the `VPATH' variable, such as GNU `make'. `cd' to the 89 | directory where you want the object files and executables to go and run 90 | the `configure' script. `configure' automatically checks for the 91 | source code in the directory that `configure' is in and in `..'. 92 | 93 | If you have to use a `make' that does not support the `VPATH' 94 | variable, you have to compile the package for one architecture at a 95 | time in the source code directory. After you have installed the 96 | package for one architecture, use `make distclean' before reconfiguring 97 | for another architecture. 98 | 99 | Installation Names 100 | ================== 101 | 102 | By default, `make install' will install the package's files in 103 | `/usr/local/bin', `/usr/local/man', etc. You can specify an 104 | installation prefix other than `/usr/local' by giving `configure' the 105 | option `--prefix=PATH'. 106 | 107 | You can specify separate installation prefixes for 108 | architecture-specific files and architecture-independent files. If you 109 | give `configure' the option `--exec-prefix=PATH', the package will use 110 | PATH as the prefix for installing programs and libraries. 111 | Documentation and other data files will still use the regular prefix. 112 | 113 | In addition, if you use an unusual directory layout you can give 114 | options like `--bindir=PATH' to specify different values for particular 115 | kinds of files. Run `configure --help' for a list of the directories 116 | you can set and what kinds of files go in them. 117 | 118 | If the package supports it, you can cause programs to be installed 119 | with an extra prefix or suffix on their names by giving `configure' the 120 | option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'. 121 | 122 | Optional Features 123 | ================= 124 | 125 | Some packages pay attention to `--enable-FEATURE' options to 126 | `configure', where FEATURE indicates an optional part of the package. 127 | They may also pay attention to `--with-PACKAGE' options, where PACKAGE 128 | is something like `gnu-as' or `x' (for the X Window System). The 129 | `README' should mention any `--enable-' and `--with-' options that the 130 | package recognizes. 131 | 132 | For packages that use the X Window System, `configure' can usually 133 | find the X include and library files automatically, but if it doesn't, 134 | you can use the `configure' options `--x-includes=DIR' and 135 | `--x-libraries=DIR' to specify their locations. 136 | 137 | Specifying the System Type 138 | ========================== 139 | 140 | There may be some features `configure' cannot figure out 141 | automatically, but needs to determine by the type of machine the package 142 | will run on. Usually, assuming the package is built to be run on the 143 | _same_ architectures, `configure' can figure that out, but if it prints 144 | a message saying it cannot guess the machine type, give it the 145 | `--build=TYPE' option. TYPE can either be a short name for the system 146 | type, such as `sun4', or a canonical name which has the form: 147 | 148 | CPU-COMPANY-SYSTEM 149 | 150 | where SYSTEM can have one of these forms: 151 | 152 | OS KERNEL-OS 153 | 154 | See the file `config.sub' for the possible values of each field. If 155 | `config.sub' isn't included in this package, then this package doesn't 156 | need to know the machine type. 157 | 158 | If you are _building_ compiler tools for cross-compiling, you should 159 | use the `--target=TYPE' option to select the type of system they will 160 | produce code for. 161 | 162 | If you want to _use_ a cross compiler, that generates code for a 163 | platform different from the build platform, you should specify the 164 | "host" platform (i.e., that on which the generated programs will 165 | eventually be run) with `--host=TYPE'. 166 | 167 | Sharing Defaults 168 | ================ 169 | 170 | If you want to set default values for `configure' scripts to share, 171 | you can create a site shell script called `config.site' that gives 172 | default values for variables like `CC', `cache_file', and `prefix'. 173 | `configure' looks for `PREFIX/share/config.site' if it exists, then 174 | `PREFIX/etc/config.site' if it exists. Or, you can set the 175 | `CONFIG_SITE' environment variable to the location of the site script. 176 | A warning: not all `configure' scripts look for a site script. 177 | 178 | Defining Variables 179 | ================== 180 | 181 | Variables not defined in a site shell script can be set in the 182 | environment passed to `configure'. However, some packages may run 183 | configure again during the build, and the customized values of these 184 | variables may be lost. In order to avoid this problem, you should set 185 | them in the `configure' command line, using `VAR=value'. For example: 186 | 187 | ./configure CC=/usr/local2/bin/gcc 188 | 189 | will cause the specified gcc to be used as the C compiler (unless it is 190 | overridden in the site shell script). 191 | 192 | `configure' Invocation 193 | ====================== 194 | 195 | `configure' recognizes the following options to control how it 196 | operates. 197 | 198 | `--help' 199 | `-h' 200 | Print a summary of the options to `configure', and exit. 201 | 202 | `--version' 203 | `-V' 204 | Print the version of Autoconf used to generate the `configure' 205 | script, and exit. 206 | 207 | `--cache-file=FILE' 208 | Enable the cache: use and save the results of the tests in FILE, 209 | traditionally `config.cache'. FILE defaults to `/dev/null' to 210 | disable caching. 211 | 212 | `--config-cache' 213 | `-C' 214 | Alias for `--cache-file=config.cache'. 215 | 216 | `--quiet' 217 | `--silent' 218 | `-q' 219 | Do not print messages saying which checks are being made. To 220 | suppress all normal output, redirect it to `/dev/null' (any error 221 | messages will still be shown). 222 | 223 | `--srcdir=DIR' 224 | Look for the package's source code in directory DIR. Usually 225 | `configure' can determine that directory automatically. 226 | 227 | `configure' also accepts some other, not widely useful, options. Run 228 | `configure --help' for more details. 229 | 230 | -------------------------------------------------------------------------------- /Makefile.am: -------------------------------------------------------------------------------- 1 | ## Process this file with automake to produce Makefile.in 2 | 3 | SUBDIRS = po src help 4 | 5 | EXTRA_DIST = \ 6 | BUGS \ 7 | HACKING \ 8 | autogen.sh \ 9 | intltool-extract.in \ 10 | intltool-merge.in \ 11 | intltool-update.in 12 | 13 | DISTCLEANFILES = \ 14 | intltool-extract \ 15 | intltool-merge \ 16 | intltool-update 17 | -------------------------------------------------------------------------------- /NEWS: -------------------------------------------------------------------------------- 1 | v1.1, 2014-10-27, Alexandre Prokoudine 2 | 3 | Changes: 4 | 5 | - Deskew has been relocated to 'Layer -> Transform' menu 6 | - Newer plugin template code 7 | - Support for more recent versions of automake 8 | - A few i18n fixes 9 | - The code fixed to use GIMP 2.8 API 10 | - The build system fixed to properly install the plugin's 11 | executable file 12 | 13 | Note that in this version cubic interpolation is harcoded. 14 | In the future, it might be a good idea to turn this into a 15 | GEGL op that would ask the user to choose a particular 16 | sampler. Patches are welcome. 17 | 18 | Contributors: Steve Lessard, Michael Natterer, 19 | Alexandre Prokoudine. 20 | 21 | v1.0, 2007-03-03, Karl Chen 22 | 23 | All assumed functionality presumably done. -------------------------------------------------------------------------------- /README: -------------------------------------------------------------------------------- 1 | This is original deskew plug-in for GIMP written by Karl Chen back in 2007. 2 | The plugin's homepage has been offline for a very long time, and the 3 | plug-in needed some fixes. So I went ahead and saved it from 4 | http://ccux-linux.de/pdb/index.php?pdetail=6271 where an src.rpm still had the 5 | original tarball. 6 | 7 | Below goes slightly adjusted original contents of README. 8 | 9 | GIMP Deskew Plug-In 10 | =================== 11 | 12 | Copyright (C) 2007 Karl Chen 13 | 14 | http://www.cubewano.org/gimp-deskew-plugin/ 15 | 16 | Distributed under GPL v2+ (see COPYING). 17 | 18 | Uses Radon skew detection algorithm and code from the PageTools project 19 | (http://sourceforge.net/projects/pagetools). kale4@users.sourceforge.net, 20 | yet@users.sourceforge.net. 21 | 22 | 23 | Usage 24 | ===== 25 | 26 | Click Layer => Transform => Deskew. 27 | 28 | Gimp will auto-straighten ("deskew") the image. 29 | 30 | 31 | Installation 32 | ============ 33 | 34 | Building/installation procedure depends on where you got the source code from. 35 | 36 | If you got source code from Git repository, 37 | 38 | ./autogen.sh 39 | make 40 | make install 41 | 42 | If you got a tarball with a version, 43 | 44 | ./configure 45 | make 46 | make install 47 | 48 | For both ./autogen.sh and ./configure you can use --prefix=INSTALL_PATH, where 49 | a typical installation path is /usr. By default /usr/local is used. 50 | -------------------------------------------------------------------------------- /TODO: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/gimp-plugins-justice/gimp-deskew-plugin/c56eed407b3fcf8cf1cff468259b440a6946311e/TODO -------------------------------------------------------------------------------- /admin/prat-config.py: -------------------------------------------------------------------------------- 1 | 2 | # config file for PRAT (see http://www.cubewano.org/prat/) 3 | 4 | PROJ_NAME = 'gimp-deskew-plugin' 5 | 6 | REPO_BASE = 'https://svn.cubewano.org/repos/%(PROJ_NAME)s'%locals() 7 | 8 | REPO_TRUNK = '%(REPO_BASE)s/trunk'%locals() 9 | REPO_TAG_DIR = '%(REPO_BASE)s/tags'%locals() 10 | 11 | RELEASES_DIR = '/srv/cubewano/www/%(PROJ_NAME)s/downloads'%locals() 12 | 13 | # DOC_OUTPUT = '/home/quarl/proj/%(PROJ_NAME)s/www/releases.htxt'%locals() 14 | # DOC_URL_DOWNLOAD_PREFIX = 'releases/' 15 | -------------------------------------------------------------------------------- /admin/prat-config.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/gimp-plugins-justice/gimp-deskew-plugin/c56eed407b3fcf8cf1cff468259b440a6946311e/admin/prat-config.pyc -------------------------------------------------------------------------------- /admin/version.py: -------------------------------------------------------------------------------- 1 | # $Id: version.py 148 2006-09-22 01:30:23Z quarl $ 2 | 3 | import subprocess 4 | 5 | def pipefrom(cmd): 6 | return subprocess.Popen(cmd, stdout=subprocess.PIPE).communicate()[0] 7 | 8 | # TODO: get this from config file or vice versa, but don't hard-code both. 9 | version = '1.1.0' 10 | -------------------------------------------------------------------------------- /admin/version.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/gimp-plugins-justice/gimp-deskew-plugin/c56eed407b3fcf8cf1cff468259b440a6946311e/admin/version.pyc -------------------------------------------------------------------------------- /autogen.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | # This script does all the magic calls to automake/autoconf and 4 | # friends that are needed to configure a cvs checkout. You need a 5 | # couple of extra tools to run this script successfully. 6 | # 7 | # If you are compiling from a released tarball you don't need these 8 | # tools and you shouldn't use this script. Just call ./configure 9 | # directly. 10 | 11 | PROJECT="GIMP Deskew Plug-In" 12 | TEST_TYPE=-f 13 | FILE=src/render.c 14 | 15 | AUTOCONF_REQUIRED_VERSION=2.54 16 | AUTOMAKE_REQUIRED_VERSION=1.6 17 | GLIB_REQUIRED_VERSION=2.0.0 18 | INTLTOOL_REQUIRED_VERSION=0.17 19 | 20 | srcdir=`dirname $0` 21 | test -z "$srcdir" && srcdir=. 22 | ORIGDIR=`pwd` 23 | cd $srcdir 24 | 25 | check_version () 26 | { 27 | # Get the major and minor version numbers 28 | local ACTUAL_VERSION_MAJOR_MINOR=$(expr "$1" : '\([[:digit:]][[:digit:]]*\.[[:digit:]]*[[:digit:]]*\)') 29 | local ACTUAL_VERSION_MAJOR=$(expr "$ACTUAL_VERSION_MAJOR_MINOR" : '\([[:digit:]][[:digit:]]*\)') 30 | local ACTUAL_VERSION_MINOR=$(expr "$ACTUAL_VERSION_MAJOR_MINOR" : '.*\.\([[:digit:]]*[[:digit:]]*\)') 31 | local MIN_VERSION_MAJOR_MINOR=$(expr "$2" : '\([[:digit:]][[:digit:]]*\.[[:digit:]]*[[:digit:]]*\)') 32 | local MIN_VERSION_MAJOR=$(expr "$MIN_VERSION_MAJOR_MINOR" : '\([[:digit:]][[:digit:]]*\)') 33 | local MIN_VERSION_MINOR=$(expr "$MIN_VERSION_MAJOR_MINOR" : '.*\.\([[:digit:]]*[[:digit:]]*\)') 34 | if expr $ACTUAL_VERSION_MAJOR \> $MIN_VERSION_MAJOR > /dev/null; then 35 | echo "yes (version $1)" 36 | elif expr $ACTUAL_VERSION_MAJOR = $MIN_VERSION_MAJOR && expr $ACTUAL_VERSION_MINOR \>= $MIN_VERSION_MINOR > /dev/null; then 37 | echo "yes (version $1)" 38 | else 39 | echo "Too old (found version $1)!" 40 | DIE=1 41 | fi 42 | } 43 | 44 | echo 45 | echo "I am testing that you have the required versions of autoconf," 46 | echo "automake, glib-gettextize and intltoolize..." 47 | echo 48 | 49 | DIE=0 50 | 51 | echo -n "checking for autoconf >= $AUTOCONF_REQUIRED_VERSION ... " 52 | if (autoconf --version) < /dev/null > /dev/null 2>&1; then 53 | VER=`autoconf --version \ 54 | | grep -iw autoconf | sed "s/.* \([0-9.]*\)[-a-z0-9]*$/\1/"` 55 | check_version $VER $AUTOCONF_REQUIRED_VERSION 56 | else 57 | echo 58 | echo " You must have autoconf installed to compile $PROJECT." 59 | echo " Download the appropriate package for your distribution," 60 | echo " or get the source tarball at ftp://ftp.gnu.org/pub/gnu/" 61 | DIE=1; 62 | fi 63 | 64 | echo -n "checking for automake >= $AUTOMAKE_REQUIRED_VERSION ... " 65 | if (automake-1.6 --version) < /dev/null > /dev/null 2>&1; then 66 | AUTOMAKE=automake-1.6 67 | ACLOCAL=aclocal-1.6 68 | elif (automake-1.7 --version) < /dev/null > /dev/null 2>&1; then 69 | AUTOMAKE=automake-1.7 70 | ACLOCAL=aclocal-1.7 71 | elif (automake-1.8 --version) < /dev/null > /dev/null 2>&1; then 72 | AUTOMAKE=automake-1.8 73 | ACLOCAL=aclocal-1.8 74 | elif (automake-1.9 --version) < /dev/null > /dev/null 2>&1; then 75 | AUTOMAKE=automake-1.9 76 | ACLOCAL=aclocal-1.9 77 | elif (automake-1.11 --version) < /dev/null > /dev/null 2>&1; then 78 | AUTOMAKE=automake-1.11 79 | ACLOCAL=aclocal-1.11 80 | elif (automake-1.12 --version) < /dev/null > /dev/null 2>&1; then 81 | AUTOMAKE=automake-1.12 82 | ACLOCAL=aclocal-1.12 83 | elif (automake-1.13 --version) < /dev/null > /dev/null 2>&1; then 84 | AUTOMAKE=automake-1.13 85 | ACLOCAL=aclocal-1.13 86 | elif (automake-1.14 --version) < /dev/null > /dev/null 2>&1; then 87 | AUTOMAKE=automake-1.14 88 | ACLOCAL=aclocal-1.14 89 | elif (automake-1.15 --version) < /dev/null > /dev/null 2>&1; then 90 | AUTOMAKE=automake-1.15 91 | ACLOCAL=aclocal-1.15 92 | elif (automake-1.16 --version) < /dev/null > /dev/null 2>&1; then 93 | AUTOMAKE=automake-1.16 94 | ACLOCAL=aclocal-1.16 95 | elif (automake-1.17 --version) < /dev/null > /dev/null 2>&1; then 96 | AUTOMAKE=automake-1.17 97 | ACLOCAL=aclocal-1.17 98 | else 99 | echo 100 | echo " You must have automake 1.6 or newer installed to compile $PROJECT." 101 | echo " Download the appropriate package for your distribution," 102 | echo " or get the source tarball at ftp://ftp.gnu.org/pub/gnu/automake/" 103 | DIE=1 104 | fi 105 | 106 | if test x$AUTOMAKE != x; then 107 | VER=`$AUTOMAKE --version \ 108 | | grep automake | sed "s/.* \([0-9.]*\)[-a-z0-9]*$/\1/"` 109 | check_version $VER $AUTOMAKE_REQUIRED_VERSION 110 | fi 111 | 112 | echo -n "checking for glib-gettextize >= $GLIB_REQUIRED_VERSION ... " 113 | if (glib-gettextize --version) < /dev/null > /dev/null 2>&1; then 114 | VER=`glib-gettextize --version \ 115 | | grep glib-gettextize | sed "s/.* \([0-9.]*\)/\1/"` 116 | check_version $VER $GLIB_REQUIRED_VERSION 117 | else 118 | echo 119 | echo " You must have glib-gettextize installed to compile $PROJECT." 120 | echo " glib-gettextize is part of glib-2.0, so you should already" 121 | echo " have it. Make sure it is in your PATH." 122 | DIE=1 123 | fi 124 | 125 | echo -n "checking for intltool >= $INTLTOOL_REQUIRED_VERSION ... " 126 | if (intltoolize --version) < /dev/null > /dev/null 2>&1; then 127 | VER=`intltoolize --version \ 128 | | grep intltoolize | sed "s/.* \([0-9.]*\)/\1/"` 129 | check_version $VER $INTLTOOL_REQUIRED_VERSION 130 | else 131 | echo 132 | echo " You must have intltool installed to compile $PROJECT." 133 | echo " Get the latest version from" 134 | echo " ftp://ftp.gnome.org/pub/GNOME/sources/intltool/" 135 | DIE=1 136 | fi 137 | 138 | if test "$DIE" -eq 1; then 139 | echo 140 | echo "Please install/upgrade the missing tools and call me again." 141 | echo 142 | exit 1 143 | fi 144 | 145 | 146 | test $TEST_TYPE $FILE || { 147 | echo 148 | echo "You must run this script in the top-level $PROJECT directory." 149 | echo 150 | exit 1 151 | } 152 | 153 | 154 | echo 155 | echo "I am going to run ./configure with the following arguments:" 156 | echo 157 | echo " --enable-maintainer-mode $AUTOGEN_CONFIGURE_ARGS $@" 158 | echo 159 | 160 | if test -z "$*"; then 161 | echo "If you wish to pass additional arguments, please specify them " 162 | echo "on the $0 command line or set the AUTOGEN_CONFIGURE_ARGS " 163 | echo "environment variable." 164 | echo 165 | fi 166 | 167 | if test -z "$ACLOCAL_FLAGS"; then 168 | 169 | acdir=`$ACLOCAL --print-ac-dir` 170 | m4list="glib-gettext.m4 intltool.m4" 171 | 172 | for file in $m4list 173 | do 174 | if [ ! -f "$acdir/$file" ]; then 175 | echo 176 | echo "WARNING: aclocal's directory is $acdir, but..." 177 | echo " no file $acdir/$file" 178 | echo " You may see fatal macro warnings below." 179 | echo " If these files are installed in /some/dir, set the ACLOCAL_FLAGS " 180 | echo " environment variable to \"-I /some/dir\", or install" 181 | echo " $acdir/$file." 182 | echo 183 | fi 184 | done 185 | fi 186 | 187 | rm -rf autom4te.cache 188 | 189 | $ACLOCAL $ACLOCAL_FLAGS 190 | RC=$? 191 | if test $RC -ne 0; then 192 | echo "$ACLOCAL gave errors. Please fix the error conditions and try again." 193 | exit 1 194 | fi 195 | 196 | # optionally feature autoheader 197 | (autoheader --version) < /dev/null > /dev/null 2>&1 && autoheader || exit 1 198 | 199 | $AUTOMAKE --add-missing || exit 1 200 | autoconf || exit 1 201 | 202 | glib-gettextize --force || exit 1 203 | intltoolize --force --automake || exit 1 204 | 205 | cd $ORIGDIR 206 | 207 | $srcdir/configure --enable-maintainer-mode $AUTOGEN_CONFIGURE_ARGS "$@" 208 | RC=$? 209 | if test $RC -ne 0; then 210 | echo 211 | echo "Configure failed or did not finish!" 212 | exit $RC 213 | fi 214 | 215 | echo 216 | echo "Now type 'make' to compile $PROJECT." 217 | -------------------------------------------------------------------------------- /config.h.in: -------------------------------------------------------------------------------- 1 | /* config.h.in. Generated from configure.in by autoheader. */ 2 | 3 | /* always defined to indicate that i18n is enabled */ 4 | #undef ENABLE_NLS 5 | 6 | /* The gettext translation domain. */ 7 | #undef GETTEXT_PACKAGE 8 | 9 | /* Define to 1 if you have the `bind_textdomain_codeset' function. */ 10 | #undef HAVE_BIND_TEXTDOMAIN_CODESET 11 | 12 | /* Define to 1 if you have the `dcgettext' function. */ 13 | #undef HAVE_DCGETTEXT 14 | 15 | /* Define if the GNU gettext() function is already present or preinstalled. */ 16 | #undef HAVE_GETTEXT 17 | 18 | /* Define to 1 if you have the header file. */ 19 | #undef HAVE_INTTYPES_H 20 | 21 | /* Define if your file defines LC_MESSAGES. */ 22 | #undef HAVE_LC_MESSAGES 23 | 24 | /* Define to 1 if you have the header file. */ 25 | #undef HAVE_LOCALE_H 26 | 27 | /* Define to 1 if you have the header file. */ 28 | #undef HAVE_MEMORY_H 29 | 30 | /* Define to 1 if you have the header file. */ 31 | #undef HAVE_STDINT_H 32 | 33 | /* Define to 1 if you have the header file. */ 34 | #undef HAVE_STDLIB_H 35 | 36 | /* Define to 1 if you have the header file. */ 37 | #undef HAVE_STRINGS_H 38 | 39 | /* Define to 1 if you have the header file. */ 40 | #undef HAVE_STRING_H 41 | 42 | /* Define to 1 if you have the header file. */ 43 | #undef HAVE_SYS_STAT_H 44 | 45 | /* Define to 1 if you have the header file. */ 46 | #undef HAVE_SYS_TYPES_H 47 | 48 | /* Define to 1 if you have the header file. */ 49 | #undef HAVE_UNISTD_H 50 | 51 | /* Define to the address where bug reports for this package should be sent. */ 52 | #undef PACKAGE_BUGREPORT 53 | 54 | /* Define to the full name of this package. */ 55 | #undef PACKAGE_NAME 56 | 57 | /* Define to the full name and version of this package. */ 58 | #undef PACKAGE_STRING 59 | 60 | /* Define to the one symbol short name of this package. */ 61 | #undef PACKAGE_TARNAME 62 | 63 | /* Define to the version of this package. */ 64 | #undef PACKAGE_VERSION 65 | 66 | /* Deskew */ 67 | #undef PLUGIN_NAME 68 | 69 | /* Define to 1 if you have the ANSI C header files. */ 70 | #undef STDC_HEADERS 71 | -------------------------------------------------------------------------------- /configure.in: -------------------------------------------------------------------------------- 1 | dnl Process this file with autoconf to produce a configure script. 2 | 3 | AC_PREREQ(2.54) 4 | 5 | dnl Name your plug-in here 6 | m4_define([plugin_name], [gimp-deskew-plugin]) 7 | 8 | dnl These three define the plug-in version number 9 | m4_define([plugin_major_version], [1]) 10 | m4_define([plugin_minor_version], [1]) 11 | m4_define([plugin_micro_version], [0]) 12 | 13 | m4_define([plugin_version], 14 | [plugin_major_version.plugin_minor_version.plugin_micro_version]) 15 | 16 | AC_INIT([plugin_name], [plugin_version]) 17 | 18 | AC_DEFINE(PLUGIN_NAME, PACKAGE_NAME, [Deskew]) 19 | dnl AC_DEFINE(PLUGIN_VERSION, PACKAGE_VERSION, [2.2.0]) 20 | 21 | dnl AC_DEFINE(PLUGIN_MAJOR_VERSION, plugin_major_version, [2]) 22 | dnl AC_DEFINE(PLUGIN_MINOR_VERSION, plugin_minor_version, [2]) 23 | dnl AC_DEFINE(PLUGIN_MICRO_VERSION, plugin_micro_version, [0]) 24 | 25 | AC_CONFIG_SRCDIR([src/main.c]) 26 | AM_CONFIG_HEADER(config.h) 27 | 28 | AM_INIT_AUTOMAKE(no-define) 29 | 30 | AC_ISC_POSIX 31 | AC_PROG_CC 32 | AM_PROG_CC_STDC 33 | AC_PROG_CXX 34 | AC_HEADER_STDC 35 | 36 | 37 | ACLOCAL="$ACLOCAL $ACLOCAL_FLAGS" 38 | 39 | AM_MAINTAINER_MODE 40 | 41 | 42 | dnl Use -Wall if we have gcc. 43 | changequote(,)dnl 44 | if test "x$GCC" = "xyes"; then 45 | case " $CFLAGS " in 46 | *[\ \ ]-Wall[\ \ ]*) ;; 47 | *) CFLAGS="$CFLAGS -Wall" ;; 48 | esac 49 | fi 50 | changequote([,])dnl 51 | 52 | 53 | GIMP_REQUIRED_VERSION=2.2.0 54 | 55 | PKG_CHECK_MODULES(GIMP, 56 | gimp-2.0 >= $GIMP_REQUIRED_VERSION gimpui-2.0 >= $GIMP_REQUIRED_VERSION) 57 | 58 | AC_SUBST(GIMP_CFLAGS) 59 | AC_SUBST(GIMP_LIBS) 60 | 61 | GIMP_LIBDIR=`$PKG_CONFIG --variable=gimplibdir gimp-2.0` 62 | AC_SUBST(GIMP_LIBDIR) 63 | 64 | 65 | dnl i18n stuff 66 | 67 | GETTEXT_PACKAGE=gimp20-deskew-plugin 68 | AC_SUBST(GETTEXT_PACKAGE) 69 | AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE", 70 | [The gettext translation domain.]) 71 | 72 | dnl Add the languages which your application supports here. 73 | dnl ALL_LINGUAS="az de fr sk sv zh_TW" 74 | ALL_LINGUAS="es ru" 75 | 76 | AC_PROG_INTLTOOL 77 | AM_GLIB_GNU_GETTEXT 78 | 79 | AC_CHECK_FUNCS(bind_textdomain_codeset) 80 | 81 | LOCALEDIR="${datadir}/locale" 82 | if test "$DATADIRNAME" = "lib"; then 83 | LOCALEDIR="$libdir/locale" 84 | fi 85 | AC_SUBST(LOCALEDIR) 86 | 87 | DATADIR="${datadir}/plugin_name" 88 | AC_SUBST(DATADIR) 89 | 90 | 91 | AC_MSG_CHECKING([if GTK+ is version 2.7.0 or newer]) 92 | if $PKG_CONFIG --atleast-version=2.7.0 gtk+-2.0; then 93 | have_gtk_2_7=yes 94 | else 95 | have_gtk_2_7=no 96 | fi 97 | AC_MSG_RESULT($have_gtk_2_7) 98 | 99 | if test "x$have_gtk_2_7" != "xyes"; then 100 | CPPFLAGS="$CPPFLAGS -DG_DISABLE_DEPRECATED -DGDK_DISABLE_DEPRECATED -DGTK_DISABLE_DEPRECATED" 101 | fi 102 | 103 | 104 | AC_MSG_CHECKING([if GIMP is version 2.3.0 or newer]) 105 | if $PKG_CONFIG --atleast-version=2.3.0 gimp-2.0; then 106 | have_gimp_2_3=yes 107 | else 108 | have_gimp_2_3=no 109 | fi 110 | AC_MSG_RESULT($have_gimp_2_3) 111 | 112 | if test "x$have_gimp_2_3" != "xyes"; then 113 | CPPFLAGS="$CPPFLAGS -DGIMP_DISABLE_DEPRECATED" 114 | fi 115 | 116 | 117 | 118 | AC_CONFIG_FILES([ 119 | Makefile 120 | src/Makefile 121 | po/Makefile.in 122 | help/Makefile 123 | help/en/Makefile 124 | help/es/Makefile 125 | help/images/Makefile 126 | ]) 127 | 128 | AC_OUTPUT 129 | -------------------------------------------------------------------------------- /debian/Makefile.am: -------------------------------------------------------------------------------- 1 | ## Process this file with automake to produce Makefile.in 2 | 3 | EXTRA_DIST = \ 4 | changelog \ 5 | control \ 6 | copyright \ 7 | docs \ 8 | gimp-deskew-plugin.doc-base \ 9 | rules 10 | -------------------------------------------------------------------------------- /debian/changelog: -------------------------------------------------------------------------------- 1 | gimp-deskew-plugin (1.1) unstable; urgency=low 2 | 3 | * Use tiling to significantly optimize transfer of data from GIMP to plugin. 4 | 5 | -- Karl Chen Sat, 08 Mar 2008 03:20:54 -0800 6 | 7 | gimp-deskew-plugin (1.0) unstable; urgency=low 8 | 9 | * Initial release. 10 | 11 | -- Karl Chen Sat, 3 Mar 2007 04:19:27 -0800 12 | 13 | 14 | -------------------------------------------------------------------------------- /debian/control: -------------------------------------------------------------------------------- 1 | Source: gimp-deskew-plugin 2 | Section: graphics 3 | Priority: optional 4 | Maintainer: Karl Chen 5 | Standards-Version: 3.0.1 6 | 7 | Package: gimp-deskew-plugin 8 | Architecture: any 9 | Depends: gimp (>= 2.0), ${shlibs:Depends} 10 | Description: A GIMP plugin for auto-straightening ("deskewing") an image. 11 | . 12 | Homepage: http://www.cubewano.org/gimp-deskew-plugin/ 13 | 14 | -------------------------------------------------------------------------------- /debian/copyright: -------------------------------------------------------------------------------- 1 | This package was debianized by Karl Chen on 2 | 2007-03-03. 3 | 4 | It was downloaded from http://www.cubewano.org/gimp-deskew-plugin/ 5 | 6 | Upstream Author(s): Karl Chen 7 | 8 | Copyright: (c) 2007 Karl Chen. 9 | 10 | The distribution of this software is subject to the terms of the GNU 11 | General Public License, the complete text of which may be found in 12 | /usr/share/common-licenses/GPL. 13 | -------------------------------------------------------------------------------- /debian/docs: -------------------------------------------------------------------------------- 1 | AUTHORS 2 | BUGS 3 | NEWS 4 | README 5 | TODO 6 | -------------------------------------------------------------------------------- /debian/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | # Sample debian/rules that uses debhelper. 3 | 4 | # quarl 2007-03-03 5 | # 6 | 7 | # Uncomment this to turn on verbose mode. 8 | #export DH_VERBOSE=1 9 | 10 | # This is the debhelper compatability version to use. 11 | export DH_COMPAT=4 12 | 13 | # Insane optimization rules 14 | # export CFLAGS=-funroll-loops -fexpensive-optimizations -fschedule-insns -O3 15 | 16 | build: build-stamp 17 | build-stamp: 18 | dh_testdir 19 | 20 | ./configure --prefix=/usr --mandir=\$${prefix}/share/man --infodir=\$${prefix}/share/info 21 | $(MAKE) 22 | 23 | touch build-stamp 24 | 25 | clean: 26 | dh_testdir 27 | dh_testroot 28 | rm -f build-stamp 29 | 30 | # Add here commands to clean up after the build process. 31 | -$(MAKE) distclean 32 | 33 | dh_clean 34 | 35 | install: build 36 | dh_testdir 37 | dh_testroot 38 | dh_clean -k 39 | dh_installdirs 40 | 41 | # Add here commands to install the package into debian/tmp. 42 | # $(MAKE) install prefix=`pwd`/debian/tmp/usr 43 | $(MAKE) install prefix=`pwd`/debian/`dh_listpackages` 44 | 45 | # Build architecture-independent files here. 46 | binary-indep: build install 47 | # We have nothing to do by default. 48 | 49 | # Build architecture-dependent files here. 50 | binary-arch: build install 51 | dh_testdir 52 | dh_testroot 53 | dh_installdocs 54 | dh_installchangelogs ChangeLog 55 | dh_link 56 | dh_strip 57 | dh_compress 58 | dh_fixperms 59 | dh_installdeb 60 | dh_shlibdeps 61 | dh_gencontrol 62 | dh_md5sums 63 | dh_builddeb 64 | 65 | binary: binary-indep binary-arch 66 | .PHONY: build clean binary-indep binary-arch binary install 67 | -------------------------------------------------------------------------------- /help/Makefile.am: -------------------------------------------------------------------------------- 1 | ## Process this file with automake to produce Makefile.in 2 | 3 | SUBDIRS = es en images 4 | -------------------------------------------------------------------------------- /help/Makefile.in: -------------------------------------------------------------------------------- 1 | # Makefile.in generated by automake 1.7.9 from Makefile.am. 2 | # @configure_input@ 3 | 4 | # Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 5 | # Free Software Foundation, Inc. 6 | # This Makefile.in is free software; the Free Software Foundation 7 | # gives unlimited permission to copy and/or distribute it, 8 | # with or without modifications, as long as this notice is preserved. 9 | 10 | # This program is distributed in the hope that it will be useful, 11 | # but WITHOUT ANY WARRANTY, to the extent permitted by law; without 12 | # even the implied warranty of MERCHANTABILITY or FITNESS FOR A 13 | # PARTICULAR PURPOSE. 14 | 15 | @SET_MAKE@ 16 | 17 | srcdir = @srcdir@ 18 | top_srcdir = @top_srcdir@ 19 | VPATH = @srcdir@ 20 | pkgdatadir = $(datadir)/@PACKAGE@ 21 | pkglibdir = $(libdir)/@PACKAGE@ 22 | pkgincludedir = $(includedir)/@PACKAGE@ 23 | top_builddir = .. 24 | 25 | am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd 26 | INSTALL = @INSTALL@ 27 | install_sh_DATA = $(install_sh) -c -m 644 28 | install_sh_PROGRAM = $(install_sh) -c 29 | install_sh_SCRIPT = $(install_sh) -c 30 | INSTALL_HEADER = $(INSTALL_DATA) 31 | transform = $(program_transform_name) 32 | NORMAL_INSTALL = : 33 | PRE_INSTALL = : 34 | POST_INSTALL = : 35 | NORMAL_UNINSTALL = : 36 | PRE_UNINSTALL = : 37 | POST_UNINSTALL = : 38 | ACLOCAL = @ACLOCAL@ 39 | ALL_LINGUAS = @ALL_LINGUAS@ 40 | AMDEP_FALSE = @AMDEP_FALSE@ 41 | AMDEP_TRUE = @AMDEP_TRUE@ 42 | AMTAR = @AMTAR@ 43 | AUTOCONF = @AUTOCONF@ 44 | AUTOHEADER = @AUTOHEADER@ 45 | AUTOMAKE = @AUTOMAKE@ 46 | AWK = @AWK@ 47 | CATALOGS = @CATALOGS@ 48 | CATOBJEXT = @CATOBJEXT@ 49 | CC = @CC@ 50 | CCDEPMODE = @CCDEPMODE@ 51 | CFLAGS = @CFLAGS@ 52 | CPP = @CPP@ 53 | CPPFLAGS = @CPPFLAGS@ 54 | CXX = @CXX@ 55 | CXXDEPMODE = @CXXDEPMODE@ 56 | CXXFLAGS = @CXXFLAGS@ 57 | CYGPATH_W = @CYGPATH_W@ 58 | DATADIR = @DATADIR@ 59 | DATADIRNAME = @DATADIRNAME@ 60 | DEFS = @DEFS@ 61 | DEPDIR = @DEPDIR@ 62 | ECHO_C = @ECHO_C@ 63 | ECHO_N = @ECHO_N@ 64 | ECHO_T = @ECHO_T@ 65 | EGREP = @EGREP@ 66 | EXEEXT = @EXEEXT@ 67 | GETTEXT_PACKAGE = @GETTEXT_PACKAGE@ 68 | GIMP_CFLAGS = @GIMP_CFLAGS@ 69 | GIMP_LIBDIR = @GIMP_LIBDIR@ 70 | GIMP_LIBS = @GIMP_LIBS@ 71 | GMOFILES = @GMOFILES@ 72 | GMSGFMT = @GMSGFMT@ 73 | GREP = @GREP@ 74 | INSTALL_DATA = @INSTALL_DATA@ 75 | INSTALL_PROGRAM = @INSTALL_PROGRAM@ 76 | INSTALL_SCRIPT = @INSTALL_SCRIPT@ 77 | INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ 78 | INSTOBJEXT = @INSTOBJEXT@ 79 | INTLLIBS = @INTLLIBS@ 80 | INTLTOOL_CAVES_RULE = @INTLTOOL_CAVES_RULE@ 81 | INTLTOOL_DESKTOP_RULE = @INTLTOOL_DESKTOP_RULE@ 82 | INTLTOOL_DIRECTORY_RULE = @INTLTOOL_DIRECTORY_RULE@ 83 | INTLTOOL_EXTRACT = @INTLTOOL_EXTRACT@ 84 | INTLTOOL_ICONV = @INTLTOOL_ICONV@ 85 | INTLTOOL_KBD_RULE = @INTLTOOL_KBD_RULE@ 86 | INTLTOOL_KEYS_RULE = @INTLTOOL_KEYS_RULE@ 87 | INTLTOOL_MERGE = @INTLTOOL_MERGE@ 88 | INTLTOOL_MSGFMT = @INTLTOOL_MSGFMT@ 89 | INTLTOOL_MSGMERGE = @INTLTOOL_MSGMERGE@ 90 | INTLTOOL_OAF_RULE = @INTLTOOL_OAF_RULE@ 91 | INTLTOOL_PERL = @INTLTOOL_PERL@ 92 | INTLTOOL_PONG_RULE = @INTLTOOL_PONG_RULE@ 93 | INTLTOOL_PROP_RULE = @INTLTOOL_PROP_RULE@ 94 | INTLTOOL_SCHEMAS_RULE = @INTLTOOL_SCHEMAS_RULE@ 95 | INTLTOOL_SERVER_RULE = @INTLTOOL_SERVER_RULE@ 96 | INTLTOOL_SERVICE_RULE = @INTLTOOL_SERVICE_RULE@ 97 | INTLTOOL_SHEET_RULE = @INTLTOOL_SHEET_RULE@ 98 | INTLTOOL_SOUNDLIST_RULE = @INTLTOOL_SOUNDLIST_RULE@ 99 | INTLTOOL_THEME_RULE = @INTLTOOL_THEME_RULE@ 100 | INTLTOOL_UI_RULE = @INTLTOOL_UI_RULE@ 101 | INTLTOOL_UPDATE = @INTLTOOL_UPDATE@ 102 | INTLTOOL_XAM_RULE = @INTLTOOL_XAM_RULE@ 103 | INTLTOOL_XGETTEXT = @INTLTOOL_XGETTEXT@ 104 | INTLTOOL_XML_NOMERGE_RULE = @INTLTOOL_XML_NOMERGE_RULE@ 105 | INTLTOOL_XML_RULE = @INTLTOOL_XML_RULE@ 106 | LDFLAGS = @LDFLAGS@ 107 | LIBOBJS = @LIBOBJS@ 108 | LIBS = @LIBS@ 109 | LOCALEDIR = @LOCALEDIR@ 110 | LTLIBOBJS = @LTLIBOBJS@ 111 | MAINT = @MAINT@ 112 | MAINTAINER_MODE_FALSE = @MAINTAINER_MODE_FALSE@ 113 | MAINTAINER_MODE_TRUE = @MAINTAINER_MODE_TRUE@ 114 | MAKEINFO = @MAKEINFO@ 115 | MKINSTALLDIRS = @MKINSTALLDIRS@ 116 | MSGFMT = @MSGFMT@ 117 | OBJEXT = @OBJEXT@ 118 | PACKAGE = @PACKAGE@ 119 | PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ 120 | PACKAGE_NAME = @PACKAGE_NAME@ 121 | PACKAGE_STRING = @PACKAGE_STRING@ 122 | PACKAGE_TARNAME = @PACKAGE_TARNAME@ 123 | PACKAGE_VERSION = @PACKAGE_VERSION@ 124 | PATH_SEPARATOR = @PATH_SEPARATOR@ 125 | PKG_CONFIG = @PKG_CONFIG@ 126 | POFILES = @POFILES@ 127 | POSUB = @POSUB@ 128 | PO_IN_DATADIR_FALSE = @PO_IN_DATADIR_FALSE@ 129 | PO_IN_DATADIR_TRUE = @PO_IN_DATADIR_TRUE@ 130 | SET_MAKE = @SET_MAKE@ 131 | SHELL = @SHELL@ 132 | STRIP = @STRIP@ 133 | USE_NLS = @USE_NLS@ 134 | VERSION = @VERSION@ 135 | XGETTEXT = @XGETTEXT@ 136 | ac_ct_CC = @ac_ct_CC@ 137 | ac_ct_CXX = @ac_ct_CXX@ 138 | am__fastdepCC_FALSE = @am__fastdepCC_FALSE@ 139 | am__fastdepCC_TRUE = @am__fastdepCC_TRUE@ 140 | am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@ 141 | am__fastdepCXX_TRUE = @am__fastdepCXX_TRUE@ 142 | am__include = @am__include@ 143 | am__leading_dot = @am__leading_dot@ 144 | am__quote = @am__quote@ 145 | bindir = @bindir@ 146 | build_alias = @build_alias@ 147 | datadir = @datadir@ 148 | datarootdir = @datarootdir@ 149 | docdir = @docdir@ 150 | dvidir = @dvidir@ 151 | exec_prefix = @exec_prefix@ 152 | host_alias = @host_alias@ 153 | htmldir = @htmldir@ 154 | includedir = @includedir@ 155 | infodir = @infodir@ 156 | install_sh = @install_sh@ 157 | libdir = @libdir@ 158 | libexecdir = @libexecdir@ 159 | localedir = @localedir@ 160 | localstatedir = @localstatedir@ 161 | mandir = @mandir@ 162 | oldincludedir = @oldincludedir@ 163 | pdfdir = @pdfdir@ 164 | prefix = @prefix@ 165 | program_transform_name = @program_transform_name@ 166 | psdir = @psdir@ 167 | sbindir = @sbindir@ 168 | sharedstatedir = @sharedstatedir@ 169 | sysconfdir = @sysconfdir@ 170 | target_alias = @target_alias@ 171 | 172 | SUBDIRS = en images 173 | subdir = help 174 | ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 175 | mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs 176 | CONFIG_HEADER = $(top_builddir)/config.h 177 | CONFIG_CLEAN_FILES = 178 | DIST_SOURCES = 179 | 180 | RECURSIVE_TARGETS = info-recursive dvi-recursive pdf-recursive \ 181 | ps-recursive install-info-recursive uninstall-info-recursive \ 182 | all-recursive install-data-recursive install-exec-recursive \ 183 | installdirs-recursive install-recursive uninstall-recursive \ 184 | check-recursive installcheck-recursive 185 | DIST_COMMON = $(srcdir)/Makefile.in Makefile.am 186 | DIST_SUBDIRS = $(SUBDIRS) 187 | all: all-recursive 188 | 189 | .SUFFIXES: 190 | $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4) 191 | cd $(top_srcdir) && \ 192 | $(AUTOMAKE) --gnu help/Makefile 193 | Makefile: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.in $(top_builddir)/config.status 194 | cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe) 195 | uninstall-info-am: 196 | 197 | # This directory's subdirectories are mostly independent; you can cd 198 | # into them and run `make' without going through this Makefile. 199 | # To change the values of `make' variables: instead of editing Makefiles, 200 | # (1) if the variable is set in `config.status', edit `config.status' 201 | # (which will cause the Makefiles to be regenerated when you run `make'); 202 | # (2) otherwise, pass the desired values on the `make' command line. 203 | $(RECURSIVE_TARGETS): 204 | @set fnord $$MAKEFLAGS; amf=$$2; \ 205 | dot_seen=no; \ 206 | target=`echo $@ | sed s/-recursive//`; \ 207 | list='$(SUBDIRS)'; for subdir in $$list; do \ 208 | echo "Making $$target in $$subdir"; \ 209 | if test "$$subdir" = "."; then \ 210 | dot_seen=yes; \ 211 | local_target="$$target-am"; \ 212 | else \ 213 | local_target="$$target"; \ 214 | fi; \ 215 | (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ 216 | || case "$$amf" in *=*) exit 1;; *k*) fail=yes;; *) exit 1;; esac; \ 217 | done; \ 218 | if test "$$dot_seen" = "no"; then \ 219 | $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ 220 | fi; test -z "$$fail" 221 | 222 | mostlyclean-recursive clean-recursive distclean-recursive \ 223 | maintainer-clean-recursive: 224 | @set fnord $$MAKEFLAGS; amf=$$2; \ 225 | dot_seen=no; \ 226 | case "$@" in \ 227 | distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ 228 | *) list='$(SUBDIRS)' ;; \ 229 | esac; \ 230 | rev=''; for subdir in $$list; do \ 231 | if test "$$subdir" = "."; then :; else \ 232 | rev="$$subdir $$rev"; \ 233 | fi; \ 234 | done; \ 235 | rev="$$rev ."; \ 236 | target=`echo $@ | sed s/-recursive//`; \ 237 | for subdir in $$rev; do \ 238 | echo "Making $$target in $$subdir"; \ 239 | if test "$$subdir" = "."; then \ 240 | local_target="$$target-am"; \ 241 | else \ 242 | local_target="$$target"; \ 243 | fi; \ 244 | (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ 245 | || case "$$amf" in *=*) exit 1;; *k*) fail=yes;; *) exit 1;; esac; \ 246 | done && test -z "$$fail" 247 | tags-recursive: 248 | list='$(SUBDIRS)'; for subdir in $$list; do \ 249 | test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \ 250 | done 251 | ctags-recursive: 252 | list='$(SUBDIRS)'; for subdir in $$list; do \ 253 | test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \ 254 | done 255 | 256 | ETAGS = etags 257 | ETAGSFLAGS = 258 | 259 | CTAGS = ctags 260 | CTAGSFLAGS = 261 | 262 | tags: TAGS 263 | 264 | ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) 265 | list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ 266 | unique=`for i in $$list; do \ 267 | if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ 268 | done | \ 269 | $(AWK) ' { files[$$0] = 1; } \ 270 | END { for (i in files) print i; }'`; \ 271 | mkid -fID $$unique 272 | 273 | TAGS: tags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ 274 | $(TAGS_FILES) $(LISP) 275 | tags=; \ 276 | here=`pwd`; \ 277 | if (etags --etags-include --version) >/dev/null 2>&1; then \ 278 | include_option=--etags-include; \ 279 | else \ 280 | include_option=--include; \ 281 | fi; \ 282 | list='$(SUBDIRS)'; for subdir in $$list; do \ 283 | if test "$$subdir" = .; then :; else \ 284 | test -f $$subdir/TAGS && \ 285 | tags="$$tags $$include_option=$$here/$$subdir/TAGS"; \ 286 | fi; \ 287 | done; \ 288 | list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ 289 | unique=`for i in $$list; do \ 290 | if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ 291 | done | \ 292 | $(AWK) ' { files[$$0] = 1; } \ 293 | END { for (i in files) print i; }'`; \ 294 | test -z "$(ETAGS_ARGS)$$tags$$unique" \ 295 | || $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ 296 | $$tags $$unique 297 | 298 | ctags: CTAGS 299 | CTAGS: ctags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ 300 | $(TAGS_FILES) $(LISP) 301 | tags=; \ 302 | here=`pwd`; \ 303 | list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ 304 | unique=`for i in $$list; do \ 305 | if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ 306 | done | \ 307 | $(AWK) ' { files[$$0] = 1; } \ 308 | END { for (i in files) print i; }'`; \ 309 | test -z "$(CTAGS_ARGS)$$tags$$unique" \ 310 | || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ 311 | $$tags $$unique 312 | 313 | GTAGS: 314 | here=`$(am__cd) $(top_builddir) && pwd` \ 315 | && cd $(top_srcdir) \ 316 | && gtags -i $(GTAGS_ARGS) $$here 317 | 318 | distclean-tags: 319 | -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags 320 | DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) 321 | 322 | top_distdir = .. 323 | distdir = $(top_distdir)/$(PACKAGE)-$(VERSION) 324 | 325 | distdir: $(DISTFILES) 326 | @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \ 327 | topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \ 328 | list='$(DISTFILES)'; for file in $$list; do \ 329 | case $$file in \ 330 | $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \ 331 | $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \ 332 | esac; \ 333 | if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ 334 | dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ 335 | if test "$$dir" != "$$file" && test "$$dir" != "."; then \ 336 | dir="/$$dir"; \ 337 | $(mkinstalldirs) "$(distdir)$$dir"; \ 338 | else \ 339 | dir=''; \ 340 | fi; \ 341 | if test -d $$d/$$file; then \ 342 | if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ 343 | cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ 344 | fi; \ 345 | cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ 346 | else \ 347 | test -f $(distdir)/$$file \ 348 | || cp -p $$d/$$file $(distdir)/$$file \ 349 | || exit 1; \ 350 | fi; \ 351 | done 352 | list='$(SUBDIRS)'; for subdir in $$list; do \ 353 | if test "$$subdir" = .; then :; else \ 354 | test -d $(distdir)/$$subdir \ 355 | || mkdir $(distdir)/$$subdir \ 356 | || exit 1; \ 357 | (cd $$subdir && \ 358 | $(MAKE) $(AM_MAKEFLAGS) \ 359 | top_distdir="$(top_distdir)" \ 360 | distdir=../$(distdir)/$$subdir \ 361 | distdir) \ 362 | || exit 1; \ 363 | fi; \ 364 | done 365 | check-am: all-am 366 | check: check-recursive 367 | all-am: Makefile 368 | installdirs: installdirs-recursive 369 | installdirs-am: 370 | 371 | install: install-recursive 372 | install-exec: install-exec-recursive 373 | install-data: install-data-recursive 374 | uninstall: uninstall-recursive 375 | 376 | install-am: all-am 377 | @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am 378 | 379 | installcheck: installcheck-recursive 380 | install-strip: 381 | $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ 382 | install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ 383 | `test -z '$(STRIP)' || \ 384 | echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install 385 | mostlyclean-generic: 386 | 387 | clean-generic: 388 | 389 | distclean-generic: 390 | -rm -f $(CONFIG_CLEAN_FILES) 391 | 392 | maintainer-clean-generic: 393 | @echo "This command is intended for maintainers to use" 394 | @echo "it deletes files that may require special tools to rebuild." 395 | clean: clean-recursive 396 | 397 | clean-am: clean-generic mostlyclean-am 398 | 399 | distclean: distclean-recursive 400 | -rm -f Makefile 401 | distclean-am: clean-am distclean-generic distclean-tags 402 | 403 | dvi: dvi-recursive 404 | 405 | dvi-am: 406 | 407 | info: info-recursive 408 | 409 | info-am: 410 | 411 | install-data-am: 412 | 413 | install-exec-am: 414 | 415 | install-info: install-info-recursive 416 | 417 | install-man: 418 | 419 | installcheck-am: 420 | 421 | maintainer-clean: maintainer-clean-recursive 422 | -rm -f Makefile 423 | maintainer-clean-am: distclean-am maintainer-clean-generic 424 | 425 | mostlyclean: mostlyclean-recursive 426 | 427 | mostlyclean-am: mostlyclean-generic 428 | 429 | pdf: pdf-recursive 430 | 431 | pdf-am: 432 | 433 | ps: ps-recursive 434 | 435 | ps-am: 436 | 437 | uninstall-am: uninstall-info-am 438 | 439 | uninstall-info: uninstall-info-recursive 440 | 441 | .PHONY: $(RECURSIVE_TARGETS) CTAGS GTAGS all all-am check check-am clean \ 442 | clean-generic clean-recursive ctags ctags-recursive distclean \ 443 | distclean-generic distclean-recursive distclean-tags distdir \ 444 | dvi dvi-am dvi-recursive info info-am info-recursive install \ 445 | install-am install-data install-data-am install-data-recursive \ 446 | install-exec install-exec-am install-exec-recursive \ 447 | install-info install-info-am install-info-recursive install-man \ 448 | install-recursive install-strip installcheck installcheck-am \ 449 | installdirs installdirs-am installdirs-recursive \ 450 | maintainer-clean maintainer-clean-generic \ 451 | maintainer-clean-recursive mostlyclean mostlyclean-generic \ 452 | mostlyclean-recursive pdf pdf-am pdf-recursive ps ps-am \ 453 | ps-recursive tags tags-recursive uninstall uninstall-am \ 454 | uninstall-info-am uninstall-info-recursive uninstall-recursive 455 | 456 | # Tell versions [3.59,3.63) of GNU make to not export all variables. 457 | # Otherwise a system limit (for SysV at least) may be exceeded. 458 | .NOEXPORT: 459 | -------------------------------------------------------------------------------- /help/en/Makefile.am: -------------------------------------------------------------------------------- 1 | ## Process this file with automake to produce Makefile.in 2 | 3 | helpdatadir = $(DATADIR)/help/en 4 | 5 | helpdata_DATA = \ 6 | gimp-help.xml \ 7 | index.html 8 | 9 | EXTRA_DIST = $(helpdata_DATA) 10 | -------------------------------------------------------------------------------- /help/en/Makefile.in: -------------------------------------------------------------------------------- 1 | # Makefile.in generated by automake 1.7.9 from Makefile.am. 2 | # @configure_input@ 3 | 4 | # Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 5 | # Free Software Foundation, Inc. 6 | # This Makefile.in is free software; the Free Software Foundation 7 | # gives unlimited permission to copy and/or distribute it, 8 | # with or without modifications, as long as this notice is preserved. 9 | 10 | # This program is distributed in the hope that it will be useful, 11 | # but WITHOUT ANY WARRANTY, to the extent permitted by law; without 12 | # even the implied warranty of MERCHANTABILITY or FITNESS FOR A 13 | # PARTICULAR PURPOSE. 14 | 15 | @SET_MAKE@ 16 | 17 | srcdir = @srcdir@ 18 | top_srcdir = @top_srcdir@ 19 | VPATH = @srcdir@ 20 | pkgdatadir = $(datadir)/@PACKAGE@ 21 | pkglibdir = $(libdir)/@PACKAGE@ 22 | pkgincludedir = $(includedir)/@PACKAGE@ 23 | top_builddir = ../.. 24 | 25 | am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd 26 | INSTALL = @INSTALL@ 27 | install_sh_DATA = $(install_sh) -c -m 644 28 | install_sh_PROGRAM = $(install_sh) -c 29 | install_sh_SCRIPT = $(install_sh) -c 30 | INSTALL_HEADER = $(INSTALL_DATA) 31 | transform = $(program_transform_name) 32 | NORMAL_INSTALL = : 33 | PRE_INSTALL = : 34 | POST_INSTALL = : 35 | NORMAL_UNINSTALL = : 36 | PRE_UNINSTALL = : 37 | POST_UNINSTALL = : 38 | ACLOCAL = @ACLOCAL@ 39 | ALL_LINGUAS = @ALL_LINGUAS@ 40 | AMDEP_FALSE = @AMDEP_FALSE@ 41 | AMDEP_TRUE = @AMDEP_TRUE@ 42 | AMTAR = @AMTAR@ 43 | AUTOCONF = @AUTOCONF@ 44 | AUTOHEADER = @AUTOHEADER@ 45 | AUTOMAKE = @AUTOMAKE@ 46 | AWK = @AWK@ 47 | CATALOGS = @CATALOGS@ 48 | CATOBJEXT = @CATOBJEXT@ 49 | CC = @CC@ 50 | CCDEPMODE = @CCDEPMODE@ 51 | CFLAGS = @CFLAGS@ 52 | CPP = @CPP@ 53 | CPPFLAGS = @CPPFLAGS@ 54 | CXX = @CXX@ 55 | CXXDEPMODE = @CXXDEPMODE@ 56 | CXXFLAGS = @CXXFLAGS@ 57 | CYGPATH_W = @CYGPATH_W@ 58 | DATADIR = @DATADIR@ 59 | DATADIRNAME = @DATADIRNAME@ 60 | DEFS = @DEFS@ 61 | DEPDIR = @DEPDIR@ 62 | ECHO_C = @ECHO_C@ 63 | ECHO_N = @ECHO_N@ 64 | ECHO_T = @ECHO_T@ 65 | EGREP = @EGREP@ 66 | EXEEXT = @EXEEXT@ 67 | GETTEXT_PACKAGE = @GETTEXT_PACKAGE@ 68 | GIMP_CFLAGS = @GIMP_CFLAGS@ 69 | GIMP_LIBDIR = @GIMP_LIBDIR@ 70 | GIMP_LIBS = @GIMP_LIBS@ 71 | GMOFILES = @GMOFILES@ 72 | GMSGFMT = @GMSGFMT@ 73 | GREP = @GREP@ 74 | INSTALL_DATA = @INSTALL_DATA@ 75 | INSTALL_PROGRAM = @INSTALL_PROGRAM@ 76 | INSTALL_SCRIPT = @INSTALL_SCRIPT@ 77 | INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ 78 | INSTOBJEXT = @INSTOBJEXT@ 79 | INTLLIBS = @INTLLIBS@ 80 | INTLTOOL_CAVES_RULE = @INTLTOOL_CAVES_RULE@ 81 | INTLTOOL_DESKTOP_RULE = @INTLTOOL_DESKTOP_RULE@ 82 | INTLTOOL_DIRECTORY_RULE = @INTLTOOL_DIRECTORY_RULE@ 83 | INTLTOOL_EXTRACT = @INTLTOOL_EXTRACT@ 84 | INTLTOOL_ICONV = @INTLTOOL_ICONV@ 85 | INTLTOOL_KBD_RULE = @INTLTOOL_KBD_RULE@ 86 | INTLTOOL_KEYS_RULE = @INTLTOOL_KEYS_RULE@ 87 | INTLTOOL_MERGE = @INTLTOOL_MERGE@ 88 | INTLTOOL_MSGFMT = @INTLTOOL_MSGFMT@ 89 | INTLTOOL_MSGMERGE = @INTLTOOL_MSGMERGE@ 90 | INTLTOOL_OAF_RULE = @INTLTOOL_OAF_RULE@ 91 | INTLTOOL_PERL = @INTLTOOL_PERL@ 92 | INTLTOOL_PONG_RULE = @INTLTOOL_PONG_RULE@ 93 | INTLTOOL_PROP_RULE = @INTLTOOL_PROP_RULE@ 94 | INTLTOOL_SCHEMAS_RULE = @INTLTOOL_SCHEMAS_RULE@ 95 | INTLTOOL_SERVER_RULE = @INTLTOOL_SERVER_RULE@ 96 | INTLTOOL_SERVICE_RULE = @INTLTOOL_SERVICE_RULE@ 97 | INTLTOOL_SHEET_RULE = @INTLTOOL_SHEET_RULE@ 98 | INTLTOOL_SOUNDLIST_RULE = @INTLTOOL_SOUNDLIST_RULE@ 99 | INTLTOOL_THEME_RULE = @INTLTOOL_THEME_RULE@ 100 | INTLTOOL_UI_RULE = @INTLTOOL_UI_RULE@ 101 | INTLTOOL_UPDATE = @INTLTOOL_UPDATE@ 102 | INTLTOOL_XAM_RULE = @INTLTOOL_XAM_RULE@ 103 | INTLTOOL_XGETTEXT = @INTLTOOL_XGETTEXT@ 104 | INTLTOOL_XML_NOMERGE_RULE = @INTLTOOL_XML_NOMERGE_RULE@ 105 | INTLTOOL_XML_RULE = @INTLTOOL_XML_RULE@ 106 | LDFLAGS = @LDFLAGS@ 107 | LIBOBJS = @LIBOBJS@ 108 | LIBS = @LIBS@ 109 | LOCALEDIR = @LOCALEDIR@ 110 | LTLIBOBJS = @LTLIBOBJS@ 111 | MAINT = @MAINT@ 112 | MAINTAINER_MODE_FALSE = @MAINTAINER_MODE_FALSE@ 113 | MAINTAINER_MODE_TRUE = @MAINTAINER_MODE_TRUE@ 114 | MAKEINFO = @MAKEINFO@ 115 | MKINSTALLDIRS = @MKINSTALLDIRS@ 116 | MSGFMT = @MSGFMT@ 117 | OBJEXT = @OBJEXT@ 118 | PACKAGE = @PACKAGE@ 119 | PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ 120 | PACKAGE_NAME = @PACKAGE_NAME@ 121 | PACKAGE_STRING = @PACKAGE_STRING@ 122 | PACKAGE_TARNAME = @PACKAGE_TARNAME@ 123 | PACKAGE_VERSION = @PACKAGE_VERSION@ 124 | PATH_SEPARATOR = @PATH_SEPARATOR@ 125 | PKG_CONFIG = @PKG_CONFIG@ 126 | POFILES = @POFILES@ 127 | POSUB = @POSUB@ 128 | PO_IN_DATADIR_FALSE = @PO_IN_DATADIR_FALSE@ 129 | PO_IN_DATADIR_TRUE = @PO_IN_DATADIR_TRUE@ 130 | SET_MAKE = @SET_MAKE@ 131 | SHELL = @SHELL@ 132 | STRIP = @STRIP@ 133 | USE_NLS = @USE_NLS@ 134 | VERSION = @VERSION@ 135 | XGETTEXT = @XGETTEXT@ 136 | ac_ct_CC = @ac_ct_CC@ 137 | ac_ct_CXX = @ac_ct_CXX@ 138 | am__fastdepCC_FALSE = @am__fastdepCC_FALSE@ 139 | am__fastdepCC_TRUE = @am__fastdepCC_TRUE@ 140 | am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@ 141 | am__fastdepCXX_TRUE = @am__fastdepCXX_TRUE@ 142 | am__include = @am__include@ 143 | am__leading_dot = @am__leading_dot@ 144 | am__quote = @am__quote@ 145 | bindir = @bindir@ 146 | build_alias = @build_alias@ 147 | datadir = @datadir@ 148 | datarootdir = @datarootdir@ 149 | docdir = @docdir@ 150 | dvidir = @dvidir@ 151 | exec_prefix = @exec_prefix@ 152 | host_alias = @host_alias@ 153 | htmldir = @htmldir@ 154 | includedir = @includedir@ 155 | infodir = @infodir@ 156 | install_sh = @install_sh@ 157 | libdir = @libdir@ 158 | libexecdir = @libexecdir@ 159 | localedir = @localedir@ 160 | localstatedir = @localstatedir@ 161 | mandir = @mandir@ 162 | oldincludedir = @oldincludedir@ 163 | pdfdir = @pdfdir@ 164 | prefix = @prefix@ 165 | program_transform_name = @program_transform_name@ 166 | psdir = @psdir@ 167 | sbindir = @sbindir@ 168 | sharedstatedir = @sharedstatedir@ 169 | sysconfdir = @sysconfdir@ 170 | target_alias = @target_alias@ 171 | 172 | helpdatadir = $(DATADIR)/help/en 173 | 174 | helpdata_DATA = \ 175 | gimp-help.xml \ 176 | index.html 177 | 178 | 179 | EXTRA_DIST = $(helpdata_DATA) 180 | subdir = help/en 181 | ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 182 | mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs 183 | CONFIG_HEADER = $(top_builddir)/config.h 184 | CONFIG_CLEAN_FILES = 185 | DIST_SOURCES = 186 | DATA = $(helpdata_DATA) 187 | 188 | DIST_COMMON = $(srcdir)/Makefile.in Makefile.am 189 | all: all-am 190 | 191 | .SUFFIXES: 192 | $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4) 193 | cd $(top_srcdir) && \ 194 | $(AUTOMAKE) --gnu help/en/Makefile 195 | Makefile: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.in $(top_builddir)/config.status 196 | cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe) 197 | uninstall-info-am: 198 | helpdataDATA_INSTALL = $(INSTALL_DATA) 199 | install-helpdataDATA: $(helpdata_DATA) 200 | @$(NORMAL_INSTALL) 201 | $(mkinstalldirs) $(DESTDIR)$(helpdatadir) 202 | @list='$(helpdata_DATA)'; for p in $$list; do \ 203 | if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ 204 | f="`echo $$p | sed -e 's|^.*/||'`"; \ 205 | echo " $(helpdataDATA_INSTALL) $$d$$p $(DESTDIR)$(helpdatadir)/$$f"; \ 206 | $(helpdataDATA_INSTALL) $$d$$p $(DESTDIR)$(helpdatadir)/$$f; \ 207 | done 208 | 209 | uninstall-helpdataDATA: 210 | @$(NORMAL_UNINSTALL) 211 | @list='$(helpdata_DATA)'; for p in $$list; do \ 212 | f="`echo $$p | sed -e 's|^.*/||'`"; \ 213 | echo " rm -f $(DESTDIR)$(helpdatadir)/$$f"; \ 214 | rm -f $(DESTDIR)$(helpdatadir)/$$f; \ 215 | done 216 | tags: TAGS 217 | TAGS: 218 | 219 | ctags: CTAGS 220 | CTAGS: 221 | 222 | DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) 223 | 224 | top_distdir = ../.. 225 | distdir = $(top_distdir)/$(PACKAGE)-$(VERSION) 226 | 227 | distdir: $(DISTFILES) 228 | @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \ 229 | topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \ 230 | list='$(DISTFILES)'; for file in $$list; do \ 231 | case $$file in \ 232 | $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \ 233 | $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \ 234 | esac; \ 235 | if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ 236 | dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ 237 | if test "$$dir" != "$$file" && test "$$dir" != "."; then \ 238 | dir="/$$dir"; \ 239 | $(mkinstalldirs) "$(distdir)$$dir"; \ 240 | else \ 241 | dir=''; \ 242 | fi; \ 243 | if test -d $$d/$$file; then \ 244 | if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ 245 | cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ 246 | fi; \ 247 | cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ 248 | else \ 249 | test -f $(distdir)/$$file \ 250 | || cp -p $$d/$$file $(distdir)/$$file \ 251 | || exit 1; \ 252 | fi; \ 253 | done 254 | check-am: all-am 255 | check: check-am 256 | all-am: Makefile $(DATA) 257 | 258 | installdirs: 259 | $(mkinstalldirs) $(DESTDIR)$(helpdatadir) 260 | install: install-am 261 | install-exec: install-exec-am 262 | install-data: install-data-am 263 | uninstall: uninstall-am 264 | 265 | install-am: all-am 266 | @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am 267 | 268 | installcheck: installcheck-am 269 | install-strip: 270 | $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ 271 | install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ 272 | `test -z '$(STRIP)' || \ 273 | echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install 274 | mostlyclean-generic: 275 | 276 | clean-generic: 277 | 278 | distclean-generic: 279 | -rm -f $(CONFIG_CLEAN_FILES) 280 | 281 | maintainer-clean-generic: 282 | @echo "This command is intended for maintainers to use" 283 | @echo "it deletes files that may require special tools to rebuild." 284 | clean: clean-am 285 | 286 | clean-am: clean-generic mostlyclean-am 287 | 288 | distclean: distclean-am 289 | -rm -f Makefile 290 | distclean-am: clean-am distclean-generic 291 | 292 | dvi: dvi-am 293 | 294 | dvi-am: 295 | 296 | info: info-am 297 | 298 | info-am: 299 | 300 | install-data-am: install-helpdataDATA 301 | 302 | install-exec-am: 303 | 304 | install-info: install-info-am 305 | 306 | install-man: 307 | 308 | installcheck-am: 309 | 310 | maintainer-clean: maintainer-clean-am 311 | -rm -f Makefile 312 | maintainer-clean-am: distclean-am maintainer-clean-generic 313 | 314 | mostlyclean: mostlyclean-am 315 | 316 | mostlyclean-am: mostlyclean-generic 317 | 318 | pdf: pdf-am 319 | 320 | pdf-am: 321 | 322 | ps: ps-am 323 | 324 | ps-am: 325 | 326 | uninstall-am: uninstall-helpdataDATA uninstall-info-am 327 | 328 | .PHONY: all all-am check check-am clean clean-generic distclean \ 329 | distclean-generic distdir dvi dvi-am info info-am install \ 330 | install-am install-data install-data-am install-exec \ 331 | install-exec-am install-helpdataDATA install-info \ 332 | install-info-am install-man install-strip installcheck \ 333 | installcheck-am installdirs maintainer-clean \ 334 | maintainer-clean-generic mostlyclean mostlyclean-generic pdf \ 335 | pdf-am ps ps-am uninstall uninstall-am uninstall-helpdataDATA \ 336 | uninstall-info-am 337 | 338 | # Tell versions [3.59,3.63) of GNU make to not export all variables. 339 | # Otherwise a system limit (for SysV at least) may be exceeded. 340 | .NOEXPORT: 341 | -------------------------------------------------------------------------------- /help/en/gimp-help.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /help/en/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | Gimp-deskew-plugin 6 | 7 | 8 | 10 | 11 | 12 | 13 | 16 | 17 | 18 | 21 | 22 | 23 | 30 | 31 |
14 | 15 |
19 | GIMP deskew plugin help page 20 |
24 |

25 | Click Layer => Transform => Deskew. 26 | 27 | Gimp will auto-straighten ("deskew") the image. 28 |

29 |
32 | 33 | 34 | 35 | -------------------------------------------------------------------------------- /help/es/Makefile.am: -------------------------------------------------------------------------------- 1 | ## Process this file with automake to produce Makefile.in 2 | 3 | helpdatadir = $(DATADIR)/help/es 4 | 5 | helpdata_DATA = \ 6 | gimp-help.xml \ 7 | index.html 8 | 9 | EXTRA_DIST = $(helpdata_DATA) 10 | -------------------------------------------------------------------------------- /help/es/gimp-help.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /help/es/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | Gimp-deskew-plugin 6 | 7 | 8 | 10 | 11 | 12 | 13 | 16 | 17 | 18 | 21 | 22 | 23 | 30 | 31 |
14 | 15 |
19 | GIMP deskew plugin página de ayuda 20 |
24 |

25 | Click Capa => Transformar => Enderezar. 26 | 27 | Gimp enderezará automáticamente ("deskew") la imagen. 28 |

29 |
32 | 33 | 34 | 35 | -------------------------------------------------------------------------------- /help/images/Makefile.am: -------------------------------------------------------------------------------- 1 | ## Process this file with automake to produce Makefile.in 2 | 3 | helpdatadir = $(DATADIR)/help/images 4 | 5 | helpdata_DATA = \ 6 | wilber.png 7 | 8 | EXTRA_DIST = $(helpdata_DATA) 9 | -------------------------------------------------------------------------------- /help/images/Makefile.in: -------------------------------------------------------------------------------- 1 | # Makefile.in generated by automake 1.7.9 from Makefile.am. 2 | # @configure_input@ 3 | 4 | # Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 5 | # Free Software Foundation, Inc. 6 | # This Makefile.in is free software; the Free Software Foundation 7 | # gives unlimited permission to copy and/or distribute it, 8 | # with or without modifications, as long as this notice is preserved. 9 | 10 | # This program is distributed in the hope that it will be useful, 11 | # but WITHOUT ANY WARRANTY, to the extent permitted by law; without 12 | # even the implied warranty of MERCHANTABILITY or FITNESS FOR A 13 | # PARTICULAR PURPOSE. 14 | 15 | @SET_MAKE@ 16 | 17 | srcdir = @srcdir@ 18 | top_srcdir = @top_srcdir@ 19 | VPATH = @srcdir@ 20 | pkgdatadir = $(datadir)/@PACKAGE@ 21 | pkglibdir = $(libdir)/@PACKAGE@ 22 | pkgincludedir = $(includedir)/@PACKAGE@ 23 | top_builddir = ../.. 24 | 25 | am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd 26 | INSTALL = @INSTALL@ 27 | install_sh_DATA = $(install_sh) -c -m 644 28 | install_sh_PROGRAM = $(install_sh) -c 29 | install_sh_SCRIPT = $(install_sh) -c 30 | INSTALL_HEADER = $(INSTALL_DATA) 31 | transform = $(program_transform_name) 32 | NORMAL_INSTALL = : 33 | PRE_INSTALL = : 34 | POST_INSTALL = : 35 | NORMAL_UNINSTALL = : 36 | PRE_UNINSTALL = : 37 | POST_UNINSTALL = : 38 | ACLOCAL = @ACLOCAL@ 39 | ALL_LINGUAS = @ALL_LINGUAS@ 40 | AMDEP_FALSE = @AMDEP_FALSE@ 41 | AMDEP_TRUE = @AMDEP_TRUE@ 42 | AMTAR = @AMTAR@ 43 | AUTOCONF = @AUTOCONF@ 44 | AUTOHEADER = @AUTOHEADER@ 45 | AUTOMAKE = @AUTOMAKE@ 46 | AWK = @AWK@ 47 | CATALOGS = @CATALOGS@ 48 | CATOBJEXT = @CATOBJEXT@ 49 | CC = @CC@ 50 | CCDEPMODE = @CCDEPMODE@ 51 | CFLAGS = @CFLAGS@ 52 | CPP = @CPP@ 53 | CPPFLAGS = @CPPFLAGS@ 54 | CXX = @CXX@ 55 | CXXDEPMODE = @CXXDEPMODE@ 56 | CXXFLAGS = @CXXFLAGS@ 57 | CYGPATH_W = @CYGPATH_W@ 58 | DATADIR = @DATADIR@ 59 | DATADIRNAME = @DATADIRNAME@ 60 | DEFS = @DEFS@ 61 | DEPDIR = @DEPDIR@ 62 | ECHO_C = @ECHO_C@ 63 | ECHO_N = @ECHO_N@ 64 | ECHO_T = @ECHO_T@ 65 | EGREP = @EGREP@ 66 | EXEEXT = @EXEEXT@ 67 | GETTEXT_PACKAGE = @GETTEXT_PACKAGE@ 68 | GIMP_CFLAGS = @GIMP_CFLAGS@ 69 | GIMP_LIBDIR = @GIMP_LIBDIR@ 70 | GIMP_LIBS = @GIMP_LIBS@ 71 | GMOFILES = @GMOFILES@ 72 | GMSGFMT = @GMSGFMT@ 73 | GREP = @GREP@ 74 | INSTALL_DATA = @INSTALL_DATA@ 75 | INSTALL_PROGRAM = @INSTALL_PROGRAM@ 76 | INSTALL_SCRIPT = @INSTALL_SCRIPT@ 77 | INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ 78 | INSTOBJEXT = @INSTOBJEXT@ 79 | INTLLIBS = @INTLLIBS@ 80 | INTLTOOL_CAVES_RULE = @INTLTOOL_CAVES_RULE@ 81 | INTLTOOL_DESKTOP_RULE = @INTLTOOL_DESKTOP_RULE@ 82 | INTLTOOL_DIRECTORY_RULE = @INTLTOOL_DIRECTORY_RULE@ 83 | INTLTOOL_EXTRACT = @INTLTOOL_EXTRACT@ 84 | INTLTOOL_ICONV = @INTLTOOL_ICONV@ 85 | INTLTOOL_KBD_RULE = @INTLTOOL_KBD_RULE@ 86 | INTLTOOL_KEYS_RULE = @INTLTOOL_KEYS_RULE@ 87 | INTLTOOL_MERGE = @INTLTOOL_MERGE@ 88 | INTLTOOL_MSGFMT = @INTLTOOL_MSGFMT@ 89 | INTLTOOL_MSGMERGE = @INTLTOOL_MSGMERGE@ 90 | INTLTOOL_OAF_RULE = @INTLTOOL_OAF_RULE@ 91 | INTLTOOL_PERL = @INTLTOOL_PERL@ 92 | INTLTOOL_PONG_RULE = @INTLTOOL_PONG_RULE@ 93 | INTLTOOL_PROP_RULE = @INTLTOOL_PROP_RULE@ 94 | INTLTOOL_SCHEMAS_RULE = @INTLTOOL_SCHEMAS_RULE@ 95 | INTLTOOL_SERVER_RULE = @INTLTOOL_SERVER_RULE@ 96 | INTLTOOL_SERVICE_RULE = @INTLTOOL_SERVICE_RULE@ 97 | INTLTOOL_SHEET_RULE = @INTLTOOL_SHEET_RULE@ 98 | INTLTOOL_SOUNDLIST_RULE = @INTLTOOL_SOUNDLIST_RULE@ 99 | INTLTOOL_THEME_RULE = @INTLTOOL_THEME_RULE@ 100 | INTLTOOL_UI_RULE = @INTLTOOL_UI_RULE@ 101 | INTLTOOL_UPDATE = @INTLTOOL_UPDATE@ 102 | INTLTOOL_XAM_RULE = @INTLTOOL_XAM_RULE@ 103 | INTLTOOL_XGETTEXT = @INTLTOOL_XGETTEXT@ 104 | INTLTOOL_XML_NOMERGE_RULE = @INTLTOOL_XML_NOMERGE_RULE@ 105 | INTLTOOL_XML_RULE = @INTLTOOL_XML_RULE@ 106 | LDFLAGS = @LDFLAGS@ 107 | LIBOBJS = @LIBOBJS@ 108 | LIBS = @LIBS@ 109 | LOCALEDIR = @LOCALEDIR@ 110 | LTLIBOBJS = @LTLIBOBJS@ 111 | MAINT = @MAINT@ 112 | MAINTAINER_MODE_FALSE = @MAINTAINER_MODE_FALSE@ 113 | MAINTAINER_MODE_TRUE = @MAINTAINER_MODE_TRUE@ 114 | MAKEINFO = @MAKEINFO@ 115 | MKINSTALLDIRS = @MKINSTALLDIRS@ 116 | MSGFMT = @MSGFMT@ 117 | OBJEXT = @OBJEXT@ 118 | PACKAGE = @PACKAGE@ 119 | PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ 120 | PACKAGE_NAME = @PACKAGE_NAME@ 121 | PACKAGE_STRING = @PACKAGE_STRING@ 122 | PACKAGE_TARNAME = @PACKAGE_TARNAME@ 123 | PACKAGE_VERSION = @PACKAGE_VERSION@ 124 | PATH_SEPARATOR = @PATH_SEPARATOR@ 125 | PKG_CONFIG = @PKG_CONFIG@ 126 | POFILES = @POFILES@ 127 | POSUB = @POSUB@ 128 | PO_IN_DATADIR_FALSE = @PO_IN_DATADIR_FALSE@ 129 | PO_IN_DATADIR_TRUE = @PO_IN_DATADIR_TRUE@ 130 | SET_MAKE = @SET_MAKE@ 131 | SHELL = @SHELL@ 132 | STRIP = @STRIP@ 133 | USE_NLS = @USE_NLS@ 134 | VERSION = @VERSION@ 135 | XGETTEXT = @XGETTEXT@ 136 | ac_ct_CC = @ac_ct_CC@ 137 | ac_ct_CXX = @ac_ct_CXX@ 138 | am__fastdepCC_FALSE = @am__fastdepCC_FALSE@ 139 | am__fastdepCC_TRUE = @am__fastdepCC_TRUE@ 140 | am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@ 141 | am__fastdepCXX_TRUE = @am__fastdepCXX_TRUE@ 142 | am__include = @am__include@ 143 | am__leading_dot = @am__leading_dot@ 144 | am__quote = @am__quote@ 145 | bindir = @bindir@ 146 | build_alias = @build_alias@ 147 | datadir = @datadir@ 148 | datarootdir = @datarootdir@ 149 | docdir = @docdir@ 150 | dvidir = @dvidir@ 151 | exec_prefix = @exec_prefix@ 152 | host_alias = @host_alias@ 153 | htmldir = @htmldir@ 154 | includedir = @includedir@ 155 | infodir = @infodir@ 156 | install_sh = @install_sh@ 157 | libdir = @libdir@ 158 | libexecdir = @libexecdir@ 159 | localedir = @localedir@ 160 | localstatedir = @localstatedir@ 161 | mandir = @mandir@ 162 | oldincludedir = @oldincludedir@ 163 | pdfdir = @pdfdir@ 164 | prefix = @prefix@ 165 | program_transform_name = @program_transform_name@ 166 | psdir = @psdir@ 167 | sbindir = @sbindir@ 168 | sharedstatedir = @sharedstatedir@ 169 | sysconfdir = @sysconfdir@ 170 | target_alias = @target_alias@ 171 | 172 | helpdatadir = $(DATADIR)/help/images 173 | 174 | helpdata_DATA = \ 175 | wilber.png 176 | 177 | 178 | EXTRA_DIST = $(helpdata_DATA) 179 | subdir = help/images 180 | ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 181 | mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs 182 | CONFIG_HEADER = $(top_builddir)/config.h 183 | CONFIG_CLEAN_FILES = 184 | DIST_SOURCES = 185 | DATA = $(helpdata_DATA) 186 | 187 | DIST_COMMON = $(srcdir)/Makefile.in Makefile.am 188 | all: all-am 189 | 190 | .SUFFIXES: 191 | $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4) 192 | cd $(top_srcdir) && \ 193 | $(AUTOMAKE) --gnu help/images/Makefile 194 | Makefile: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.in $(top_builddir)/config.status 195 | cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe) 196 | uninstall-info-am: 197 | helpdataDATA_INSTALL = $(INSTALL_DATA) 198 | install-helpdataDATA: $(helpdata_DATA) 199 | @$(NORMAL_INSTALL) 200 | $(mkinstalldirs) $(DESTDIR)$(helpdatadir) 201 | @list='$(helpdata_DATA)'; for p in $$list; do \ 202 | if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ 203 | f="`echo $$p | sed -e 's|^.*/||'`"; \ 204 | echo " $(helpdataDATA_INSTALL) $$d$$p $(DESTDIR)$(helpdatadir)/$$f"; \ 205 | $(helpdataDATA_INSTALL) $$d$$p $(DESTDIR)$(helpdatadir)/$$f; \ 206 | done 207 | 208 | uninstall-helpdataDATA: 209 | @$(NORMAL_UNINSTALL) 210 | @list='$(helpdata_DATA)'; for p in $$list; do \ 211 | f="`echo $$p | sed -e 's|^.*/||'`"; \ 212 | echo " rm -f $(DESTDIR)$(helpdatadir)/$$f"; \ 213 | rm -f $(DESTDIR)$(helpdatadir)/$$f; \ 214 | done 215 | tags: TAGS 216 | TAGS: 217 | 218 | ctags: CTAGS 219 | CTAGS: 220 | 221 | DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) 222 | 223 | top_distdir = ../.. 224 | distdir = $(top_distdir)/$(PACKAGE)-$(VERSION) 225 | 226 | distdir: $(DISTFILES) 227 | @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \ 228 | topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \ 229 | list='$(DISTFILES)'; for file in $$list; do \ 230 | case $$file in \ 231 | $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \ 232 | $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \ 233 | esac; \ 234 | if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ 235 | dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ 236 | if test "$$dir" != "$$file" && test "$$dir" != "."; then \ 237 | dir="/$$dir"; \ 238 | $(mkinstalldirs) "$(distdir)$$dir"; \ 239 | else \ 240 | dir=''; \ 241 | fi; \ 242 | if test -d $$d/$$file; then \ 243 | if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ 244 | cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ 245 | fi; \ 246 | cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ 247 | else \ 248 | test -f $(distdir)/$$file \ 249 | || cp -p $$d/$$file $(distdir)/$$file \ 250 | || exit 1; \ 251 | fi; \ 252 | done 253 | check-am: all-am 254 | check: check-am 255 | all-am: Makefile $(DATA) 256 | 257 | installdirs: 258 | $(mkinstalldirs) $(DESTDIR)$(helpdatadir) 259 | install: install-am 260 | install-exec: install-exec-am 261 | install-data: install-data-am 262 | uninstall: uninstall-am 263 | 264 | install-am: all-am 265 | @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am 266 | 267 | installcheck: installcheck-am 268 | install-strip: 269 | $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ 270 | install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ 271 | `test -z '$(STRIP)' || \ 272 | echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install 273 | mostlyclean-generic: 274 | 275 | clean-generic: 276 | 277 | distclean-generic: 278 | -rm -f $(CONFIG_CLEAN_FILES) 279 | 280 | maintainer-clean-generic: 281 | @echo "This command is intended for maintainers to use" 282 | @echo "it deletes files that may require special tools to rebuild." 283 | clean: clean-am 284 | 285 | clean-am: clean-generic mostlyclean-am 286 | 287 | distclean: distclean-am 288 | -rm -f Makefile 289 | distclean-am: clean-am distclean-generic 290 | 291 | dvi: dvi-am 292 | 293 | dvi-am: 294 | 295 | info: info-am 296 | 297 | info-am: 298 | 299 | install-data-am: install-helpdataDATA 300 | 301 | install-exec-am: 302 | 303 | install-info: install-info-am 304 | 305 | install-man: 306 | 307 | installcheck-am: 308 | 309 | maintainer-clean: maintainer-clean-am 310 | -rm -f Makefile 311 | maintainer-clean-am: distclean-am maintainer-clean-generic 312 | 313 | mostlyclean: mostlyclean-am 314 | 315 | mostlyclean-am: mostlyclean-generic 316 | 317 | pdf: pdf-am 318 | 319 | pdf-am: 320 | 321 | ps: ps-am 322 | 323 | ps-am: 324 | 325 | uninstall-am: uninstall-helpdataDATA uninstall-info-am 326 | 327 | .PHONY: all all-am check check-am clean clean-generic distclean \ 328 | distclean-generic distdir dvi dvi-am info info-am install \ 329 | install-am install-data install-data-am install-exec \ 330 | install-exec-am install-helpdataDATA install-info \ 331 | install-info-am install-man install-strip installcheck \ 332 | installcheck-am installdirs maintainer-clean \ 333 | maintainer-clean-generic mostlyclean mostlyclean-generic pdf \ 334 | pdf-am ps ps-am uninstall uninstall-am uninstall-helpdataDATA \ 335 | uninstall-info-am 336 | 337 | # Tell versions [3.59,3.63) of GNU make to not export all variables. 338 | # Otherwise a system limit (for SysV at least) may be exceeded. 339 | .NOEXPORT: 340 | -------------------------------------------------------------------------------- /help/images/wilber.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/gimp-plugins-justice/gimp-deskew-plugin/c56eed407b3fcf8cf1cff468259b440a6946311e/help/images/wilber.png -------------------------------------------------------------------------------- /po/ChangeLog: -------------------------------------------------------------------------------- 1 | 2007-03-03 Karl Chen 2 | 3 | * initial revision, based on gimp-plugin-template 4 | -------------------------------------------------------------------------------- /po/Makefile.in.in: -------------------------------------------------------------------------------- 1 | /usr/share/intltool/Makefile.in.in -------------------------------------------------------------------------------- /po/POTFILES.in: -------------------------------------------------------------------------------- 1 | # List of source files containing translatable strings. 2 | 3 | src/interface.c 4 | src/main.c 5 | src/render.c 6 | -------------------------------------------------------------------------------- /po/es.po: -------------------------------------------------------------------------------- 1 | # GIMP deskew plugin 1.1 2 | # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER 3 | # This file is distributed under the same license as the PACKAGE package. 4 | # FIRST AUTHOR , YEAR. 5 | # Alberto Fanjul , 2023 6 | # 7 | msgid "" 8 | msgstr "" 9 | "Project-Id-Version: gimp deskew plugin 1.1\n" 10 | "Report-Msgid-Bugs-To: \n" 11 | "POT-Creation-Date: 2019-01-23 04:23+0300\n" 12 | "PO-Revision-Date: 2019-01-23 04:23+0300\n" 13 | "Last-Translator: Alberto Fanjul \n" 14 | "Language-Team: Spanish - Spain \n" 15 | "Language: es_ES\n" 16 | "MIME-Version: 1.0\n" 17 | "Content-Type: text/plain; charset=UTF-8\n" 18 | "Content-Transfer-Encoding: 8bit\n" 19 | "Plural-Forms: nplurals=2; plural=(n != 1);\n" 20 | "X-Generator: Gtranslator 3.31.0\n" 21 | 22 | #: ../src/interface.c:109 ../src/main.c:130 23 | msgid "Deskew" 24 | msgstr "Enderezar" 25 | 26 | #. gimp_scale_entry_new() examples 27 | #: ../src/interface.c:124 28 | msgid "ScaleEntry Examples" 29 | msgstr "" 30 | 31 | #: ../src/interface.c:137 32 | msgid "Dummy 1:" 33 | msgstr "" 34 | 35 | #: ../src/interface.c:140 36 | msgid "Dummy scale entry 1" 37 | msgstr "" 38 | 39 | #: ../src/interface.c:146 40 | msgid "Dummy 2:" 41 | msgstr "" 42 | 43 | #: ../src/interface.c:149 44 | msgid "Dummy scale entry 2" 45 | msgstr "" 46 | 47 | #: ../src/interface.c:155 48 | msgid "Dummy 3:" 49 | msgstr "" 50 | 51 | #: ../src/interface.c:158 52 | msgid "Dummy scale entry 3" 53 | msgstr "" 54 | 55 | #. gimp_random_seed_new() example 56 | #: ../src/interface.c:165 57 | msgid "A Random Seed Entry" 58 | msgstr "" 59 | 60 | #. gimp_coordinates_new() example 61 | #: ../src/interface.c:180 62 | msgid "" 63 | "A GimpCoordinates Widget\n" 64 | "Initialized with the Drawable's Size" 65 | msgstr "" 66 | 67 | #: ../src/interface.c:198 68 | msgid "Width:" 69 | msgstr "Ancho:" 70 | 71 | #: ../src/interface.c:202 72 | msgid "Height:" 73 | msgstr "Alto:" 74 | 75 | #. Image and drawable menus 76 | #: ../src/interface.c:210 77 | msgid "Image and Drawable Menu Examples" 78 | msgstr "" 79 | 80 | #: ../src/interface.c:229 81 | msgid "Layers:" 82 | msgstr "Capas:" 83 | 84 | #: ../src/interface.c:237 85 | msgid "RGB Images:" 86 | msgstr "Imágenes RGB:" 87 | 88 | #: ../src/main.c:125 89 | msgid "Automatically straighten the rotated image" 90 | msgstr "Enderezar automáticamente la imagen rotada" 91 | 92 | #: ../src/main.c:126 93 | msgid "This plug-in automatically straightens (deskews) rotated images" 94 | msgstr "Este plugin endereza automáticamente (deskews) imágenes rotadas" 95 | -------------------------------------------------------------------------------- /po/ru.po: -------------------------------------------------------------------------------- 1 | # SOME DESCRIPTIVE TITLE. 2 | # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER 3 | # This file is distributed under the same license as the PACKAGE package. 4 | # FIRST AUTHOR , YEAR. 5 | # Александр Прокудин , 2010. 6 | # Alexandre Prokoudine , 2019. 7 | # 8 | msgid "" 9 | msgstr "" 10 | "Project-Id-Version: gimp deskew plugin 1.1\n" 11 | "Report-Msgid-Bugs-To: \n" 12 | "POT-Creation-Date: 2019-01-23 04:23+0300\n" 13 | "PO-Revision-Date: 2019-01-23 04:23+0300\n" 14 | "Last-Translator: Alexandre Prokoudine \n" 15 | "Language-Team: русский \n" 16 | "Language: ru\n" 17 | "MIME-Version: 1.0\n" 18 | "Content-Type: text/plain; charset=UTF-8\n" 19 | "Content-Transfer-Encoding: 8bit\n" 20 | "Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n" 21 | "%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2)\n" 22 | "X-Generator: Gtranslator 3.31.0\n" 23 | 24 | #: ../src/interface.c:109 ../src/main.c:130 25 | msgid "Deskew" 26 | msgstr "Выровнять перекос скана" 27 | 28 | #. gimp_scale_entry_new() examples 29 | #: ../src/interface.c:124 30 | msgid "ScaleEntry Examples" 31 | msgstr "" 32 | 33 | #: ../src/interface.c:137 34 | msgid "Dummy 1:" 35 | msgstr "" 36 | 37 | #: ../src/interface.c:140 38 | msgid "Dummy scale entry 1" 39 | msgstr "" 40 | 41 | #: ../src/interface.c:146 42 | msgid "Dummy 2:" 43 | msgstr "" 44 | 45 | #: ../src/interface.c:149 46 | msgid "Dummy scale entry 2" 47 | msgstr "" 48 | 49 | #: ../src/interface.c:155 50 | msgid "Dummy 3:" 51 | msgstr "" 52 | 53 | #: ../src/interface.c:158 54 | msgid "Dummy scale entry 3" 55 | msgstr "" 56 | 57 | #. gimp_random_seed_new() example 58 | #: ../src/interface.c:165 59 | msgid "A Random Seed Entry" 60 | msgstr "" 61 | 62 | #. gimp_coordinates_new() example 63 | #: ../src/interface.c:180 64 | msgid "" 65 | "A GimpCoordinates Widget\n" 66 | "Initialized with the Drawable's Size" 67 | msgstr "" 68 | 69 | #: ../src/interface.c:198 70 | msgid "Width:" 71 | msgstr "Ширина:" 72 | 73 | #: ../src/interface.c:202 74 | msgid "Height:" 75 | msgstr "Высота:" 76 | 77 | #. Image and drawable menus 78 | #: ../src/interface.c:210 79 | msgid "Image and Drawable Menu Examples" 80 | msgstr "" 81 | 82 | #: ../src/interface.c:229 83 | msgid "Layers:" 84 | msgstr "Слои:" 85 | 86 | #: ../src/interface.c:237 87 | msgid "RGB Images:" 88 | msgstr "Изображения RGB:" 89 | 90 | #: ../src/main.c:125 91 | msgid "Automatically straighten the rotated image" 92 | msgstr "Автоматически выровнять перекос в отсканированном изображении" 93 | 94 | #: ../src/main.c:126 95 | msgid "This plug-in automatically straightens (deskews) rotated images" 96 | msgstr "" 97 | "Этот плагин автоматически выровнивает перекос в отсканированном изображении" 98 | -------------------------------------------------------------------------------- /src/Makefile.am: -------------------------------------------------------------------------------- 1 | ## Process this file with automake to produce Makefile.in 2 | 3 | bin_PROGRAMS = deskew 4 | 5 | bindir = `pkg-config --variable=gimplibdir gimp-2.0`/plug-ins 6 | 7 | deskew_SOURCES = \ 8 | plugin-intl.h \ 9 | interface.c \ 10 | interface.h \ 11 | main.c \ 12 | main.h \ 13 | render.c \ 14 | render.h \ 15 | formats/gimpfact.cc \ 16 | formats/gimpfact.h \ 17 | raster/bwfactory.h \ 18 | raster/bwimage.cc \ 19 | raster/bwimage.h \ 20 | raster/deskewer.cc \ 21 | raster/deskewer.h \ 22 | util/bitutil.cc \ 23 | util/bitutil.h \ 24 | util/cntptr.h \ 25 | deskew.cc \ 26 | deskew.h 27 | 28 | AM_CPPFLAGS = \ 29 | -DLOCALEDIR=\""$(LOCALEDIR)"\" \ 30 | -DDATADIR=\""$(DATADIR)"\" 31 | 32 | INCLUDES =\ 33 | -I$(top_srcdir) \ 34 | @GIMP_CFLAGS@ \ 35 | -I$(includedir) 36 | 37 | LDADD = $(GIMP_LIBS) 38 | #LDADD = $(GIMP_LIBS) -lnetpbm 39 | 40 | -------------------------------------------------------------------------------- /src/Makefile.in: -------------------------------------------------------------------------------- 1 | # Makefile.in generated by automake 1.7.9 from Makefile.am. 2 | # @configure_input@ 3 | 4 | # Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 5 | # Free Software Foundation, Inc. 6 | # This Makefile.in is free software; the Free Software Foundation 7 | # gives unlimited permission to copy and/or distribute it, 8 | # with or without modifications, as long as this notice is preserved. 9 | 10 | # This program is distributed in the hope that it will be useful, 11 | # but WITHOUT ANY WARRANTY, to the extent permitted by law; without 12 | # even the implied warranty of MERCHANTABILITY or FITNESS FOR A 13 | # PARTICULAR PURPOSE. 14 | 15 | @SET_MAKE@ 16 | 17 | srcdir = @srcdir@ 18 | top_srcdir = @top_srcdir@ 19 | VPATH = @srcdir@ 20 | pkgdatadir = $(datadir)/@PACKAGE@ 21 | pkglibdir = $(libdir)/@PACKAGE@ 22 | pkgincludedir = $(includedir)/@PACKAGE@ 23 | top_builddir = .. 24 | 25 | am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd 26 | INSTALL = @INSTALL@ 27 | install_sh_DATA = $(install_sh) -c -m 644 28 | install_sh_PROGRAM = $(install_sh) -c 29 | install_sh_SCRIPT = $(install_sh) -c 30 | INSTALL_HEADER = $(INSTALL_DATA) 31 | transform = $(program_transform_name) 32 | NORMAL_INSTALL = : 33 | PRE_INSTALL = : 34 | POST_INSTALL = : 35 | NORMAL_UNINSTALL = : 36 | PRE_UNINSTALL = : 37 | POST_UNINSTALL = : 38 | ACLOCAL = @ACLOCAL@ 39 | ALL_LINGUAS = @ALL_LINGUAS@ 40 | AMDEP_FALSE = @AMDEP_FALSE@ 41 | AMDEP_TRUE = @AMDEP_TRUE@ 42 | AMTAR = @AMTAR@ 43 | AUTOCONF = @AUTOCONF@ 44 | AUTOHEADER = @AUTOHEADER@ 45 | AUTOMAKE = @AUTOMAKE@ 46 | AWK = @AWK@ 47 | CATALOGS = @CATALOGS@ 48 | CATOBJEXT = @CATOBJEXT@ 49 | CC = @CC@ 50 | CCDEPMODE = @CCDEPMODE@ 51 | CFLAGS = @CFLAGS@ 52 | CPP = @CPP@ 53 | CPPFLAGS = @CPPFLAGS@ 54 | CXX = @CXX@ 55 | CXXDEPMODE = @CXXDEPMODE@ 56 | CXXFLAGS = @CXXFLAGS@ 57 | CYGPATH_W = @CYGPATH_W@ 58 | DATADIR = @DATADIR@ 59 | DATADIRNAME = @DATADIRNAME@ 60 | DEFS = @DEFS@ 61 | DEPDIR = @DEPDIR@ 62 | ECHO_C = @ECHO_C@ 63 | ECHO_N = @ECHO_N@ 64 | ECHO_T = @ECHO_T@ 65 | EGREP = @EGREP@ 66 | EXEEXT = @EXEEXT@ 67 | GETTEXT_PACKAGE = @GETTEXT_PACKAGE@ 68 | GIMP_CFLAGS = @GIMP_CFLAGS@ 69 | GIMP_LIBDIR = @GIMP_LIBDIR@ 70 | GIMP_LIBS = @GIMP_LIBS@ 71 | GMOFILES = @GMOFILES@ 72 | GMSGFMT = @GMSGFMT@ 73 | GREP = @GREP@ 74 | INSTALL_DATA = @INSTALL_DATA@ 75 | INSTALL_PROGRAM = @INSTALL_PROGRAM@ 76 | INSTALL_SCRIPT = @INSTALL_SCRIPT@ 77 | INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ 78 | INSTOBJEXT = @INSTOBJEXT@ 79 | INTLLIBS = @INTLLIBS@ 80 | INTLTOOL_CAVES_RULE = @INTLTOOL_CAVES_RULE@ 81 | INTLTOOL_DESKTOP_RULE = @INTLTOOL_DESKTOP_RULE@ 82 | INTLTOOL_DIRECTORY_RULE = @INTLTOOL_DIRECTORY_RULE@ 83 | INTLTOOL_EXTRACT = @INTLTOOL_EXTRACT@ 84 | INTLTOOL_ICONV = @INTLTOOL_ICONV@ 85 | INTLTOOL_KBD_RULE = @INTLTOOL_KBD_RULE@ 86 | INTLTOOL_KEYS_RULE = @INTLTOOL_KEYS_RULE@ 87 | INTLTOOL_MERGE = @INTLTOOL_MERGE@ 88 | INTLTOOL_MSGFMT = @INTLTOOL_MSGFMT@ 89 | INTLTOOL_MSGMERGE = @INTLTOOL_MSGMERGE@ 90 | INTLTOOL_OAF_RULE = @INTLTOOL_OAF_RULE@ 91 | INTLTOOL_PERL = @INTLTOOL_PERL@ 92 | INTLTOOL_PONG_RULE = @INTLTOOL_PONG_RULE@ 93 | INTLTOOL_PROP_RULE = @INTLTOOL_PROP_RULE@ 94 | INTLTOOL_SCHEMAS_RULE = @INTLTOOL_SCHEMAS_RULE@ 95 | INTLTOOL_SERVER_RULE = @INTLTOOL_SERVER_RULE@ 96 | INTLTOOL_SERVICE_RULE = @INTLTOOL_SERVICE_RULE@ 97 | INTLTOOL_SHEET_RULE = @INTLTOOL_SHEET_RULE@ 98 | INTLTOOL_SOUNDLIST_RULE = @INTLTOOL_SOUNDLIST_RULE@ 99 | INTLTOOL_THEME_RULE = @INTLTOOL_THEME_RULE@ 100 | INTLTOOL_UI_RULE = @INTLTOOL_UI_RULE@ 101 | INTLTOOL_UPDATE = @INTLTOOL_UPDATE@ 102 | INTLTOOL_XAM_RULE = @INTLTOOL_XAM_RULE@ 103 | INTLTOOL_XGETTEXT = @INTLTOOL_XGETTEXT@ 104 | INTLTOOL_XML_NOMERGE_RULE = @INTLTOOL_XML_NOMERGE_RULE@ 105 | INTLTOOL_XML_RULE = @INTLTOOL_XML_RULE@ 106 | LDFLAGS = @LDFLAGS@ 107 | LIBOBJS = @LIBOBJS@ 108 | LIBS = @LIBS@ 109 | LOCALEDIR = @LOCALEDIR@ 110 | LTLIBOBJS = @LTLIBOBJS@ 111 | MAINT = @MAINT@ 112 | MAINTAINER_MODE_FALSE = @MAINTAINER_MODE_FALSE@ 113 | MAINTAINER_MODE_TRUE = @MAINTAINER_MODE_TRUE@ 114 | MAKEINFO = @MAKEINFO@ 115 | MKINSTALLDIRS = @MKINSTALLDIRS@ 116 | MSGFMT = @MSGFMT@ 117 | OBJEXT = @OBJEXT@ 118 | PACKAGE = @PACKAGE@ 119 | PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ 120 | PACKAGE_NAME = @PACKAGE_NAME@ 121 | PACKAGE_STRING = @PACKAGE_STRING@ 122 | PACKAGE_TARNAME = @PACKAGE_TARNAME@ 123 | PACKAGE_VERSION = @PACKAGE_VERSION@ 124 | PATH_SEPARATOR = @PATH_SEPARATOR@ 125 | PKG_CONFIG = @PKG_CONFIG@ 126 | POFILES = @POFILES@ 127 | POSUB = @POSUB@ 128 | PO_IN_DATADIR_FALSE = @PO_IN_DATADIR_FALSE@ 129 | PO_IN_DATADIR_TRUE = @PO_IN_DATADIR_TRUE@ 130 | SET_MAKE = @SET_MAKE@ 131 | SHELL = @SHELL@ 132 | STRIP = @STRIP@ 133 | USE_NLS = @USE_NLS@ 134 | VERSION = @VERSION@ 135 | XGETTEXT = @XGETTEXT@ 136 | ac_ct_CC = @ac_ct_CC@ 137 | ac_ct_CXX = @ac_ct_CXX@ 138 | am__fastdepCC_FALSE = @am__fastdepCC_FALSE@ 139 | am__fastdepCC_TRUE = @am__fastdepCC_TRUE@ 140 | am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@ 141 | am__fastdepCXX_TRUE = @am__fastdepCXX_TRUE@ 142 | am__include = @am__include@ 143 | am__leading_dot = @am__leading_dot@ 144 | am__quote = @am__quote@ 145 | 146 | bindir = $(prefix)$(GIMP_LIBDIR)/plug-ins 147 | build_alias = @build_alias@ 148 | datadir = @datadir@ 149 | datarootdir = @datarootdir@ 150 | docdir = @docdir@ 151 | dvidir = @dvidir@ 152 | exec_prefix = @exec_prefix@ 153 | host_alias = @host_alias@ 154 | htmldir = @htmldir@ 155 | includedir = @includedir@ 156 | infodir = @infodir@ 157 | install_sh = @install_sh@ 158 | libdir = @libdir@ 159 | libexecdir = @libexecdir@ 160 | localedir = @localedir@ 161 | localstatedir = @localstatedir@ 162 | mandir = @mandir@ 163 | oldincludedir = @oldincludedir@ 164 | pdfdir = @pdfdir@ 165 | prefix = @prefix@ 166 | program_transform_name = @program_transform_name@ 167 | psdir = @psdir@ 168 | sbindir = @sbindir@ 169 | sharedstatedir = @sharedstatedir@ 170 | sysconfdir = @sysconfdir@ 171 | target_alias = @target_alias@ 172 | 173 | bin_PROGRAMS = deskew 174 | 175 | deskew_SOURCES = \ 176 | plugin-intl.h \ 177 | interface.c \ 178 | interface.h \ 179 | main.c \ 180 | main.h \ 181 | render.c \ 182 | render.h \ 183 | formats/gimpfact.cc \ 184 | formats/gimpfact.h \ 185 | raster/bwfactory.h \ 186 | raster/bwimage.cc \ 187 | raster/bwimage.h \ 188 | raster/deskewer.cc \ 189 | raster/deskewer.h \ 190 | util/bitutil.cc \ 191 | util/bitutil.h \ 192 | util/cntptr.h \ 193 | deskew.cc \ 194 | deskew.h 195 | 196 | 197 | AM_CPPFLAGS = \ 198 | -DLOCALEDIR=\""$(LOCALEDIR)"\" \ 199 | -DDATADIR=\""$(DATADIR)"\" 200 | 201 | 202 | INCLUDES = \ 203 | -I$(top_srcdir) \ 204 | @GIMP_CFLAGS@ \ 205 | -I$(includedir) 206 | 207 | 208 | LDADD = $(GIMP_LIBS) 209 | subdir = src 210 | ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 211 | mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs 212 | CONFIG_HEADER = $(top_builddir)/config.h 213 | CONFIG_CLEAN_FILES = 214 | bin_PROGRAMS = deskew$(EXEEXT) 215 | PROGRAMS = $(bin_PROGRAMS) 216 | 217 | am_deskew_OBJECTS = interface.$(OBJEXT) main.$(OBJEXT) render.$(OBJEXT) \ 218 | gimpfact.$(OBJEXT) bwimage.$(OBJEXT) deskewer.$(OBJEXT) \ 219 | bitutil.$(OBJEXT) deskew.$(OBJEXT) 220 | deskew_OBJECTS = $(am_deskew_OBJECTS) 221 | deskew_LDADD = $(LDADD) 222 | deskew_DEPENDENCIES = 223 | deskew_LDFLAGS = 224 | 225 | DEFAULT_INCLUDES = -I. -I$(srcdir) -I$(top_builddir) 226 | depcomp = $(SHELL) $(top_srcdir)/depcomp 227 | am__depfiles_maybe = depfiles 228 | @AMDEP_TRUE@DEP_FILES = ./$(DEPDIR)/bitutil.Po ./$(DEPDIR)/bwimage.Po \ 229 | @AMDEP_TRUE@ ./$(DEPDIR)/deskew.Po ./$(DEPDIR)/deskewer.Po \ 230 | @AMDEP_TRUE@ ./$(DEPDIR)/gimpfact.Po ./$(DEPDIR)/interface.Po \ 231 | @AMDEP_TRUE@ ./$(DEPDIR)/main.Po ./$(DEPDIR)/render.Po 232 | COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ 233 | $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) 234 | CCLD = $(CC) 235 | LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ 236 | CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ 237 | $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) 238 | CXXLD = $(CXX) 239 | CXXLINK = $(CXXLD) $(AM_CXXFLAGS) $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) \ 240 | -o $@ 241 | DIST_SOURCES = $(deskew_SOURCES) 242 | DIST_COMMON = $(srcdir)/Makefile.in Makefile.am 243 | SOURCES = $(deskew_SOURCES) 244 | 245 | all: all-am 246 | 247 | .SUFFIXES: 248 | .SUFFIXES: .c .cc .o .obj 249 | $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4) 250 | cd $(top_srcdir) && \ 251 | $(AUTOMAKE) --gnu src/Makefile 252 | Makefile: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.in $(top_builddir)/config.status 253 | cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe) 254 | binPROGRAMS_INSTALL = $(INSTALL_PROGRAM) 255 | install-binPROGRAMS: $(bin_PROGRAMS) 256 | @$(NORMAL_INSTALL) 257 | $(mkinstalldirs) $(DESTDIR)$(bindir) 258 | @list='$(bin_PROGRAMS)'; for p in $$list; do \ 259 | p1=`echo $$p|sed 's/$(EXEEXT)$$//'`; \ 260 | if test -f $$p \ 261 | ; then \ 262 | f=`echo "$$p1" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`; \ 263 | echo " $(INSTALL_PROGRAM_ENV) $(binPROGRAMS_INSTALL) $$p $(DESTDIR)$(bindir)/$$f"; \ 264 | $(INSTALL_PROGRAM_ENV) $(binPROGRAMS_INSTALL) $$p $(DESTDIR)$(bindir)/$$f || exit 1; \ 265 | else :; fi; \ 266 | done 267 | 268 | uninstall-binPROGRAMS: 269 | @$(NORMAL_UNINSTALL) 270 | @list='$(bin_PROGRAMS)'; for p in $$list; do \ 271 | f=`echo "$$p" | sed 's,^.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/'`; \ 272 | echo " rm -f $(DESTDIR)$(bindir)/$$f"; \ 273 | rm -f $(DESTDIR)$(bindir)/$$f; \ 274 | done 275 | 276 | clean-binPROGRAMS: 277 | -test -z "$(bin_PROGRAMS)" || rm -f $(bin_PROGRAMS) 278 | deskew$(EXEEXT): $(deskew_OBJECTS) $(deskew_DEPENDENCIES) 279 | @rm -f deskew$(EXEEXT) 280 | $(CXXLINK) $(deskew_LDFLAGS) $(deskew_OBJECTS) $(deskew_LDADD) $(LIBS) 281 | 282 | mostlyclean-compile: 283 | -rm -f *.$(OBJEXT) core *.core 284 | 285 | distclean-compile: 286 | -rm -f *.tab.c 287 | 288 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/bitutil.Po@am__quote@ 289 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/bwimage.Po@am__quote@ 290 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/deskew.Po@am__quote@ 291 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/deskewer.Po@am__quote@ 292 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gimpfact.Po@am__quote@ 293 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/interface.Po@am__quote@ 294 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/main.Po@am__quote@ 295 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/render.Po@am__quote@ 296 | 297 | .c.o: 298 | @am__fastdepCC_TRUE@ if $(COMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" \ 299 | @am__fastdepCC_TRUE@ -c -o $@ `test -f '$<' || echo '$(srcdir)/'`$<; \ 300 | @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; \ 301 | @am__fastdepCC_TRUE@ else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; \ 302 | @am__fastdepCC_TRUE@ fi 303 | @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ 304 | @AMDEP_TRUE@@am__fastdepCC_FALSE@ depfile='$(DEPDIR)/$*.Po' tmpdepfile='$(DEPDIR)/$*.TPo' @AMDEPBACKSLASH@ 305 | @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 306 | @am__fastdepCC_FALSE@ $(COMPILE) -c `test -f '$<' || echo '$(srcdir)/'`$< 307 | 308 | .c.obj: 309 | @am__fastdepCC_TRUE@ if $(COMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" \ 310 | @am__fastdepCC_TRUE@ -c -o $@ `if test -f '$<'; then $(CYGPATH_W) '$<'; else $(CYGPATH_W) '$(srcdir)/$<'; fi`; \ 311 | @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; \ 312 | @am__fastdepCC_TRUE@ else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; \ 313 | @am__fastdepCC_TRUE@ fi 314 | @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ 315 | @AMDEP_TRUE@@am__fastdepCC_FALSE@ depfile='$(DEPDIR)/$*.Po' tmpdepfile='$(DEPDIR)/$*.TPo' @AMDEPBACKSLASH@ 316 | @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 317 | @am__fastdepCC_FALSE@ $(COMPILE) -c `if test -f '$<'; then $(CYGPATH_W) '$<'; else $(CYGPATH_W) '$(srcdir)/$<'; fi` 318 | 319 | .cc.o: 320 | @am__fastdepCXX_TRUE@ if $(CXXCOMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" \ 321 | @am__fastdepCXX_TRUE@ -c -o $@ `test -f '$<' || echo '$(srcdir)/'`$<; \ 322 | @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; \ 323 | @am__fastdepCXX_TRUE@ else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; \ 324 | @am__fastdepCXX_TRUE@ fi 325 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ 326 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/$*.Po' tmpdepfile='$(DEPDIR)/$*.TPo' @AMDEPBACKSLASH@ 327 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 328 | @am__fastdepCXX_FALSE@ $(CXXCOMPILE) -c -o $@ `test -f '$<' || echo '$(srcdir)/'`$< 329 | 330 | .cc.obj: 331 | @am__fastdepCXX_TRUE@ if $(CXXCOMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" \ 332 | @am__fastdepCXX_TRUE@ -c -o $@ `if test -f '$<'; then $(CYGPATH_W) '$<'; else $(CYGPATH_W) '$(srcdir)/$<'; fi`; \ 333 | @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; \ 334 | @am__fastdepCXX_TRUE@ else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; \ 335 | @am__fastdepCXX_TRUE@ fi 336 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ 337 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/$*.Po' tmpdepfile='$(DEPDIR)/$*.TPo' @AMDEPBACKSLASH@ 338 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 339 | @am__fastdepCXX_FALSE@ $(CXXCOMPILE) -c -o $@ `if test -f '$<'; then $(CYGPATH_W) '$<'; else $(CYGPATH_W) '$(srcdir)/$<'; fi` 340 | 341 | gimpfact.o: formats/gimpfact.cc 342 | @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT gimpfact.o -MD -MP -MF "$(DEPDIR)/gimpfact.Tpo" \ 343 | @am__fastdepCXX_TRUE@ -c -o gimpfact.o `test -f 'formats/gimpfact.cc' || echo '$(srcdir)/'`formats/gimpfact.cc; \ 344 | @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/gimpfact.Tpo" "$(DEPDIR)/gimpfact.Po"; \ 345 | @am__fastdepCXX_TRUE@ else rm -f "$(DEPDIR)/gimpfact.Tpo"; exit 1; \ 346 | @am__fastdepCXX_TRUE@ fi 347 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='formats/gimpfact.cc' object='gimpfact.o' libtool=no @AMDEPBACKSLASH@ 348 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/gimpfact.Po' tmpdepfile='$(DEPDIR)/gimpfact.TPo' @AMDEPBACKSLASH@ 349 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 350 | @am__fastdepCXX_FALSE@ $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o gimpfact.o `test -f 'formats/gimpfact.cc' || echo '$(srcdir)/'`formats/gimpfact.cc 351 | 352 | gimpfact.obj: formats/gimpfact.cc 353 | @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT gimpfact.obj -MD -MP -MF "$(DEPDIR)/gimpfact.Tpo" \ 354 | @am__fastdepCXX_TRUE@ -c -o gimpfact.obj `if test -f 'formats/gimpfact.cc'; then $(CYGPATH_W) 'formats/gimpfact.cc'; else $(CYGPATH_W) '$(srcdir)/formats/gimpfact.cc'; fi`; \ 355 | @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/gimpfact.Tpo" "$(DEPDIR)/gimpfact.Po"; \ 356 | @am__fastdepCXX_TRUE@ else rm -f "$(DEPDIR)/gimpfact.Tpo"; exit 1; \ 357 | @am__fastdepCXX_TRUE@ fi 358 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='formats/gimpfact.cc' object='gimpfact.obj' libtool=no @AMDEPBACKSLASH@ 359 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/gimpfact.Po' tmpdepfile='$(DEPDIR)/gimpfact.TPo' @AMDEPBACKSLASH@ 360 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 361 | @am__fastdepCXX_FALSE@ $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o gimpfact.obj `if test -f 'formats/gimpfact.cc'; then $(CYGPATH_W) 'formats/gimpfact.cc'; else $(CYGPATH_W) '$(srcdir)/formats/gimpfact.cc'; fi` 362 | 363 | bwimage.o: raster/bwimage.cc 364 | @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT bwimage.o -MD -MP -MF "$(DEPDIR)/bwimage.Tpo" \ 365 | @am__fastdepCXX_TRUE@ -c -o bwimage.o `test -f 'raster/bwimage.cc' || echo '$(srcdir)/'`raster/bwimage.cc; \ 366 | @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/bwimage.Tpo" "$(DEPDIR)/bwimage.Po"; \ 367 | @am__fastdepCXX_TRUE@ else rm -f "$(DEPDIR)/bwimage.Tpo"; exit 1; \ 368 | @am__fastdepCXX_TRUE@ fi 369 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='raster/bwimage.cc' object='bwimage.o' libtool=no @AMDEPBACKSLASH@ 370 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/bwimage.Po' tmpdepfile='$(DEPDIR)/bwimage.TPo' @AMDEPBACKSLASH@ 371 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 372 | @am__fastdepCXX_FALSE@ $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o bwimage.o `test -f 'raster/bwimage.cc' || echo '$(srcdir)/'`raster/bwimage.cc 373 | 374 | bwimage.obj: raster/bwimage.cc 375 | @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT bwimage.obj -MD -MP -MF "$(DEPDIR)/bwimage.Tpo" \ 376 | @am__fastdepCXX_TRUE@ -c -o bwimage.obj `if test -f 'raster/bwimage.cc'; then $(CYGPATH_W) 'raster/bwimage.cc'; else $(CYGPATH_W) '$(srcdir)/raster/bwimage.cc'; fi`; \ 377 | @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/bwimage.Tpo" "$(DEPDIR)/bwimage.Po"; \ 378 | @am__fastdepCXX_TRUE@ else rm -f "$(DEPDIR)/bwimage.Tpo"; exit 1; \ 379 | @am__fastdepCXX_TRUE@ fi 380 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='raster/bwimage.cc' object='bwimage.obj' libtool=no @AMDEPBACKSLASH@ 381 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/bwimage.Po' tmpdepfile='$(DEPDIR)/bwimage.TPo' @AMDEPBACKSLASH@ 382 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 383 | @am__fastdepCXX_FALSE@ $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o bwimage.obj `if test -f 'raster/bwimage.cc'; then $(CYGPATH_W) 'raster/bwimage.cc'; else $(CYGPATH_W) '$(srcdir)/raster/bwimage.cc'; fi` 384 | 385 | deskewer.o: raster/deskewer.cc 386 | @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT deskewer.o -MD -MP -MF "$(DEPDIR)/deskewer.Tpo" \ 387 | @am__fastdepCXX_TRUE@ -c -o deskewer.o `test -f 'raster/deskewer.cc' || echo '$(srcdir)/'`raster/deskewer.cc; \ 388 | @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/deskewer.Tpo" "$(DEPDIR)/deskewer.Po"; \ 389 | @am__fastdepCXX_TRUE@ else rm -f "$(DEPDIR)/deskewer.Tpo"; exit 1; \ 390 | @am__fastdepCXX_TRUE@ fi 391 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='raster/deskewer.cc' object='deskewer.o' libtool=no @AMDEPBACKSLASH@ 392 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/deskewer.Po' tmpdepfile='$(DEPDIR)/deskewer.TPo' @AMDEPBACKSLASH@ 393 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 394 | @am__fastdepCXX_FALSE@ $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o deskewer.o `test -f 'raster/deskewer.cc' || echo '$(srcdir)/'`raster/deskewer.cc 395 | 396 | deskewer.obj: raster/deskewer.cc 397 | @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT deskewer.obj -MD -MP -MF "$(DEPDIR)/deskewer.Tpo" \ 398 | @am__fastdepCXX_TRUE@ -c -o deskewer.obj `if test -f 'raster/deskewer.cc'; then $(CYGPATH_W) 'raster/deskewer.cc'; else $(CYGPATH_W) '$(srcdir)/raster/deskewer.cc'; fi`; \ 399 | @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/deskewer.Tpo" "$(DEPDIR)/deskewer.Po"; \ 400 | @am__fastdepCXX_TRUE@ else rm -f "$(DEPDIR)/deskewer.Tpo"; exit 1; \ 401 | @am__fastdepCXX_TRUE@ fi 402 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='raster/deskewer.cc' object='deskewer.obj' libtool=no @AMDEPBACKSLASH@ 403 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/deskewer.Po' tmpdepfile='$(DEPDIR)/deskewer.TPo' @AMDEPBACKSLASH@ 404 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 405 | @am__fastdepCXX_FALSE@ $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o deskewer.obj `if test -f 'raster/deskewer.cc'; then $(CYGPATH_W) 'raster/deskewer.cc'; else $(CYGPATH_W) '$(srcdir)/raster/deskewer.cc'; fi` 406 | 407 | bitutil.o: util/bitutil.cc 408 | @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT bitutil.o -MD -MP -MF "$(DEPDIR)/bitutil.Tpo" \ 409 | @am__fastdepCXX_TRUE@ -c -o bitutil.o `test -f 'util/bitutil.cc' || echo '$(srcdir)/'`util/bitutil.cc; \ 410 | @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/bitutil.Tpo" "$(DEPDIR)/bitutil.Po"; \ 411 | @am__fastdepCXX_TRUE@ else rm -f "$(DEPDIR)/bitutil.Tpo"; exit 1; \ 412 | @am__fastdepCXX_TRUE@ fi 413 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='util/bitutil.cc' object='bitutil.o' libtool=no @AMDEPBACKSLASH@ 414 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/bitutil.Po' tmpdepfile='$(DEPDIR)/bitutil.TPo' @AMDEPBACKSLASH@ 415 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 416 | @am__fastdepCXX_FALSE@ $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o bitutil.o `test -f 'util/bitutil.cc' || echo '$(srcdir)/'`util/bitutil.cc 417 | 418 | bitutil.obj: util/bitutil.cc 419 | @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT bitutil.obj -MD -MP -MF "$(DEPDIR)/bitutil.Tpo" \ 420 | @am__fastdepCXX_TRUE@ -c -o bitutil.obj `if test -f 'util/bitutil.cc'; then $(CYGPATH_W) 'util/bitutil.cc'; else $(CYGPATH_W) '$(srcdir)/util/bitutil.cc'; fi`; \ 421 | @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/bitutil.Tpo" "$(DEPDIR)/bitutil.Po"; \ 422 | @am__fastdepCXX_TRUE@ else rm -f "$(DEPDIR)/bitutil.Tpo"; exit 1; \ 423 | @am__fastdepCXX_TRUE@ fi 424 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='util/bitutil.cc' object='bitutil.obj' libtool=no @AMDEPBACKSLASH@ 425 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/bitutil.Po' tmpdepfile='$(DEPDIR)/bitutil.TPo' @AMDEPBACKSLASH@ 426 | @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 427 | @am__fastdepCXX_FALSE@ $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o bitutil.obj `if test -f 'util/bitutil.cc'; then $(CYGPATH_W) 'util/bitutil.cc'; else $(CYGPATH_W) '$(srcdir)/util/bitutil.cc'; fi` 428 | uninstall-info-am: 429 | 430 | ETAGS = etags 431 | ETAGSFLAGS = 432 | 433 | CTAGS = ctags 434 | CTAGSFLAGS = 435 | 436 | tags: TAGS 437 | 438 | ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) 439 | list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ 440 | unique=`for i in $$list; do \ 441 | if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ 442 | done | \ 443 | $(AWK) ' { files[$$0] = 1; } \ 444 | END { for (i in files) print i; }'`; \ 445 | mkid -fID $$unique 446 | 447 | TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ 448 | $(TAGS_FILES) $(LISP) 449 | tags=; \ 450 | here=`pwd`; \ 451 | list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ 452 | unique=`for i in $$list; do \ 453 | if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ 454 | done | \ 455 | $(AWK) ' { files[$$0] = 1; } \ 456 | END { for (i in files) print i; }'`; \ 457 | test -z "$(ETAGS_ARGS)$$tags$$unique" \ 458 | || $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ 459 | $$tags $$unique 460 | 461 | ctags: CTAGS 462 | CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ 463 | $(TAGS_FILES) $(LISP) 464 | tags=; \ 465 | here=`pwd`; \ 466 | list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ 467 | unique=`for i in $$list; do \ 468 | if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ 469 | done | \ 470 | $(AWK) ' { files[$$0] = 1; } \ 471 | END { for (i in files) print i; }'`; \ 472 | test -z "$(CTAGS_ARGS)$$tags$$unique" \ 473 | || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ 474 | $$tags $$unique 475 | 476 | GTAGS: 477 | here=`$(am__cd) $(top_builddir) && pwd` \ 478 | && cd $(top_srcdir) \ 479 | && gtags -i $(GTAGS_ARGS) $$here 480 | 481 | distclean-tags: 482 | -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags 483 | DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) 484 | 485 | top_distdir = .. 486 | distdir = $(top_distdir)/$(PACKAGE)-$(VERSION) 487 | 488 | distdir: $(DISTFILES) 489 | @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \ 490 | topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \ 491 | list='$(DISTFILES)'; for file in $$list; do \ 492 | case $$file in \ 493 | $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \ 494 | $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \ 495 | esac; \ 496 | if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ 497 | dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ 498 | if test "$$dir" != "$$file" && test "$$dir" != "."; then \ 499 | dir="/$$dir"; \ 500 | $(mkinstalldirs) "$(distdir)$$dir"; \ 501 | else \ 502 | dir=''; \ 503 | fi; \ 504 | if test -d $$d/$$file; then \ 505 | if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ 506 | cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ 507 | fi; \ 508 | cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ 509 | else \ 510 | test -f $(distdir)/$$file \ 511 | || cp -p $$d/$$file $(distdir)/$$file \ 512 | || exit 1; \ 513 | fi; \ 514 | done 515 | check-am: all-am 516 | check: check-am 517 | all-am: Makefile $(PROGRAMS) 518 | 519 | installdirs: 520 | $(mkinstalldirs) $(DESTDIR)$(bindir) 521 | install: install-am 522 | install-exec: install-exec-am 523 | install-data: install-data-am 524 | uninstall: uninstall-am 525 | 526 | install-am: all-am 527 | @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am 528 | 529 | installcheck: installcheck-am 530 | install-strip: 531 | $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ 532 | install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ 533 | `test -z '$(STRIP)' || \ 534 | echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install 535 | mostlyclean-generic: 536 | 537 | clean-generic: 538 | 539 | distclean-generic: 540 | -rm -f $(CONFIG_CLEAN_FILES) 541 | 542 | maintainer-clean-generic: 543 | @echo "This command is intended for maintainers to use" 544 | @echo "it deletes files that may require special tools to rebuild." 545 | clean: clean-am 546 | 547 | clean-am: clean-binPROGRAMS clean-generic mostlyclean-am 548 | 549 | distclean: distclean-am 550 | -rm -rf ./$(DEPDIR) 551 | -rm -f Makefile 552 | distclean-am: clean-am distclean-compile distclean-generic \ 553 | distclean-tags 554 | 555 | dvi: dvi-am 556 | 557 | dvi-am: 558 | 559 | info: info-am 560 | 561 | info-am: 562 | 563 | install-data-am: 564 | 565 | install-exec-am: install-binPROGRAMS 566 | 567 | install-info: install-info-am 568 | 569 | install-man: 570 | 571 | installcheck-am: 572 | 573 | maintainer-clean: maintainer-clean-am 574 | -rm -rf ./$(DEPDIR) 575 | -rm -f Makefile 576 | maintainer-clean-am: distclean-am maintainer-clean-generic 577 | 578 | mostlyclean: mostlyclean-am 579 | 580 | mostlyclean-am: mostlyclean-compile mostlyclean-generic 581 | 582 | pdf: pdf-am 583 | 584 | pdf-am: 585 | 586 | ps: ps-am 587 | 588 | ps-am: 589 | 590 | uninstall-am: uninstall-binPROGRAMS uninstall-info-am 591 | 592 | .PHONY: CTAGS GTAGS all all-am check check-am clean clean-binPROGRAMS \ 593 | clean-generic ctags distclean distclean-compile \ 594 | distclean-generic distclean-tags distdir dvi dvi-am info \ 595 | info-am install install-am install-binPROGRAMS install-data \ 596 | install-data-am install-exec install-exec-am install-info \ 597 | install-info-am install-man install-strip installcheck \ 598 | installcheck-am installdirs maintainer-clean \ 599 | maintainer-clean-generic mostlyclean mostlyclean-compile \ 600 | mostlyclean-generic pdf pdf-am ps ps-am tags uninstall \ 601 | uninstall-am uninstall-binPROGRAMS uninstall-info-am 602 | 603 | #LDADD = $(GIMP_LIBS) -lnetpbm 604 | # Tell versions [3.59,3.63) of GNU make to not export all variables. 605 | # Otherwise a system limit (for SysV at least) may be exceeded. 606 | .NOEXPORT: 607 | -------------------------------------------------------------------------------- /src/deskew.cc: -------------------------------------------------------------------------------- 1 | 2 | // quarl 2007-03-03 3 | // initial version 4 | 5 | #include "deskew.h" 6 | #include "formats/gimpfact.h" 7 | #include "raster/deskewer.h" 8 | 9 | // TODO: de-objectize - remove namespaces, factories, etc. 10 | 11 | double gimp_find_skew(GimpDrawable *drawable) 12 | { 13 | GimpFactory f(drawable); 14 | CntPtr b = f.create(); 15 | double alpha = pagetools::Deskewer::findSkew(*b); 16 | return alpha; 17 | } 18 | -------------------------------------------------------------------------------- /src/deskew.h: -------------------------------------------------------------------------------- 1 | // quarl 2007-03-03 2 | // initial version 3 | 4 | #ifndef DESKEW_H 5 | #define DESKEW_H 6 | 7 | #include 8 | 9 | // #define DEBUG 1 10 | 11 | #if DEBUG 12 | #include 13 | #define DEBUGPRINT(x...) fprintf(stderr, x) 14 | #else 15 | #define DEBUGPRINT(x...) ((void)0) 16 | #endif 17 | 18 | #ifdef __cplusplus 19 | extern "C" { 20 | #endif 21 | 22 | extern double gimp_find_skew(GimpDrawable *drawable); 23 | 24 | #ifdef __cplusplus 25 | } 26 | #endif 27 | 28 | #endif 29 | -------------------------------------------------------------------------------- /src/formats/Makefile: -------------------------------------------------------------------------------- 1 | all .o: 2 | cd .. && $(MAKE) $@ 3 | -------------------------------------------------------------------------------- /src/formats/gimpfact.cc: -------------------------------------------------------------------------------- 1 | // GIMP deskew plug-in 2 | // 3 | // Copyright (C) 2007, 2008 Karl Chen 4 | 5 | // This program is free software; you can redistribute it and/or modify it 6 | // under the terms of the GNU General Public License as published by the Free 7 | // Software Foundation; either version 2 of the License, or (at your option) 8 | // any later version. 9 | 10 | // This program is distributed in the hope that it will be useful, but WITHOUT 11 | // ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 12 | // FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for 13 | // more details. 14 | 15 | // You should have received a copy of the GNU General Public License along 16 | // with this program; if not, write to the Free Software Foundation, Inc., 51 17 | // Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. 18 | 19 | // quarl 2007-03-03 initial version 20 | 21 | #include 22 | #include "deskew.h" 23 | 24 | GimpFactory::GimpFactory(GimpDrawable *drawable) 25 | :drawable_(drawable) 26 | { 27 | } 28 | 29 | // read a BWImage (packed black&white image) from Gimp 30 | 31 | CntPtr 32 | GimpFactory::create() { 33 | 34 | // quarl 2007-03-03 35 | // TODO: this could be a parameter, but for now I don't think we need it. 36 | gint black_threshold = 100; 37 | 38 | gint x1, y1, x2, y2; 39 | 40 | gimp_drawable_mask_bounds (drawable_->drawable_id, 41 | &x1, &y1, 42 | &x2, &y2); 43 | 44 | gint bpp = gimp_drawable_bpp (drawable_->drawable_id); 45 | 46 | gboolean has_alpha = gimp_drawable_has_alpha(drawable_->drawable_id); 47 | 48 | gint w = x2 - x1; 49 | gint h = y2 - y1; 50 | 51 | DEBUGPRINT("GimpFactory::create(): bounds: x1=%d, x2=%d, y1=%d, y2=%d, w=%d, h=%d, bpp=%d\n", 52 | x1, x2, y1, y2, w, h, bpp); 53 | 54 | gint max_bpp_check = bpp; 55 | if (has_alpha) { 56 | // ignore last channel (XXX this assumes 1 byte per channel and alpha 57 | // channel is last byte!) 58 | max_bpp_check --; 59 | } 60 | 61 | CntPtr image = CntPtr(new BWImage(w, h)); 62 | 63 | GimpPixelRgn rgn; 64 | gimp_pixel_rgn_init (&rgn, 65 | drawable_, 66 | x1, y1, 67 | w, h, 68 | FALSE, FALSE); 69 | 70 | unsigned int bytewidth = image->bytewidth(); 71 | unsigned char padmask=0xFF<<((w+7)%8); 72 | 73 | #if DEBUG 74 | fprintf(stderr, "## writing to /tmp/t.pbm\n"); 75 | FILE *D = fopen("/tmp/t.pbm", "w"); 76 | fprintf(D, "P4\n%d %d\n", w, h); 77 | #endif 78 | 79 | double total_pixels = double(w) * double(h); 80 | double prev_show_progress = -99; 81 | double pixels_seen = 0; 82 | 83 | image->zeroAll(); 84 | 85 | for (gpointer pr = gimp_pixel_rgns_register (1, &rgn); 86 | pr != NULL; 87 | pr = gimp_pixel_rgns_process (pr)) 88 | { 89 | pixels_seen += double(rgn.w) * double(rgn.h); 90 | // fprintf(stderr, "## pixels_seen = %ld\n", (long)pixels_seen); 91 | 92 | for (int y = 0; y < rgn.h; ++y) { 93 | for (int x = 0; x < rgn.w; ++x) { 94 | for (int k = 0; k < max_bpp_check; ++k) { 95 | if (rgn.data[y * rgn.rowstride + x * bpp + k] < black_threshold) { 96 | image->setPixelOn( rgn.y + y - y1, rgn.x + x - x1 ); 97 | break; 98 | } 99 | } 100 | } 101 | } 102 | 103 | double progress = pixels_seen / total_pixels; 104 | if (progress > prev_show_progress + 0.01) { 105 | gimp_progress_update(progress); 106 | prev_show_progress = progress; 107 | } 108 | } 109 | 110 | 111 | DEBUGPRINT("GimpFactory::create(): done\n"); 112 | 113 | return image; 114 | } 115 | -------------------------------------------------------------------------------- /src/formats/gimpfact.h: -------------------------------------------------------------------------------- 1 | #ifndef GIMPFACT_H 2 | #define GIMPFACT_H 3 | 4 | // quarl 2007-03-03 initial version 5 | 6 | #include 7 | #include 8 | 9 | using pagetools::CntPtr; 10 | using pagetools::BWFactory; 11 | using pagetools::BWImage; 12 | 13 | class GimpFactory: public BWFactory 14 | { 15 | public: 16 | GimpFactory(GimpDrawable *drawable); 17 | virtual CntPtr create(); 18 | private: 19 | GimpDrawable *drawable_; 20 | }; 21 | 22 | #endif//GIMPFACT_H 23 | -------------------------------------------------------------------------------- /src/interface.c: -------------------------------------------------------------------------------- 1 | // GIMP deskew plug-in 2 | // 3 | // Copyright (C) 2007 Karl Chen 4 | 5 | // This program is free software; you can redistribute it and/or modify it 6 | // under the terms of the GNU General Public License as published by the Free 7 | // Software Foundation; either version 2 of the License, or (at your option) 8 | // any later version. 9 | 10 | // This program is distributed in the hope that it will be useful, but WITHOUT 11 | // ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 12 | // FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for 13 | // more details. 14 | 15 | // You should have received a copy of the GNU General Public License along 16 | // with this program; if not, write to the Free Software Foundation, Inc., 51 17 | // Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. 18 | 19 | /* GIMP Plug-in Template 20 | * Copyright (C) 2000-2004 Michael Natterer (the "Author"). 21 | * All Rights Reserved. 22 | * 23 | * Permission is hereby granted, free of charge, to any person obtaining a 24 | * copy of this software and associated documentation files (the "Software"), 25 | * to deal in the Software without restriction, including without limitation 26 | * the rights to use, copy, modify, merge, publish, distribute, sublicense, 27 | * and/or sell copies of the Software, and to permit persons to whom the 28 | * Software is furnished to do so, subject to the following conditions: 29 | * 30 | * The above copyright notice and this permission notice shall be included 31 | * in all copies or substantial portions of the Software. 32 | * 33 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 34 | * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 35 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL 36 | * THE AUTHOR BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 37 | * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 38 | * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 39 | * 40 | * Except as contained in this notice, the name of the Author of the 41 | * Software shall not be used in advertising or otherwise to promote the 42 | * sale, use or other dealings in this Software without prior written 43 | * authorization from the Author. 44 | */ 45 | 46 | #include "config.h" 47 | 48 | #include 49 | #include 50 | #include 51 | 52 | #include "main.h" 53 | #include "interface.h" 54 | 55 | #include "plugin-intl.h" 56 | 57 | 58 | /* Constants */ 59 | 60 | #define SCALE_WIDTH 180 61 | #define SPIN_BUTTON_WIDTH 75 62 | #define RANDOM_SEED_WIDTH 100 63 | 64 | 65 | /* Local function prototypes */ 66 | 67 | static gboolean dialog_image_constraint_func (gint32 image_id, 68 | gpointer data); 69 | 70 | 71 | /* Local variables */ 72 | 73 | static PlugInUIVals *ui_state = NULL; 74 | 75 | 76 | /* Public functions */ 77 | 78 | gboolean 79 | dialog (gint32 image_ID, 80 | GimpDrawable *drawable, 81 | PlugInVals *vals, 82 | PlugInImageVals *image_vals, 83 | PlugInDrawableVals *drawable_vals, 84 | PlugInUIVals *ui_vals) 85 | { 86 | #if 1 87 | // quarl 2007-03-03 88 | // No dialog for now. Shouldn't be called. 89 | abort(); 90 | #else 91 | GtkWidget *dlg; 92 | GtkWidget *main_vbox; 93 | GtkWidget *frame; 94 | GtkWidget *table; 95 | GtkWidget *hbox; 96 | GtkWidget *hbox2; 97 | GtkWidget *coordinates; 98 | GtkWidget *combo; 99 | GtkObject *adj; 100 | gint row; 101 | gboolean run = FALSE; 102 | GimpUnit unit; 103 | gdouble xres, yres; 104 | 105 | ui_state = ui_vals; 106 | 107 | gimp_ui_init (PLUGIN_NAME, TRUE); 108 | 109 | dlg = gimp_dialog_new (_("Deskew"), PLUGIN_NAME, 110 | NULL, 0, 111 | gimp_standard_help_func, "gimp-deskew-plug-in", 112 | 113 | GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL, 114 | GTK_STOCK_OK, GTK_RESPONSE_OK, 115 | 116 | NULL); 117 | 118 | main_vbox = gtk_vbox_new (FALSE, 12); 119 | gtk_container_set_border_width (GTK_CONTAINER (main_vbox), 12); 120 | gtk_container_add (GTK_CONTAINER (GTK_DIALOG (dlg)->vbox), main_vbox); 121 | 122 | /* gimp_scale_entry_new() examples */ 123 | 124 | frame = gimp_frame_new (_("ScaleEntry Examples")); 125 | gtk_box_pack_start (GTK_BOX (main_vbox), frame, FALSE, FALSE, 0); 126 | gtk_widget_show (frame); 127 | 128 | table = gtk_table_new (3, 3, FALSE); 129 | gtk_table_set_col_spacings (GTK_TABLE (table), 6); 130 | gtk_table_set_row_spacings (GTK_TABLE (table), 2); 131 | gtk_container_add (GTK_CONTAINER (frame), table); 132 | gtk_widget_show (table); 133 | 134 | row = 0; 135 | 136 | adj = gimp_scale_entry_new (GTK_TABLE (table), 0, row++, 137 | _("Dummy 1:"), SCALE_WIDTH, SPIN_BUTTON_WIDTH, 138 | vals->dummy1, 0, 100, 1, 10, 0, 139 | TRUE, 0, 0, 140 | _("Dummy scale entry 1"), NULL); 141 | g_signal_connect (adj, "value_changed", 142 | G_CALLBACK (gimp_int_adjustment_update), 143 | &vals->dummy1); 144 | 145 | adj = gimp_scale_entry_new (GTK_TABLE (table), 0, row++, 146 | _("Dummy 2:"), SCALE_WIDTH, SPIN_BUTTON_WIDTH, 147 | vals->dummy2, 0, 200, 1, 10, 0, 148 | TRUE, 0, 0, 149 | _("Dummy scale entry 2"), NULL); 150 | g_signal_connect (adj, "value_changed", 151 | G_CALLBACK (gimp_int_adjustment_update), 152 | &vals->dummy2); 153 | 154 | adj = gimp_scale_entry_new (GTK_TABLE (table), 0, row++, 155 | _("Dummy 3:"), SCALE_WIDTH, SPIN_BUTTON_WIDTH, 156 | vals->dummy3, -100, 100, 1, 10, 0, 157 | TRUE, 0, 0, 158 | _("Dummy scale entry 3"), NULL); 159 | g_signal_connect (adj, "value_changed", 160 | G_CALLBACK (gimp_int_adjustment_update), 161 | &vals->dummy3); 162 | 163 | /* gimp_random_seed_new() example */ 164 | 165 | frame = gimp_frame_new (_("A Random Seed Entry")); 166 | gtk_box_pack_start (GTK_BOX (main_vbox), frame, FALSE, FALSE, 0); 167 | gtk_widget_show (frame); 168 | hbox = gtk_hbox_new (FALSE, 6); 169 | gtk_container_add (GTK_CONTAINER (frame), hbox); 170 | gtk_widget_show (hbox); 171 | 172 | hbox2 = gimp_random_seed_new (&vals->seed, &vals->random_seed); 173 | gtk_widget_set_size_request (GTK_WIDGET (GIMP_RANDOM_SEED_SPINBUTTON (hbox2)), 174 | RANDOM_SEED_WIDTH, -1); 175 | gtk_box_pack_start (GTK_BOX (hbox), hbox2, FALSE, FALSE, 0); 176 | gtk_widget_show (hbox2); 177 | 178 | /* gimp_coordinates_new() example */ 179 | 180 | frame = gimp_frame_new (_("A GimpCoordinates Widget\n" 181 | "Initialized with the Drawable's Size")); 182 | gtk_box_pack_start (GTK_BOX (main_vbox), frame, FALSE, FALSE, 0); 183 | gtk_widget_show (frame); 184 | 185 | hbox = gtk_hbox_new (FALSE, 4); 186 | gtk_container_set_border_width (GTK_CONTAINER (hbox), 4); 187 | gtk_container_add (GTK_CONTAINER (frame), hbox); 188 | gtk_widget_show (hbox); 189 | 190 | unit = gimp_image_get_unit (image_ID); 191 | gimp_image_get_resolution (image_ID, &xres, &yres); 192 | 193 | coordinates = gimp_coordinates_new (unit, "%p", TRUE, TRUE, SPIN_BUTTON_WIDTH, 194 | GIMP_SIZE_ENTRY_UPDATE_SIZE, 195 | 196 | ui_vals->chain_active, TRUE, 197 | 198 | _("Width:"), drawable->width, xres, 199 | 1, GIMP_MAX_IMAGE_SIZE, 200 | 0, drawable->width, 201 | 202 | _("Height:"), drawable->height, yres, 203 | 1, GIMP_MAX_IMAGE_SIZE, 204 | 0, drawable->height); 205 | gtk_box_pack_start (GTK_BOX (hbox), coordinates, FALSE, FALSE, 0); 206 | gtk_widget_show (coordinates); 207 | 208 | /* Image and drawable menus */ 209 | 210 | frame = gimp_frame_new (_("Image and Drawable Menu Examples")); 211 | gtk_box_pack_start (GTK_BOX (main_vbox), frame, FALSE, FALSE, 0); 212 | gtk_widget_show (frame); 213 | 214 | table = gtk_table_new (3, 2, FALSE); 215 | gtk_container_set_border_width (GTK_CONTAINER (table), 4); 216 | gtk_table_set_col_spacings (GTK_TABLE (table), 4); 217 | gtk_table_set_row_spacings (GTK_TABLE (table), 2); 218 | gtk_container_add (GTK_CONTAINER (frame), table); 219 | gtk_widget_show (table); 220 | 221 | row = 0; 222 | 223 | combo = gimp_layer_combo_box_new (NULL, NULL); 224 | gimp_int_combo_box_connect (GIMP_INT_COMBO_BOX (combo), drawable->drawable_id, 225 | G_CALLBACK (gimp_int_combo_box_get_active), 226 | &drawable_vals->drawable_id); 227 | 228 | gimp_table_attach_aligned (GTK_TABLE (table), 0, row++, 229 | _("Layers:"), 0.0, 0.5, combo, 1, FALSE); 230 | 231 | combo = gimp_image_combo_box_new (dialog_image_constraint_func, NULL); 232 | gimp_int_combo_box_connect (GIMP_INT_COMBO_BOX (combo), image_ID, 233 | G_CALLBACK (gimp_int_combo_box_get_active), 234 | &image_vals->image_id); 235 | 236 | gimp_table_attach_aligned (GTK_TABLE (table), 0, row++, 237 | _("RGB Images:"), 0.0, 0.5, combo, 1, FALSE); 238 | 239 | /* Show the main containers */ 240 | 241 | gtk_widget_show (main_vbox); 242 | gtk_widget_show (dlg); 243 | 244 | run = (gimp_dialog_run (GIMP_DIALOG (dlg)) == GTK_RESPONSE_OK); 245 | 246 | if (run) 247 | { 248 | /* Save ui values */ 249 | ui_state->chain_active = 250 | gimp_chain_button_get_active (GIMP_COORDINATES_CHAINBUTTON (coordinates)); 251 | } 252 | 253 | gtk_widget_destroy (dlg); 254 | 255 | return run; 256 | #endif 257 | } 258 | 259 | 260 | /* Private functions */ 261 | 262 | static gboolean 263 | dialog_image_constraint_func (gint32 image_id, 264 | gpointer data) 265 | { 266 | return (gimp_image_base_type (image_id) == GIMP_RGB); 267 | } 268 | -------------------------------------------------------------------------------- /src/interface.h: -------------------------------------------------------------------------------- 1 | 2 | #ifndef __INTERFACE_H__ 3 | #define __INTERFACE_H__ 4 | 5 | 6 | /* Public functions */ 7 | 8 | gboolean dialog (gint32 image_ID, 9 | GimpDrawable *drawable, 10 | PlugInVals *vals, 11 | PlugInImageVals *image_vals, 12 | PlugInDrawableVals *drawable_vals, 13 | PlugInUIVals *ui_vals); 14 | 15 | 16 | #endif /* __INTERFACE_H__ */ 17 | -------------------------------------------------------------------------------- /src/main.c: -------------------------------------------------------------------------------- 1 | // GIMP deskew plug-in 2 | // 3 | // Copyright (C) 2007, 2008 Karl Chen 4 | 5 | // This program is free software; you can redistribute it and/or modify it 6 | // under the terms of the GNU General Public License as published by the Free 7 | // Software Foundation; either version 2 of the License, or (at your option) 8 | // any later version. 9 | 10 | // This program is distributed in the hope that it will be useful, but WITHOUT 11 | // ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 12 | // FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for 13 | // more details. 14 | 15 | // You should have received a copy of the GNU General Public License along 16 | // with this program; if not, write to the Free Software Foundation, Inc., 51 17 | // Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. 18 | 19 | #include "config.h" 20 | 21 | #include 22 | 23 | #include 24 | #include 25 | 26 | #include "main.h" 27 | #include "interface.h" 28 | #include "render.h" 29 | 30 | #include "plugin-intl.h" 31 | 32 | 33 | /* Constants */ 34 | 35 | #define PROCEDURE_NAME "gimp_deskew_plugin" 36 | 37 | #define DATA_KEY_VALS "deskew" 38 | #define DATA_KEY_UI_VALS "deskew_ui" 39 | 40 | #define PARASITE_KEY "deskew-options" 41 | 42 | 43 | /* Local function prototypes */ 44 | 45 | static void query (void); 46 | static void run (const gchar *name, 47 | gint nparams, 48 | const GimpParam *param, 49 | gint *nreturn_vals, 50 | GimpParam **return_vals); 51 | 52 | 53 | /* Local variables */ 54 | 55 | const PlugInVals default_vals = 56 | { 57 | 0, 58 | 1, 59 | 2, 60 | 0, 61 | FALSE 62 | }; 63 | 64 | const PlugInImageVals default_image_vals = 65 | { 66 | 0 67 | }; 68 | 69 | const PlugInDrawableVals default_drawable_vals = 70 | { 71 | 0 72 | }; 73 | 74 | const PlugInUIVals default_ui_vals = 75 | { 76 | TRUE 77 | }; 78 | 79 | static PlugInVals vals; 80 | static PlugInImageVals image_vals; 81 | static PlugInDrawableVals drawable_vals; 82 | static PlugInUIVals ui_vals; 83 | 84 | 85 | GimpPlugInInfo PLUG_IN_INFO = 86 | { 87 | NULL, /* init_proc */ 88 | NULL, /* quit_proc */ 89 | query, /* query_proc */ 90 | run, /* run_proc */ 91 | }; 92 | 93 | MAIN () 94 | 95 | static void 96 | query (void) 97 | { 98 | gchar *help_path; 99 | gchar *help_uri; 100 | 101 | static GimpParamDef args[] = 102 | { 103 | { GIMP_PDB_INT32, "run_mode", "Interactive, non-interactive" }, 104 | { GIMP_PDB_IMAGE, "image", "Input image" }, 105 | { GIMP_PDB_DRAWABLE, "drawable", "Input drawable" }, 106 | { GIMP_PDB_INT32, "dummy", "dummy1" }, 107 | { GIMP_PDB_INT32, "dummy", "dummy2" }, 108 | { GIMP_PDB_INT32, "dummy", "dummy3" }, 109 | { GIMP_PDB_INT32, "seed", "Seed value (used only if randomize is FALSE)" }, 110 | { GIMP_PDB_INT32, "randomize", "Use a random seed (TRUE, FALSE)" } 111 | }; 112 | 113 | gimp_plugin_domain_register (GETTEXT_PACKAGE, LOCALEDIR); 114 | 115 | help_path = g_build_filename (DATADIR, "help", NULL); 116 | help_uri = g_filename_to_uri (help_path, NULL, NULL); 117 | g_free (help_path); 118 | 119 | gimp_plugin_help_register ("http://www.cubewano.org/gimp-deskew-plugin/help", 120 | help_uri); 121 | 122 | g_free (help_uri); 123 | 124 | gimp_install_procedure (PROCEDURE_NAME, 125 | N_("Automatically straighten the rotated image"), 126 | N_("This plug-in automatically straightens (deskews) rotated images"), 127 | "Karl Chen ", 128 | "Karl Chen ", 129 | "2008", 130 | N_("Deskew"), 131 | "RGB*, GRAY*, INDEXED*", 132 | GIMP_PLUGIN, 133 | G_N_ELEMENTS (args), 0, 134 | args, NULL); 135 | 136 | gimp_plugin_menu_register (PROCEDURE_NAME, "/Layer/Transform"); 137 | } 138 | 139 | static void 140 | run (const gchar *name, 141 | gint n_params, 142 | const GimpParam *param, 143 | gint *nreturn_vals, 144 | GimpParam **return_vals) 145 | { 146 | static GimpParam values[1]; 147 | GimpDrawable *drawable; 148 | gint32 image_ID; 149 | GimpRunMode run_mode; 150 | GimpPDBStatusType status = GIMP_PDB_SUCCESS; 151 | 152 | *nreturn_vals = 1; 153 | *return_vals = values; 154 | 155 | /* Initialize i18n support */ 156 | bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR); 157 | #ifdef HAVE_BIND_TEXTDOMAIN_CODESET 158 | bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8"); 159 | #endif 160 | textdomain (GETTEXT_PACKAGE); 161 | 162 | run_mode = param[0].data.d_int32; 163 | image_ID = param[1].data.d_int32; 164 | drawable = gimp_drawable_get (param[2].data.d_drawable); 165 | 166 | /* Initialize with default values */ 167 | vals = default_vals; 168 | image_vals = default_image_vals; 169 | drawable_vals = default_drawable_vals; 170 | ui_vals = default_ui_vals; 171 | 172 | if (strcmp (name, PROCEDURE_NAME) == 0) 173 | { 174 | switch (run_mode) 175 | { 176 | case GIMP_RUN_NONINTERACTIVE: 177 | if (n_params != 3) 178 | { 179 | status = GIMP_PDB_CALLING_ERROR; 180 | } 181 | else 182 | { 183 | // vals.dummy1 = param[3].data.d_int32; 184 | // vals.dummy2 = param[4].data.d_int32; 185 | // vals.dummy3 = param[5].data.d_int32; 186 | // vals.seed = param[6].data.d_int32; 187 | // vals.random_seed = param[7].data.d_int32; 188 | 189 | // if (vals.random_seed) 190 | // vals.seed = g_random_int (); 191 | } 192 | break; 193 | 194 | case GIMP_RUN_INTERACTIVE: 195 | /* Possibly retrieve data */ 196 | gimp_get_data (DATA_KEY_VALS, &vals); 197 | gimp_get_data (DATA_KEY_UI_VALS, &ui_vals); 198 | 199 | // if (! dialog (image_ID, drawable, 200 | // &vals, &image_vals, &drawable_vals, &ui_vals)) 201 | // { 202 | // status = GIMP_PDB_CANCEL; 203 | // } 204 | // break; 205 | 206 | case GIMP_RUN_WITH_LAST_VALS: 207 | /* Possibly retrieve data */ 208 | // gimp_get_data (DATA_KEY_VALS, &vals); 209 | 210 | // if (vals.random_seed) 211 | // vals.seed = g_random_int (); 212 | break; 213 | 214 | default: 215 | break; 216 | } 217 | } 218 | else 219 | { 220 | status = GIMP_PDB_CALLING_ERROR; 221 | } 222 | 223 | if (status == GIMP_PDB_SUCCESS) 224 | { 225 | render (image_ID, drawable, &vals, &image_vals, &drawable_vals); 226 | 227 | if (run_mode != GIMP_RUN_NONINTERACTIVE) 228 | gimp_displays_flush (); 229 | 230 | if (run_mode == GIMP_RUN_INTERACTIVE) 231 | { 232 | gimp_set_data (DATA_KEY_VALS, &vals, sizeof (vals)); 233 | gimp_set_data (DATA_KEY_UI_VALS, &ui_vals, sizeof (ui_vals)); 234 | } 235 | 236 | gimp_drawable_detach (drawable); 237 | } 238 | 239 | values[0].type = GIMP_PDB_STATUS; 240 | values[0].data.d_status = status; 241 | } 242 | -------------------------------------------------------------------------------- /src/main.h: -------------------------------------------------------------------------------- 1 | /* GIMP Plug-in Template 2 | * Copyright (C) 2000 Michael Natterer (the "Author"). 3 | * All Rights Reserved. 4 | * 5 | * Permission is hereby granted, free of charge, to any person obtaining a 6 | * copy of this software and associated documentation files (the "Software"), 7 | * to deal in the Software without restriction, including without limitation 8 | * the rights to use, copy, modify, merge, publish, distribute, sublicense, 9 | * and/or sell copies of the Software, and to permit persons to whom the 10 | * Software is furnished to do so, subject to the following conditions: 11 | * 12 | * The above copyright notice and this permission notice shall be included 13 | * in all copies or substantial portions of the Software. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 16 | * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL 18 | * THE AUTHOR BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 19 | * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 20 | * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | * 22 | * Except as contained in this notice, the name of the Author of the 23 | * Software shall not be used in advertising or otherwise to promote the 24 | * sale, use or other dealings in this Software without prior written 25 | * authorization from the Author. 26 | */ 27 | 28 | #ifndef __MAIN_H__ 29 | #define __MAIN_H__ 30 | 31 | 32 | typedef struct 33 | { 34 | gint dummy1; 35 | gint dummy2; 36 | gint dummy3; 37 | guint seed; 38 | gboolean random_seed; 39 | } PlugInVals; 40 | 41 | typedef struct 42 | { 43 | gint32 image_id; 44 | } PlugInImageVals; 45 | 46 | typedef struct 47 | { 48 | gint32 drawable_id; 49 | } PlugInDrawableVals; 50 | 51 | typedef struct 52 | { 53 | gboolean chain_active; 54 | } PlugInUIVals; 55 | 56 | 57 | /* Default values */ 58 | 59 | extern const PlugInVals default_vals; 60 | extern const PlugInImageVals default_image_vals; 61 | extern const PlugInDrawableVals default_drawable_vals; 62 | extern const PlugInUIVals default_ui_vals; 63 | 64 | 65 | #endif /* __MAIN_H__ */ 66 | -------------------------------------------------------------------------------- /src/plugin-intl.h: -------------------------------------------------------------------------------- 1 | /* plugin-intl.h 2 | * 3 | * Permission is hereby granted, free of charge, to any person obtaining a 4 | * copy of this software and associated documentation files (the "Software"), 5 | * to deal in the Software without restriction, including without limitation 6 | * the rights to use, copy, modify, merge, publish, distribute, sublicense, 7 | * and/or sell copies of the Software, and to permit persons to whom the 8 | * Software is furnished to do so, subject to the following conditions: 9 | * 10 | * The above copyright notice and this permission notice shall be included 11 | * in all copies or substantial portions of the Software. 12 | * 13 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 14 | * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 15 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL 16 | * THE AUTHOR BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 17 | * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 18 | * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 19 | * 20 | * Except as contained in this notice, the name of the Author of the 21 | * Software shall not be used in advertising or otherwise to promote the 22 | * sale, use or other dealings in this Software without prior written 23 | * authorization from the Author. 24 | */ 25 | 26 | #ifndef __PLUGIN_INTL_H__ 27 | #define __PLUGIN_INTL_H__ 28 | 29 | 30 | #ifndef GETTEXT_PACKAGE 31 | #error "config.h must be included prior to plugin-intl.h" 32 | #endif 33 | 34 | #include 35 | 36 | #define _(String) gettext (String) 37 | 38 | #ifdef gettext_noop 39 | # define N_(String) gettext_noop (String) 40 | #else 41 | # define N_(String) (String) 42 | #endif 43 | 44 | 45 | #endif /* __PLUGIN_INTL_H__ */ 46 | -------------------------------------------------------------------------------- /src/raster/bwfactory.h: -------------------------------------------------------------------------------- 1 | #ifndef __CF_BWFACTORY_H__ 2 | #define __CF_BWFACTORY_H__ 3 | 4 | /* 5 | This file is part of Page Layout Detection Tools. 6 | 7 | This code is free software; you can redistribute it and/or modify 8 | it under the terms of the GNU General Public License as published by 9 | the Free Software Foundation; either version 2 of the License, or 10 | (at your option) any later version. 11 | 12 | This code is distributed in the hope that it will be useful, 13 | but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | GNU General Public License for more details. 16 | 17 | You should have received a copy of the GNU General Public License 18 | along with this code; if not, write to the Free Software 19 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 20 | */ 21 | 22 | #include 23 | #include 24 | 25 | namespace pagetools{ 26 | 27 | class BWFactory{ 28 | public: 29 | virtual CntPtr create()=0; 30 | }; 31 | 32 | }// namespace pagetools 33 | #endif//__CF_BWFACTORY_H__ 34 | -------------------------------------------------------------------------------- /src/raster/bwimage.cc: -------------------------------------------------------------------------------- 1 | /* 2 | This file is part of Page Layout Detection Tools. 3 | 4 | This code is free software; you can redistribute it and/or modify 5 | it under the terms of the GNU General Public License as published by 6 | the Free Software Foundation; either version 2 of the License, or 7 | (at your option) any later version. 8 | 9 | This code is distributed in the hope that it will be useful, 10 | but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | GNU General Public License for more details. 13 | 14 | You should have received a copy of the GNU General Public License 15 | along with this code; if not, write to the Free Software 16 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #include 20 | #include 21 | 22 | namespace pagetools{ 23 | 24 | BWImage::BWImage() 25 | :w_(0), h_(0), bw_(0), data_(0) 26 | { 27 | } 28 | 29 | 30 | BWImage::BWImage(unsigned int w, unsigned int h) 31 | :w_(w), h_(h) 32 | { 33 | bw_=(w+7)/8; 34 | data_=new unsigned char[bw_*h_]; 35 | } 36 | 37 | BWImage::BWImage(unsigned int w, unsigned int h, unsigned int bw) 38 | :w_(w), h_(h), bw_(bw){ 39 | data_=new unsigned char[bw_*h_]; 40 | } 41 | 42 | BWImage::~BWImage(){ 43 | delete [] data_; 44 | } 45 | 46 | 47 | void 48 | BWImage::setSize(unsigned int w, unsigned int h){ 49 | delete [] data_; 50 | w_=w; 51 | h_=h; 52 | bw_=(w+7)/8; 53 | data_=new unsigned char[bw_*h_]; 54 | } 55 | 56 | void 57 | BWImage::setBitorder(bitorder_t bitorder){ 58 | bitorder_=bitorder; 59 | } 60 | 61 | 62 | void BWImage::zeroAll() { 63 | memset(data_, 0, bw_*h_); 64 | } 65 | 66 | }// namespace pagetools 67 | -------------------------------------------------------------------------------- /src/raster/bwimage.h: -------------------------------------------------------------------------------- 1 | #ifndef __CF_BWIMAGE_H__ 2 | #define __CF_BWIMAGE_H__ 3 | 4 | /* 5 | This file is part of Page Layout Detection Tools. 6 | 7 | This code is free software; you can redistribute it and/or modify 8 | it under the terms of the GNU General Public License as published by 9 | the Free Software Foundation; either version 2 of the License, or 10 | (at your option) any later version. 11 | 12 | This code is distributed in the hope that it will be useful, 13 | but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | GNU General Public License for more details. 16 | 17 | You should have received a copy of the GNU General Public License 18 | along with this code; if not, write to the Free Software 19 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 20 | */ 21 | 22 | namespace pagetools{ 23 | 24 | class BWImage{ 25 | public: 26 | typedef enum {MSB2LSB, LSB2MSB } bitorder_t; 27 | 28 | BWImage(); 29 | BWImage(unsigned int w, unsigned int h); 30 | BWImage(unsigned int w, unsigned int h, unsigned int bw); 31 | virtual ~BWImage(); 32 | 33 | // Accessor(s) 34 | 35 | unsigned int bytewidth()const{return bw_;} 36 | unsigned int width()const{return w_;} 37 | unsigned int height()const{return h_;} 38 | 39 | unsigned char const *scanline(unsigned int ir)const{ 40 | return data_+ir*bw_; 41 | } 42 | 43 | // Modifiers 44 | unsigned char *scanline(unsigned int ir){ 45 | return data_+ir*bw_; 46 | } 47 | 48 | void setSize(unsigned int w, unsigned int h); // Discards old data 49 | 50 | void setBitorder(bitorder_t bitorder); 51 | 52 | void zeroAll(); 53 | 54 | inline void setPixelOn(unsigned int y, unsigned int x) { 55 | scanline(y)[x / 8] |= (1 << (x%8)); 56 | } 57 | 58 | private: 59 | unsigned char *data_; 60 | unsigned int w_; // Width 61 | unsigned int h_; // Height 62 | unsigned int bw_; // Byte width 63 | bitorder_t bitorder_; 64 | 65 | // Assignment and copy ctor prohibited: 66 | BWImage(const BWImage&); 67 | const BWImage& operator=(const BWImage&); 68 | }; 69 | }// namespace pagetools 70 | #endif//__CF_BWIMAGE_H__ 71 | -------------------------------------------------------------------------------- /src/raster/deskewer.cc: -------------------------------------------------------------------------------- 1 | /* 2 | This file is part of Page Layout Detection Tools. 3 | 4 | This code is free software; you can redistribute it and/or modify 5 | it under the terms of the GNU General Public License as published by 6 | the Free Software Foundation; either version 2 of the License, or 7 | (at your option) any later version. 8 | 9 | This code is distributed in the hope that it will be useful, 10 | but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | GNU General Public License for more details. 13 | 14 | You should have received a copy of the GNU General Public License 15 | along with this code; if not, write to the Free Software 16 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #include 20 | #include 21 | #include 22 | #include 23 | 24 | namespace pagetools{ 25 | 26 | unsigned int 27 | Deskewer::next_pow2(unsigned int n){ 28 | unsigned int retval=1; 29 | while(retvalvmax){ 48 | imax=i; 49 | vmax=s; 50 | } 51 | sum+=s; 52 | } 53 | unsigned int h=img.height(); 54 | if(vmax<=3*sum/h){ // Heuristics !!! 55 | return 0; 56 | } 57 | int iskew= (int)imax-int(w2)+1; 58 | delete[] sharpness; 59 | return atan((double)iskew/(8*w2)); 60 | 61 | } 62 | 63 | void 64 | Deskewer::radon(const BWImage& img, int sign, unsigned int sharpness[]){ 65 | unsigned short int *p1_, *p2_; // Stored columnwise 66 | 67 | unsigned int w2=next_pow2(img.bytewidth()); 68 | unsigned int w=img.bytewidth(); 69 | unsigned int h=img.height(); 70 | 71 | unsigned int s=h*w2; 72 | p1_=new unsigned short int[s]; 73 | p2_=new unsigned short int[s]; 74 | // Fill in the first table 75 | memset(p1_, 0, sizeof(unsigned short int)*s); 76 | unsigned int ir, ic; 77 | unsigned char const *bitcount=BitUtil::bitcount(); 78 | for(ir=0; ir0){ 82 | p1_[h*ic+ir]=bitcount[scl[w-1-ic]]; 83 | 84 | }else{ 85 | p1_[h*ic+ir]=bitcount[scl[ic]]; 86 | } 87 | } 88 | } 89 | 90 | 91 | // Iterate 92 | unsigned short int *x1=p1_; 93 | unsigned short int *x2=p2_; 94 | unsigned int step=1; 95 | for(;;){ 96 | unsigned int i; 97 | for(i=0; i=w2) break; 127 | } 128 | // Now, compute the sum of squared finite differences: 129 | for(ic=0; ic 23 | 24 | namespace pagetools{ 25 | 26 | class Deskewer{ 27 | public: 28 | static unsigned int next_pow2(unsigned int n); 29 | 30 | static double findSkew(const BWImage& img); 31 | static void radon(const BWImage& img, int sign, unsigned int sharpness[]); // sign = +-1 32 | 33 | }; 34 | 35 | }//namespace pagetools 36 | 37 | #endif//__CF_DESKEWER_H__ 38 | -------------------------------------------------------------------------------- /src/render.c: -------------------------------------------------------------------------------- 1 | // GIMP deskew plug-in 2 | // 3 | // Copyright (C) 2007 Karl Chen 4 | 5 | // This program is free software; you can redistribute it and/or modify it 6 | // under the terms of the GNU General Public License as published by the Free 7 | // Software Foundation; either version 2 of the License, or (at your option) 8 | // any later version. 9 | 10 | // This program is distributed in the hope that it will be useful, but WITHOUT 11 | // ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 12 | // FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for 13 | // more details. 14 | 15 | // You should have received a copy of the GNU General Public License along 16 | // with this program; if not, write to the Free Software Foundation, Inc., 51 17 | // Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. 18 | 19 | #include "config.h" 20 | 21 | #include 22 | 23 | #include 24 | 25 | #include "main.h" 26 | #include "render.h" 27 | 28 | #include "plugin-intl.h" 29 | 30 | #define DEBUG 1 31 | #include "deskew.h" 32 | 33 | /* Public functions */ 34 | 35 | const double deskew_threshold = 0.01/57.295; 36 | 37 | void 38 | render (gint32 image_ID, 39 | GimpDrawable *drawable, 40 | PlugInVals *vals, 41 | PlugInImageVals *image_vals, 42 | PlugInDrawableVals *drawable_vals) 43 | { 44 | double angle = gimp_find_skew(drawable); // in radians 45 | 46 | DEBUGPRINT("deskew: angle=%.2f\n", 47 | 57.295779513082320876798154814105*angle); 48 | 49 | if (fabs(angle) < deskew_threshold) { 50 | // nothing to do; already straightened. 51 | return; 52 | } 53 | gimp_context_push (); 54 | gimp_context_set_interpolation (GIMP_INTERPOLATION_CUBIC); 55 | gimp_context_set_transform_resize (GIMP_TRANSFORM_RESIZE_ADJUST); 56 | 57 | drawable->drawable_id = 58 | gimp_item_transform_rotate(drawable->drawable_id, 59 | angle, 60 | TRUE, -1, -1); 61 | gimp_context_pop (); 62 | } 63 | -------------------------------------------------------------------------------- /src/render.h: -------------------------------------------------------------------------------- 1 | #ifndef __RENDER_H__ 2 | #define __RENDER_H__ 3 | 4 | 5 | /* Public functions */ 6 | 7 | void render (gint32 image_ID, 8 | GimpDrawable *drawable, 9 | PlugInVals *vals, 10 | PlugInImageVals *image_vals, 11 | PlugInDrawableVals *drawable_vals); 12 | 13 | 14 | #endif /* __RENDER_H__ */ 15 | -------------------------------------------------------------------------------- /src/util/bitutil.cc: -------------------------------------------------------------------------------- 1 | /* 2 | This file is part of Page Layout Detection Tools. 3 | 4 | This code is free software; you can redistribute it and/or modify 5 | it under the terms of the GNU General Public License as published by 6 | the Free Software Foundation; either version 2 of the License, or 7 | (at your option) any later version. 8 | 9 | This code is distributed in the hope that it will be useful, 10 | but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | GNU General Public License for more details. 13 | 14 | You should have received a copy of the GNU General Public License 15 | along with this code; if not, write to the Free Software 16 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #include 20 | 21 | namespace pagetools{ 22 | 23 | BitUtil *BitUtil::instance_=0; 24 | 25 | const unsigned char* 26 | BitUtil::bitcount(){ 27 | if(!instance_){ 28 | instance_=new BitUtil; 29 | } 30 | return instance_->bitcount_; 31 | } 32 | 33 | const unsigned char* 34 | BitUtil::invbits(){ 35 | if(!instance_){ 36 | instance_=new BitUtil; 37 | } 38 | return instance_->invbits_; 39 | } 40 | 41 | BitUtil::BitUtil(){ 42 | bitcount_=new unsigned char[256]; 43 | invbits_=new unsigned char[256]; 44 | unsigned int i; 45 | for(i=0; i<256; i++){ 46 | unsigned int j=i, cnt=0; 47 | do{ 48 | cnt+=j&1; 49 | }while(j>>=1); 50 | char x=(i<<4)|(i>>4); 51 | x=((x&0xCC)>>2)|((x&0x33)<<2); 52 | x=((x&0xAA)>>1)|((x&0x55)<<1); 53 | bitcount_[i]=cnt; 54 | invbits_[i]=x; 55 | } 56 | } 57 | 58 | } 59 | -------------------------------------------------------------------------------- /src/util/bitutil.h: -------------------------------------------------------------------------------- 1 | #ifndef __BITUTIL_H__ 2 | #define __BITUTIL_H__ 3 | 4 | /* 5 | This file is part of Page Layout Detection Tools. 6 | 7 | This code is free software; you can redistribute it and/or modify 8 | it under the terms of the GNU General Public License as published by 9 | the Free Software Foundation; either version 2 of the License, or 10 | (at your option) any later version. 11 | 12 | This code is distributed in the hope that it will be useful, 13 | but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | GNU General Public License for more details. 16 | 17 | You should have received a copy of the GNU General Public License 18 | along with this code; if not, write to the Free Software 19 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 20 | */ 21 | 22 | namespace pagetools{ 23 | 24 | class BitUtil{ 25 | public: 26 | static const unsigned char *bitcount(); 27 | static const unsigned char *invbits(); 28 | 29 | private: 30 | static BitUtil *instance_; 31 | unsigned char *bitcount_; 32 | unsigned char *invbits_; 33 | BitUtil(); 34 | }; 35 | 36 | }// namespace pagetools 37 | 38 | #endif//__BITUTIL_H__ 39 | -------------------------------------------------------------------------------- /src/util/cntptr.h: -------------------------------------------------------------------------------- 1 | #ifndef __CF_CNTPTR_H__ 2 | #define __CF_CNTPTR_H__ 3 | 4 | /* 5 | This file is part of Page Layout Detection Tools. 6 | 7 | This code is free software; you can redistribute it and/or modify 8 | it under the terms of the GNU General Public License as published by 9 | the Free Software Foundation; either version 2 of the License, or 10 | (at your option) any later version. 11 | 12 | This code is distributed in the hope that it will be useful, 13 | but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | GNU General Public License for more details. 16 | 17 | You should have received a copy of the GNU General Public License 18 | along with this code; if not, write to the Free Software 19 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 20 | */ 21 | 22 | /* Reference counted pointer. Scalar delete is called when the last reference is 23 | unlinked. The stored pointer may be zero. 24 | */ 25 | namespace pagetools{ 26 | 27 | template 28 | class CntPtr{ 29 | public: 30 | // Ctors 31 | CntPtr(); 32 | CntPtr(T *obj); // obj must be created by scalar new or be zero 33 | CntPtr(const CntPtr& rhs); 34 | 35 | // Dtor - made non-virtual on purpose 36 | ~CntPtr(){unlink();} 37 | 38 | // Assignment 39 | CntPtr& operator =(const CntPtr& rhs); 40 | CntPtr& operator =(T *obj); // obj must be created by scalar new or be zero 41 | 42 | // Accessors 43 | T* get()const{return obj_;} // Returns raw pointer - don't delete it 44 | 45 | operator bool()const{return obj_!=0;} 46 | 47 | // Operators 48 | T& operator*()const{return *obj_;} 49 | 50 | T* operator->()const{return obj_;} 51 | 52 | bool operator ==(const CntPtr& rhs){// Equality of pointees 53 | return obj_==rhs.obj_; 54 | } 55 | 56 | private: 57 | void unlink(); 58 | T *obj_; 59 | int *cnt_; 60 | }; 61 | 62 | template 63 | inline 64 | CntPtr:: 65 | CntPtr() 66 | :obj_(0) 67 | ,cnt_(new int(1)) 68 | {} 69 | 70 | template 71 | inline 72 | CntPtr:: 73 | CntPtr(T *obj) 74 | :obj_(obj) 75 | ,cnt_(new int(1)) 76 | {} 77 | 78 | template 79 | inline 80 | CntPtr:: 81 | CntPtr(const CntPtr& rhs) 82 | :obj_(rhs.obj_) 83 | ,cnt_(rhs.cnt_) 84 | { 85 | ++*cnt_; 86 | } 87 | 88 | template 89 | inline void 90 | CntPtr:: 91 | unlink() 92 | 93 | { 94 | if(!(--*cnt_)){ 95 | delete obj_; 96 | delete cnt_; 97 | } 98 | } 99 | 100 | template 101 | inline CntPtr& 102 | CntPtr:: 103 | operator =(const CntPtr& rhs){ 104 | if(obj_==rhs.obj_) { 105 | return *this; // Do nothing if a=a 106 | } 107 | unlink(); 108 | obj_=rhs.obj_; 109 | cnt_=rhs.cnt_; 110 | ++*cnt_; 111 | return *this; 112 | } 113 | 114 | template 115 | inline CntPtr& 116 | CntPtr:: 117 | operator =(T *obj){ 118 | if(obj_==obj) { 119 | return *this; // Do nothing if assigning the pointer to the same object 120 | } 121 | unlink(); 122 | obj_=obj; 123 | cnt_=new int(1); 124 | return *this; 125 | } 126 | 127 | }// namespace pagetools 128 | 129 | #endif//__CF_CNTPTR_H__ 130 | --------------------------------------------------------------------------------