MCPcopy Create free account
hub / github.com/SpartanJ/eepp / getNewLineType

Method getNewLineType

src/eepp/ui/doc/textformat.cpp:302–309  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

300 Uint32 numInvalidPoints() const { return numPoints - numValidPoints; }
301
302 TextFormat::LineEnding getNewLineType() const {
303 eeASSERT( numCRLF <= numLines );
304 if ( numCRLF == 0 || numCRLF * 2 < numLines ) {
305 return TextFormat::LineEnding::LF;
306 } else {
307 return TextFormat::LineEnding::CRLF;
308 }
309 }
310
311 void calcScore() {
312 score = ( ( 2.5f * numWhitespace + numPlainAscii - 100.f * numInvalidPoints() -

Callers 2

guessFileEncodingFunction · 0.80
autodetectMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected