Skip to content

Commit

Permalink
opt: remove gls qtextcodec
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaoyifang committed Jan 3, 2025
1 parent 20947e1 commit c5cb2b2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/dict/gls.cc
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,6 @@ GlsScanner::GlsScanner( string const & fileName ):
encoding = Encoding::Utf8;
}

auto encoding = Text::getEncodingNameFor( encoding );
// We now can use our own readNextLine() function
lineFeed = Text::initLineFeed( encoding );

Expand Down Expand Up @@ -255,7 +254,8 @@ bool GlsScanner::readNextLine( std::u32string & out, size_t & offset )
if ( pos == -1 ) {
return false;
}
QString line = Iconv::toQString( encoding, readBufferPtr, pos );

QString line = Iconv::toQString( Text::getEncodingNameFor( encoding ), readBufferPtr, pos );

line = Utils::rstrip( line );

Expand Down

0 comments on commit c5cb2b2

Please sign in to comment.