Spell check

This commit is contained in:
Jay Berkenbilt 2019-01-04 20:10:34 -05:00
parent ee2aad4381
commit 2e342ee5bb
8 changed files with 295 additions and 17 deletions

View File

@ -84,7 +84,7 @@ class JSON
// element of this object's corresponding array.
// * Otherwise, the value is ignored.
//
// QPDF's JSON output conforms to certain strict compatability
// QPDF's JSON output conforms to certain strict compatibility
// rules as discussed in the manual. The idea is that a JSON
// structure created manually in qpdf.cc doubles as both JSON help
// information and a schema for validating the JSON that qpdf

View File

@ -182,7 +182,7 @@ class QPDFFormFieldObjectHelper: public QPDFObjectHelper
void setV(std::string const& utf8_value, bool need_appearances = true);
// Update the appearance stream for this field. Note that qpdf's
// abilitiy to generate appearance streams is limited. We only
// ability to generate appearance streams is limited. We only
// generate appearance streams for streams of type text or choice.
// The appearance uses the default parameters provided in the
// file, and it only supports ASCII characters. Quadding is

View File

@ -592,8 +592,8 @@ class QPDFObjectHandle
QPDF_DLL
void mergeResources(QPDFObjectHandle other);
// Get all resource names from a resourcey dictionary. If this
// object is a dctionary, this method returns a set of all the
// Get all resource names from a resource dictionary. If this
// object is a dictionary, this method returns a set of all the
// keys in all top-level subdictionaries. For resources
// dictionaries, this is the collection of names that may be
// referenced in the content stream.

View File

