Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Doc building fixes #1744

Merged
merged 5 commits into from
Apr 18, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions docs/sphinx-docs/build_sphinx.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,14 +70,14 @@ def inplace_change(filename, old_string, new_string):
# Thanks to http://stackoverflow.com/questions/4128144/replace-string-within-file-contents
s=open(filename).read()
if old_string in s:
print('Changing "{old_string}" to "{new_string}"'.format(**locals()))
print('Changing "{old_string}" to "{new_string}" in {filename}'.format(**locals()))
s=s.replace(old_string, new_string)
f=open(filename, 'w')
f.write(s)
f.flush()
f.close()
else:
print('No occurrences of "{old_string}" found.'.format(**locals()))
print('No occurrences of "{old_string}" found in {filename}.'.format(**locals()))

def _remove_dir(dir_path):
"""Removes the given directory."""
Expand Down
1 change: 1 addition & 0 deletions docs/sphinx-docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -228,6 +228,7 @@
\newcommand{\gt}{>} % HTML needs \gt rather than >
\renewcommand{\AA}{\text{\r{A}}} % Allow \AA in math mode
\DeclareUnicodeCharacter {212B} {\AA} % Angstrom
\DeclareUnicodeCharacter {0393} {\ensuremath{\Gamma}} % Gamma
\DeclareUnicodeCharacter {00B7} {\ensuremath{\cdot}} % cdot
\DeclareUnicodeCharacter {00B0} {\ensuremath{^\circ}} % degrees
"""
Expand Down
2 changes: 1 addition & 1 deletion src/sas/qtgui/Calculators/DataOperationUtilityPanel.py
Original file line number Diff line number Diff line change
Expand Up @@ -267,7 +267,7 @@ def onInputCoefficient(self):
if self.txtNumber.isModified():
input_to_check = str(self.txtNumber.text())

if input_to_check is None or input_to_check is '':
if input_to_check is None or input_to_check == '':
msg = 'DataOperation: Number requires a float number'
logging.warning(msg)
self.txtNumber.setStyleSheet(BG_RED)
Expand Down
2 changes: 1 addition & 1 deletion src/sas/qtgui/Perspectives/Fitting/FittingPerspective.py
Original file line number Diff line number Diff line change
Expand Up @@ -549,7 +549,7 @@ def getTabByName(self, name):
"""
Returns the tab with with attribute name *name*
"""
assert(name, str)
assert isinstance(name, str)
for tab in self.tabs:
if tab.modelName() == name:
return tab
Expand Down
2 changes: 1 addition & 1 deletion src/sas/sascalc/fit/Loader.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from __future__ import print_function

# class Loader to load any king of file
# class Loader to load any kind of file
#import wx
#import string
import numpy as np
Expand Down