[Libreoffice-commits] dev-tools.git: helpauthoring/HelpAuthoring
helpauthoring/HelpAuthoring/_Main.xba |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) New commits: commit 7c3f34f01629f9e09704bd6c25f3142dbd0b5061 Author: Olivier HallotDate: Wed Jun 7 19:01:40 2017 -0300 Bump version to 3.1.5 insinde About box Change-Id: I8380e8cb54aa4eded380a9cc8165ffbed9f5ab3e Reviewed-on: https://gerrit.libreoffice.org/38550 Reviewed-by: Olivier Hallot Tested-by: Olivier Hallot diff --git a/helpauthoring/HelpAuthoring/_Main.xba b/helpauthoring/HelpAuthoring/_Main.xba index 05ccfad..7f53c76 100644 --- a/helpauthoring/HelpAuthoring/_Main.xba +++ b/helpauthoring/HelpAuthoring/_Main.xba @@ -24,7 +24,7 @@ # the License at http://www.apache.org/licenses/LICENSE-2.0 . # -Global Const Version = v3.1.4 +Global Const Version = v3.1.5 Global Const strErr_NoHelpFile = Not a Help File ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] dev-tools.git: helpauthoring/HelpAuthoring
helpauthoring/HelpAuthoring/_Main.xba |5 - 1 file changed, 4 insertions(+), 1 deletion(-) New commits: commit 5ca47d236f717ef0d427c8a2ef60edbeada09bf9 Author: Yousuf PhilipsDate: Mon Mar 7 07:21:24 2016 +0400 Make web view default Change-Id: I14879489b6a177b8f593ff0f02e6fef61fca5b35 Reviewed-on: https://gerrit.libreoffice.org/22966 Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara diff --git a/helpauthoring/HelpAuthoring/_Main.xba b/helpauthoring/HelpAuthoring/_Main.xba index d661100..05ccfad 100644 --- a/helpauthoring/HelpAuthoring/_Main.xba +++ b/helpauthoring/HelpAuthoring/_Main.xba @@ -30,7 +30,7 @@ Global Const strErr_NoHelpFile = Not a Help File Global Const GitClient = git-gui -Global Const WebView = false +Global Const WebView = true Global Const ConsoleTerminal = true @@ -467,6 +467,9 @@ Sub ReloadXHP path = document.URL document.close(-1) oDoc = StarDesktop.loadComponentFromURL(path, path, 0, FileProperties()) + if WebView = true then + goKey( .uno:BrowseView ) + end if End Sub Sub UnhideParaIDs ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] dev-tools.git: helpauthoring/HelpAuthoring
helpauthoring/HelpAuthoring/_Main.xba |1 + 1 file changed, 1 insertion(+) New commits: commit a87446d10f28a0f8a485f4632bf0b00501be1438 Author: Yousuf PhilipsDate: Tue Oct 6 12:00:31 2015 +0400 Make sure to select the full title line in wizard Change-Id: I81bba8b4ca5e33f8a6cfca3ee40ea6145614c2a6 Reviewed-on: https://gerrit.libreoffice.org/19184 Reviewed-by: Yousuf Philips Tested-by: Yousuf Philips diff --git a/helpauthoring/HelpAuthoring/_Main.xba b/helpauthoring/HelpAuthoring/_Main.xba index bafa420..d7c982c 100644 --- a/helpauthoring/HelpAuthoring/_Main.xba +++ b/helpauthoring/HelpAuthoring/_Main.xba @@ -127,6 +127,7 @@ Sub SetMetaDataOnSave(Path as String) goKey( .uno:StartOfParaSel, 1, 1 ) goUp( 1, 1 ) + goKey( .uno:StartOfParaSel, 1, 1 ) InsertSection( lcase( AlphaNum( Replace( title, , _ ) ) ) ) ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] dev-tools.git: helpauthoring/HelpAuthoring
helpauthoring/HelpAuthoring/Helpers.xba |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) New commits: commit 36e325c6a334907e24eab8a6605da78a842544b0 Author: Yousuf PhilipsDate: Wed Sep 30 23:39:54 2015 +0400 tdf#94490 Improve the creation of unique paragraph IDs Change-Id: I3a4eaddc51868c24e419de89cca913c2dc1a557e Reviewed-on: https://gerrit.libreoffice.org/19045 Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara diff --git a/helpauthoring/HelpAuthoring/Helpers.xba b/helpauthoring/HelpAuthoring/Helpers.xba index fcd7faf..a01d4d6 100644 --- a/helpauthoring/HelpAuthoring/Helpers.xba +++ b/helpauthoring/HelpAuthoring/Helpers.xba @@ -125,7 +125,7 @@ Function CreateID sDate = ReplaceAll(Date,/:. \,) sTime = ReplaceAll(Time,/:. \AMP,) Randomize -CreateID = sDate + sTime + Int(Rnd * 100) +CreateID = sDate + sTime + Int(Rnd * 1) End Function === ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] dev-tools.git: helpauthoring/HelpAuthoring
helpauthoring/HelpAuthoring/Comment.xba |3 ++ helpauthoring/HelpAuthoring/Embed.xba | 27 ++ helpauthoring/HelpAuthoring/Helpers.xba |8 +++ helpauthoring/HelpAuthoring/OtherElements.xba |6 +++-- 4 files changed, 30 insertions(+), 14 deletions(-) New commits: commit 947978deaff85e19270d21ff09a76fbf33b69f2e Author: Yousuf PhilipsDate: Tue Sep 15 00:07:11 2015 +0400 Various fixes to functions so they preform better Change-Id: I8fddd3be3dbcfbbf9f1c8673d5de6932d413f600 Reviewed-on: https://gerrit.libreoffice.org/18577 Reviewed-by: Jan Holesovsky Tested-by: Jan Holesovsky diff --git a/helpauthoring/HelpAuthoring/Comment.xba b/helpauthoring/HelpAuthoring/Comment.xba index 3156357..52b428d 100644 --- a/helpauthoring/HelpAuthoring/Comment.xba +++ b/helpauthoring/HelpAuthoring/Comment.xba @@ -61,6 +61,9 @@ Sub Main InsertTag(COMMENT_,COMMENT) SetCharStyle(hlp_aux_comment) InsertTag(COMMENT,oTxtComment.Text) +goLeft( 1, 1 ) +SetCharStyle(hlp_aux_comment) +goRight( 1 ) InsertTag(_COMMENT,/COMMENT) End If End If diff --git a/helpauthoring/HelpAuthoring/Embed.xba b/helpauthoring/HelpAuthoring/Embed.xba index 0f82833..8291232 100644 --- a/helpauthoring/HelpAuthoring/Embed.xba +++ b/helpauthoring/HelpAuthoring/Embed.xba @@ -182,6 +182,11 @@ Sub UpdateFileName oTxtHidFName.Text = ShortFName End If + DocRoot = GetDocumentRoot() + if FileExists( DocRoot + oTxtHidFName.Text ) then + oTxtHidFName.Text = DocRoot + oTxtHidFName.Text + end if + oButBrowseIDs = oDialog.GetControl(butBrowseIDs) If not(FileExists(oTxtHidFName.Text)) Then msgbox oTxtHidFName.Text+ cannot be found.,48,Doh! @@ -242,11 +247,13 @@ Sub BrowseEmbed arTmp(n) = Right(arTmp(n),Len(arTmp(n))-Instr(arTmp(n),id=)-3) sId = Left(arTmp(n),Instr(arTmp(n),)-1) arTmp(n) = Right(arTmp(n),Len(arTmp(n))-Instr(arTmp(n),)) -If Instr(arTmp(n),/section)0 Then +If Instr(arTmp(n),/section) 0 Then arTmp(n) = Left(arTmp(n),Instr(arTmp(n),/section)-1) -End If -If Len(arTmp(n) 100) Then -arTmp(n) = Left(arTmp(n),100)+... + If Len(arTmp(n) 100) Then + arTmp(n) = Left(arTmp(n),100)+... + End If + else + arTmp(n) = [[Unable to get related text]] End If sDim = ubound(arSecs()) arSecs(sDim) = sId+: +arTmp(n) @@ -261,10 +268,14 @@ Sub BrowseEmbed arTmp(n) = Right(arTmp(n),Len(arTmp(n))-Instr(arTmp(n),id=)-3) sId = Left(arTmp(n),Instr(arTmp(n),)-1) arTmp(n) = Right(arTmp(n),Len(arTmp(n))-Instr(arTmp(n),)) -arTmp(n) = Left(arTmp(n),Instr(arTmp(n),/variable)-1) -If Len(arTmp(n) 100) Then -arTmp(n) = Left(arTmp(n),100)+... -End If +if Instr(arTmp(n),/variable) 0 then + arTmp(n) = Left(arTmp(n),Instr(arTmp(n),/variable)-1) + If Len(arTmp(n) 100) Then + arTmp(n) = Left(arTmp(n),100)+... + End If + else + arTmp(n) = [[Unable to get related text]] + end if sDim = ubound(arVars()) arVars(sDim) = sId+: +arTmp(n) sDim = ubound(arVars())+1 diff --git a/helpauthoring/HelpAuthoring/Helpers.xba b/helpauthoring/HelpAuthoring/Helpers.xba index 25d533e..cece54b 100644 --- a/helpauthoring/HelpAuthoring/Helpers.xba +++ b/helpauthoring/HelpAuthoring/Helpers.xba @@ -409,10 +409,10 @@ end Sub === Sub InsertNewParaData -If not IsHelpFile Then -msgbox(strErr_NoHelpFile) -Exit Sub -End If +If not IsHelpFile Then +msgbox(strErr_NoHelpFile) +Exit Sub +End If oSel = thiscomponent.getcurrentcontroller.getselection oCur = oSel(0).getText.createTextCursorByRange(oSel(0)) diff --git a/helpauthoring/HelpAuthoring/OtherElements.xba b/helpauthoring/HelpAuthoring/OtherElements.xba index bae4f31..ab81d99 100644 --- a/helpauthoring/HelpAuthoring/OtherElements.xba +++ b/helpauthoring/HelpAuthoring/OtherElements.xba @@ -90,6 +90,8 @@ Sub InsertSwitchOSParagraph End Sub Sub InsertSwitchOSInline +InsertText( ) +GoLeft( 1 ) InsertTag(SWITCHINLINE_,SWITCHINLINE select=sys,hlp_aux_switch) InsertCaseInlineNow(WIN) @@ -103,7 +105,6 @@ Sub
[Libreoffice-commits] dev-tools.git: helpauthoring/HelpAuthoring
helpauthoring/HelpAuthoring/_Main.xba |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) New commits: commit d1b3160a5ca08bfbfeaa5a1d3ac4d4aa4f50e5f3 Author: Yousuf PhilipsDate: Sun Sep 13 23:23:51 2015 +0400 Fix dialog return value in new file wizard Change-Id: Iefdf212ddb7a2e620fe7b6e8e715bb32abf1acaf Reviewed-on: https://gerrit.libreoffice.org/18539 Reviewed-by: Jan Holesovsky Tested-by: Jan Holesovsky diff --git a/helpauthoring/HelpAuthoring/_Main.xba b/helpauthoring/HelpAuthoring/_Main.xba index be5f59c..61abba5 100644 --- a/helpauthoring/HelpAuthoring/_Main.xba +++ b/helpauthoring/HelpAuthoring/_Main.xba @@ -75,7 +75,7 @@ Sub SetMetaDataOnSave(Path as String) If document.DocumentProperties.Title = Then Ret = msgbox( Automatically generate a basic help file?, 1+32, Basic Help File ) - If Ret = 0 Then + If Ret = 2 Then Exit Sub End if ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] dev-tools.git: helpauthoring/HelpAuthoring
helpauthoring/HelpAuthoring/OtherElements.xba |2 +- helpauthoring/HelpAuthoring/Validate.xba | 10 ++ 2 files changed, 7 insertions(+), 5 deletions(-) New commits: commit 2ddad0eafa26b96fb455eea5245a145e7346ca55 Author: Yousuf PhilipsDate: Sun Sep 13 16:36:49 2015 +0400 Dont display unnecessary dialogs Change-Id: Ica0bc38bd23f298ce3e44e2d1bb8db0acf2c7a62 Reviewed-on: https://gerrit.libreoffice.org/18531 Reviewed-by: Jan Holesovsky Tested-by: Jan Holesovsky diff --git a/helpauthoring/HelpAuthoring/OtherElements.xba b/helpauthoring/HelpAuthoring/OtherElements.xba index e718ac2..c93bc81 100644 --- a/helpauthoring/HelpAuthoring/OtherElements.xba +++ b/helpauthoring/HelpAuthoring/OtherElements.xba @@ -416,7 +416,7 @@ Sub ToggleParaL10NStatus If (sID = ) Then -msgbox Paragraph has no ID. Assigning ID.,48,Info +msgbox Paragraph has no ID. Assigning ID.,48,Info InsertNewParaData thiscomponent.getcurrentcontroller.select(oSel(0)) arParaData = GetParaData diff --git a/helpauthoring/HelpAuthoring/Validate.xba b/helpauthoring/HelpAuthoring/Validate.xba index 70e07a7..4e24ecd 100644 --- a/helpauthoring/HelpAuthoring/Validate.xba +++ b/helpauthoring/HelpAuthoring/Validate.xba @@ -43,10 +43,10 @@ Dim bWarnParaNoID As Boolean Sub ValidateXHP -Validate +Validate( save ) End Sub -Sub Validate +Sub Validate( optional sOrigin as string ) If not IsHelpFile Then msgbox(strErr_NoHelpFile) @@ -102,7 +102,9 @@ Sub Validate Terminate(Element +aTagsOpen(ubound(aTagsOpen()))+ not closed,TextElement) End If -msgbox(Validation finished.) +if IsMissing(sOrigin) then +msgbox(Validation finished.) +end if End Sub @@ -207,7 +209,7 @@ Sub CheckParaID(TE As Object) If posID = 0 Then If bWarnParaNoID Then - Warn(Paragraph has no ID.,IDs will be assigned on save. You can also assign an ID using the Assign Paragraph ID menu item,TPE) + Warn(Paragraph has no ID.,IDs will be assigned on save. You can also assign an ID using the Assign Paragraph ID menu item,TPE) bWarnParaNoID = FALSE End If ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] dev-tools.git: helpauthoring/HelpAuthoring
helpauthoring/HelpAuthoring/_Main.xba |7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) New commits: commit 84f91a57539f7841cf50c924440f6890341c29c6 Author: Yousuf PhilipsDate: Sun Sep 13 16:21:04 2015 +0400 Use last used directory in the open dialog Change-Id: I67db6dc4032b1de22c1eec484a0da4d673973b79 Reviewed-on: https://gerrit.libreoffice.org/18530 Reviewed-by: Jan Holesovsky Tested-by: Jan Holesovsky diff --git a/helpauthoring/HelpAuthoring/_Main.xba b/helpauthoring/HelpAuthoring/_Main.xba index 61abba5..c181ab1 100644 --- a/helpauthoring/HelpAuthoring/_Main.xba +++ b/helpauthoring/HelpAuthoring/_Main.xba @@ -266,11 +266,16 @@ Dim FileProperties(1) As New com.sun.star.beans.PropertyValue ListAny(0) = com.sun.star.ui.dialogs.TemplateDescription.FILEOPEN_SIMPLE oFileDialog = CreateUnoService(com.sun.star.ui.dialogs.FilePicker) oFileDialog.Initialize(ListAny()) -oFileDialog.DisplayDirectory = sDocRoot +If sLastSaveDir AND IsSubDir(sLastSaveDir,sDocRoot) Then +oFileDialog.setDisplayDirectory(sLastSaveDir) +Else + oFileDialog.DisplayDirectory = sDocRoot +End If oFileDialog.AppendFilter(Help, *.xhp) oFileDialog.SetTitle(Open Help File) iAccept = oFileDialog.Execute() If iAccept = 1 Then + WriteConfig(LastSaveDir,oFileDialog.getDisplayDirectory+/) sPath = oFileDialog.Files(0) FileProperties(0).Name = FilterName FileProperties(0).Value =XHP_Help ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] dev-tools.git: helpauthoring/HelpAuthoring
helpauthoring/HelpAuthoring/OtherElements.xba | 21 +++-- 1 file changed, 11 insertions(+), 10 deletions(-) New commits: commit e3189845ad125274a353a99de47a3c41d5d78d87 Author: Yousuf PhilipsDate: Sun Sep 13 17:57:10 2015 +0400 Tweaks for insert extended tip and and insert section Change-Id: Ieb455d5f33736e47b83f9b6b1f0691cdb03a44d4 diff --git a/helpauthoring/HelpAuthoring/OtherElements.xba b/helpauthoring/HelpAuthoring/OtherElements.xba index c93bc81..bae4f31 100644 --- a/helpauthoring/HelpAuthoring/OtherElements.xba +++ b/helpauthoring/HelpAuthoring/OtherElements.xba @@ -287,6 +287,9 @@ Sub InsertExtendedTip Exit Sub End If +ID = . +ID = inputbox(A help ID (hID) is a unique reference key to context-sensitive help when a user uses the F1 key or the Help button. There are two types: UNO commands and Symbolic names.+chr(10)+examples: .uno:InsertCtrl, SID_FM_CONVERTTO_IMAGECONTROL,Enter Help ID (hID),.uno: ) + thiscomponent.getcurrentcontroller.select(oCurStart) If Ret=6 Then InsertTag(AHID_,AHID hid=+ID+) @@ -318,10 +321,8 @@ Sub CloseSort GoDown(1) End Sub -sub InsertSection - - -If not IsHelpFile Then +sub InsertSection( optional sSecName as string ) +If not IsHelpFile and IsMissing(sSecName) Then msgbox(strErr_NoHelpFile) Exit Sub End If @@ -336,11 +337,11 @@ sub InsertSection oEnd = oCur.getEnd oCurEnd = oEnd.getText.createTextCursorByRange(oEnd) -sSectionName = AlphaNum(inputbox(Please specify a section name/identifier:)) - -If sSectionName = Then -Exit Sub -End If +if IsMissing(sSecName) or sSecName = 0 then +sSectionName = AlphaNum(inputbox(Please specify a section name/identifier:)) +else +sSectionName = sSecName +end if If sSectionName = Then msgbox No (valid) identifier -- no section.+chr(13)+Hint: Use only A-Z,a-z,0-9 and _,48,Doh! @@ -372,8 +373,8 @@ sub InsertSection thiscomponent.getcurrentcontroller.select(oCurStart) CR_before GoUp(1) -InsertTag(SECTION_,SECTION id=+sSectionName+) SetParaStyle(hlp_aux_section) +InsertTag(SECTION_,SECTION id=+sSectionName+) thiscomponent.getcurrentcontroller.select(oCurEnd) CR ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] dev-tools.git: helpauthoring/HelpAuthoring
helpauthoring/HelpAuthoring/_Main.xba |1 - 1 file changed, 1 deletion(-) New commits: commit 28d4864fb930e2d9d8d3a66ac43116bdac7dc9e8 Author: Yousuf PhilipsDate: Fri Sep 11 02:29:09 2015 +0400 Dont set indexer during new help file wizard Change-Id: I61c13635c92cc91151ef882265032541ec81ac60 Reviewed-on: https://gerrit.libreoffice.org/18476 Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara diff --git a/helpauthoring/HelpAuthoring/_Main.xba b/helpauthoring/HelpAuthoring/_Main.xba index e19e844..90a2eae 100644 --- a/helpauthoring/HelpAuthoring/_Main.xba +++ b/helpauthoring/HelpAuthoring/_Main.xba @@ -80,7 +80,6 @@ Sub SetMetaDataOnSave(Path as String) End if document.DocumentProperties.UserDefinedProperties.ID = Replace( AlphaNum(Path), xhp, xml ) - document.DocumentProperties.UserDefinedProperties.Indexer = include title = inputbox(The help title is a few word description of the help file topic.,Enter Help Title) If title = "" Then ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] dev-tools.git: helpauthoring/HelpAuthoring
helpauthoring/HelpAuthoring/Validate.xba | 10 -- 1 file changed, 4 insertions(+), 6 deletions(-) New commits: commit 8a50ace751fbeb22e3fb0607fdb00975db637b66 Author: Yousuf PhilipsDate: Thu Sep 10 02:55:39 2015 +0400 Always jump to cursor position to insert new paragraph data Change-Id: I76041a4cfd056da18812771bd16218ca63b45568 Reviewed-on: https://gerrit.libreoffice.org/18454 Reviewed-by: Jan Holesovsky Tested-by: Jan Holesovsky diff --git a/helpauthoring/HelpAuthoring/Validate.xba b/helpauthoring/HelpAuthoring/Validate.xba index cbdab4b..70e07a7 100644 --- a/helpauthoring/HelpAuthoring/Validate.xba +++ b/helpauthoring/HelpAuthoring/Validate.xba @@ -209,18 +209,16 @@ Sub CheckParaID(TE As Object) If bWarnParaNoID Then Warn(Paragraph has no ID.,IDs will be assigned on save. You can also assign an ID using the Assign Paragraph ID menu item,TPE) bWarnParaNoID = FALSE -InsertNewParaData - Else - oCur = TE.getText.createTextCursorByRange(TE) -thiscomponent.getcurrentcontroller.select(oCur) -InsertNewParaData End If + + oCur = TE.getText.createTextCursorByRange(TE) + thiscomponent.getcurrentcontroller.select(oCur) + InsertNewParaData ElseIf posID 1 Then Terminate(Paragraph ID not at the start of the paragraph. The paragraph ID must be the first element of a paragraph. Move the ID to the beginning of the paragraph,TPE) End If End If - End If End Sub ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] dev-tools.git: helpauthoring/HelpAuthoring
helpauthoring/HelpAuthoring/_Main.xba |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) New commits: commit 4869d188a8f506022afa80ee4dcc436ab199fb1a Author: Yousuf PhilipsDate: Thu Sep 10 04:01:52 2015 +0400 Dont clear help topic id and indexer Change-Id: Ibe5fe6b9ba400f9bd749b464b4b51dca1ddc6de3 Reviewed-on: https://gerrit.libreoffice.org/18456 Reviewed-by: Jan Holesovsky Tested-by: Jan Holesovsky diff --git a/helpauthoring/HelpAuthoring/_Main.xba b/helpauthoring/HelpAuthoring/_Main.xba index ff3ab44..e19e844 100644 --- a/helpauthoring/HelpAuthoring/_Main.xba +++ b/helpauthoring/HelpAuthoring/_Main.xba @@ -68,8 +68,8 @@ Sub SetMetaDataOnSave(Path as String) document.DocumentInfo.SetUserFieldName(2,Comment) document.DocumentInfo.SetPropertyValue(Subject,Path) -document.DocumentProperties.UserDefinedProperties.Indexer = Present in template properties -document.DocumentProperties.UserDefinedProperties.ID = Present in template properties +document.DocumentProperties.UserDefinedProperties.Indexer = Present in template properties +document.DocumentProperties.UserDefinedProperties.ID = Present in template properties document.DocumentInfo.SetUserFieldName(2,Comment) document.DocumentProperties.Subject = Path ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] dev-tools.git: helpauthoring/HelpAuthoring
helpauthoring/HelpAuthoring/Helpers.xba | 81 +++- helpauthoring/HelpAuthoring/_Main.xba | 62 2 files changed, 91 insertions(+), 52 deletions(-) New commits: commit faa1bf41bb02e21d22dc3082bd53b58aad243c5e Author: Yousuf PhilipsDate: Thu Sep 10 03:59:50 2015 +0400 Add wizard to creating new help file Change-Id: Id56b80da8311078787f17f16a1012580193b0ec0 Reviewed-on: https://gerrit.libreoffice.org/18455 Reviewed-by: Jan Holesovsky Tested-by: Jan Holesovsky diff --git a/helpauthoring/HelpAuthoring/Helpers.xba b/helpauthoring/HelpAuthoring/Helpers.xba index 628578d..fdd56bf 100644 --- a/helpauthoring/HelpAuthoring/Helpers.xba +++ b/helpauthoring/HelpAuthoring/Helpers.xba @@ -229,11 +229,11 @@ Sub InsertField(Field as String, Content as String) End Sub === - GoUp + GoKey --- - Simulates the CursorUp key + Executes any uno command but targetting to keyboard keystrokes === -Sub goUp(Count As Integer, Optional bSelect As Boolean) +Sub goKey(Command as String, Optional Count As Integer, Optional bSelect As Boolean) dim document as object dim dispatcher as object @@ -250,7 +250,20 @@ Sub goUp(Count As Integer, Optional bSelect As Boolean) args(1).Value = bSelect End If -dispatcher.executeDispatch(document, .uno:GoUp, , 0, args()) +dispatcher.executeDispatch(document, Command, , 0, args()) +End Sub + +=== + GoUp +--- + Simulates the CursorUp key +=== +Sub goUp(Count As Integer, Optional bSelect As Boolean) +If IsMissing(bSelect) Then + goKey( .uno:GoUp, Count ) + Else + goKey( .uno:GoUp, Count, bSelect ) + End if End Sub === @@ -259,23 +272,11 @@ End Sub Simulates the CursorDown key === Sub goDown(Count As Integer, Optional bSelect As Boolean) -dim document as object -dim dispatcher as object - -document = ThisComponent.CurrentController.Frame -dispatcher = createUnoService(com.sun.star.frame.DispatchHelper) - -dim args(1) as new com.sun.star.beans.PropertyValue -args(0).Name = Count -args(0).Value = Count -args(1).Name = Select If IsMissing(bSelect) Then -args(1).Value = false -Else -args(1).Value = bSelect -End If - -dispatcher.executeDispatch(document, .uno:GoDown, , 0, args()) + goKey( .uno:GoDown, Count ) + Else + goKey( .uno:GoDown, Count, bSelect ) + End if End Sub @@ -285,23 +286,11 @@ End Sub Simulates the CursorRight key === Sub goRight(Count As Integer, Optional bSelect As Boolean) -dim document as object -dim dispatcher as object - -document = ThisComponent.CurrentController.Frame -dispatcher = createUnoService(com.sun.star.frame.DispatchHelper) - -dim args(1) as new com.sun.star.beans.PropertyValue -args(0).Name = Count -args(0).Value = Count -args(1).Name = Select If IsMissing(bSelect) Then -args(1).Value = false -Else -args(1).Value = bSelect -End If - -dispatcher.executeDispatch(document, .uno:GoRight, , 0, args()) + goKey( .uno:GoRight, Count ) + Else + goKey( .uno:GoRight, Count, bSelect ) + End if End Sub === @@ -310,23 +299,11 @@ End Sub Simulates the CursorLeft key === Sub goLeft(Count As Integer, optional bSelect As boolean) -dim document as object -dim dispatcher as object - -document = ThisComponent.CurrentController.Frame -dispatcher = createUnoService(com.sun.star.frame.DispatchHelper) - -dim args(1) as new com.sun.star.beans.PropertyValue -args(0).Name = Count -args(0).Value = Count -args(1).Name = Select If IsMissing(bSelect) Then -args(1).Value = false -Else -args(1).Value = bSelect -End If - -dispatcher.executeDispatch(document, .uno:GoLeft, , 0, args()) + goKey( .uno:GoLeft, Count ) + Else + goKey( .uno:GoLeft, Count, bSelect ) + End if End Sub === diff --git a/helpauthoring/HelpAuthoring/_Main.xba b/helpauthoring/HelpAuthoring/_Main.xba index 9746c02..ff3ab44 100644 --- a/helpauthoring/HelpAuthoring/_Main.xba +++ b/helpauthoring/HelpAuthoring/_Main.xba @@ -73,6 +73,68 @@