@ -5,9 +5,11 @@ abacc
abc
ABCD
abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnom
abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnom
abcde
abcdefABCDEF
abcdefghbcdefghicdefghijdefghijkefghijklfghijklmg
abcdefghbcdefghicdefghijdefghijkefghijklfghijklmg
abcdefghijklmnopqrstuvwxyz
ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghi
ABI
@ -24,7 +26,11 @@ activatePipelineStack
ActiveState
acyclic
adbe
addArrayElement
addChoicesToCompletions
addContentTokenFilter
addDictionaryMember
addOptionsToCompletions
addPage
addPageAt
addPageContents
@ -57,15 +63,19 @@ allowModifyOther
allowPoundAnywhereInName
allowPrintHighRes
allowPrintLowRes
alternativename
annot
annotationflags
annots
antivirus
anyBadTokens
aobjid
aoh
ap
apexcovantage
api
APIs
appearancestate
appendable
appendItem
appendString
@ -74,11 +84,78 @@ appimage
arandom
arg
argc
argCheck
argCheckLinearization
argCoalesceContents
argCollate
argCompletionBash
argCompletionZsh
argCompressStreams
argCopyEncryption
argCopyright
argDecodeLevel
argDecrypt
argDeterministicId
argEmpty
argEncrypt
argEncryptionFilePassword
argEndEncrypt
argfile
argFilteredStreamData
argFlattenAnnotations
argForceVersion
argGenerateAppearances
argHelp
argIgnoreXrefStreams
argJson
argJsonHelp
argJsonKey
argJsonObject
argKeepFilesOpen
argLinearize
argLinearizePass
argMinVersion
argNewlineBeforeEndstream
argNoOriginalObjectIds
argNormalizeContent
argNoWarn
argObjectStreams
argOiMinArea
argOiMinHeight
argOiMinWidth
argOptimizeImages
argPages
ArgParser
argPassword
argPasswordIsHexKey
argPositional
argPreserveUnreferenced
argPreserveUnreferencedResources
argProgress
argQdf
argRawStreamData
argRotate
args
argShowEncryption
argShowEncryptionKey
argShowLinearization
argShowNpages
argShowObject
argShowPages
argShowXref
argSplitPages
argStaticAesIv
argStaticId
argStreamData
argSuppressRecovery
argv
argVerbose
argVersion
argWithImages
arko
arko's
Arora
arr
arrayOrStreamToStreamArray
ArtBox
ascii
@ -114,6 +191,7 @@ autoconf
autogen
autoheader
autolabel
autoload
automake
autotools
ba
@ -128,7 +206,11 @@ baeca
BaseFont
basename
BaseVersion
bashcompinit
bashdefault
bb
BBox
bbox
bc
beb
Berkenbilt
@ -138,10 +220,12 @@ bidirectionally
binmode
bis
BitsPerComponent
bitspercomponent
bitstream
BitStream
BitWriter
BleedBox
bmc
BogusRandomDataProvider
boldseq
bookinfo
@ -153,6 +237,7 @@ bpr
brdp
bs
BT
btn
buf
BufferInputSource
buflen
@ -162,6 +247,7 @@ bufsize
BUGREPORT
buildrules
bw
bx
bytesNeeded
ca
calc
@ -198,6 +284,7 @@ cgi
ch
ChangeLog
Checkboxes
checkCompletion
checkDataChecksum
checkError
checkFileChecksum
@ -207,6 +294,9 @@ checkHSharedObject
checkLinearization
checkLinearizationInternal
checkPageContents
checkSchema
checkSchemaInternal
checkSeen
checkUnread
CHGeneric
cho
@ -225,6 +315,7 @@ cl
classname
clearPipelineStack
cleartext
ClearTextMetadata
ClosedFileInputSource
CloseHandle
closeObject
@ -242,6 +333,7 @@ colorspace
ColorToGray
com
commandline
COMP
compareVersions
compatbility
CompressConfig
@ -307,8 +399,11 @@ debian
dec
declspec
decodeAverage
decodelevel
decodeLevelChoices
decodePaeth
DecodeParms
decodeparms
decodeRow
decodeStreams
decodeSub
@ -320,6 +415,7 @@ decrypting
decryptStream
decryptString
def
defaultvalue
deflateEnd
deflateInit
defq
@ -331,6 +427,9 @@ dereference
dereferenced
dest
DESTDIR
destpage
destpageposfrom
dests
detecet
dev
devel
@ -367,10 +466,15 @@ docdir
DocOpen
DOCTYPE
DocumentHelper
doFinalChecks
DOTLESS
doubleBoxSize
doWriteSetup
Doxygen
dp
dquote
driverless
dropdown
DTD
dtdvalid
dumpHGeneric
@ -384,6 +488,8 @@ dwHighDateTime
dwLowDateTime
DWORD
dwVolumeSerialNumber
dx
dy
ea
eadb
earlychange
@ -393,6 +499,7 @@ EBADF
ebae
ecc
ecedd
ecks
eded
eeb
eeee
@ -405,6 +512,7 @@ elif
elt
EmbeddedFiles
embeddedFiles
emc
emptyPDF
en
encodeDataIncrementally
@ -428,12 +536,14 @@ enqueueObjectsStandard
enqueuePart
enqueues
enqueuing
enspliel
enum
env
envar
eod
eof
eol
ep
epub
eq
ERANGE
@ -443,6 +553,8 @@ errno
erroffset
errptr
esize
esses
eval
exc
exe
exp
@ -467,6 +579,8 @@ fghij
fh
fi
fI
fieldflags
fieldtype
fIinfilename
fileinfo
FileInputSource
@ -476,6 +590,7 @@ filep
Filespec
FILETIME
filetrailer
filterability
filterCompressedObjects
filterPageContents
findAndSkipNextEOL
@ -484,6 +599,8 @@ findEndstream
findFirst
findHeader
findLast
findObject
findObjectAtOrBelow
findPage
findSource
findStartxref
@ -492,9 +609,13 @@ fIoutfilename
firstname
firstterm
fis
fixDanglingReferences
fl
flarp
flate
FlateDecode
flattenAnnotations
flattenAnnotationsForPage
flattenPagesTree
flattenScalarReferences
Florian
@ -502,9 +623,13 @@ FMT
fn
fname
fo
foh
fopen
forcePDFVersion
ForceR
ForceV
foreach
fp
fprintf
fR
fr
@ -519,20 +644,27 @@ ftell
ftelli
ftello
fullinfo
fullname
fullpad
func
fv
fweimer
fwrite
fx
FxConflict
Fxo
Gagic
GajiÄ
gajic
gcc
gcurl
gen
generateAppearance
generateAppearancesIfNeeded
generateHintStream
generateID
generateObjectStreams
generateTextAppearance
genok
getAllObjects
getAllPages
@ -543,6 +675,7 @@ getAnnotationsForField
getAppearanceDictionary
getAppearanceState
getAppearanceStream
getArrayAsMatrix
getArrayAsRectangle
getArrayAsVector
getArrayItem
@ -554,6 +687,7 @@ getBits
getBitsSigned
getBoolValue
getBuffer
getChoices
getCompressibleObjects
getCompressibleObjGens
getCount
@ -562,6 +696,8 @@ getDefaultAppearance
getDefaultValue
getDefaultValueAsString
getDescription
getDest
getDestPage
getDict
getDictAsMap
getEncryptionKey
@ -578,7 +714,9 @@ getFileChecksum
GetFileInformationByHandle
getFilename
getFilePosition
getFinalVersion
getFirstChar
getFlags
getFormFields
getFullyQualifiedName
getGen
@ -593,9 +731,13 @@ getInlineImageValue
getInstance
getIntValue
getItem
getJSON
getKey
getKeyForObject
getKeys
getKids
getLabelForPage
getLabelsForPageRange
getLastChar
GetLastError
getLastOffset
@ -605,7 +747,9 @@ getLinearizationOffset
getLinearizedParts
getMappingName
getMatch
getMax
getMessageDetail
getMin
getName
getNeedAppearances
getNext
@ -628,9 +772,11 @@ getOffset
getOffsetLength
getOperatorValue
getOriginalID
getOutlinesForPage
getOwningQPDF
getP
getPaddedUserPassword
getPageContentForAppearance
getPageContents
getPageImages
getParent
@ -648,13 +794,17 @@ getRawValue
getRealValue
getRect
getRefcount
getResourceNames
getRoot
getSize
getStreamData
getStringValue
getSubtype
GetSystemTime
getTf
getTitle
getToken
getTopLevelOutlines
getTrailer
getTrimmedTrailer
getTrimmedUserPassword
@ -680,12 +830,14 @@ ghostscript
GhostScript
GiB
github
glarp
glerbl
glibc
gm
gmail
GNUC
gnuwin
GoTo
gpg
grayscale
grep
@ -697,15 +849,24 @@ Gynvael
gz
gzip
HAGOOGAMAGOOGLE
handleArgFileArguments
handleBashArguments
handleCode
handleCompletion
handleData
handleEOF
handleHelpArgs
handleObject
handleToken
hasAcroForm
hasacroform
hasDescription
hasIndex
hasKey
hasName
hasObjectDescription
hasOutlines
hasPageLabels
hb
hbp
HCRYPTPROV
@ -720,6 +881,7 @@ HGeneric
hh
HighPart
hijklmnoijklmnopjklmnopqklmnopqrlmnopqrsmnopqrstn
hijklmnoijklmnopjklmnopqklmnopqrlmnopqrsmnopqrstn
hlen
Hoffmann
HOi
@ -755,6 +917,7 @@ ImageC
ImageChecker
ImageInverter
ImageMask
ImageOptimizer
ImageProvider
inbuf
includeIgnorable
@ -767,12 +930,15 @@ infilename
inflateEnd
inflateInit
inflateReset
ing
init
initializeByPage
initializeEncryption
initializePipelineStack
initializeSpecialStreams
initializeVector
initializeWithRandomBytes
initOptionTable
inline
InlineImage
inlineimage
@ -804,6 +970,11 @@ iostream
irdp
isArray
isBool
isCheckbox
ischeckbox
isChecked
isChoice
ischoice
isDataModified
isDelimiter
isDictionary
@ -815,6 +986,7 @@ isInitialized
isInlineImage
isInteger
isLinearized
isMatrix
isName
isNull
isNumber
@ -825,6 +997,9 @@ isOrHasName
isPageObject
isPagesObject
ispell
isPushbutton
isRadioButton
isradiobutton
isReal
isRectangle
isReserved
@ -833,6 +1008,8 @@ isspace
isSpace
isStream
isString
isText
istext
istream
istype
isType
@ -841,21 +1018,31 @@ itemizedlist
iter
ith
iz
jarr
JCS
JDIMENSION
jdouble
jerr
jexp
Jian
jint
jklmnopqrstuvwxyz
jmap
jmp
jmpbuf
JMSG
jnull
jo
jpeg
jpeglib
jpg
JPOOL
jq
JSAMPARRAY
JSAMPLE
JSAMPROW
json
jstr
Jurczyk
keybits
keylen
@ -931,12 +1118,22 @@ LZWDecoder
m'qpdf
MacOS
Macports
makeArray
makeBool
makeDictionary
makeDirect
makeDirectInternal
Makefile
makeIndirectObject
makeInt
makeNull
makeNumber
makePipeline
makeReal
makeString
malloc
manualFinish
mappingname
Mateusz
maxEnd
maxlen
@ -954,6 +1151,7 @@ memcpy
memmove
memset
merchantability
mergeResources
metadata
mgr
MILLE
@ -968,6 +1166,7 @@ mk
mkinstalldirs
mklink
monoseq
mr
MSC
msg
msvc
@ -990,13 +1189,17 @@ nbytes
nch
ndash
NeedAppearances
needappearances
nEMC
nendobj
nendstream
ness
nET
newArray
newBool
NewDict
newDictionary
newFromMatrix
newFromRectangle
newIndirect
newInlineImage
@ -1016,9 +1219,11 @@ nfields
nFileIndexHigh
nFileIndexLow
nfirst
ngrandkids
nitems
nkids
nl
nlines
nmatches
nMatches
NoBackref
@ -1028,22 +1233,32 @@ NOMEMORY
NONINFRINGEMENT
nonprintable
noout
nopt
normalizeName
normalizer
NoRotate
nospace
nouppercase
NoView
npages
npos
nq
nQ
nrounds
nshared
nspaces
nspecs
nstream
nstripes
NTE
ntoh
ntotal
NUL
num
numericValue
numrange
nums
numtree
nval
nw
nwalsh
@ -1055,6 +1270,7 @@ OBJDIR
objdump
ObjectHelper
ObjectHolder
objectStreamsChoices
objectWarning
ObjGen
ObjGens
@ -1062,24 +1278,30 @@ objGenToIndirect
objid
objidok
objok
objspec
ObjStm
objstm
ObjUser
objusers
oc
OE
odh
oe
OffsetInputSource
og
ogs
oi
oiter
okey
ol
olist
omap
ooh
op
OpenAction
openObject
opensource
optionalParameter
OptionEntry
ord
org
orig
@ -1108,10 +1330,15 @@ pacman
padLen
Paeth
PaethPredictor
PageLabel
PageLabels
pagelabels
pagemode
PageMode
pageno
pageobj
pagepos
pageposfrom
PageSpec
para
param
@ -1120,9 +1347,14 @@ parms
parsecontent
parseContentStream
parseInternal
parseNumrange
parseOptions
parsePageContents
parsePagesOptions
ParserCallbacks
parseRotationParameter
parseVersion
partialname
partLen
pathsep
patmv
@ -1150,6 +1382,7 @@ Pfeifle
ph
phe
php
pikepdf
pipeContentStreams
PipelineAccessor
pipePageContents
@ -1161,6 +1394,7 @@ PKI
pl
plaintext
plb
pldh
png
PNGFilter
pngify
@ -1216,6 +1450,7 @@ pushMD
pushOutlinesToPart
pushPipeline
PUTU
pypi
qarray
QArray
qdf
@ -1239,6 +1474,9 @@ QPDFExc
QPDFFake
QPDFFakeName
QPDFFormFieldObjectHelper
QPDFMatrix
QPDFNameTreeObjectHelper
QPDFNumberTreeObjectHelper
QPDFObject
QPDFObjectHandle
QPDFObjectHandle's
@ -1247,8 +1485,11 @@ QPDFObjectHelper
QPDFObjectTypeAccessor
QPDFObjGen
QPDFObjGens
QPDFOutlineDocumentHelper
QPDFOutlineObjectHelper
QPDFPageData
QPDFPageDocumentHelper
QPDFPageLabelDocumentHelper
QPDFPageObjectHelper
qpdfs
QPDFSomethingDocumentHelper
@ -1289,6 +1530,7 @@ rcon
RDONLY
rdp
rdquo
readArgsFromFile
readHGeneric
readHintStream
readHPageOffset
@ -1303,7 +1545,9 @@ readToken
reattached
recompress
recompressed
recompresses
recompressing
recompression
recomputation
recoverStreamLength
rect
@ -1332,9 +1576,12 @@ replaceReserved
replaceStreamData
reportProgress
repos
requiredChoices
requiredParameter
reserveObjects
resetBits
resolveLiteral
resolveNamedDest
resolveObjectsInStream
ResolveRecorder
resync
@ -1360,6 +1607,7 @@ rm
RNRT
rollover
rotatePage
rotatex
RotationSpec
roundoff
rr
@ -1379,6 +1627,8 @@ sarray
SASLprep
scanline
scanlines
sch
sdp
se
SecureRandomDataProvider
sed
@ -1391,6 +1641,7 @@ setArrayFromVector
setArrayItem
setAttemptRecovery
setbase
setCheckBoxValue
setCompressStreams
setContentNormalization
setDataKey
@ -1436,6 +1687,7 @@ setPreserveEncryption
setPreserveUnreferencedObjects
setQDFMode
setR
setRadioButtonValue
setRandomDataProvider
setStaticAesIV
setStaticID
@ -1448,6 +1700,7 @@ setTrailer
setU
setV
setvbuf
sev
sf
sha
shallowCopy
@ -1464,6 +1717,7 @@ sph
sphlib
sprintf
sqlite
squote
srand
srandom
src
@ -1488,11 +1742,13 @@ stdout
stevens
STL
StmF
stopOnError
str
strcasecmp
strchr
strcmp
strcpy
streamDataChoices
StreamDataProvider
strerror
StrF
@ -1507,6 +1763,7 @@ strncmp
stronghorse
strrchr
strstr
strtod
strtoi
strtol
strtoll
@ -1514,10 +1771,12 @@ struct
stylesheet
stylesheets
subclasses
subdictionaries
subdictionary
SubFilter
SubFilters
sublicense
subparsers
Subramanyam
substr
substring
@ -1528,6 +1787,8 @@ suppressions
svg
swapObjects
swversion
sx
sy
Symlink
sys
sysnow
@ -1542,7 +1803,10 @@ Te
TerminateParsing
terminateParsing
TESTSUITE
Tf
tf
tff
TfFinder
tfh
tgen
th
thomas
@ -1557,6 +1821,7 @@ tobj
tobjid
TODO
toffset
tok
TokenFilter
TokenFilters
tokenize
@ -1577,13 +1842,16 @@ tt
ttype
TU
turbo
Tx
Tval
tx
txt
ty
typeWarning
ubuntu
uc
udata
UE
uHHHH
uinow
uint
uiter
@ -1617,6 +1885,7 @@ unresolvable
unretrieved
upass
updateAllPagesCache
updateMap
updateObjectMaps
updateObjectMapsInternal
updatePagesCache
@ -1624,6 +1893,8 @@ urandom
url
urx
ury
usageExit
UseAes
UseOutlines
useStaticIV
useZeroIV
@ -1636,6 +1907,7 @@ uval
val
valgrind
valstr
ValueSetter
var
variablelist
varlistentry
@ -1664,6 +1936,8 @@ WinAnsiEncoding
wincrypt
WindowsCryptProvider
Wold
wrapInArray
writeAppearance
writeBinary
writeBits
writeBitsSigned
@ -1702,6 +1976,7 @@ xc
xcc
xD
xDC
xe
xeaa
xee
xefcdab
@ -1724,9 +1999,10 @@ xmlns
xobj
xobject
XObject
XObject's
XObjects
xor
XP
xp
xpacket
xpdf
XPOST
@ -1742,6 +2018,7 @@ XSLTPROC
XXX
xy
yn
yp
yuiop
yyyymmdd
z's
@ -1753,6 +2030,7 @@ Zeroize
zeroizing
zfree
zlib
zsh
zstream
zzzzz
zzzzzz

View File

@ -356,7 +356,7 @@ QPDFFormFieldObjectHelper::setRadioButtonValue(QPDFObjectHandle name)
// * If this is a radio button field that has a parent that is
// also a radio button field and has no explicit /V, call itself
// on the parent
// * If this is a radio button field with childen, set /V to the
// * If this is a radio button field with children, set /V to the
// given value. Then, for each child, if the child has the
// specified value as one of its keys in the /N subdictionary of
// its /AP (i.e. its normal appearance stream dictionary), set

View File

@ -1658,7 +1658,7 @@ outfile.pdf</option>
<para>
This option is repeatable. If specified, only top-level keys
specified will be included in the json output. If not
specified, all keys wil be shown.
specified, all keys will be shown.
</para>
</listitem>
</varlistentry>

View File

@ -275,7 +275,7 @@ static JSON json_schema(std::set<std::string>* keys = 0)
// ID and an array for pages because we want to index by position.
// The pages in the pages array contain references back to the
// original object, which can be resolved in the objects
// dictionary. When a PDF constract that maps back to an original
// dictionary. When a PDF construct that maps back to an original
// object is represented separately, use "object" as the key that
// references the original object.
@ -462,7 +462,7 @@ static JSON json_schema(std::set<std::string>* keys = 0)
JSON::makeString("whether field is a checkbox"));
fields.addDictionaryMember(
"isradiobutton",
JSON::makeString("whether field is a radiobutton --"
JSON::makeString("whether field is a radio button --"
" buttons in a single group share a parent"));
fields.addDictionaryMember(
"ischoice",
@ -613,9 +613,9 @@ class ArgParser
void argJsonObject(char* parameter);
void argCheck();
void argOptimizeImages();
void argOiMinWidth(char* paramter);
void argOiMinHeight(char* paramter);
void argOiMinArea(char* paramter);
void argOiMinWidth(char* parameter);
void argOiMinHeight(char* parameter);
void argOiMinArea(char* parameter);
void arg40Print(char* parameter);
void arg40Modify(char* parameter);
void arg40Extract(char* parameter);
@ -3574,7 +3574,7 @@ ImageOptimizer::evaluate(std::string const& description)
long long orig_length = image.getDict().getKey("/Length").getIntValue();
if (c.getCount() >= orig_length)
{
QTC::TC("qpdf", "qpdf image optimize no shink");
QTC::TC("qpdf", "qpdf image optimize no shrink");
if (o.verbose)
{
std::cout << whoami << ": " << description

View File

@ -403,5 +403,5 @@ QPDFFormFieldObjectHelper list first too low 0
QPDFFormFieldObjectHelper list last too high 0
QPDF detected dangling ref 0
qpdf image optimize no pipeline 0
qpdf image optimize no shink 0
qpdf image optimize no shrink 0
qpdf image optimize too small 0