The QGIS Desktop 3.16 link calls qgis-ltr-bin.exe, the QGIS3 link calls qgis-ltr-bin.exe, and every Desktop link or anything else the user might do will call qgis-ltr-bin.exe. My qgis-ltr-bin.exe is calling qgis-ltr-bin_osgeo.exe with the network installer. The not so pretty bit: after installing qgis via osgeo4w, I copy over qgis-ltr-bin.* to qgis-ltr-bin_osgeo.* I overwrite qgis-ltr-bin.exe with my qgis-ltr-bin.exe. I also copy my QGIS3.lnk to the User Start Menu before QGIS gets a chance to do it. I set environment variables there, I set the global user settings and default transformations that the people in my organisation need to have, and I call qgis using the network profile directory. This is a python script that is compiled to an executable. I made my own QGIS3.lnk, which I have stored in a subdirectory I made under bin. So the user needs to put their own link in that spot before QGIS does. But, if wintoast sees the link, it will not overwrite it, thank god. If ( WinToastLib::WinToast::instance()->initialize() )Ĭan you let me know how you solved this? I have my own VB Script where I create a shortcut to QGIS after a user installs it and out custom toolbar and I want to get rid of the QGIS solution is similar.Īs you know, but just to establish background: The start menu link from installation (QGIS Desktop 3.16) is in the Windows Start Menu, but the QGIS3 start menu link gets put in the User's Start Menu. We have shown that this link is created directly by qgis-bin.exe by wintoastlib when qgis starts. This problem is amplified by the fact that Windows 10 displays the automatically generated link in some cases more prominently then the link set up by the administrator. If we establish that the qgis-ltr.bat is neccessary for administration of enterprise usage in a windows environment, then it becomes clear that if the usage of an organisation's qgis-ltr.bat is overridden by automatically generated links that lead to improper use of qgis (without a profile, without the right default coordinate transforms, breaking geopackages), that is not optimal. If there is a way to accomplish always running qgis with command line options and the right environment variables without using the qgis-ltr.bat, I have not found it in the documentation. This is neccessary for setting the proper default coordinate transform from GK to UTM for our users, who are not able to handle the transform choice dialog new in QGIS 3.10. Thirdly, we have a network location for our qgis_global_settings.ini, which we also pass as an argument to qgis using the bat. We must use a networked profile directory, which is passed to qgis using the -profiles argument. bat we set environment variables (for instance we cant use geopackage in a windows network environment without setting OGR_SQLITE_JOURNAL=DELETE). Running from qgis-ltr.bat is very important for running QGIS on a Windows Networked environment. And also the qgswinnative and wintoast code is quite clear about what it is doing. I could show a Process Monitor log that shows qgis.exe creating the file. It does not happen in Windows 7, apparently because there is a compatability check inside wintoastlib, and perhaps only Windows 10 is "compatible" with the feature. (See wintoastlib.cpp in the initialize() function. It is specifically created by Qgis on Windows 10, using wintoastlib. This happens when QGIS is loading the main window. Just to clarify: Qgis (ltr) is definitely explicitly creating a start menu link called QGIS3 under C:\Users\xxx\AppData\Roaming\Microsoft\Windows\Start Menu\Programs.We are going to try a workaround by running python code at qgis start up that deletes the link. This is especially problematic in 3.10, where global settings must be used to avoid having the user being presented with datum transform selection windows. Thus the user will open a qgis where the profile is not properly set up. On windows 10, the creation of this link gives the user an attractive, shiny start menu item that is presented in some cases with preference over the real start menu item. The qgis-ltr.bat is where network profiles are set and global settings are used. This is an intentional feature, but when qgis is installed as a networked installation for an organisation with many users, it is a bug. There is no way to prevent the creation of this link with an environment variable, for instance. The initialize code in wintoastlib creates the link. MCapabilities = mCapabilities | NativeDesktopNotifications If ( WinToastLib::WinToast::instance()-> initialize() )
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |