Sprites Aux2 palette group card. More...
#include <palette_group_card.h>
Public Member Functions | |
| SpritesAux2PaletteCard (Rom *rom) | |
| ~SpritesAux2PaletteCard () override=default | |
Public Member Functions inherited from yaze::editor::PaletteGroupCard | |
| PaletteGroupCard (const std::string &group_name, const std::string &display_name, Rom *rom) | |
| Construct a new Palette Group Card. | |
| virtual | ~PaletteGroupCard ()=default |
| void | Draw () |
| Draw the card's ImGui UI. | |
| void | Show () |
| void | Hide () |
| bool | IsVisible () const |
| bool * | visibility_flag () |
| absl::Status | SaveToRom () |
| Save all modified palettes to ROM. | |
| void | DiscardChanges () |
| Discard all unsaved changes. | |
| void | ResetPalette (int palette_index) |
| Reset a specific palette to original ROM values. | |
| void | ResetColor (int palette_index, int color_index) |
| Reset a specific color to original ROM value. | |
| void | SetColor (int palette_index, int color_index, const gfx::SnesColor &new_color) |
| Set a color value (records change for undo) | |
| void | Undo () |
| void | Redo () |
| bool | CanUndo () const |
| bool | CanRedo () const |
| void | ClearHistory () |
| bool | HasUnsavedChanges () const |
| bool | IsPaletteModified (int palette_index) const |
| bool | IsColorModified (int palette_index, int color_index) const |
| int | GetSelectedPaletteIndex () const |
| void | SetSelectedPaletteIndex (int index) |
| int | GetSelectedColorIndex () const |
| void | SetSelectedColorIndex (int index) |
| std::string | ExportToJson () const |
| absl::Status | ImportFromJson (const std::string &json) |
| std::string | ExportToClipboard () const |
| absl::Status | ImportFromClipboard () |
Protected Member Functions | |
| gfx::PaletteGroup * | GetPaletteGroup () override |
| Get the palette group for this card. | |
| const gfx::PaletteGroup * | GetPaletteGroup () const override |
| const PaletteGroupMetadata & | GetMetadata () const override |
| Get metadata for this palette group. | |
| void | DrawPaletteGrid () override |
| Draw the palette grid specific to this palette type. | |
| int | GetColorsPerRow () const override |
| Get the number of colors per row for grid layout. | |
Protected Member Functions inherited from yaze::editor::PaletteGroupCard | |
| virtual void | DrawCustomToolbarButtons () |
| Draw additional toolbar buttons (called after standard buttons) | |
| virtual void | DrawCustomPanels () |
| Draw additional panels (called after main content) | |
| void | DrawToolbar () |
| Draw standard toolbar with save/discard/undo/redo. | |
| void | DrawPaletteSelector () |
| Draw palette selector dropdown. | |
| void | DrawColorPicker () |
| Draw color picker for selected color. | |
| void | DrawColorInfo () |
| Draw color info panel with RGB/SNES/Hex values. | |
| void | DrawMetadataInfo () |
| Draw palette metadata info panel. | |
| void | DrawBatchOperationsPopup () |
| Draw batch operations popup. | |
| gfx::SnesPalette * | GetMutablePalette (int index) |
| Get mutable palette by index. | |
| gfx::SnesColor | GetOriginalColor (int palette_index, int color_index) const |
| Get original color from ROM (for reset/comparison) | |
| absl::Status | WriteColorToRom (int palette_index, int color_index, const gfx::SnesColor &color) |
| Write a single color to ROM. | |
| void | MarkModified (int palette_index, int color_index) |
| Mark palette as modified. | |
| void | ClearModified (int palette_index) |
| Clear modified flags for palette. | |
Static Private Member Functions | |
| static PaletteGroupMetadata | InitializeMetadata () |
Static Private Attributes | |
| static const PaletteGroupMetadata | metadata_ |
Additional Inherited Members | |
Protected Attributes inherited from yaze::editor::PaletteGroupCard | |
| std::string | group_name_ |
| std::string | display_name_ |
| Rom * | rom_ |
| bool | show_ = false |
| int | selected_palette_ = 0 |
| int | selected_color_ = -1 |
| gfx::SnesColor | editing_color_ |
| bool | auto_save_enabled_ = false |
| bool | show_snes_format_ = true |
| bool | show_hex_format_ = true |
Sprites Aux2 palette group card.
Manages auxiliary sprite palettes 2
Definition at line 392 of file palette_group_card.h.
|
explicit |
Definition at line 1022 of file palette_group_card.cc.
|
overridedefault |
|
overrideprotectedvirtual |
Get the palette group for this card.
Implements yaze::editor::PaletteGroupCard.
Definition at line 1046 of file palette_group_card.cc.
References yaze::Rom::mutable_palette_group(), and yaze::editor::PaletteGroupCard::rom_.
|
overrideprotectedvirtual |
Implements yaze::editor::PaletteGroupCard.
Definition at line 1050 of file palette_group_card.cc.
References yaze::editor::PaletteGroupCard::rom_.
|
inlineoverrideprotectedvirtual |
Get metadata for this palette group.
Implements yaze::editor::PaletteGroupCard.
Definition at line 400 of file palette_group_card.h.
References metadata_.
|
overrideprotectedvirtual |
Draw the palette grid specific to this palette type.
Implements yaze::editor::PaletteGroupCard.
Definition at line 1054 of file palette_group_card.cc.
References yaze::editor::PaletteGroupCard::editing_color_, GetColorsPerRow(), yaze::editor::PaletteGroupCard::GetMutablePalette(), yaze::editor::PaletteGroupCard::IsColorModified(), yaze::gui::PaletteColorButton(), yaze::editor::PaletteGroupCard::selected_color_, and yaze::editor::PaletteGroupCard::selected_palette_.
|
inlineoverrideprotectedvirtual |
Get the number of colors per row for grid layout.
Implements yaze::editor::PaletteGroupCard.
Definition at line 402 of file palette_group_card.h.
Referenced by DrawPaletteGrid().
|
staticprivate |
Definition at line 1025 of file palette_group_card.cc.
References yaze::editor::PaletteGroupMetadata::colors_per_palette, yaze::editor::PaletteGroupMetadata::colors_per_row, yaze::editor::PaletteMetadata::description, yaze::editor::PaletteGroupMetadata::display_name, yaze::editor::PaletteGroupMetadata::group_name, yaze::editor::PaletteMetadata::name, yaze::editor::PaletteMetadata::palette_id, yaze::editor::PaletteGroupMetadata::palettes, yaze::editor::PaletteMetadata::rom_address, yaze::editor::PaletteMetadata::usage_notes, and yaze::editor::PaletteMetadata::vram_address.
|
staticprivate |
Definition at line 406 of file palette_group_card.h.
Referenced by GetMetadata().