Push new version
This commit is contained in:
parent
6100d5d40e
commit
907c483775
3 changed files with 26 additions and 42 deletions
|
@ -1,7 +1,6 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE script:module PUBLIC "-//OpenOffice.org//DTD OfficeDocument 1.0//EN" "module.dtd">
|
||||
<script:module xmlns:script="http://openoffice.org/2000/script" script:name="Validation" script:language="StarBasic">Sub markval30
|
||||
|
||||
<script:module xmlns:script="http://openoffice.org/2000/script" script:name="Validation" script:language="StarBasic">Sub markval31
|
||||
End Sub
|
||||
|
||||
|
||||
|
@ -770,11 +769,9 @@ Sub fontReportButton
|
|||
Exit sub
|
||||
EndIf
|
||||
Dim FileName As String
|
||||
FileName = getCharsInFont(targetFontName)
|
||||
getCharsInFont(targetFontName)
|
||||
statusIndicator.end()
|
||||
If FileName <> "" Then
|
||||
openReport(FileName)
|
||||
EndIf
|
||||
|
||||
End Sub
|
||||
|
||||
Sub onSelectFont(oEvent)
|
||||
|
@ -914,7 +911,7 @@ Sub addToArray(xArray(),vNextElement)
|
|||
xArray(iUB) = vNextElement
|
||||
End Sub
|
||||
|
||||
Function getCharsInFont(fontName As String) As String
|
||||
Sub getCharsInFont(fontName As String)
|
||||
Dim resultArray() As String
|
||||
Dim pageNums() As Long
|
||||
Dim firstPages() As Long
|
||||
|
@ -1000,43 +997,30 @@ Function getCharsInFont(fontName As String) As String
|
|||
EndIf
|
||||
Next j
|
||||
Next i
|
||||
resultString = ""
|
||||
For i = LBound(resultArray) To UBound(resultArray)
|
||||
resultString = resultString & "<a href='https://unicode-table.com/ru/" & resultArray(i) & "'" & ">https://unicode-table.com/ru/" & resultArray(i) & "</a> " & getTranslation("charFirstPage") & " " & pageNums(i) & "<br>" & Chr(10)
|
||||
Next i
|
||||
|
||||
If resultString <> "" Then
|
||||
'MsgBox "Символы в шрифте "& fontName &Chr(10)&resultString
|
||||
Dim FileName As String 'Holds the file name
|
||||
Dim n As Integer 'Holds the file number
|
||||
Dim f As Integer 'Index variable
|
||||
Dim s As String 'Temporary string for input
|
||||
Dim fileaccess As Object
|
||||
Dim outtextstream As Object
|
||||
Dim out As Object
|
||||
|
||||
Dim sTemp$
|
||||
GlobalScope.BasicLibraries.loadLibrary("Tools")
|
||||
path=DirectoryNameoutofPath(ThisComponent.getURL(),"/")
|
||||
FileName = path & "/symbolsInFont" & fontName & ".html"
|
||||
'n = FreeFile() 'Next free file number
|
||||
'Open FileName For Output Access Read Write As #n 'Open for read/write
|
||||
fileaccess = createUnoService ("com.sun.star.ucb.SimpleFileAccess")
|
||||
outtextstream = createUnoService ("com.sun.star.io.TextOutputStream")
|
||||
outtextstream.setEncoding( "UTF-8" )
|
||||
out = fileaccess.openFileWrite( FileName )
|
||||
outtextstream.setOutputStream( out )
|
||||
outtextstream.writeString( "<html><head><title>" & getTranslation("symbolsInFontHeading") & " "& fontName & "</title></head><body><h2>" & getTranslation("symbolsInFontHeading") & " "& fontName &":</h2>"&resultString &"</body></html>" )
|
||||
outtextstream.closeOutput()
|
||||
getCharsInFont = FileName
|
||||
Exit Function
|
||||
Dim newDocCursor As Object
|
||||
Dim newDoc As Object
|
||||
newDoc = starDesktop.loadComponentFromURL("private:factory/swriter", "_blank", 0, Array())
|
||||
newDocCursor = newDoc.getCurrentController().getViewCursor()
|
||||
newDocCursor.String = getTranslation("symbolsInFontHeading") & " " & fontName
|
||||
newDocCursor.ParaStyleName = "Heading 1"
|
||||
newDocCursor.collapseToEnd()
|
||||
newDocCursor.Text.insertControlCharacter(newDocCursor.End,com.sun.star.text.ControlCharacter.PARAGRAPH_BREAK,False)
|
||||
For i = LBound(resultArray) To UBound(resultArray)
|
||||
newDocCursor.ParaStyleName = "Text body"
|
||||
newDocCursor.String = "https://unicode-table.com/ru/" & resultArray(i)
|
||||
newDocCursor.HyperLinkURL = "https://unicode-table.com/ru/" & resultArray(i)
|
||||
newDocCursor.collapseToEnd()
|
||||
newDocCursor.String = " " & getTranslation("charFirstPage") & " " & pageNums(i)
|
||||
newDocCursor.collapseToEnd()
|
||||
newDocCursor.Text.insertControlCharacter(newDocCursor.End,com.sun.star.text.ControlCharacter.PARAGRAPH_BREAK,False)
|
||||
Next i
|
||||
Exit Sub
|
||||
|
||||
Else
|
||||
MsgBox getTranslation("symbolsInFontNotFound1") & " " & fontName & " " & getTranslation("symbolsInFontNotFound2")
|
||||
getCharsInFont = ""
|
||||
Exit Function
|
||||
EndIf
|
||||
End Function
|
||||
End Sub
|
||||
|
||||
|
||||
Function findBadCharacters() As Boolean
|
||||
|
|
|
@ -2,9 +2,9 @@
|
|||
<description xmlns="http://openoffice.org/extensions/update/2006"
|
||||
xmlns:xlink="http://www.w3.org/1999/xlink">
|
||||
<identifier value="pro.litvinovg.Redaction"/>
|
||||
<version value="0.10.6" />
|
||||
<version value="0.10.7" />
|
||||
<update-download>
|
||||
<src xlink:href="https://dev.litvinovg.pro/litvinovg/cleanandvalidate/uploads/2b71def6e0a91a02dbee2b8c73fda880/cleanAndValidate.oxt" />
|
||||
<src xlink:href="https://dev.litvinovg.pro/litvinovg/cleanandvalidate/uploads/0545689ae686a087e51c90d0d0d15043/cleanAndValidate.oxt" />
|
||||
</update-download>
|
||||
<release-notes>
|
||||
<src xlink:href="https://dev.litvinovg.pro/litvinovg/cleanandvalidate/-/raw/master/releasenotes.txt" lang="en" />
|
||||
|
|
|
@ -1 +1 @@
|
|||
version=0.10.6
|
||||
version=0.10.7
|
||||
|
|
Loading…
Add table
Reference in a new issue