Remove unused imports
This commit is contained in:
+1
-1
@@ -15,7 +15,7 @@ import configparser
|
||||
import sys
|
||||
import nw
|
||||
|
||||
from os import path, mkdir, makedirs, getcwd
|
||||
from os import path, mkdir, makedirs
|
||||
from appdirs import user_config_dir
|
||||
from datetime import datetime
|
||||
|
||||
|
||||
@@ -15,11 +15,9 @@ import nw
|
||||
|
||||
from os import path
|
||||
|
||||
from PyQt5.QtWidgets import QMessageBox
|
||||
|
||||
from nw.convert.file.text import TextFile
|
||||
from nw.convert.tokenizer import Tokenizer
|
||||
from nw.constants import nwAlert, nwItemLayout
|
||||
from nw.constants import nwAlert
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
|
||||
@@ -10,7 +10,6 @@
|
||||
|
||||
"""
|
||||
|
||||
import textwrap
|
||||
import logging
|
||||
import re
|
||||
import nw
|
||||
|
||||
@@ -16,14 +16,11 @@ import nw
|
||||
from os import path
|
||||
|
||||
from PyQt5.QtCore import Qt
|
||||
from PyQt5.QtGui import (
|
||||
QIcon, QPixmap, QColor, QBrush, QStandardItemModel, QFont
|
||||
)
|
||||
from PyQt5.QtGui import QFont
|
||||
from PyQt5.QtWidgets import (
|
||||
QDialog, QHBoxLayout, QVBoxLayout, QFormLayout, QLineEdit, QPlainTextEdit,
|
||||
QLabel, QWidget, QTabWidget, QDialogButtonBox, QSpinBox, QGroupBox,
|
||||
QComboBox, QMessageBox, QCheckBox, QGridLayout, QFontComboBox, QPushButton,
|
||||
QFileDialog
|
||||
QDialog, QHBoxLayout, QVBoxLayout, QLineEdit, QLabel, QWidget, QTabWidget,
|
||||
QDialogButtonBox, QSpinBox, QGroupBox, QComboBox, QMessageBox, QCheckBox,
|
||||
QGridLayout, QFontComboBox, QPushButton, QFileDialog
|
||||
)
|
||||
|
||||
from nw.tools import NWSpellCheck, NWSpellSimple, NWSpellEnchant
|
||||
|
||||
@@ -24,8 +24,7 @@ from PyQt5.QtWidgets import (
|
||||
)
|
||||
|
||||
from nw.convert import TextFile, HtmlFile, MarkdownFile, LaTeXFile, ConcatFile
|
||||
from nw.project import NWDoc
|
||||
from nw.tools import numberToWord, OptLastState
|
||||
from nw.tools import OptLastState
|
||||
from nw.common import packageRefURL
|
||||
from nw.constants import nwFiles, nwItemType, nwAlert
|
||||
|
||||
|
||||
@@ -17,8 +17,8 @@ from os import path
|
||||
|
||||
from PyQt5.QtCore import Qt
|
||||
from PyQt5.QtWidgets import (
|
||||
QDialog, QHBoxLayout, QVBoxLayout, QGroupBox, QFormLayout,
|
||||
QLineEdit, QPushButton, QComboBox
|
||||
QDialog, QHBoxLayout, QVBoxLayout, QGroupBox, QFormLayout, QLineEdit,
|
||||
QPushButton, QComboBox
|
||||
)
|
||||
|
||||
from nw.constants import nwLabels, nwItemLayout, nwItemClass, nwItemType
|
||||
|
||||
@@ -19,9 +19,9 @@ from PyQt5.QtCore import Qt
|
||||
from PyQt5.QtGui import QIcon, QPixmap, QColor, QBrush
|
||||
from PyQt5.QtWidgets import (
|
||||
QDialog, QHBoxLayout, QVBoxLayout, QFormLayout, QLineEdit, QPlainTextEdit,
|
||||
QLabel, QWidget, QTabWidget, QDialogButtonBox, QListWidget,
|
||||
QListWidgetItem, QPushButton, QColorDialog, QAbstractItemView, QTreeWidget,
|
||||
QTreeWidgetItem, QCheckBox
|
||||
QLabel, QWidget, QTabWidget, QDialogButtonBox, QListWidget, QPushButton,
|
||||
QListWidgetItem, QColorDialog, QAbstractItemView, QTreeWidget, QCheckBox,
|
||||
QTreeWidgetItem
|
||||
)
|
||||
|
||||
from nw.constants import nwAlert
|
||||
|
||||
@@ -17,11 +17,10 @@ from os import path
|
||||
from datetime import datetime
|
||||
|
||||
from PyQt5.QtCore import Qt
|
||||
from PyQt5.QtGui import QIcon, QColor, QPixmap, QFont
|
||||
from PyQt5.QtGui import QFont
|
||||
from PyQt5.QtWidgets import (
|
||||
QDialog, QVBoxLayout, QHBoxLayout, QTreeWidget, QTreeWidgetItem,
|
||||
QDialogButtonBox, QHeaderView, QGridLayout, QLabel, QGroupBox,
|
||||
QCheckBox
|
||||
QDialog, QHBoxLayout, QTreeWidget, QTreeWidgetItem, QDialogButtonBox,
|
||||
QGridLayout, QLabel, QGroupBox, QCheckBox
|
||||
)
|
||||
|
||||
from nw.constants import nwConst, nwFiles, nwAlert
|
||||
|
||||
@@ -16,11 +16,11 @@ import nw
|
||||
from os import path
|
||||
|
||||
from PyQt5.QtCore import Qt
|
||||
from PyQt5.QtGui import QIcon, QColor, QPixmap
|
||||
from PyQt5.QtGui import QColor, QPixmap
|
||||
from PyQt5.QtWidgets import (
|
||||
QDialog, QVBoxLayout, QHBoxLayout, QTableWidget, QTableWidgetItem,
|
||||
QDialogButtonBox, QLabel, QPushButton, QHeaderView, QGridLayout,
|
||||
QGroupBox, QCheckBox
|
||||
QDialog, QVBoxLayout, QHBoxLayout, QTableWidget, QTableWidgetItem, QLabel,
|
||||
QDialogButtonBox, QPushButton, QHeaderView, QGridLayout, QGroupBox,
|
||||
QCheckBox
|
||||
)
|
||||
|
||||
from nw.constants import nwFiles, nwItemClass
|
||||
|
||||
@@ -15,13 +15,13 @@ import nw
|
||||
|
||||
from time import time
|
||||
|
||||
from PyQt5.QtCore import Qt, QTimer, QSizeF
|
||||
from PyQt5.QtCore import Qt, QTimer
|
||||
from PyQt5.QtWidgets import (
|
||||
qApp, QTextEdit, QAction, QMenu, QShortcut, QMessageBox
|
||||
)
|
||||
from PyQt5.QtGui import (
|
||||
QTextCursor, QTextOption, QIcon, QKeySequence, QFont, QColor,
|
||||
QPalette, QTextDocument
|
||||
QTextCursor, QTextOption, QKeySequence, QFont, QColor, QPalette,
|
||||
QTextDocument
|
||||
)
|
||||
|
||||
from nw.project import NWDoc
|
||||
|
||||
@@ -14,7 +14,7 @@ import logging
|
||||
import nw
|
||||
|
||||
from PyQt5.QtCore import Qt, QSize
|
||||
from PyQt5.QtGui import QIcon, QFont, QColor
|
||||
from PyQt5.QtGui import QFont, QColor
|
||||
from PyQt5.QtWidgets import (
|
||||
QTreeWidget, QTreeWidgetItem, QAbstractItemView, QApplication
|
||||
)
|
||||
|
||||
@@ -17,7 +17,7 @@ from PyQt5.QtCore import Qt
|
||||
from PyQt5.QtWidgets import QTextBrowser
|
||||
from PyQt5.QtGui import QTextOption, QFont, QPalette, QColor
|
||||
|
||||
from nw.convert import Tokenizer, ToHtml
|
||||
from nw.convert import ToHtml
|
||||
from nw.constants import nwAlert, nwItemType
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
@@ -13,8 +13,6 @@
|
||||
import logging
|
||||
import nw
|
||||
|
||||
from PyQt5.QtCore import Qt
|
||||
from PyQt5.QtGui import QPalette, QColor
|
||||
from PyQt5.QtWidgets import QFrame, QHBoxLayout, QLabel, QPushButton
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
@@ -14,7 +14,6 @@ import logging
|
||||
import nw
|
||||
|
||||
from PyQt5.QtCore import Qt
|
||||
from PyQt5.QtGui import QIcon
|
||||
from PyQt5.QtWidgets import (
|
||||
QFrame, QGridLayout, QLabel, QLineEdit, QPushButton, QApplication
|
||||
)
|
||||
|
||||
@@ -14,10 +14,8 @@ import logging
|
||||
import nw
|
||||
|
||||
from PyQt5.QtCore import Qt, QSize
|
||||
from PyQt5.QtGui import QFont
|
||||
from PyQt5.QtWidgets import (
|
||||
QWidget, QHBoxLayout, QVBoxLayout, QLabel, QGroupBox, QScrollArea, QFrame,
|
||||
QToolButton, QSizePolicy, QCheckBox, QGridLayout
|
||||
QWidget, QLabel, QScrollArea, QFrame, QToolButton, QCheckBox, QGridLayout
|
||||
)
|
||||
|
||||
from nw.constants import nwLabels
|
||||
|
||||
+1
-1
@@ -14,7 +14,7 @@ import logging
|
||||
import nw
|
||||
|
||||
from PyQt5.QtCore import QUrl
|
||||
from PyQt5.QtGui import QIcon, QDesktopServices
|
||||
from PyQt5.QtGui import QDesktopServices
|
||||
from PyQt5.QtWidgets import QMenuBar, QAction, QMessageBox
|
||||
|
||||
from nw.constants import nwItemType, nwItemClass, nwDocAction
|
||||
|
||||
+2
-2
@@ -16,8 +16,8 @@ import nw
|
||||
from time import time
|
||||
|
||||
from PyQt5.QtCore import Qt, QTimer
|
||||
from PyQt5.QtGui import QIcon, QColor, QPixmap, QFont
|
||||
from PyQt5.QtWidgets import QStatusBar, QLabel, QFrame
|
||||
from PyQt5.QtGui import QColor, QPixmap, QFont
|
||||
from PyQt5.QtWidgets import QStatusBar, QLabel
|
||||
|
||||
from nw.tools import NWSpellCheck
|
||||
|
||||
|
||||
+1
-1
@@ -17,7 +17,7 @@ import nw
|
||||
from os import path, listdir
|
||||
|
||||
from PyQt5.QtWidgets import qApp
|
||||
from PyQt5.QtGui import QPalette, QColor, QIcon, QPixmap
|
||||
from PyQt5.QtGui import QPalette, QColor, QIcon
|
||||
|
||||
from nw.constants import nwAlert
|
||||
from nw.gui.icons import GuiIcons
|
||||
|
||||
@@ -18,8 +18,6 @@ from PyQt5.QtGui import (
|
||||
QColor, QTextCharFormat, QFont, QSyntaxHighlighter, QBrush
|
||||
)
|
||||
|
||||
from nw.constants import nwUnicode
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
class GuiDocHighlighter(QSyntaxHighlighter):
|
||||
|
||||
+2
-2
@@ -19,8 +19,8 @@ from os import path
|
||||
from PyQt5.QtCore import Qt, QTimer
|
||||
from PyQt5.QtGui import QIcon, QPixmap, QColor
|
||||
from PyQt5.QtWidgets import (
|
||||
qApp, QWidget, QMainWindow, QVBoxLayout, QFrame, QSplitter, QFileDialog,
|
||||
QShortcut, QMessageBox, QProgressDialog, QDialog
|
||||
qApp, QMainWindow, QVBoxLayout, QFrame, QSplitter, QFileDialog, QShortcut,
|
||||
QMessageBox, QProgressDialog, QDialog
|
||||
)
|
||||
|
||||
from nw.gui import (
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
import logging
|
||||
import nw
|
||||
|
||||
from os import path, mkdir, listdir
|
||||
from os import path
|
||||
from shutil import make_archive
|
||||
from datetime import datetime
|
||||
|
||||
|
||||
+1
-2
@@ -16,9 +16,8 @@ import nw
|
||||
|
||||
from os import path
|
||||
|
||||
from nw.project.document import NWDoc
|
||||
from nw.constants import (
|
||||
nwFiles, nwKeyWords, nwItemType, nwItemClass, nwItemLayout, nwAlert
|
||||
nwFiles, nwKeyWords, nwItemType, nwItemClass, nwAlert
|
||||
)
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
@@ -13,7 +13,6 @@
|
||||
import logging
|
||||
import nw
|
||||
|
||||
from os import path, mkdir
|
||||
from lxml import etree
|
||||
from datetime import datetime
|
||||
|
||||
|
||||
@@ -16,7 +16,6 @@ import nw
|
||||
from lxml import etree
|
||||
|
||||
from nw.common import checkInt
|
||||
from nw.constants import nwItemClass
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
|
||||
@@ -13,8 +13,6 @@
|
||||
import logging
|
||||
import nw
|
||||
|
||||
from os import path
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
def numberToWord(numVal, theLanguage):
|
||||
|
||||
Reference in New Issue
Block a user