cellects.gui.custom_widgets
cellects.gui.custom_widgets
This module contains all modified/simplified widgets from PySide6 It is made to be easier to use and to be consistant in terms of colors and sizes.
MainTabsWidget
Bases: QPushButton
A custom QPushButton that mimics an explorer tab appearance.
Features: - Customizable text - Night mode support - Three states: not_in_use (grey border), in_use (black border), not_usable (grey text) - Tooltip support for not_usable state
Source code in src/cellects/gui/custom_widgets.py
576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 | |
get_state()
is_night_mode()
set_in_use()
set_not_in_use()
set_not_usable(tooltip_text='This tab is not usable')
Set the tab to 'not_usable' state with grey text.
Args: tooltip_text (str): Custom tooltip text to show when hovering
Source code in src/cellects/gui/custom_widgets.py
update_style()
Update the widget's stylesheetµ
Source code in src/cellects/gui/custom_widgets.py
PButton
Bases: QPushButton
Source code in src/cellects/gui/custom_widgets.py
__init__(text, fade=True, tip=None, night_mode=False)
self.setStyleSheet("background-color: rgb(107, 145, 202);
" "border-color: rgb(255, 255, 255); " "color: rgb(0, 0, 0); " "font: 17pt "Britannic Bold";") :param text:
Source code in src/cellects/gui/custom_widgets.py
WindowType
Bases: QWidget
Source code in src/cellects/gui/custom_widgets.py
resizeEvent(event)
Use this signal to detect a resize event and call center window function
:param event: :return: