97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
|
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
|
+
+
+
-
+
+
+
+
+
+
-
|
if( fossil_force_newline() ){
lineCnt++;
}
break;
}
len += ((zText[0]=='\t') ? 8 : 1);
if( zText[0]=='\n' || len>=tlen ){
const char *zNewLine;
if( doIndent ){
fossil_print("%*s", indent, "");
}
doIndent = 1;
zNewLine = zText + 1;
while( zText>zLine && !fossil_isspace(zText[0]) ){ zText--; }
if( zText>zLine ){
fossil_print("%.*s", (int)(zText - zLine), zLine);
fossil_print("%.*s", (int)(zText - zLine), zLine);
zLine = zText;
}else{
fossil_print("%.*s", (int)(zNewLine - zLine), zLine);
zLine = zNewLine;
}
if( fossil_force_newline() ){
lineCnt++;
}
zLine = zText;
if( !zLine++ ) break;
len = 0;
}
zText++;
}
return lineCnt;
}
|