Files
loongoffice/wizards/source/sfdocuments/script.xlb
Jean-Pierre Ledure 88a67c50af ScriptForge - (SFDocuments) new FormDocument service
The SF_FormDocument service is focused on :
- The orchestration of Base form documents
  (aka Base Forms, but this is confusing)
  and the identification of and the access to their controls.
- Form documents are always contained in a Base document.

A form document may be opened either:
- via code or user interface from the Base file welcome page
- via code only, without having its Base container opened first
In any mode, a form document can be opened only in 1 single copy.

The FormDocument service is triggered either by
    base.OpenFormDocument(...)
    database.OpenFormDocument(...)
        ' Base file may be closed
    ui.GetDocument(...)

Specific methods:
    CloseDocument()
    Forms()
    GetDatabase()
    PrintOut()
Next methods are inherited from the Document superclass:
    Activate()
    CreateMenu(), RemoveMenu()
    ExportAsPdf()
    RunCommand()
    SaveCopyAs()
    SetPrinter()

As a consequence, next methods remain available
but should be declared as deprecated in the help:
    base.CloseFormDocument()
    base.Forms()
    base.PrintOut()
    base.SetPrinter()

Above changes have several more minor impacts :
- beside IsCalc, IsWriter, ... , a new IsFormDocument property
- the UI service identifies open form documents
- a new service means a new entry to register
  in the Services catalog
- management of form events has been reviewed
- the connection between Base, FormDocument, Form
  and Database services is reinforced
- menus were available on components, now also on sub-components

The new service is available for both Basic and Python user scripts.
It requires in the help
    - a new sf_formdocument page
    - a review of the sf_base, sf_database, sf_form, sf_ui pages

Change-Id: Ib06d1c4565ca093af2f068fa5b8082082641752e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/145080
Tested-by: Jean-Pierre Ledure <jp@ledure.be>
Reviewed-by: Jean-Pierre Ledure <jp@ledure.be>
Tested-by: Jenkins
2023-01-05 15:00:28 +00:00

15 lines
821 B
XML

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE library:library PUBLIC "-//OpenOffice.org//DTD OfficeDocument 1.0//EN" "library.dtd">
<library:library xmlns:library="http://openoffice.org/2000/library" library:name="SFDocuments" library:readonly="false" library:passwordprotected="false">
<library:element library:name="__License"/>
<library:element library:name="SF_Document"/>
<library:element library:name="SF_Calc"/>
<library:element library:name="SF_Register"/>
<library:element library:name="SF_Base"/>
<library:element library:name="SF_Form"/>
<library:element library:name="SF_FormControl"/>
<library:element library:name="SF_Writer"/>
<library:element library:name="SF_Chart"/>
<library:element library:name="SF_DocumentListener"/>
<library:element library:name="SF_FormDocument"/>
</library:library>