LibrePCB Developers Documentation
Loading...
Searching...
No Matches
LibraryEditorTab Class Referenceabstract

Specialized base class for all library editor tabs. More...

#include <libraryeditortab.h>

+ Inheritance diagram for LibraryEditorTab:
+ Collaboration diagram for LibraryEditorTab:

Public Member Functions

 LibraryEditorTab ()=delete
 
 LibraryEditorTab (const LibraryEditorTab &other)=delete
 
 LibraryEditorTab (LibraryEditor &editor, QObject *parent=nullptr) noexcept
 
virtual ~LibraryEditorTab () noexcept
 
virtual FilePath getDirectoryPath () const noexcept=0
 
LibraryEditorTaboperator= (const LibraryEditorTab &rhs)=delete
 
- Public Member Functions inherited from WindowTab
 WindowTab ()=delete
 
 WindowTab (const WindowTab &other)=delete
 
 WindowTab (GuiApplication &app, QObject *parent=nullptr) noexcept
 
virtual ~WindowTab () noexcept
 
virtual ui::TabData getUiData () const noexcept=0
 
virtual void setUiData (const ui::TabData &data) noexcept
 
virtual void activate () noexcept
 
virtual void deactivate () noexcept
 
virtual void trigger (ui::TabAction a) noexcept
 
virtual slint::Image renderScene (float width, float height, int scene) noexcept
 
virtual bool processScenePointerEvent (const QPointF &pos, slint::private_api::PointerEvent e) noexcept
 
virtual bool processSceneScrolled (const QPointF &pos, slint::private_api::PointerScrollEvent e) noexcept
 
virtual bool processSceneKeyEvent (const slint::private_api::KeyEvent &e) noexcept
 
virtual bool requestClose () noexcept
 Request to close the tab.
 
WindowTaboperator= (const WindowTab &rhs)=delete
 

Protected Member Functions

bool isPathOutsideLibDir () const noexcept
 
bool hasUnsavedChanges () const noexcept
 
void scheduleChecks () noexcept
 
void runChecks () noexcept
 
virtual std::optional< std::pair< RuleCheckMessageList, QSet< SExpression > > > runChecksImpl ()=0
 
virtual bool autoFixImpl (const std::shared_ptr< const RuleCheckMessage > &msg, bool checkOnly)=0
 
virtual void messageApprovalChanged (const SExpression &approval, bool approved) noexcept=0
 
virtual void notifyDerivedUiDataChanged () noexcept=0
 
QString getWorkspaceSettingsUserName () const noexcept
 

Protected Attributes

LibraryEditormEditor
 
std::unique_ptr< UndoStackmUndoStack
 
bool mManualModificationsMade
 
QSet< SExpressionmSupportedApprovals
 
QSet< SExpressionmDisappearedApprovals
 
std::shared_ptr< RuleCheckMessagesModelmCheckMessages
 
slint::SharedString mCheckError
 
QTimer mRuleCheckDelayTimer
 
- Protected Attributes inherited from WindowTab
GuiApplicationmApp
 

Private Member Functions

bool autoFixHandler (const std::shared_ptr< const RuleCheckMessage > &msg, bool checkOnly) noexcept
 

Additional Inherited Members

- Signals inherited from WindowTab
void panelPageRequested (ui::PanelPage p)
 
void closeRequested ()
 
void closeEnforced ()
 
void statusBarMessageChanged (const QString &message, int timeoutMs)
 
void cursorCoordinatesChanged (const Point &pos, const LengthUnit &unit)
 
- Public Attributes inherited from WindowTab
Signal< WindowTabonUiDataChanged
 

Detailed Description

Specialized base class for all library editor tabs.

Constructor & Destructor Documentation

◆ LibraryEditorTab() [1/3]

LibraryEditorTab ( )
delete

◆ LibraryEditorTab() [2/3]

LibraryEditorTab ( const LibraryEditorTab other)
delete

◆ LibraryEditorTab() [3/3]

LibraryEditorTab ( LibraryEditor editor,
QObject *  parent = nullptr 
)
explicitnoexcept
+ Here is the call graph for this function:

◆ ~LibraryEditorTab()

~LibraryEditorTab ( )
virtualnoexcept
+ Here is the call graph for this function:

Member Function Documentation

◆ getDirectoryPath()

virtual FilePath getDirectoryPath ( ) const
pure virtualnoexcept

Implemented in ComponentCategoryTab, PackageCategoryTab, LibraryTab, and SymbolTab.

+ Here is the caller graph for this function:

◆ operator=()

LibraryEditorTab & operator= ( const LibraryEditorTab rhs)
delete

◆ isPathOutsideLibDir()

bool isPathOutsideLibDir ( ) const
protectednoexcept
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ hasUnsavedChanges()

bool hasUnsavedChanges ( ) const
protectednoexcept
+ Here is the caller graph for this function:

◆ scheduleChecks()

void scheduleChecks ( )
protectednoexcept
+ Here is the caller graph for this function:

◆ runChecks()

void runChecks ( )
protectednoexcept
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ runChecksImpl()

virtual std::optional< std::pair< RuleCheckMessageList, QSet< SExpression > > > runChecksImpl ( )
protectedpure virtual

Implemented in ComponentCategoryTab, PackageCategoryTab, LibraryTab, and SymbolTab.

+ Here is the caller graph for this function:

◆ autoFixImpl()

virtual bool autoFixImpl ( const std::shared_ptr< const RuleCheckMessage > &  msg,
bool  checkOnly 
)
protectedpure virtual

◆ messageApprovalChanged()

virtual void messageApprovalChanged ( const SExpression approval,
bool  approved 
)
protectedpure virtualnoexcept

Implemented in ComponentCategoryTab, PackageCategoryTab, LibraryTab, and SymbolTab.

+ Here is the caller graph for this function:

◆ notifyDerivedUiDataChanged()

virtual void notifyDerivedUiDataChanged ( )
protectedpure virtualnoexcept

Implemented in ComponentCategoryTab, PackageCategoryTab, LibraryTab, and SymbolTab.

+ Here is the caller graph for this function:

◆ getWorkspaceSettingsUserName()

QString getWorkspaceSettingsUserName ( ) const
protectednoexcept
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ autoFixHandler()

bool autoFixHandler ( const std::shared_ptr< const RuleCheckMessage > &  msg,
bool  checkOnly 
)
privatenoexcept
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Member Data Documentation

◆ mEditor

LibraryEditor& mEditor
protected

◆ mUndoStack

std::unique_ptr<UndoStack> mUndoStack
protected

◆ mManualModificationsMade

bool mManualModificationsMade
protected

◆ mSupportedApprovals

QSet<SExpression> mSupportedApprovals
protected

◆ mDisappearedApprovals

QSet<SExpression> mDisappearedApprovals
protected

◆ mCheckMessages

std::shared_ptr<RuleCheckMessagesModel> mCheckMessages
protected

◆ mCheckError

slint::SharedString mCheckError
protected

◆ mRuleCheckDelayTimer

QTimer mRuleCheckDelayTimer
protected

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