• Skip to content
  • Skip to link menu
KDE 3.5 API Reference
  • KDE API Reference
  • API Reference
  • Sitemap
  • Contact Us
 

Kate

katelinerange.cpp

Go to the documentation of this file.
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., 51 Franklin Street, Fifth Floor,
00017    Boston, MA 02110-1301, USA.
00018 */
00019 
00020 #include "katelinerange.h"
00021 
00022 KateLineRange::KateLineRange()
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 KateLineRange::~KateLineRange ()
00038 {
00039 }
00040 
00041 void KateLineRange::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 KateLineRange& r, const KateTextCursor& c)
00056 {
00057   return r.line > c.line() || r.endCol > c.col();
00058 }
00059 
00060 bool operator>= (const KateLineRange& r, const KateTextCursor& c)
00061 {
00062   return r.line > c.line() || r.endCol >= c.col();
00063 }
00064 
00065 bool operator< (const KateLineRange& r, const KateTextCursor& c)
00066 {
00067   return r.line < c.line() || r.startCol < c.col();
00068 }
00069 
00070 bool operator<= (const KateLineRange& 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;

Kate

Skip menu "Kate"
  • Main Page
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

API Reference

Skip menu "API Reference"
  • dcop
  • DNSSD
  • interfaces
  • Kate
  • kconf_update
  • KDECore
  • KDED
  • kdefx
  • KDEsu
  • kdeui
  • KDocTools
  • KHTML
  • KImgIO
  • KInit
  • kio
  • kioslave
  • KJS
  • KNewStuff
  • KParts
  • KUtils
Generated for API Reference by doxygen 1.5.9
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal