break_lines.h
00001 #ifndef BREAK_LINES_H
00002 #define BREAK_LINES_H
00003
00004 #include <qstring.h>
00005
00006 namespace khtml {
00007 inline bool isBreakable( const QChar *str, int pos, int )
00008 {
00009 const QChar *c = str+pos;
00010 unsigned short ch = c->unicode();
00011 if ( ch > 0xff ) {
00012
00013 unsigned char row = c->row();
00014 if ( row == 0x0e ) {
00015
00016 if ( c->cell() < 0x80 ) {
00017
00018
00019 return true;
00020 } else
00021 return false;
00022 }
00023 if ( row > 0x2d && row < 0xfb || row == 0x11 )
00024
00025
00026 return true;
00027 else
00028 return c->isSpace();
00029 } else {
00030 if ( ch == ' ' || ch == '\n' )
00031 return true;
00032 }
00033 return false;
00034 }
00035
00036 };
00037
00038 #endif
This file is part of the documentation for kdelibs Version 3.1.0.