kate Library API Documentation

katelinerange.cpp

00001 /* This file is part of the KDE libraries 00002 Copyright (C) 2002,2003 Hamish Rodda <rodda@kde.org> 00003 Copyright (C) 2003 Anakim Border <aborder@sources.sourceforge.net> 00004 00005 This library is free software; you can redistribute it and/or 00006 modify it under the terms of the GNU Library General Public 00007 License version 2 as published by the Free Software Foundation. 00008 00009 This library is distributed in the hope that it will be useful, 00010 but WITHOUT ANY WARRANTY; without even the implied warranty of 00011 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00012 Library General Public License for more details. 00013 00014 You should have received a copy of the GNU Library General Public License 00015 along with this library; see the file COPYING.LIB. If not, write to 00016 the Free Software Foundation, Inc., 59 Temple Place - Suite 330, 00017 Boston, MA 02111-1307, USA. 00018 */ 00019 00020 #include "katelinerange.h" 00021 00022 LineRange::LineRange() 00023 : line(-1) 00024 , virtualLine(-1) 00025 , startCol(-1) 00026 , endCol(-1) 00027 , startX(-1) 00028 , endX(-1) 00029 , dirty(false) 00030 , viewLine(-1) 00031 , wrap(false) 00032 , startsInvisibleBlock(false) 00033 , shiftX(0) 00034 { 00035 } 00036 00037 LineRange::~LineRange () 00038 { 00039 } 00040 00041 void LineRange::clear() 00042 { 00043 line = -1; 00044 virtualLine = -1; 00045 startCol = -1; 00046 endCol = -1; 00047 startX = -1; 00048 shiftX = 0; 00049 endX = -1; 00050 viewLine = -1; 00051 wrap = false; 00052 startsInvisibleBlock = false; 00053 } 00054 00055 bool operator> (const LineRange& r, const KateTextCursor& c) 00056 { 00057 return r.line > c.line() || r.endCol > c.col(); 00058 } 00059 00060 bool operator>= (const LineRange& r, const KateTextCursor& c) 00061 { 00062 return r.line > c.line() || r.endCol >= c.col(); 00063 } 00064 00065 bool operator< (const LineRange& r, const KateTextCursor& c) 00066 { 00067 return r.line < c.line() || r.startCol < c.col(); 00068 } 00069 00070 bool operator<= (const LineRange& r, const KateTextCursor& c) 00071 { 00072 return r.line < c.line() || r.startCol <= c.col(); 00073 } 00074 00075 // kate: space-indent on; indent-width 2; replace-tabs on;
KDE Logo
This file is part of the documentation for kate Library Version 3.2.3.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Sun Oct 10 18:56:23 2004 by doxygen 1.3.7 written by Dimitri van Heesch, © 1997-2003