mirror of
https://gitlab.futo.org/keyboard/latinime.git
synced 2024-09-28 14:54:30 +01:00
* commit '880cb6187cfe4ec6632bc2d19d70411210818bc9': Make digraph lookups case insensitive
This commit is contained in:
commit
05da1df8ee
@ -14,6 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "char_utils.h"
|
||||
#include "binary_format.h"
|
||||
#include "defines.h"
|
||||
#include "digraph_utils.h"
|
||||
@ -120,10 +121,11 @@ const DigraphUtils::DigraphType DigraphUtils::USED_DIGRAPH_TYPES[] =
|
||||
/* static */ const DigraphUtils::digraph_t *DigraphUtils::getDigraphForDigraphTypeAndCodePoint(
|
||||
const DigraphUtils::DigraphType digraphType, const int compositeGlyphCodePoint) {
|
||||
const DigraphUtils::digraph_t *digraphs = 0;
|
||||
const int compositeGlyphLowerCodePoint = toLowerCase(compositeGlyphCodePoint);
|
||||
const int digraphsSize =
|
||||
DigraphUtils::getAllDigraphsForDictionaryAndReturnSize(digraphType, &digraphs);
|
||||
for (int i = 0; i < digraphsSize; i++) {
|
||||
if (digraphs[i].compositeGlyph == compositeGlyphCodePoint) {
|
||||
if (digraphs[i].compositeGlyph == compositeGlyphLowerCodePoint) {
|
||||
return &digraphs[i];
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user