Cockatrice 2025-11-30-Development-2.11.0-beta.38
A cross-platform virtual tabletop for multiplayer card games
Loading...
Searching...
No Matches
PrintingSelector Class Reference

#include <printing_selector.h>

Inheritance diagram for PrintingSelector:
[legend]
Collaboration diagram for PrintingSelector:
[legend]

Public Slots

void retranslateUi ()
void updateDisplay ()
 Updates the display by clearing the layout and loading new sets for the current card.
void selectPreviousCard ()
 Selects the previous card in the list.
void selectNextCard ()
 Selects the next card in the list.
void toggleVisibilityNavigationButtons (bool _state)
 Toggles the visibility of the navigation buttons.

Public Member Functions

 PrintingSelector (QWidget *parent, AbstractTabDeckEditor *deckEditor)
 Constructs a PrintingSelector widget to display and manage card printings.
void setCard (const CardInfoPtr &newCard, const QString &_currentZone)
 Sets the current card for the selector and updates the display.
void getAllSetsForCurrentCard ()
 Loads and displays all sets for the current selected card.
DeckListModelgetDeckModel () const

Private Slots

void printingsInDeckChanged ()

Private Member Functions

void selectCard (int changeBy)
 Selects a card based on the change direction.

Private Attributes

QVBoxLayout * layout
SettingsButtonWidgetdisplayOptionsWidget
QWidget * sortAndOptionsContainer
QHBoxLayout * sortAndOptionsLayout
QCheckBox * navigationCheckBox
PrintingSelectorCardSortingWidgetsortToolBar
PrintingSelectorCardSearchWidgetsearchBar
FlowWidgetflowWidget
CardSizeWidgetcardSizeWidget
PrintingSelectorCardSelectionWidgetcardSelectionBar
AbstractTabDeckEditordeckEditor
DeckListModeldeckModel
QTreeView * deckView
CardInfoPtr selectedCard
QString currentZone
QTimer * widgetLoadingBufferTimer
int currentIndex = 0

Constructor & Destructor Documentation

◆ PrintingSelector()

PrintingSelector::PrintingSelector ( QWidget * parent,
AbstractTabDeckEditor * _deckEditor )

Constructs a PrintingSelector widget to display and manage card printings.

This constructor initializes the PrintingSelector widget, setting up various child widgets such as sorting tools, search bar, card size options, and navigation controls. It also connects signals and slots to update the display when the deck model changes, and loads available printings for the selected card.

Parameters
parentThe parent widget for the PrintingSelector.
deckEditorThe TabDeckEditor instance used for managing the deck.
deckModelThe DeckListModel instance that provides data for the deck's contents.
deckViewThe QTreeView instance used to display the deck and its contents.
Here is the call graph for this function:

Member Function Documentation

◆ getAllSetsForCurrentCard()

void PrintingSelector::getAllSetsForCurrentCard ( )

Loads and displays all sets for the current selected card.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getDeckModel()

DeckListModel * PrintingSelector::getDeckModel ( ) const
inlinenodiscard

◆ printingsInDeckChanged

void PrintingSelector::printingsInDeckChanged ( )
privateslot
Here is the call graph for this function:
Here is the caller graph for this function:

◆ retranslateUi

void PrintingSelector::retranslateUi ( )
slot
Here is the caller graph for this function:

◆ selectCard()

void PrintingSelector::selectCard ( int changeBy)
private

Selects a card based on the change direction.

Parameters
changeByThe direction to change, -1 for previous, 1 for next.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ selectNextCard

void PrintingSelector::selectNextCard ( )
slot

Selects the next card in the list.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ selectPreviousCard

void PrintingSelector::selectPreviousCard ( )
slot

Selects the previous card in the list.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ setCard()

void PrintingSelector::setCard ( const CardInfoPtr & newCard,
const QString & _currentZone )

Sets the current card for the selector and updates the display.

Parameters
newCardThe new card to set.
_currentZoneThe current zone the card is in.
Here is the call graph for this function:

◆ toggleVisibilityNavigationButtons

void PrintingSelector::toggleVisibilityNavigationButtons ( bool _state)
slot

Toggles the visibility of the navigation buttons.

Parameters
_stateThe visibility state to set.
Here is the caller graph for this function:

◆ updateDisplay

void PrintingSelector::updateDisplay ( )
slot

Updates the display by clearing the layout and loading new sets for the current card.

Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ cardSelectionBar

PrintingSelectorCardSelectionWidget* PrintingSelector::cardSelectionBar
private

◆ cardSizeWidget

CardSizeWidget* PrintingSelector::cardSizeWidget
private

◆ currentIndex

int PrintingSelector::currentIndex = 0
private

◆ currentZone

QString PrintingSelector::currentZone
private

◆ deckEditor

AbstractTabDeckEditor* PrintingSelector::deckEditor
private

◆ deckModel

DeckListModel* PrintingSelector::deckModel
private

◆ deckView

QTreeView* PrintingSelector::deckView
private

◆ displayOptionsWidget

SettingsButtonWidget* PrintingSelector::displayOptionsWidget
private

◆ flowWidget

FlowWidget* PrintingSelector::flowWidget
private

◆ layout

QVBoxLayout* PrintingSelector::layout
private

◆ navigationCheckBox

QCheckBox* PrintingSelector::navigationCheckBox
private

◆ searchBar

PrintingSelectorCardSearchWidget* PrintingSelector::searchBar
private

◆ selectedCard

CardInfoPtr PrintingSelector::selectedCard
private

◆ sortAndOptionsContainer

QWidget* PrintingSelector::sortAndOptionsContainer
private

◆ sortAndOptionsLayout

QHBoxLayout* PrintingSelector::sortAndOptionsLayout
private

◆ sortToolBar

PrintingSelectorCardSortingWidget* PrintingSelector::sortToolBar
private

◆ widgetLoadingBufferTimer

QTimer* PrintingSelector::widgetLoadingBufferTimer
private

The documentation for this class was generated from the following files: