Added remove all pagebreaks option in advanced mode

This commit is contained in:
Georgy Litvinov 2020-03-06 14:50:48 +01:00
parent 082768d368
commit fa3ff2c16b
3 changed files with 11 additions and 6 deletions

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE script:module PUBLIC "-//OpenOffice.org//DTD OfficeDocument 1.0//EN" "module.dtd"> <!DOCTYPE script:module PUBLIC "-//OpenOffice.org//DTD OfficeDocument 1.0//EN" "module.dtd">
<script:module xmlns:script="http://openoffice.org/2000/script" script:name="Clean" script:language="StarBasic">Sub mark27 <script:module xmlns:script="http://openoffice.org/2000/script" script:name="Clean" script:language="StarBasic">Sub mark28
End Sub End Sub
@ -82,6 +82,10 @@ Private Sub cleanAccordingTo(dialog)
statusIndicator.Start(&quot;Загружаем стили из шаблона&quot;,100) statusIndicator.Start(&quot;Загружаем стили из шаблона&quot;,100)
loadArticleStyles loadArticleStyles
EndIf EndIf
If dialog.getControl(&quot;removeManualPageBreaks&quot;).state = 1 Then
removeManualPageBreaks
EndIf
statusIndicator.end() statusIndicator.end()
saveAndreload() saveAndreload()
MsgBox &quot;Чистка завершена.&quot; MsgBox &quot;Чистка завершена.&quot;
@ -499,7 +503,7 @@ Private Sub disposeAllBookmarks()
End Sub End Sub
Private Sub disposePageBreaks Private Sub removeManualPageBreaks
oTextCursor = ThisComponent.Text.CreateTextCursor() oTextCursor = ThisComponent.Text.CreateTextCursor()
enum1 = ThisComponent.Text.createEnumeration enum1 = ThisComponent.Text.createEnumeration
While enum1.hasMoreElements While enum1.hasMoreElements

View file

@ -1,10 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE dlg:window PUBLIC "-//OpenOffice.org//DTD OfficeDocument 1.0//EN" "dialog.dtd"> <!DOCTYPE dlg:window PUBLIC "-//OpenOffice.org//DTD OfficeDocument 1.0//EN" "dialog.dtd">
<dlg:window xmlns:dlg="http://openoffice.org/2000/dialog" xmlns:script="http://openoffice.org/2000/script" dlg:id="CleaningDialog" dlg:left="108" dlg:top="17" dlg:width="237" dlg:height="156" dlg:closeable="true" dlg:moveable="true"> <dlg:window xmlns:dlg="http://openoffice.org/2000/dialog" xmlns:script="http://openoffice.org/2000/script" dlg:id="CleaningDialog" dlg:left="108" dlg:top="17" dlg:width="237" dlg:height="168" dlg:closeable="true" dlg:moveable="true">
<dlg:bulletinboard> <dlg:bulletinboard>
<dlg:button dlg:id="Cancel" dlg:tab-index="0" dlg:left="65" dlg:top="139" dlg:width="40" dlg:height="12" dlg:value="Отмена" dlg:button-type="cancel"/> <dlg:button dlg:id="Cancel" dlg:tab-index="0" dlg:left="65" dlg:top="151" dlg:width="40" dlg:height="12" dlg:value="Отмена" dlg:button-type="cancel"/>
<dlg:button dlg:id="CommandButton1" dlg:tab-index="1" dlg:left="41" dlg:top="169" dlg:width="2" dlg:height="0" dlg:value="CommandButton1"/> <dlg:button dlg:id="CommandButton1" dlg:tab-index="1" dlg:left="41" dlg:top="169" dlg:width="2" dlg:height="0" dlg:value="CommandButton1"/>
<dlg:button dlg:id="OK" dlg:tab-index="2" dlg:left="129" dlg:top="139" dlg:width="40" dlg:height="12" dlg:value="OK" dlg:button-type="ok"/> <dlg:button dlg:id="OK" dlg:tab-index="2" dlg:left="129" dlg:top="151" dlg:width="40" dlg:height="12" dlg:value="OK" dlg:button-type="ok"/>
<dlg:checkbox dlg:id="fontsInStyles" dlg:tab-index="3" dlg:left="10" dlg:top="9" dlg:width="218" dlg:height="7" dlg:value="Заменить названия шрифтов в стилях" dlg:checked="false"/> <dlg:checkbox dlg:id="fontsInStyles" dlg:tab-index="3" dlg:left="10" dlg:top="9" dlg:width="218" dlg:height="7" dlg:value="Заменить названия шрифтов в стилях" dlg:checked="false"/>
<dlg:checkbox dlg:id="removeLinks" dlg:tab-index="6" dlg:left="10" dlg:top="40" dlg:width="218" dlg:height="7" dlg:value="Удалить гиперссылки" dlg:checked="false"/> <dlg:checkbox dlg:id="removeLinks" dlg:tab-index="6" dlg:left="10" dlg:top="40" dlg:width="218" dlg:height="7" dlg:value="Удалить гиперссылки" dlg:checked="false"/>
<dlg:checkbox dlg:id="cleanFormatting" dlg:tab-index="5" dlg:left="10" dlg:top="30" dlg:width="218" dlg:height="7" dlg:value="Очистить форматирование" dlg:checked="false"/> <dlg:checkbox dlg:id="cleanFormatting" dlg:tab-index="5" dlg:left="10" dlg:top="30" dlg:width="218" dlg:height="7" dlg:value="Очистить форматирование" dlg:checked="false"/>
@ -17,5 +17,6 @@
<dlg:checkbox dlg:id="loadStandardStyles" dlg:tab-index="13" dlg:left="10" dlg:top="114" dlg:width="218" dlg:height="7" dlg:value="Загрузить стили страниц из шаблона Статья.ott" dlg:checked="false"/> <dlg:checkbox dlg:id="loadStandardStyles" dlg:tab-index="13" dlg:left="10" dlg:top="114" dlg:width="218" dlg:height="7" dlg:value="Загрузить стили страниц из шаблона Статья.ott" dlg:checked="false"/>
<dlg:checkbox dlg:id="symbolsConversion" dlg:tab-index="4" dlg:left="10" dlg:top="20" dlg:width="218" dlg:height="7" dlg:value="Произвести конвертацию символов" dlg:checked="false"/> <dlg:checkbox dlg:id="symbolsConversion" dlg:tab-index="4" dlg:left="10" dlg:top="20" dlg:width="218" dlg:height="7" dlg:value="Произвести конвертацию символов" dlg:checked="false"/>
<dlg:checkbox dlg:id="removeUnusedStyles" dlg:tab-index="14" dlg:left="10" dlg:top="124" dlg:width="218" dlg:height="7" dlg:value="Удалить неиспользуемые стили" dlg:checked="false"/> <dlg:checkbox dlg:id="removeUnusedStyles" dlg:tab-index="14" dlg:left="10" dlg:top="124" dlg:width="218" dlg:height="7" dlg:value="Удалить неиспользуемые стили" dlg:checked="false"/>
<dlg:checkbox dlg:id="removeManualPageBreaks" dlg:tab-index="15" dlg:left="10" dlg:top="134" dlg:width="218" dlg:height="7" dlg:value="Удалить все разрывы страниц" dlg:checked="false"/>
</dlg:bulletinboard> </dlg:bulletinboard>
</dlg:window> </dlg:window>

View file

@ -3,7 +3,7 @@
xmlns:dep="http://openoffice.org/extensions/description/2006" xmlns:dep="http://openoffice.org/extensions/description/2006"
xmlns:xlink="http://www.w3.org/1999/xlink"> xmlns:xlink="http://www.w3.org/1999/xlink">
<identifier value="pro.litvinovg.Redaction" /> <identifier value="pro.litvinovg.Redaction" />
<version value="0.5.1" /> <version value="0.5.2" />
<platform value="all" /> <platform value="all" />
<display-name> <display-name>
<name lang="en">Cleaning and validation documents for publishing in html and epub with pagination</name> <name lang="en">Cleaning and validation documents for publishing in html and epub with pagination</name>