author | harlekin <harlekin> | 2003-03-08 21:18:44 (UTC) |
---|---|---|
committer | harlekin <harlekin> | 2003-03-08 21:18:44 (UTC) |
commit | e0ee59855dfd924d33b4fcd98d5fa74a95437e71 (patch) (unidiff) | |
tree | 6a7094b8cd634958242cb767bf1bcb7a30dfd68d /noncore/settings | |
parent | 803d651da2d61409029b12b378ea815a16109ce7 (diff) | |
download | opie-e0ee59855dfd924d33b4fcd98d5fa74a95437e71.zip opie-e0ee59855dfd924d33b4fcd98d5fa74a95437e71.tar.gz opie-e0ee59855dfd924d33b4fcd98d5fa74a95437e71.tar.bz2 |
use the wrench from inline
-rw-r--r-- | noncore/settings/appearance2/appearance.cpp | 72 |
1 files changed, 36 insertions, 36 deletions
diff --git a/noncore/settings/appearance2/appearance.cpp b/noncore/settings/appearance2/appearance.cpp index 2b35119..8dc70ee 100644 --- a/noncore/settings/appearance2/appearance.cpp +++ b/noncore/settings/appearance2/appearance.cpp | |||
@@ -422,5 +422,5 @@ Appearance::Appearance( QWidget* parent, const char* name, WFlags ) | |||
422 | QWidget *styletab; | 422 | QWidget *styletab; |
423 | 423 | ||
424 | m_color_list = 0; | 424 | m_color_list = 0; |
425 | 425 | ||
426 | tw-> addTab ( styletab = createStyleTab ( tw, config ), "appearance/style", tr( "Style" )); | 426 | tw-> addTab ( styletab = createStyleTab ( tw, config ), "appearance/style", tr( "Style" )); |
@@ -429,3 +429,3 @@ Appearance::Appearance( QWidget* parent, const char* name, WFlags ) | |||
429 | tw-> addTab ( createDecoTab ( tw, config ), "appearance/deco", tr( "Windows" ) ); | 429 | tw-> addTab ( createDecoTab ( tw, config ), "appearance/deco", tr( "Windows" ) ); |
430 | tw-> addTab ( m_advtab = createAdvancedTab ( tw, config ), "appearance/advanced", tr( "Advanced" ) ); | 430 | tw-> addTab ( m_advtab = createAdvancedTab ( tw, config ), "SettingsIcon", tr( "Advanced" ) ); |
431 | 431 | ||
@@ -532,9 +532,9 @@ void Appearance::styleClicked ( int index ) | |||
532 | m_style_settings-> setEnabled ( sli ? sli-> hasSettings ( ) : false ); | 532 | m_style_settings-> setEnabled ( sli ? sli-> hasSettings ( ) : false ); |
533 | 533 | ||
534 | if ( m_sample && sli && sli-> style ( )) { | 534 | if ( m_sample && sli && sli-> style ( )) { |
535 | int ci = m_color_list ? m_color_list-> currentItem ( ) : -1; | 535 | int ci = m_color_list ? m_color_list-> currentItem ( ) : -1; |
536 | 536 | ||
537 | m_sample-> setStyle2 ( sli-> style ( ), ci < 0 ? palette ( ) : ((ColorListItem *) m_color_list-> item ( ci ))-> palette ( )); | 537 | m_sample-> setStyle2 ( sli-> style ( ), ci < 0 ? palette ( ) : ((ColorListItem *) m_color_list-> item ( ci ))-> palette ( )); |
538 | } | 538 | } |
539 | 539 | ||
540 | m_style_changed |= ( index != m_original_style ); | 540 | m_style_changed |= ( index != m_original_style ); |
@@ -570,6 +570,6 @@ void Appearance::decoClicked ( int index ) | |||
570 | DecoListItem *dli = (DecoListItem *) m_deco_list-> item ( index ); | 570 | DecoListItem *dli = (DecoListItem *) m_deco_list-> item ( index ); |
571 | 571 | ||
572 | if ( m_sample ) { | 572 | if ( m_sample ) { |
573 | if ( dli && dli-> interface ( )) | 573 | if ( dli && dli-> interface ( )) |
574 | m_sample-> setDecoration ( dli-> interface ( )); | 574 | m_sample-> setDecoration ( dli-> interface ( )); |
575 | else | 575 | else |
@@ -583,3 +583,3 @@ void Appearance::fontClicked ( const QFont &f ) | |||
583 | { | 583 | { |
584 | m_font_changed |= ( f != m_sample-> font ( )); | 584 | m_font_changed |= ( f != m_sample-> font ( )); |
585 | m_sample-> setFont ( f ); | 585 | m_sample-> setFont ( f ); |
@@ -605,6 +605,6 @@ void Appearance::editSchemeClicked ( ) | |||
605 | QColor colors [QColorGroup::NColorRoles]; | 605 | QColor colors [QColorGroup::NColorRoles]; |
606 | 606 | ||
607 | for ( QColorGroup::ColorRole role = (QColorGroup::ColorRole) 0; role != QColorGroup::NColorRoles; ((int) role )++ ) { | 607 | for ( QColorGroup::ColorRole role = (QColorGroup::ColorRole) 0; role != QColorGroup::NColorRoles; ((int) role )++ ) { |
608 | QColor col = item-> color ( role ); | 608 | QColor col = item-> color ( role ); |
609 | 609 | ||
610 | if ( col. isValid ( )) { | 610 | if ( col. isValid ( )) { |
@@ -612,3 +612,3 @@ void Appearance::editSchemeClicked ( ) | |||
612 | colors [cnt] = col; | 612 | colors [cnt] = col; |
613 | 613 | ||
614 | cnt++; | 614 | cnt++; |
@@ -622,3 +622,3 @@ void Appearance::editSchemeClicked ( ) | |||
622 | cnt = 0; | 622 | cnt = 0; |
623 | 623 | ||
624 | for ( QColorGroup::ColorRole role = (QColorGroup::ColorRole) 0; role != QColorGroup::NColorRoles; ((int) role )++ ) { | 624 | for ( QColorGroup::ColorRole role = (QColorGroup::ColorRole) 0; role != QColorGroup::NColorRoles; ((int) role )++ ) { |
@@ -629,6 +629,6 @@ void Appearance::editSchemeClicked ( ) | |||
629 | } | 629 | } |
630 | 630 | ||
631 | m_color_list-> setCurrentItem ( 0 ); | 631 | m_color_list-> setCurrentItem ( 0 ); |
632 | colorClicked ( 0 ); | 632 | colorClicked ( 0 ); |
633 | 633 | ||
634 | m_color_changed = true; | 634 | m_color_changed = true; |
@@ -660,5 +660,5 @@ void Appearance::saveSchemeClicked() | |||
660 | if ( !file. exists ( )) | 660 | if ( !file. exists ( )) |
661 | { | 661 | { |
662 | QPalette p = item-> palette ( ); | 662 | QPalette p = item-> palette ( ); |
663 | 663 | ||
664 | Config config ( file.name(), Config::File ); | 664 | Config config ( file.name(), Config::File ); |
@@ -667,5 +667,5 @@ void Appearance::saveSchemeClicked() | |||
667 | item-> save ( config ); | 667 | item-> save ( config ); |
668 | 668 | ||
669 | config. write ( ); // need to flush the config info first | 669 | config. write ( ); // need to flush the config info first |
670 | 670 | ||
671 | m_color_list-> insertItem ( new ColorListItem ( schemename, config )); | 671 | m_color_list-> insertItem ( new ColorListItem ( schemename, config )); |
@@ -724,3 +724,3 @@ void Appearance::upExcept ( ) | |||
724 | ExceptListItem *it = (ExceptListItem *) m_except-> selectedItem ( ); | 724 | ExceptListItem *it = (ExceptListItem *) m_except-> selectedItem ( ); |
725 | 725 | ||
726 | if ( it && it-> itemAbove ( )) | 726 | if ( it && it-> itemAbove ( )) |
@@ -732,3 +732,3 @@ void Appearance::downExcept ( ) | |||
732 | ExceptListItem *it = (ExceptListItem *) m_except-> selectedItem ( ); | 732 | ExceptListItem *it = (ExceptListItem *) m_except-> selectedItem ( ); |
733 | 733 | ||
734 | if ( it && it-> itemBelow ( )) | 734 | if ( it && it-> itemBelow ( )) |
@@ -739,9 +739,9 @@ class ExEdit : public QLineEdit { | |||
739 | public: | 739 | public: |
740 | ExEdit ( ExceptListItem *item ) | 740 | ExEdit ( ExceptListItem *item ) |
741 | : QLineEdit ( item-> listView ( )-> viewport ( ), "exedit" ), it ( item ) | 741 | : QLineEdit ( item-> listView ( )-> viewport ( ), "exedit" ), it ( item ) |
742 | { | 742 | { |
743 | setFrame ( false ); | 743 | setFrame ( false ); |
744 | 744 | ||
745 | QRect r = it-> listView ( )-> itemRect ( it ); | 745 | QRect r = it-> listView ( )-> itemRect ( it ); |
746 | 746 | ||
747 | int x = it-> listView ( )-> header ( )-> cellPos ( 3 ) - 1; | 747 | int x = it-> listView ( )-> header ( )-> cellPos ( 3 ) - 1; |
@@ -750,10 +750,10 @@ public: | |||
750 | int h = r. height ( ); // + 2; | 750 | int h = r. height ( ); // + 2; |
751 | 751 | ||
752 | setText ( it-> pattern ( )); | 752 | setText ( it-> pattern ( )); |
753 | setGeometry ( x, y, w, h ); | 753 | setGeometry ( x, y, w, h ); |
754 | 754 | ||
755 | qDebug ( "ExEdit: [%s] at %d,%d %d,%d", it->text(2).latin1(),x,y,w,h); | 755 | qDebug ( "ExEdit: [%s] at %d,%d %d,%d", it->text(2).latin1(),x,y,w,h); |
756 | 756 | ||
757 | m_out = true; | 757 | m_out = true; |
758 | 758 | ||
759 | show ( ); | 759 | show ( ); |
@@ -763,4 +763,4 @@ public: | |||
763 | } | 763 | } |
764 | 764 | ||
765 | virtual void focusOutEvent ( QFocusEvent * ) | 765 | virtual void focusOutEvent ( QFocusEvent * ) |
766 | { | 766 | { |
@@ -771,3 +771,3 @@ public: | |||
771 | } | 771 | } |
772 | 772 | ||
773 | virtual void keyPressEvent ( QKeyEvent *e ) | 773 | virtual void keyPressEvent ( QKeyEvent *e ) |
@@ -783,3 +783,3 @@ public: | |||
783 | } | 783 | } |
784 | 784 | ||
785 | private: | 785 | private: |