Fix various typos

This commit is contained in:
Luz Paz 2025-03-22 13:09:53 -04:00
parent 1b131fa74d
commit 253030327b
17 changed files with 31 additions and 31 deletions

View File

@ -2856,7 +2856,7 @@ typedef struct
uLong crc32_wait; // crc32 we must obtain after decompress all uLong crc32_wait; // crc32 we must obtain after decompress all
uLong rest_read_compressed; // number of byte to be decompressed uLong rest_read_compressed; // number of byte to be decompressed
uLong rest_read_uncompressed;//number of byte to be obtained after decomp uLong rest_read_uncompressed;//number of byte to be obtained after decomp
LUFILE* file; // io structore of the zipfile LUFILE* file; // io structure of the zipfile
uLong compression_method; // compression method (0==store) uLong compression_method; // compression method (0==store)
uLong byte_before_the_zipfile;// byte before the zipfile, (>0 for sfx) uLong byte_before_the_zipfile;// byte before the zipfile, (>0 for sfx)
} file_in_zip_read_info_s; } file_in_zip_read_info_s;
@ -2865,7 +2865,7 @@ typedef struct
// unz_s contain internal information about the zipfile // unz_s contain internal information about the zipfile
typedef struct typedef struct
{ {
LUFILE* file; // io structore of the zipfile LUFILE* file; // io structure of the zipfile
unz_global_info gi; // public global information unz_global_info gi; // public global information
uLong byte_before_the_zipfile;// byte before the zipfile, (>0 for sfx) uLong byte_before_the_zipfile;// byte before the zipfile, (>0 for sfx)
uLong num_file; // number of the current file in the zipfile uLong num_file; // number of the current file in the zipfile
@ -3138,7 +3138,7 @@ int unzGetGlobalInfo (unzFile file,unz_global_info *pglobal_info)
} }
// Translate date/time from Dos format to tm_unz (readable more easilty) // Translate date/time from Dos format to tm_unz (more easily readable)
void unzlocal_DosDateToTmuDate (uLong ulDosDate, tm_unz* ptm) void unzlocal_DosDateToTmuDate (uLong ulDosDate, tm_unz* ptm)
{ {
uLong uDate; uLong uDate;

View File

@ -39,7 +39,7 @@ select = [
'RUF047', # needless else 'RUF047', # needless else
'E302', 'E303', 'E304', 'E305', 'W391', # blank-line standard 'E302', 'E303', 'E304', 'E305', 'W391', # blank-line standard
'E111', 'E112', 'E113', 'E117', # code indentation 'E111', 'E112', 'E113', 'E117', # code indentation
'E114', 'E115', 'E116', 'E261', 'E262', 'E265', # comment formating 'E114', 'E115', 'E116', 'E261', 'E262', 'E265', # comment formatting
'E201', 'E202', 'E211', 'E251', 'E275', # various whitespace 'E201', 'E202', 'E211', 'E251', 'E275', # various whitespace
] ]
unfixable = ['PIE794', 'ISC001'] unfixable = ['PIE794', 'ISC001']

View File

@ -668,7 +668,7 @@
/* /*
* SanDisk * SanDisk
* several devices (c150 for sure) are definately dual-mode and must * several devices (c150 for sure) are definitely dual-mode and must
* have the USB mass storage driver that hooks them unloaded first. * have the USB mass storage driver that hooks them unloaded first.
* They all have problematic dual-mode making the device unload effect * They all have problematic dual-mode making the device unload effect
* uncertain on these devices. * uncertain on these devices.
@ -2537,7 +2537,7 @@
/* /*
* Motorola Xoom (Wingray) variants * Motorola Xoom (Wingray) variants
* *
* These devices seem to use these product IDs simulatenously * These devices seem to use these product IDs simultaneously
* https://code.google.com/p/android-source-browsing/source/browse/init.stingray.usb.rc?repo=device--moto--wingray * https://code.google.com/p/android-source-browsing/source/browse/init.stingray.usb.rc?repo=device--moto--wingray
* *
* 0x70a3 - Factory test - reported as early MTP ID * 0x70a3 - Factory test - reported as early MTP ID
@ -2796,7 +2796,7 @@
// Reported by jaile <jaile@users.sourceforge.net> // Reported by jaile <jaile@users.sourceforge.net>
{ "Asus", 0x0b05, "TF300 Transformer (MTP+ADB)", 0x4c81, { "Asus", 0x0b05, "TF300 Transformer (MTP+ADB)", 0x4c81,
DEVICE_FLAGS_ANDROID_BUGS }, DEVICE_FLAGS_ANDROID_BUGS },
// Repored by Florian Apolloner <f-apolloner@users.sourceforge.net> // Reported by Florian Apolloner <f-apolloner@users.sourceforge.net>
{ "Asus", 0x0b05, "TF700 Transformer (MTP)", 0x4c90, { "Asus", 0x0b05, "TF700 Transformer (MTP)", 0x4c90,
DEVICE_FLAGS_ANDROID_BUGS }, DEVICE_FLAGS_ANDROID_BUGS },
{ "Asus", 0x0b05, "TF700 Transformer (MTP+ADB)", 0x4c91, { "Asus", 0x0b05, "TF700 Transformer (MTP+ADB)", 0x4c91,
@ -3359,7 +3359,7 @@
#if 1 #if 1
/* after some review I commented it back in. There was apparently /* after some review I commented it back in. There was apparently
* only one or two devices misbehaving (having this ID in mass storage mode), * only one or two devices misbehaving (having this ID in mass storage mode),
* but more seem to use it regulary as MTP devices. Marcus 20150401 */ * but more seem to use it regularly as MTP devices. Marcus 20150401 */
/* /*
* This had to be commented out - the same VID+PID is used also for * This had to be commented out - the same VID+PID is used also for
* other modes than MTP, so we need to let mtp-probe do its job on this * other modes than MTP, so we need to let mtp-probe do its job on this
@ -3454,7 +3454,7 @@
#if 1 #if 1
/* after some review I commented it back in. There was apparently /* after some review I commented it back in. There was apparently
* only one or two devices misbehaving (having this ID in mass storage mode), * only one or two devices misbehaving (having this ID in mass storage mode),
* but more seem to use it regulary as MTP devices. Marcus 20150401 */ * but more seem to use it regularly as MTP devices. Marcus 20150401 */
/* /*
* This had to be commented out - the same VID+PID is used also for * This had to be commented out - the same VID+PID is used also for
* other modes than MTP, so we need to let mtp-probe do its job on this * other modes than MTP, so we need to let mtp-probe do its job on this
@ -3951,7 +3951,7 @@
DEVICE_FLAGS_ANDROID_BUGS }, DEVICE_FLAGS_ANDROID_BUGS },
/* In update 4 the order of devices was changed for /* In update 4 the order of devices was changed for
better OS X / Windows suport and another device-id better OS X / Windows support and another device-id
got assigned for the MTP */ got assigned for the MTP */
{ "Jolla", 0x2931, "Sailfish (ID2)", 0x0a05, { "Jolla", 0x2931, "Sailfish (ID2)", 0x0a05,
DEVICE_FLAGS_ANDROID_BUGS }, DEVICE_FLAGS_ANDROID_BUGS },

View File

@ -33,7 +33,7 @@ COALESCE_FACTOR = 20.0
BOTTOM_FACTOR = 2.0 BOTTOM_FACTOR = 2.0
# Where lines overlap, top of one to bottom of next should exceed # Where lines overlap, top of one to bottom of next should exceed
# the line height by this factor for them to be considered diferent. # the line height by this factor for them to be considered different.
HEIGHT_FACTOR = 1.5 HEIGHT_FACTOR = 1.5
# Fraction of text height that two strings' bottoms can differ by # Fraction of text height that two strings' bottoms can differ by
@ -822,7 +822,7 @@ class Page:
# Not within text boundaries # Not within text boundaries
self.texts.remove(text) self.texts.remove(text)
# Find any image occurances if requested # Find any image occurrences if requested
# These can be interspersed with text # These can be interspersed with text
if not self.opts.no_images: if not self.opts.no_images:
for img in page.xpath('descendant::image'): for img in page.xpath('descendant::image'):

View File

@ -289,7 +289,7 @@ class PML_HTMLizer:
return text return text
if code in self.DIV_STATES: if code in self.DIV_STATES:
# Ignore multilple T's on the same line. They do not have a closing # Ignore multiple T's on the same line. They do not have a closing
# code. They get closed at the end of the line. # code. They get closed at the end of the line.
if code == 'T' and self.state['T'][0]: if code == 'T' and self.state['T'][0]:
self.code_value(stream) self.code_value(stream)
@ -582,7 +582,7 @@ class PML_HTMLizer:
text = self.process_code('Sd', line, 'sb') text = self.process_code('Sd', line, 'sb')
elif c in 'xXC': elif c in 'xXC':
empty = False empty = False
# The PML was modified eariler so x and X put the text # The PML was modified earlier so x and X put the text
# inside of ="" so we don't have do special processing # inside of ="" so we don't have do special processing
# for C. # for C.
t = '' t = ''

View File

@ -107,7 +107,7 @@ class AddBrackets:
def __in_body_func(self, line): def __in_body_func(self, line):
''' '''
Select what action to take in body: Select what action to take in body:
1-At the end of the file close the braket if a bracket was opened 1-At the end of the file close the bracket if a bracket was opened
This happens if there is achange This happens if there is achange
2-If an open bracket is found the code inside is ignore 2-If an open bracket is found the code inside is ignore
(written without modifications) (written without modifications)

View File

@ -109,7 +109,7 @@ class ConvertToTags:
Process lines for open tags that have attributes. Process lines for open tags that have attributes.
The important info is between [17:-1]. Take this info and split it The important info is between [17:-1]. Take this info and split it
with the delimiter '<'. The first token in this group is the element with the delimiter '<'. The first token in this group is the element
name. The rest are attributes, separated fromt their values by '>'. So name. The rest are attributes, separated from their values by '>'. So
read each token one at a time, and split them by '>'. read each token one at a time, and split them by '>'.
''' '''
# mi<tg<open-att__<footnote<num> # mi<tg<open-att__<footnote<num>

View File

@ -187,7 +187,7 @@ class FieldStrings:
my_string --the string to parse. my_string --the string to parse.
type -- the type of string. type -- the type of string.
Returns: Returns:
Returns a string for a field instrution attribute. Returns a string for a field instruction attribute.
Logic: Logic:
This handles all "large" fields, which means everything except This handles all "large" fields, which means everything except
toc entries, index entries, and bookmarks toc entries, index entries, and bookmarks

View File

@ -5,7 +5,7 @@ class ParseOptions:
''' '''
Requires: Requires:
system_string --The string from the command line system_string --The string from the command line
options_dict -- a dictionary with the key equal to the opition, and options_dict -- a dictionary with the key equal to the option, and
a list describing that option. (See below) a list describing that option. (See below)
Returns: Returns:
A tuple. The first item in the tuple is a dictionary containing A tuple. The first item in the tuple is a dictionary containing
@ -223,7 +223,7 @@ class ParseOptions:
Returns: Returns:
nothing nothing
Logic: Logic:
Check each value in the newly creatd options list to see if it Check each value in the newly created options list to see if it
matches what the user describes as a legal option. matches what the user describes as a legal option.
''' '''
illegal_options = [] illegal_options = []

View File

@ -31,7 +31,7 @@ Before any para_def token is found. This means all the text in the preamble.
Look for the token 'cw<pf<par-def___'. This will changet the state to collect_tokens. Look for the token 'cw<pf<par-def___'. This will changet the state to collect_tokens.
2. collect_tokens. 2. collect_tokens.
Found a paragraph_def. Need to get all tokens. Found a paragraph_def. Need to get all tokens.
Change with start of a paragrph ('mi<mk<para-start'). State then becomes Change with start of a paragraph ('mi<mk<para-start'). State then becomes
in_paragraphs in_paragraphs
If another paragraph definition is found, the state does not change. If another paragraph definition is found, the state does not change.
But the dictionary is reset. But the dictionary is reset.

View File

@ -206,7 +206,7 @@ class Sections:
nothing nothing
Logic: Logic:
I have found a section definition. Check if the line is the end of I have found a section definition. Check if the line is the end of
the defnition (a paragraph definition), or if it contains info that the definition (a paragraph definition), or if it contains info that
should be added to the values dictionary. If neither of these should be added to the values dictionary. If neither of these
cases are true, output the line to a file. cases are true, output the line to a file.
''' '''

View File

@ -256,7 +256,7 @@ class Table:
control word with another method. control word with another method.
Check for states that will end this state. Check for states that will end this state.
While in the row definition, certain tokens can end a row or end a table. While in the row definition, certain tokens can end a row or end a table.
If a paragrah definition (pard-start) is found, and the you are already in If a paragraph definition (pard-start) is found, and you are already in
a table, start of a row. a table, start of a row.
''' '''
if self.__token_info == 'cw<tb<row_______': if self.__token_info == 'cw<tb<row_______':

View File

@ -67,7 +67,7 @@ This editor is available in two ways:
calibre-debug -c "from calibre.gui2.dialogs.ff_doc_editor import main; main()"[/CODE] calibre-debug -c "from calibre.gui2.dialogs.ff_doc_editor import main; main()"[/CODE]
all on one line. all on one line.
[*]By defining a keyboard shortcut in calibre for the action `Open the template [*]By defining a keyboard shortcut in calibre for the action `Open the template
documenation editor` in the `Miscellaneous` section. There is no default shortcut. documentation editor` in the `Miscellaneous` section. There is no default shortcut.
[/LIST] [/LIST]
[/LIST] [/LIST]
''' '''

View File

@ -372,7 +372,7 @@ class LazyConfigWidgetBase(ConfigWidgetBase):
# called when the widget is actually displays. We can't do something like # called when the widget is actually displays. We can't do something like
# lazy_genesis because Qt does "things" before showEvent() is called. In # lazy_genesis because Qt does "things" before showEvent() is called. In
# particular, the register function doesn't work with combo boxes if # particular, the register function doesn't work with combo boxes if
# genesis isn't called before everythign else. Why is a mystery. # genesis isn't called before everything else. Why is a mystery.
if not self.lazy_init_called: if not self.lazy_init_called:
if hasattr(self, 'lazy_initialize'): if hasattr(self, 'lazy_initialize'):
self.lazy_initialize() self.lazy_initialize()

View File

@ -231,7 +231,7 @@ class LazyEditRulesBase(LazyConfigWidgetBase):
def lazy_initialize(self): def lazy_initialize(self):
if not self.rule_set_name: if not self.rule_set_name:
raise NotImplementedError('You must define the attribut "rule_set_name" in LazyEditRulesBase subclasses') raise NotImplementedError('You must define the attribute "rule_set_name" in LazyEditRulesBase subclasses')
self.load_rule_set(self.rule_set_name) self.load_rule_set(self.rule_set_name)
def load_rule_set(self, name): def load_rule_set(self, name):

View File

@ -112,7 +112,7 @@ class TTSEmbed(Dialog):
s.addWidget(p) s.addWidget(p)
self.remove_media_button = b = self.bb.addButton(_('&Remove existing audio'), QDialogButtonBox.ButtonRole.ActionRole) self.remove_media_button = b = self.bb.addButton(_('&Remove existing audio'), QDialogButtonBox.ButtonRole.ActionRole)
b.setToolTip(_('Remove any exisiting audio overlays, such as a previously created Text-to-speech narration from this book')) b.setToolTip(_('Remove any existing audio overlays, such as a previously created Text-to-speech narration from this book'))
b.setIcon(QIcon.ic('trash.png')) b.setIcon(QIcon.ic('trash.png'))
b.clicked.connect(self.remove_media) b.clicked.connect(self.remove_media)
v.addWidget(self.bb) v.addWidget(self.bb)

View File

@ -521,14 +521,14 @@ bool WinToast::initialize(_Out_opt_ WinToastError* error) {
if (_shortcutPolicy != SHORTCUT_POLICY_IGNORE) { if (_shortcutPolicy != SHORTCUT_POLICY_IGNORE) {
if (createShortcut() < 0) { if (createShortcut() < 0) {
setError(error, WinToastError::ShellLinkNotCreated); setError(error, WinToastError::ShellLinkNotCreated);
DEBUG_MSG(L"Error while attaching the AUMI to the current proccess =("); DEBUG_MSG(L"Error while attaching the AUMI to the current process =(");
return false; return false;
} }
} }
if (FAILED(DllImporter::SetCurrentProcessExplicitAppUserModelID(_aumi.c_str()))) { if (FAILED(DllImporter::SetCurrentProcessExplicitAppUserModelID(_aumi.c_str()))) {
setError(error, WinToastError::InvalidAppUserModelID); setError(error, WinToastError::InvalidAppUserModelID);
DEBUG_MSG(L"Error while attaching the AUMI to the current proccess =("); DEBUG_MSG(L"Error while attaching the AUMI to the current process =(");
return false; return false;
} }
@ -560,8 +560,8 @@ HRESULT WinToast::validateShellLinkHelper(_Out_ bool& wasChanged) {
// Let's load the file as shell link to validate. // Let's load the file as shell link to validate.
// - Create a shell link // - Create a shell link
// - Create a persistant file // - Create a persistent file
// - Load the path as data for the persistant file // - Load the path as data for the persistent file
// - Read the property AUMI and validate with the current // - Read the property AUMI and validate with the current
// - Review if AUMI is equal. // - Review if AUMI is equal.
ComPtr<IShellLink> shellLink; ComPtr<IShellLink> shellLink;