diff options
| author | Michele Calgaro <michele.calgaro@yahoo.it> | 2025-12-08 15:17:51 +0900 |
|---|---|---|
| committer | Michele Calgaro <michele.calgaro@yahoo.it> | 2025-12-08 19:38:03 +0900 |
| commit | 7d612f7c91d55501276a385a30dbadb121e7bd9f (patch) | |
| tree | 4c6f1546e16db32779dfbf5c9e107b938faee6bb /src/kernel/tqrichtext_p.cpp | |
| parent | 5a863a8932d14b99c5f838c4efa1618070d71b29 (diff) | |
| download | tqt-7d612f7c91d55501276a385a30dbadb121e7bd9f.tar.gz tqt-7d612f7c91d55501276a385a30dbadb121e7bd9f.zip | |
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
Diffstat (limited to 'src/kernel/tqrichtext_p.cpp')
| -rw-r--r-- | src/kernel/tqrichtext_p.cpp | 56 |
1 files changed, 28 insertions, 28 deletions
diff --git a/src/kernel/tqrichtext_p.cpp b/src/kernel/tqrichtext_p.cpp index 165d319db..13dba99c6 100644 --- a/src/kernel/tqrichtext_p.cpp +++ b/src/kernel/tqrichtext_p.cpp @@ -51,38 +51,38 @@ TQTextCustomItem::~TQTextCustomItem() {} void TQTextCustomItem::adjustToPainter( TQPainter* p){ if ( p ) width = 0; } TQTextCustomItem::Placement TQTextCustomItem::placement() const { return PlaceInline; } -bool TQTextCustomItem::ownLine() const { return FALSE; } +bool TQTextCustomItem::ownLine() const { return false; } void TQTextCustomItem::resize( int nwidth ){ width = nwidth; } void TQTextCustomItem::invalidate() {} -bool TQTextCustomItem::isNested() const { return FALSE; } +bool TQTextCustomItem::isNested() const { return false; } int TQTextCustomItem::minimumWidth() const { return 0; } TQString TQTextCustomItem::richText() const { return TQString::null; } bool TQTextCustomItem::enter( TQTextCursor *, TQTextDocument*&, TQTextParagraph *&, int &, int &, int &, bool ) { - return TRUE; + return true; } bool TQTextCustomItem::enterAt( TQTextCursor *, TQTextDocument *&, TQTextParagraph *&, int &, int &, int &, const TQPoint & ) { - return TRUE; + return true; } bool TQTextCustomItem::next( TQTextCursor *, TQTextDocument *&, TQTextParagraph *&, int &, int &, int & ) { - return TRUE; + return true; } bool TQTextCustomItem::prev( TQTextCursor *, TQTextDocument *&, TQTextParagraph *&, int &, int &, int & ) { - return TRUE; + return true; } bool TQTextCustomItem::down( TQTextCursor *, TQTextDocument *&, TQTextParagraph *&, int &, int &, int & ) { - return TRUE; + return true; } bool TQTextCustomItem::up( TQTextCursor *, TQTextDocument *&, TQTextParagraph *&, int &, int &, int & ) { - return TRUE; + return true; } #endif // TQT_NO_TEXTCUSTOMITEM @@ -90,7 +90,7 @@ void TQTextFlow::setPageSize( int ps ) { pagesize = ps; } #ifndef TQT_NO_TEXTCUSTOMITEM bool TQTextFlow::isEmpty() { return leftItems.isEmpty() && rightItems.isEmpty(); } #else -bool TQTextFlow::isEmpty() { return TRUE; } +bool TQTextFlow::isEmpty() { return true; } #endif #ifndef TQT_NO_TEXTCUSTOMITEM @@ -177,7 +177,7 @@ void TQTextDocument::setSelectionStart( int id, const TQTextCursor &cursor ) TQTextDocumentSelection sel; sel.startCursor = cursor; sel.endCursor = cursor; - sel.swapped = FALSE; + sel.swapped = false; selections[ id ] = sel; } @@ -198,33 +198,33 @@ TQTextFormat::~TQTextFormat() } TQTextFormat::TQTextFormat() - : fm( TQFontMetrics( fn ) ), linkColor( TRUE ), logicalFontSize( 3 ), stdSize( tqApp->font().pointSize() ) + : fm( TQFontMetrics( fn ) ), linkColor( true ), logicalFontSize( 3 ), stdSize( tqApp->font().pointSize() ) { ref = 0; - usePixelSizes = FALSE; + usePixelSizes = false; if ( stdSize == -1 ) { stdSize = tqApp->font().pixelSize(); - usePixelSizes = TRUE; + usePixelSizes = true; } - missp = FALSE; + missp = false; ha = AlignNormal; collection = 0; } TQTextFormat::TQTextFormat( const TQStyleSheetItem *style ) - : fm( TQFontMetrics( fn ) ), linkColor( TRUE ), logicalFontSize( 3 ), stdSize( tqApp->font().pointSize() ) + : fm( TQFontMetrics( fn ) ), linkColor( true ), logicalFontSize( 3 ), stdSize( tqApp->font().pointSize() ) { ref = 0; - usePixelSizes = FALSE; + usePixelSizes = false; if ( stdSize == -1 ) { stdSize = tqApp->font().pixelSize(); - usePixelSizes = TRUE; + usePixelSizes = true; } - missp = FALSE; + missp = false; ha = AlignNormal; collection = 0; fn = TQFont( style->fontFamily(), @@ -240,7 +240,7 @@ TQTextFormat::TQTextFormat( const TQStyleSheetItem *style ) hei = fm.lineSpacing(); asc = fm.ascent() + (fm.leading()+1)/2; dsc = fm.descent(); - missp = FALSE; + missp = false; ha = AlignNormal; memset( widths, 0, 256 ); generateKey(); @@ -248,14 +248,14 @@ TQTextFormat::TQTextFormat( const TQStyleSheetItem *style ) } TQTextFormat::TQTextFormat( const TQFont &f, const TQColor &c, TQTextFormatCollection *parent ) - : fn( f ), col( c ), fm( TQFontMetrics( f ) ), linkColor( TRUE ), + : fn( f ), col( c ), fm( TQFontMetrics( f ) ), linkColor( true ), logicalFontSize( 3 ), stdSize( f.pointSize() ) { ref = 0; - usePixelSizes = FALSE; + usePixelSizes = false; if ( stdSize == -1 ) { stdSize = f.pixelSize(); - usePixelSizes = TRUE; + usePixelSizes = true; } collection = parent; leftBearing = fm.minLeftBearing(); @@ -263,7 +263,7 @@ TQTextFormat::TQTextFormat( const TQFont &f, const TQColor &c, TQTextFormatColle hei = fm.lineSpacing(); asc = fm.ascent() + (fm.leading()+1)/2; dsc = fm.descent(); - missp = FALSE; + missp = false; ha = AlignNormal; memset( widths, 0, 256 ); generateKey(); @@ -475,7 +475,7 @@ void TQTextParagraph::setSelection( int id, int start, int end ) sel.start = start; sel.end = end; (*mSelections)[ id ] = sel; - setChanged( TRUE, TRUE ); + setChanged( true, true ); } void TQTextParagraph::removeSelection( int id ) @@ -484,7 +484,7 @@ void TQTextParagraph::removeSelection( int id ) return; if ( mSelections ) mSelections->remove( id ); - setChanged( TRUE, TRUE ); + setChanged( true, true ); } int TQTextParagraph::selectionStart( int id ) const @@ -509,16 +509,16 @@ int TQTextParagraph::selectionEnd( int id ) const bool TQTextParagraph::hasSelection( int id ) const { - return mSelections ? mSelections->contains( id ) : FALSE; + return mSelections ? mSelections->contains( id ) : false; } bool TQTextParagraph::fullSelected( int id ) const { if ( !mSelections ) - return FALSE; + return false; TQMap<int, TQTextParagraphSelection>::ConstIterator it = mSelections->find( id ); if ( it == mSelections->end() ) - return FALSE; + return false; return ( *it ).start == 0 && ( *it ).end == str->length() - 1; } |
