|
|
@ -66,8 +66,7 @@ class ContentProcessor private constructor( |
|
|
|
it.code <= 0x20 || it == ' ' || it == ',' || it == ',' |
|
|
|
it.code <= 0x20 || it == ' ' || it == ',' || it == ',' |
|
|
|
} |
|
|
|
} |
|
|
|
//去除重复标题 |
|
|
|
//去除重复标题 |
|
|
|
val titleRegex = |
|
|
|
val titleRegex = "^(\\s|\\pP|${book.name})*${chapter.title}(\\s|\\pP)+".toRegex() |
|
|
|
"^(\\s|\\pP)*(${book.name})*(\\s|\\pP)*${chapter.title}(\\s|\\pP)+".toRegex() |
|
|
|
|
|
|
|
mContent = mContent.replace(titleRegex, "") |
|
|
|
mContent = mContent.replace(titleRegex, "") |
|
|
|
if (includeTitle) { |
|
|
|
if (includeTitle) { |
|
|
|
//重新添加标题 |
|
|
|
//重新添加标题 |
|
|
|