News:

--

Main Menu

define starting folder for tinypy

Started by Manfredi, April 17, 2026, 11:59:41 AM

Previous topic - Next topic

Manfredi

Whenever I start one of my scripts (tinypy) with an open dialog e.g.:
inputFolder=gui.dirSelect("Select Source Folder")

The seletion box starts with the following folder:
C:\Program Files\Avidemux 2.8 VC++ 64bits

After this I have to select my source.

Is there any possible solution to set an other path for the program/script to start?
In the doumentation of tinypy I couldn't find a solution.

Attached you'll find such a script.

eumagga0x2a

No, this is not possible with the current interface, unfortunately. More than that, when opening a file dialog from tinyPy to select a directory, Avidemux doesn't pass the last selected directory to the dialog. This is inconsistent with the behavior of the file dialog to select a file when invoked via scripting, thus most likely a bug.

QFileDialog defaults to the present working directory when an empty QString is passed to the file dialog, this must be the directory where the executable is located on Windows, the directory from where the Avidemux binary is called on Linux.

eumagga0x2a