diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/storage/phrase_index.cpp | 4 | ||||
-rw-r--r-- | src/storage/phrase_index.h | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/storage/phrase_index.cpp b/src/storage/phrase_index.cpp index d5b0ddc..3df14f5 100644 --- a/src/storage/phrase_index.cpp +++ b/src/storage/phrase_index.cpp @@ -53,8 +53,8 @@ void PhraseItem::append_pronunciation(ChewingKey * keys, guint32 freq){ void PhraseItem::remove_nth_pronunciation(size_t index){ guint8 phrase_length = get_phrase_length(); set_n_pronunciation(get_n_pronunciation() - 1); - size_t offset = phrase_item_header + phrase_length * sizeof ( ucs4_t ) + - index * (phrase_length * sizeof (ChewingKey) + sizeof(guint32)); + size_t offset = phrase_item_header + phrase_length * sizeof(ucs4_t) + + index * (phrase_length * sizeof(ChewingKey) + sizeof(guint32)); m_chunk.remove_content(offset, phrase_length * sizeof(ChewingKey) + sizeof(guint32)); } diff --git a/src/storage/phrase_index.h b/src/storage/phrase_index.h index 75813bf..aca74f6 100644 --- a/src/storage/phrase_index.h +++ b/src/storage/phrase_index.h @@ -42,7 +42,7 @@ * ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ * + Phrase Length + number of Pronunciations + Uni-gram Frequency+ * ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ - * + Phrase String(UCS2) + n Pronunciations with Frequency + + * + Phrase String(UCS4) + n Pronunciations with Frequency + * +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */ |