-
Add comments to force line breaks, parenthesize function arguments that are contatenated strings, etc. -- these kinds of changes improve clang-format's results and also cause emacs cc-mode to match clang-format. After this type of change, most of the time, when clang-format and emacs disagree, clang-format is better.
-
Run this: for i in **/*.cc **/*.c **/*.h **/*.hh; do clang-format < $i >| $i.new && mv $i.new $i done
-
The executables that libtool built invoked the underlying binary with an "lt-" prefix. The code contained numerous workarounds for testing, which can now be removed.
-
With cmake, we are customizing the path for each test suite so we can ensure we get the right qpdf without having to use an environment variable.
-
Also fix typo in pdf-attach-file example.
-
Convert loop to use range-based for statement. Remove unnecessary variables.
-
Convert loop to use range-based for statement. Remove unnecessary variables.
-
Convert loops to use range-based for statements. Simplify the extract_bookmarks function.
-
This comment expands all tabs using an 8-character tab-width. You should ignore this commit when using git blame or use git blame -w. In the early days, I used to use tabs where possible for indentation, since emacs did this automatically. In recent years, I have switched to only using spaces, which means qpdf source code has been a mixture of spaces and tabs. I have avoided cleaning this up because of not wanting gratuitous whitespaces change to cloud the output of git blame, but I changed my mind after discussing with users who view qpdf source code in editors/IDEs that have other tab widths by default and in light of the fact that I am planning to start applying automatic code formatting soon.
-
Change "-" to "--" for named parameters. Remove spaces inside "[ option ]" for optional parameters. Fix "pdf-mod-info --dump file" to match usage message.
-
None of these are in the public API.
-
Let argv be a null-terminated array. There is already code that assumes this, and it makes it easier to construct the arguments.
-
Use QPDFObjectHandle::isNameAndEquals, isDictionaryOfType and isStreamOfType.
-
The /Subtype entry that specifies the mime type of an embedded file is inside the embedded file stream dictionary directly, not it in the parameter dictionary. See Table 45 and 46 in the PDF 1.7 specification: https://www.adobe.com/content/dam/acom/en/devnet/pdf/pdfs/PDF32000_2008.pdf#page=112
-
Use the first of ASCII, PDFDocEncoding, or UTF-16 that is capable of encoding the string.