20#ifndef LIBREPCB_EDITOR_LIBRARYEDITOR_H
21#define LIBREPCB_EDITOR_LIBRARYEDITOR_H
46class LibraryEditorTab;
67 QObject* parent =
nullptr) noexcept;
79 ui::LibraryData
getUiData() const noexcept;
80 void setUiData(const ui::LibraryData& data) noexcept;
108 bool save() noexcept;
This class represents absolute, well-formatted paths to files or directories.
Definition filepath.h:127
The Library class represents a library directory.
Definition library.h:46
The Signal class is used to emit signals on non-QObject derived classes.
Definition signalslot.h:65
The Workspace class represents a workspace with all its data (library, projects, settings,...
Definition workspace.h:54
The GuiApplication class.
Definition guiapplication.h:75
The LibraryEditor class.
Definition libraryeditor.h:56
bool save() noexcept
Save the library to the harddisc.
Definition libraryeditor.cpp:150
Signal< LibraryEditor > onUiDataChanged
Definition libraryeditor.h:61
std::unique_ptr< UndoStack > mUndoStack
Definition libraryeditor.h:128
QVector< QPointer< LibraryEditorTab > > mRegisteredTabs
Definition libraryeditor.h:133
Library & getLibrary() noexcept
Definition libraryeditor.h:74
void manualModificationsMade()
bool mManualModificationsMade
Modifications bypassing the undo stack.
Definition libraryeditor.h:131
Workspace & getWorkspace() noexcept
Definition libraryeditor.h:72
void unregisterTab(LibraryEditorTab &tab) noexcept
Definition libraryeditor.cpp:172
UndoStack & getUndoStack() noexcept
Definition libraryeditor.h:75
int mUiIndex
Definition libraryeditor.h:127
void setManualModificationsMade() noexcept
Set the flag that manual modifications (no undo stack) are made.
Definition libraryeditor.cpp:143
GuiApplication & getApp() noexcept
Definition libraryeditor.h:71
ui::LibraryData getUiData() const noexcept
Definition libraryeditor.cpp:94
void setUiIndex(int index) noexcept
Definition libraryeditor.cpp:87
std::unique_ptr< Library > mLibrary
Definition libraryeditor.h:126
FilePath getFilePath() const noexcept
Definition libraryeditor.cpp:79
bool hasUnsavedChanges() const noexcept
Definition libraryeditor.cpp:139
int getUiIndex() const noexcept
Definition libraryeditor.h:77
void forceClosingTabs(const QSet< FilePath > &fp) noexcept
Definition libraryeditor.cpp:177
Workspace & mWorkspace
Definition libraryeditor.h:125
void registerTab(LibraryEditorTab &tab) noexcept
Definition libraryeditor.cpp:167
LibraryEditor(const LibraryEditor &other)=delete
bool requestClose() noexcept
Request to close the library.
Definition libraryeditor.cpp:107
bool isWritable() const noexcept
Definition libraryeditor.cpp:83
void aboutToBeDestroyed()
GuiApplication & mApp
Definition libraryeditor.h:124
void setUiData(const ui::LibraryData &data) noexcept
Definition libraryeditor.cpp:103
Specialized base class for all library editor tabs.
Definition libraryeditortab.h:55
The UndoStack class holds UndoCommand objects and provides undo/redo commands.
Definition undostack.h:106
Definition occmodel.cpp:77