コード例 #1
0
 def __init__(self, parent=None):
     QListWidget.__init__(self, parent)
     self.setSpacing(2)
     pi = plugins['progress_indicator'][0]
     pi.set_no_activate_on_click(self)
     self.itemActivated.connect(self.item_activated)
     self.uuid_map = {}
コード例 #2
0
 def __init__(self, parent=None):
     QListWidget.__init__(self, parent)
     self.setFocusPolicy(Qt.NoFocus)
     self.setStyleSheet('QListWidget::item { padding: 3px; }')
     self.delegate = ResultsDelegate(self)
     self.setItemDelegate(self.delegate)
     self.itemClicked.connect(self.item_activated)
コード例 #3
0
ファイル: search.py プロジェクト: YIXINSHUWU/calibre
 def __init__(self, parent=None):
     QListWidget.__init__(self, parent)
     self.setFocusPolicy(Qt.NoFocus)
     self.delegate = ResultsDelegate(self)
     self.setItemDelegate(self.delegate)
     self.itemClicked.connect(self.item_activated)
     self.blank_icon = QIcon(I('blank.png'))
コード例 #4
0
 def __init__(self, parent=None):
     QListWidget.__init__(self, parent)
     self.setAlternatingRowColors(True)
     self.setStyleSheet('QListView::item { padding: 0.5ex }')
     self.setContextMenuPolicy(Qt.ContextMenuPolicy.ActionsContextMenu)
     self.ac_edit = ac = QAction(QIcon(I('edit_input.png')), _('Rename this bookmark'), self)
     self.addAction(ac)
     self.ac_delete = ac = QAction(QIcon(I('trash.png')), _('Remove this bookmark'), self)
     self.addAction(ac)
コード例 #5
0
ファイル: highlights.py プロジェクト: zhibimohai/calibre
 def __init__(self, parent=None):
     QListWidget.__init__(self, parent)
     self.setSelectionMode(self.ExtendedSelection)
     self.setSpacing(2)
     pi = plugins['progress_indicator'][0]
     pi.set_no_activate_on_click(self)
     self.itemActivated.connect(self.item_activated)
     self.currentItemChanged.connect(self.current_item_changed)
     self.uuid_map = {}
コード例 #6
0
ファイル: authors_edit.py プロジェクト: j-howell/calibre
 def __init__(self, all_authors, parent):
     QListWidget.__init__(self, parent)
     self.setDragEnabled(True)
     self.setSelectionMode(self.ExtendedSelection)
     self.setDropIndicatorShown(True)
     self.setDragDropMode(self.InternalMove)
     self.setAlternatingRowColors(True)
     self.d = ItemDelegate(all_authors, self)
     self.d.edited.connect(self.edited, type=Qt.QueuedConnection)
     self.setItemDelegate(self.d)
コード例 #7
0
 def __init__(self, all_authors, parent):
     QListWidget.__init__(self, parent)
     self.setDragEnabled(True)
     self.setSelectionMode(self.ExtendedSelection)
     self.setDropIndicatorShown(True)
     self.setDragDropMode(self.InternalMove)
     self.setAlternatingRowColors(True)
     self.d = ItemDelegate(all_authors, self)
     self.d.edited.connect(self.edited, type=Qt.QueuedConnection)
     self.setItemDelegate(self.d)
コード例 #8
0
ファイル: toolbars.py プロジェクト: zhanghb1994/calibre
 def __init__(self, actions, parent=None, is_source=True):
     QListWidget.__init__(self, parent)
     self.setSelectionMode(self.ExtendedSelection)
     self.setDragEnabled(True)
     self.viewport().setAcceptDrops(True)
     self.setDropIndicatorShown(True)
     self.setDragDropMode(self.InternalMove)
     self.setDefaultDropAction(Qt.CopyAction if ismacos else Qt.MoveAction)
     self.setMinimumHeight(400)
     self.is_source = is_source
     if is_source:
         actions = self.sort_actions_alphabetically(actions)
         actions = [None] + actions
     self.set_names(actions)
コード例 #9
0
ファイル: bookmarkmanager.py プロジェクト: AtulKumar2/calibre
 def __init__(self, parent=None):
     QListWidget.__init__(self, parent)
     self.setDragEnabled(True)
     self.setDragDropMode(self.InternalMove)
     self.setDefaultDropAction(Qt.MoveAction)
     self.setAlternatingRowColors(True)
     self.setStyleSheet('QListView::item { padding: 0.5ex }')
     self.viewport().setAcceptDrops(True)
     self.setDropIndicatorShown(True)
     self.setContextMenuPolicy(Qt.ActionsContextMenu)
     self.ac_edit = ac = QAction(QIcon(I('edit_input.png')), _('Edit this bookmark'), self)
     self.addAction(ac)
     self.ac_delete = ac = QAction(QIcon(I('trash.png')), _('Remove this bookmark'), self)
     self.addAction(ac)
     self.ac_sort = ac = QAction(_('Sort by name'), self)
     self.addAction(ac)
     self.ac_sort_pos = ac = QAction(_('Sort by position in book'), self)
     self.addAction(ac)
コード例 #10
0
 def __init__(self, parent=None):
     QListWidget.__init__(self, parent)
     self.setDragEnabled(True)
     self.setDragDropMode(self.InternalMove)
     self.setDefaultDropAction(Qt.MoveAction)
     self.setAlternatingRowColors(True)
     self.setStyleSheet('QListView::item { padding: 0.5ex }')
     self.viewport().setAcceptDrops(True)
     self.setDropIndicatorShown(True)
     self.setContextMenuPolicy(Qt.ActionsContextMenu)
     self.ac_edit = ac = QAction(QIcon(I('edit_input.png')), _('Rename this bookmark'), self)
     self.addAction(ac)
     self.ac_delete = ac = QAction(QIcon(I('trash.png')), _('Remove this bookmark'), self)
     self.addAction(ac)
     self.ac_sort = ac = QAction(_('Sort by name'), self)
     self.addAction(ac)
     self.ac_sort_pos = ac = QAction(_('Sort by position in book'), self)
     self.addAction(ac)
コード例 #11
0
ファイル: widgets.py プロジェクト: razman786/tigger
 def __init__(self, *args):
     QListWidget.__init__(self, *args)
     self.setContextMenuPolicy(Qt.CustomContextMenu)
     self.customContextMenuRequested[QPoint].connect(
         self._request_context_menu)
コード例 #12
0
ファイル: preferences.py プロジェクト: yipeng0428/calibre
 def __init__(self, parent=None):
     QListWidget.__init__(self, parent)
     self.setSelectionMode(
         QAbstractItemView.SelectionMode.ExtendedSelection)
コード例 #13
0
 def __init__(self, parent=None):
     QListWidget.__init__(self, parent)
     self.setFocusPolicy(Qt.NoFocus)
     self.setSpacing(2)
コード例 #14
0
 def __init__(self, parent=None):
     QListWidget.__init__(self, parent)
     self.setSelectionMode(self.ExtendedSelection)
コード例 #15
0
ファイル: utils.py プロジェクト: a-peter/SumColumnPlugin
	def __init__(self, parent, custom_columns={}):
		QListWidget.__init__(self, parent)
		self.init_with_list(custom_columns)
コード例 #16
0
 def __init__(self, parent=None):
     QListWidget.__init__(self, parent)
     self.setSelectionMode(self.ExtendedSelection)
コード例 #17
0
ファイル: ListWidget.py プロジェクト: iBlitzkriegi/ServerGui
 def __init__(self, parent=None):
     QListWidget.__init__(self, parent)
     self.setUniformItemSizes(True)
     self.players = []
     global path
     self.path = path
コード例 #18
0
 def __init__(self, parent, gui):
     QListWidget.__init__(self, parent)
     self.gui = gui
     self.setAlternatingRowColors(True)
     self.setSelectionBehavior(QtGui.QAbstractItemView.SelectRows)
コード例 #19
0
 def __init__(self, parent):
     QListWidget.__init__(self, parent)
     self.setSortingEnabled(False)
     self.setSelectionMode(QAbstractItemView.SingleSelection)
     self.blank_icon = get_icon('blank.png')