Cockatrice 2026-01-14-Development-2.11.0-beta.46
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 toggleVisibilityNavigationButtons (bool _state)
 Toggles the visibility of the navigation buttons.

Signals

void prevCardRequested ()
void nextCardRequested ()
void cardAmountsChanged (const QMap< QString, QPair< int, int > > &uuidToAmounts)

Public Member Functions

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

Private Slots

void printingsInDeckChanged ()
void updateCardAmounts ()

Private Attributes

QVBoxLayout * layout
SettingsButtonWidgetdisplayOptionsWidget
QWidget * sortAndOptionsContainer
QHBoxLayout * sortAndOptionsLayout
QCheckBox * navigationCheckBox
PrintingSelectorCardSortingWidgetsortToolBar
PrintingSelectorCardSearchWidgetsearchBar
PrintingSelectorPlaceholderWidgetplaceholderWidget
FlowWidgetflowWidget
CardSizeWidgetcardSizeWidget
PrintingSelectorCardSelectionWidgetcardSelectionBar
AbstractTabDeckEditordeckEditor
DeckStateManagerdeckStateManager
CardInfoPtr selectedCard
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.
Here is the call graph for this function:

Member Function Documentation

◆ cardAmountsChanged

void PrintingSelector::cardAmountsChanged ( const QMap< QString, QPair< int, int > > & uuidToAmounts)
signal

The amounts of the printings in the deck has changed

Parameters
uuidToAmountsMap of uuids to the amounts (maindeck, sideboard) in the deck
Here is the caller graph for this function:

◆ 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:

◆ nextCardRequested

void PrintingSelector::nextCardRequested ( )
signal

Requests the next card in the list

Here is the caller graph for this function:

◆ prevCardRequested

void PrintingSelector::prevCardRequested ( )
signal

Requests the previous card in the list

Here is the caller graph for this function:

◆ 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:

◆ setCard()

void PrintingSelector::setCard ( const CardInfoPtr & newCard)

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

Parameters
newCardThe new card to set.
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:

◆ updateCardAmounts

void PrintingSelector::updateCardAmounts ( )
privateslot
Here is the call graph for this function:
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

◆ deckEditor

AbstractTabDeckEditor* PrintingSelector::deckEditor
private

◆ deckStateManager

DeckStateManager* PrintingSelector::deckStateManager
private

◆ displayOptionsWidget

SettingsButtonWidget* PrintingSelector::displayOptionsWidget
private

◆ flowWidget

FlowWidget* PrintingSelector::flowWidget
private

◆ layout

QVBoxLayout* PrintingSelector::layout
private

◆ navigationCheckBox

QCheckBox* PrintingSelector::navigationCheckBox
private

◆ placeholderWidget

PrintingSelectorPlaceholderWidget* PrintingSelector::placeholderWidget
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: