Date: prev next · Thread: first prev next last
2014 Archives by date, by thread · List index


Hi Stephan,


I have found 3 solution for solve the problem with the Headless mode on Windows.

1. Static Variable
        Set a static Variable for set the Headless mode 
        (Bad solution)

2. Over Parameter
        Set Parameter in functions:
         soffice_main(bool bHeadless) - SVMain(bool bHeadless) - 
          ImplSVMain(bool bHeadless) - InitVCL(bool bHeadless)
        In "InitVCL" would be read the commandline and set the 
        variable "m_headless", the test goes with function 
        "bool IsHeadless()" in desktop\source\app\cmdlineargs.hxx.
        Here can set the Headless variable in dependencies of the 
        parameter (a lot of changes)

This 2 solution have the problem with the function "bool Application::IsHeadlessModeRequested()" in 
vcl\source\app\svapp.cxx, the confusing of that is "bool Application::IsHeadlessModeEnabled()" but 
the function "IsHeadlessModeRequested()" give the status back, and then can set with "void 
Application::EnableHeadlessMode( bool dialogsAreFatal )", but I am not sure for using this function 
in case of the LibreOfficeKit.

3. Fix the Windows function "osl_createCommandArgs_Impl" in sal\osl\w32\process.cxx 
        1. When argv == NULL or no context then use the windows 
        function "GetCommandLineW()" in other case use the
        context of the argv parameter.
        or
        2. When argv has context then adding to the windows 
        function "GetCommandLineW()" 

This last fix is for the commandline "m_headless, bool IsHeadless()" and the 
"IsHeadlessModeRequested".


Juergen Funk




Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.