2
1
mirror of https://github.com/qpdf/qpdf.git synced 2024-11-10 23:20:58 +00:00

Spell check

This commit is contained in:
Jay Berkenbilt 2019-01-31 21:40:06 -05:00
parent 1fba24aada
commit fec5bb124c
7 changed files with 118 additions and 19 deletions

View File

@ -40,7 +40,7 @@ RELEASE PREPARATION
* Run a spelling checker over the source code to catch errors in * Run a spelling checker over the source code to catch errors in
variable names, strings, and comments. variable names, strings, and comments.
ispell -p ispell-words **/*.hh **/*.cc manual/* ChangeLog README* ispell -p ispell-words **/*.hh **/*.cc manual/* ChangeLog README* TODO
* If needed, run large file and image comparison tests. Configure * If needed, run large file and image comparison tests. Configure
options: options:

View File

@ -174,8 +174,8 @@ class QPDFPageObjectHelper: public QPDFObjectHelper
// to be inserted into the same or a different QPDF object using // to be inserted into the same or a different QPDF object using
// any of the addPage methods in QPDFPageDocumentHelper or QPDF. // any of the addPage methods in QPDFPageDocumentHelper or QPDF.
// Without calling one of those methods, the page will not be // Without calling one of those methods, the page will not be
// added anywhere. Thew new page object shares all content streams // added anywhere. The new page object shares all content streams
// and indirect objet resources with the original page, so if you // and indirect object resources with the original page, so if you
// are going to modify the contents or other aspects of the page, // are going to modify the contents or other aspects of the page,
// you will need to handling copying of the component parts // you will need to handling copying of the component parts
// separately. // separately.

View File

@ -19,6 +19,7 @@ accessor
aclocal aclocal
AcroForm AcroForm
acroform acroform
acroread
activatePipelineStack activatePipelineStack
ActiveState ActiveState
acyclic acyclic
@ -79,6 +80,7 @@ appearancestate
appendable appendable
appendItem appendItem
appendString appendString
appian
AppImage AppImage
appimage appimage
arandom arandom
@ -100,6 +102,8 @@ argEmpty
argEncrypt argEncrypt
argEncryptionFilePassword argEncryptionFilePassword
argEndEncrypt argEndEncrypt
argEndUnderOverlay
argExternalizeInlineImages
argfile argfile
argFilteredStreamData argFilteredStreamData
argFlattenAnnotations argFlattenAnnotations
@ -107,11 +111,13 @@ argForceVersion
argGenerateAppearances argGenerateAppearances
argHelp argHelp
argIgnoreXrefStreams argIgnoreXrefStreams
argIiMinBytes
argJson argJson
argJsonHelp argJsonHelp
argJsonKey argJsonKey
argJsonObject argJsonObject
argKeepFilesOpen argKeepFilesOpen
argKeepInlineImages
argLinearize argLinearize
argLinearizePass argLinearizePass
argMinVersion argMinVersion
@ -124,10 +130,12 @@ argOiMinArea
argOiMinHeight argOiMinHeight
argOiMinWidth argOiMinWidth
argOptimizeImages argOptimizeImages
argOverlay
argPages argPages
ArgParser ArgParser
argPassword argPassword
argPasswordIsHexKey argPasswordIsHexKey
argPasswordMode
argPositional argPositional
argPreserveUnreferenced argPreserveUnreferenced
argPreserveUnreferencedResources argPreserveUnreferencedResources
@ -147,7 +155,14 @@ argSplitPages
argStaticAesIv argStaticAesIv
argStaticId argStaticId
argStreamData argStreamData
argSuppressPasswordRecovery
argSuppressRecovery argSuppressRecovery
argUnderlay
argUOfrom
argUOpassword
argUOpositional
argUOrepeat
argUOto
argv argv
argVerbose argVerbose
argVersion argVersion
@ -188,7 +203,9 @@ atoi
auth auth
AuthEvent AuthEvent
autobuilder autobuilder
autobuilders
autoconf autoconf
autofiles
autogen autogen
autoheader autoheader
autolabel autolabel
@ -217,6 +234,7 @@ beb
Berkenbilt Berkenbilt
betweenTokens betweenTokens
bf bf
bi
bidirectionally bidirectionally
binmode binmode
bis bis
@ -233,6 +251,7 @@ bookinfo
bool bool
BORLANDC BORLANDC
bp bp
BPC
bpp bpp
bpr bpr
brdp brdp
@ -268,6 +287,7 @@ cc
ccase ccase
ccc ccc
CCF CCF
CCITT
CCITTFaxDecode CCITTFaxDecode
cd cd
cdc cdc
@ -319,6 +339,7 @@ clearPipelineStack
clearsign clearsign
cleartext cleartext
ClearTextMetadata ClearTextMetadata
CLI
ClosedFileInputSource ClosedFileInputSource
CloseHandle CloseHandle
closeObject closeObject
@ -347,7 +368,9 @@ config
conftest conftest
const const
ContentNormalizer ContentNormalizer
ContentProvider
contrib contrib
convertIIDict
CopiedStreamDataProvider CopiedStreamDataProvider
copyEncryptionParameters copyEncryptionParameters
copyForeign copyForeign
@ -384,8 +407,10 @@ ctest
ctx ctx
ctype ctype
CVE CVE
cx
cxx cxx
CXXFLAGS CXXFLAGS
cy
cygwin cygwin
da da
daae daae
@ -497,6 +522,7 @@ dwVolumeSerialNumber
dx dx
dy dy
ea ea
eacute
eadb eadb
earlychange earlychange
EarlyChange EarlyChange
@ -512,7 +538,7 @@ eeee
ef ef
EFF EFF
efgh efgh
EI ei
ejb ejb
elif elif
elt elt
@ -521,6 +547,7 @@ embeddedFiles
emc emc
emptyPDF emptyPDF
en en
encodable
encodeDataIncrementally encodeDataIncrementally
encodeFile encodeFile
encodeRow encodeRow
@ -568,6 +595,9 @@ exp
expectInlineImage expectInlineImage
ExtensionLevel ExtensionLevel
extern extern
externalize
externalized
externalizeInlineImages
fb fb
fBqpdf fBqpdf
fc fc
@ -575,6 +605,7 @@ fcc
fclose fclose
fcntl fcntl
fd fd
fdict
feebbd feebbd
ferror ferror
ff ff
@ -602,6 +633,7 @@ filterCompressedObjects
filterPageContents filterPageContents
findAndSkipNextEOL findAndSkipNextEOL
findAttachmentStreams findAttachmentStreams
findEI
findEndstream findEndstream
findFirst findFirst
findHeader findHeader
@ -626,6 +658,7 @@ flattenAnnotationsForPage
flattenPagesTree flattenPagesTree
flattenScalarReferences flattenScalarReferences
Florian Florian
fmatrix
FMT FMT
fn fn
fname fname
@ -690,7 +723,9 @@ getArrayItem
getArrayNItems getArrayNItems
getAsArray getAsArray
getAsMap getAsMap
getAsMatrix
getAsVector getAsVector
getAttribute
getBits getBits
getBitsSigned getBitsSigned
getBoolValue getBoolValue
@ -699,6 +734,8 @@ getChoices
getCompressibleObjects getCompressibleObjects
getCompressibleObjGens getCompressibleObjGens
getCount getCount
getCropBox
getDA
getDataChecksum getDataChecksum
getDefaultAppearance getDefaultAppearance
getDefaultValue getDefaultValue
@ -728,6 +765,7 @@ getFlags
getFontFromResource getFontFromResource
getFontName getFontName
getFormFields getFormFields
getFormXObjectForPage
getFullyQualifiedName getFullyQualifiedName
getGen getGen
getGeneration getGeneration
@ -757,7 +795,9 @@ getLinearizationOffset
getLinearizedParts getLinearizedParts
getMappingName getMappingName
getMatch getMatch
getMatrixForTransformations
getMax getMax
getMediaBox
getMessageDetail getMessageDetail
getMin getMin
getName getName
@ -818,6 +858,7 @@ getTitle
getToken getToken
getTopLevelOutlines getTopLevelOutlines
getTrailer getTrailer
getTrimBox
getTrimmedTrailer getTrimmedTrailer
getTrimmedUserPassword getTrimmedUserPassword
getTrimmedUserPassword's getTrimmedUserPassword's
@ -827,6 +868,8 @@ getTypeName
getU getU
getUE getUE
getUncompressedObject getUncompressedObject
getUniqueId
getUniqueResourceName
getUserPassword getUserPassword
getUTF getUTF
getV getV
@ -922,6 +965,8 @@ iff
ifndef ifndef
ifstream ifstream
ignorable ignorable
IIm
iit
ijg ijg
Im Im
ImageC ImageC
@ -953,6 +998,7 @@ initOptionTable
inline inline
InlineImage InlineImage
inlineimage inlineimage
InlineImageTracker
ino ino
inode inode
inpdf inpdf
@ -1179,6 +1225,7 @@ MixColumn
mk mk
mkinstalldirs mkinstalldirs
mklink mklink
ModOther
monoseq monoseq
mr mr
MSC MSC
@ -1199,6 +1246,7 @@ nannots
nbackrefs nbackrefs
nbits nbits
nbsp nbsp
nBT
nbytes nbytes
nch nch
ndash ndash
@ -1212,6 +1260,7 @@ nET
newArray newArray
newBool newBool
NewDict NewDict
newdict
newDictionary newDictionary
newFromMatrix newFromMatrix
newFromRectangle newFromRectangle
@ -1259,6 +1308,7 @@ npos
nproc nproc
nq nq
nQ nQ
nr
nrounds nrounds
nshared nshared
nspaces nspaces
@ -1288,6 +1338,7 @@ ObjectHolder
objectStreamsChoices objectStreamsChoices
objectWarning objectWarning
ObjGen ObjGen
objgen
ObjGens ObjGens
objGenToIndirect objGenToIndirect
objid objid
@ -1300,6 +1351,7 @@ ObjUser
objusers objusers
oc oc
odh odh
odict
oe oe
OffsetInputSource OffsetInputSource
og og
@ -1313,6 +1365,7 @@ olist
omap omap
ooh ooh
op op
opages
OpenAction OpenAction
openObject openObject
opensource opensource
@ -1323,6 +1376,7 @@ org
orig orig
orred orred
os os
OSS
ostream ostream
ostringstream ostringstream
ot ot
@ -1346,12 +1400,14 @@ pacman
padLen padLen
Paeth Paeth
PaethPredictor PaethPredictor
pagefile
PageLabel PageLabel
PageLabels PageLabels
pagelabels pagelabels
pagemode pagemode
PageMode PageMode
pageno pageno
pagenos
pageobj pageobj
pagepos pagepos
pageposfrom pageposfrom
@ -1369,6 +1425,7 @@ parsePageContents
parsePagesOptions parsePagesOptions
ParserCallbacks ParserCallbacks
parseRotationParameter parseRotationParameter
parseUnderOverlayOptions
parseVersion parseVersion
partialname partialname
partLen partLen
@ -1385,6 +1442,8 @@ pcre
pdf pdf
PDFâ PDFâ
PDFContext PDFContext
pdfdoc
PDFDoc
PDFDocEncoding PDFDocEncoding
pdfDumpInfoDict pdfDumpInfoDict
PDFs PDFs
@ -1409,9 +1468,11 @@ Pkey
pkg pkg
PKI PKI
pl pl
placeFormXObject
plaintext plaintext
plb plb
pldh pldh
pm
png png
PNGFilter PNGFilter
pngify pngify
@ -1419,10 +1480,12 @@ PointerHolder
PointerHolder's PointerHolder's
popPipelineStack popPipelineStack
poppler poppler
popup
pornin pornin
pos pos
POSIX POSIX
PP PP
PPA
pr pr
pragma pragma
pre pre
@ -1454,9 +1517,11 @@ prov
provideRandomData provideRandomData
provideStreamData provideStreamData
proxied proxied
ps
PSâ PSâ
pseudorandom pseudorandom
pt pt
ptemp
pthread pthread
ptr ptr
pushDiscardFilter pushDiscardFilter
@ -1518,8 +1583,10 @@ QPDFSystemError
QPDFTokenizer QPDFTokenizer
QPDFTYPES QPDFTYPES
QPDFVersion QPDFVersion
QPDFWordTokenFinder
QPDFWriter QPDFWriter
QPDFXRefEntry QPDFXRefEntry
qpf
qqqcqqq qqqcqqq
qstream qstream
QStream QStream
@ -1561,6 +1628,7 @@ readObject
readObjectAtOffset readObjectAtOffset
readObjectInternal readObjectInternal
readToken readToken
realmain
reattached reattached
recompress recompress
recompressed recompressed
@ -1645,9 +1713,11 @@ sAlT
saphir saphir
sarray sarray
SASLprep SASLprep
savable
scanline scanline
scanlines scanlines
sch sch
sdk
sdp sdp
se se
SecureRandomDataProvider SecureRandomDataProvider
@ -1677,6 +1747,7 @@ setFile
setFilename setFilename
setFromVector setFromVector
setIgnoreXRefStreams setIgnoreXRefStreams
setImmediateCopyFrom
setItem setItem
setIV setIV
setjmp setjmp
@ -1724,6 +1795,7 @@ sev
sf sf
sha sha
shallowCopy shallowCopy
shallowCopyPage
showLinearizationData showLinearizationData
showXRefTable showXRefTable
sizeof sizeof
@ -1743,6 +1815,9 @@ srandom
src src
srdp srdp
sstream sstream
stampfile
stamppdf
StandardEncoding
startoffset startoffset
startxref startxref
stat stat
@ -1830,11 +1905,14 @@ TfFinder
tfh tfh
tgen tgen
th th
thax
thomas thomas
tiffcmp tiffcmp
TIFFPredictor TIFFPredictor
Tj Tj
TM TL
Tm
tmatrix
tmp tmp
tnum tnum
Tobias Tobias
@ -1851,12 +1929,15 @@ tokenizer
tokenizing tokenizing
tokenTypeName tokenTypeName
toolchain toolchain
Toolchains toolchains
toupper toupper
toUTF toUTF
tp tp
transcode transcode
transcoders
transcodes
transcoding transcoding
transformRectangle
traverseField traverseField
travis travis
TrimBox TrimBox
@ -1869,6 +1950,7 @@ Tval
tx tx
txt txt
ty ty
typename
typeWarning typeWarning
ubuntu ubuntu
uc uc
@ -1886,7 +1968,11 @@ ULONGLONG
uncompresesd uncompresesd
uncompress uncompress
uncompressing uncompressing
unconflicting
undef undef
underlaid
underlaying
UnderOverlay
understandDecodeParams understandDecodeParams
unencrypted unencrypted
unfilterable unfilterable
@ -1906,6 +1992,8 @@ unreadCh
unreferenced unreferenced
unresolvable unresolvable
unretrieved unretrieved
uo
upages
upass upass
updateAllPagesCache updateAllPagesCache
updateMap updateMap
@ -1919,6 +2007,7 @@ ury
usageExit usageExit
UseAes UseAes
UseOutlines UseOutlines
UserUnit
useStaticIV useStaticIV
useZeroIV useZeroIV
USLetter USLetter
@ -1926,6 +2015,7 @@ usr
utf utf
Util Util
utils utils
uuid
uval uval
val val
valgrind valgrind
@ -1950,7 +2040,9 @@ vp
vvv vvv
warnIfPossible warnIfPossible
wb wb
wchar
Wconversion Wconversion
wcslen
Weimer Weimer
werror werror
WFLAGS WFLAGS
@ -1960,6 +2052,8 @@ winansi
WinAnsiEncoding WinAnsiEncoding
wincrypt wincrypt
WindowsCryptProvider WindowsCryptProvider
wmain
wmatrix
Wold Wold
wrapInArray wrapInArray
writeAppearance writeAppearance
@ -1995,6 +2089,7 @@ xA
xa xa
xABUL xABUL
xb xb
xbd
xbebfbc xbebfbc
xbf xbf
xc xc
@ -2006,6 +2101,7 @@ xDC
xe xe
xeaa xeaa
xee xee
xef
xefcdab xefcdab
xF xF
xf xf
@ -2040,18 +2136,21 @@ xrefFirst
XRefStm XRefStm
xrefStream xrefStream
xrefTable xrefTable
xscale
xsl xsl
XSLTPROC XSLTPROC
XXX XXX
xy xy
yn yn
yp yp
yscale
yuiop yuiop
yyyymmdd yyyymmdd
z's z's
zalloc zalloc
zarko zarko
Zarko's Zarko's
zcaron
zdata zdata
Zeroize Zeroize
zeroizing zeroizing

View File

@ -553,7 +553,7 @@ QPDFPageObjectHelper::shallowCopyPage()
{ {
throw std::runtime_error( throw std::runtime_error(
"QPDFPageObjectHelper::shallowCopyPage" "QPDFPageObjectHelper::shallowCopyPage"
" called with a direct objet"); " called with a direct object");
} }
QPDFObjectHandle new_page = this->oh.shallowCopy(); QPDFObjectHandle new_page = this->oh.shallowCopy();
return QPDFPageObjectHelper(qpdf->makeIndirectObject(new_page)); return QPDFPageObjectHelper(qpdf->makeIndirectObject(new_page));
@ -623,7 +623,7 @@ QPDFPageObjectHelper::getFormXObjectForPage(bool handle_transformations)
{ {
throw std::runtime_error( throw std::runtime_error(
"QPDFPageObjectHelper::getFormXObjectForPage" "QPDFPageObjectHelper::getFormXObjectForPage"
" called with a direct objet"); " called with a direct object");
} }
QPDFObjectHandle result = QPDFObjectHandle::newStream(qpdf); QPDFObjectHandle result = QPDFObjectHandle::newStream(qpdf);
QPDFObjectHandle newdict = result.getDict(); QPDFObjectHandle newdict = result.getDict();
@ -690,7 +690,7 @@ QPDFPageObjectHelper::placeFormXObject(
if (invert_transformations) if (invert_transformations)
{ {
// tmatrix inverts scaling and rotation of the destination // tmatrix inverts scaling and rotation of the destination
// page. Applying this matrix allows the overlayed form // page. Applying this matrix allows the overlaid form
// XObject's to be absolute rather than relative to properties // XObject's to be absolute rather than relative to properties
// of the destination page. tmatrix is part of the computed // of the destination page. tmatrix is part of the computed
// transformation matrix. // transformation matrix.
@ -713,7 +713,7 @@ QPDFPageObjectHelper::placeFormXObject(
// to adjust this for scale and position. // to adjust this for scale and position.
// Step 1: figure out what scale factor we need to make the form // Step 1: figure out what scale factor we need to make the form
// XObject's bnounding box fit within the destination rectangle. // XObject's bounding box fit within the destination rectangle.
// Transform bounding box // Transform bounding box
QPDFObjectHandle::Rectangle bbox = bbox_obj.getArrayAsRectangle(); QPDFObjectHandle::Rectangle bbox = bbox_obj.getArrayAsRectangle();

View File

@ -266,7 +266,7 @@ make
prevent you from accidentally forgetting to regenerate prevent you from accidentally forgetting to regenerate
automatic files after modifying their sources. If your automatic files after modifying their sources. If your
packaging environment automatically refreshes automatic files, packaging environment automatically refreshes automatic files,
it can cause this check to fail. Supress qpdf's checks by it can cause this check to fail. Suppress qpdf's checks by
passing <option>--disable-check-autofiles</option> to passing <option>--disable-check-autofiles</option> to
<command>/.configure</command>. This is safe since qpdf's <command>/.configure</command>. This is safe since qpdf's
<command>autogen.sh</command> just runs autotools in the normal <command>autogen.sh</command> just runs autotools in the normal
@ -1259,7 +1259,7 @@ outfile.pdf</option>
output. The <option>--overlay</option> and output. The <option>--overlay</option> and
<option>--underlay</option> options work the same way, except <option>--underlay</option> options work the same way, except
underlay pages are drawn underneath the page to which they are underlay pages are drawn underneath the page to which they are
applied, possibly obscured by the origial page, and overlay files applied, possibly obscured by the original page, and overlay files
are drawn on top of the page to which they are applied, possibly are drawn on top of the page to which they are applied, possibly
obscuring the page. You can combine overlay and underlay. obscuring the page. You can combine overlay and underlay.
</para> </para>
@ -4331,7 +4331,7 @@ print "\n";
correctly receive them. In the past, they would have correctly receive them. In the past, they would have
either been encoded as Windows code page 1252 (also known either been encoded as Windows code page 1252 (also known
as &ldquo;Windows ANSI&rdquo; or as something as &ldquo;Windows ANSI&rdquo; or as something
unintelligble. In almost all cases, qpdf is able to unintelligible. In almost all cases, qpdf is able to
properly interpret Unicode arguments now, whereas in the properly interpret Unicode arguments now, whereas in the
past, it would almost never interpret them properly. The past, it would almost never interpret them properly. The
result is that non-ASCII passwords given to the qpdf CLI result is that non-ASCII passwords given to the qpdf CLI
@ -4425,7 +4425,7 @@ print "\n";
encryption options <option>--assemble</option>, encryption options <option>--assemble</option>,
<option>--annotate</option>, <option>--form</option>, and <option>--annotate</option>, <option>--form</option>, and
<option>--modify-other</option> allow more fine-grained <option>--modify-other</option> allow more fine-grained
granluarity in configuring options. Before, the granularity in configuring options. Before, the
<option>--modify</option> option only configured certain <option>--modify</option> option only configured certain
predefined groups of permissions. predefined groups of permissions.
</para> </para>
@ -4573,7 +4573,7 @@ print "\n";
Add method Add method
<function>QPDFPageObjectHelper::getAttribute</function> for <function>QPDFPageObjectHelper::getAttribute</function> for
retrieving an attribute from the page dictionary taking retrieving an attribute from the page dictionary taking
inheritence into consideration, and optionally making a copy inheritance into consideration, and optionally making a copy
if your intention is to modify the attribute. if your intention is to modify the attribute.
</para> </para>
</listitem> </listitem>

View File

@ -1194,7 +1194,7 @@ ArgParser::argHelp()
<< "cases, but you can fine-tune with this option.\n" << "cases, but you can fine-tune with this option.\n"
<< "\n" << "\n"
<< " bytes: use the password literally as supplied\n" << " bytes: use the password literally as supplied\n"
<< " hex-bytes: interpret the password as ahex-encoded byte string\n" << " hex-bytes: interpret the password as a hex-encoded byte string\n"
<< " unicode: interpret the password as a UTF-8 encoded string\n" << " unicode: interpret the password as a UTF-8 encoded string\n"
<< " auto: attempt to infer the encoding and adjust as needed\n" << " auto: attempt to infer the encoding and adjust as needed\n"
<< "\n" << "\n"
@ -1258,7 +1258,7 @@ ArgParser::argHelp()
<< "\n" << "\n"
<< "These options allow pages from another file to be overlaid or underlaid\n" << "These options allow pages from another file to be overlaid or underlaid\n"
<< "on the primary output. Overlaid pages are drawn on top of the destination\n" << "on the primary output. Overlaid pages are drawn on top of the destination\n"
<< "page and may obsecure the page. Underlaid pages are drawn below the\n" << "page and may obscure the page. Underlaid pages are drawn below the\n"
<< "destination page.\n" << "destination page.\n"
<< "\n" << "\n"
<< "{--overlay | --underlay } file\n" << "{--overlay | --underlay } file\n"

View File

@ -1985,9 +1985,9 @@ void runtest(int n, char const* filename1, char const* arg2)
// red pages are from pdf, blue pages are from pdf2 // red pages are from pdf, blue pages are from pdf2
// red pages always have stated rotation absolutely // red pages always have stated rotation absolutely
// 56: blue pages are overlayed exactly on top of red pages // 56: blue pages are overlaid exactly on top of red pages
// 57: blue pages have stated rotation relative to red pages // 57: blue pages have stated rotation relative to red pages
// 58: blue pages have no rotation (absolutely upgright) // 58: blue pages have no rotation (absolutely upright)
// 59: blue pages have stated rotation absolutely // 59: blue pages have stated rotation absolutely
bool handle_from_transformation = ((n == 57) || (n == 59)); bool handle_from_transformation = ((n == 57) || (n == 59));
bool invert_to_transformation = ((n == 58) || (n == 59)); bool invert_to_transformation = ((n == 58) || (n == 59));