How run script Python GTK and Glade in windows? - python-3.x

Sorry about my English, i want to create an application with windows interface, through the website Setting up GTK for Windows I followed all MSYS2 steps to install GTK and Glade for windows. But now I can't find Glade, I can't run a python script.

About the second problem:
For me, it is sufficient to search for Glade with Windows' search function. If this is not the case for you, I have the direct executable path for you: glade.exe should be located in [..., folder where you installed msys2 to]\msys2\mingw64\bin\glade.exe.

Related

How to run GTK3 Python3 script outside of MSYS2 in Windows

How can I make my GTK3+ Python script work outside of Msys2's own Python interpreter, into my own venv (virtual environment) Python3 interpreter? I want to prepare my Python 3 script for distribution to other computers, but without Msys2.
I'm using Windows 10.
I've successfully followed the instructions on GTK's website, to download GTK3+ and the Python bindings, in Windows.
I've installed GTK3+ and the Python bindings using MSYS2. My script runs successfully within MSYS2's Python3 interpreter in C:\msys64\mingw64\bin. However, I want to run my Python script outside of MSYS2, with a separate Python 3 interpreter (venv) - not the one in MSYS2.
From my research, it seems that I need to copy the GTK3 .dll files and icons from
C:\msys64\mingw64\bin
and C:\msys64\mingw64\share
to the Python3 interpreter path that I want, with my script files in there too.
But when I attempt to run my script in the virtual environment, I get:
builtins.ImportError: cannot import name '_gi' from 'gi'
Any ideas? Thanks.
I don't know if that is possible.
But if the final intent is to distribute your app, then you should install PyInstaller inside MSYS2 and generate an executable there. Then you'll be able to distribute and execute your app on any Windows machine.
It will only be possible to run your program using the MSYS2 Python interpreter and with all of the required libraries. You can't just copy files and then run them with the Windows Python interpreter that was built using MSVC.
PyInstaller is a good solution to package an app with the interpreter and all of the libraries. The issue you mentioned about getting errors about no module named '_struct' has been fixed.

Launch Labview program through Python

I am working on a project in which I have to launch a VI (Labview program) through my GUI written in python. I have not the administrator rights so I installed PyCharm Community with the JetBrain Toolbox and Python 3.3 with an MSI file.
I read on the internet that to do what I want, I need to install the pywin32 extension: extension -link, but when I launch it, it doesn't find my Python installation.
So, my question is: is there another way to control VI from python?
Thank you in advance for your answer. I am a beginner in both languages.
If you want to run a plain VI, you have to run the LabVIEW IDE -- a
VI is a source code file, not a built executable, so to run directly,
it has to be hosted in the editor.
If you want to run a VI built into
an executable, you obviously have to run that built EXE.
So, either way, you're going to have to be able to launch an EXE.
Can your Python invoke C-style DLLs? If so, you could build your VI into a DLL and then call the VI that way.

configure command line tool not found in the Qt directory (Linux 32-bit)

I have problem finding the configure command line tool. I downloaded Qt online installer for Linux 32-bit and it seems that the configure tool is not included. I have looked inside the Qt main directory. Does anyone have any idea where to find it or how to get it?
Thanks!
That tool is a part of Qt source code and is only useful when you're going to build Qt yourself. In that case, you shouldn't be downloading any installers; download the source code archive instead.
You can install the build-essential meta package to get a complete build environment for Ubuntu.

Qmake in cygwin not found for QT5

I tried to install QT5 within cygwin and succeeded. I am also getting the Xorg menu with Cygwin/X for the designer.
But I could not find the qmake.exe for QT5. I only get the following files in the cygwin select package window
And also it shows mingw64-xxxx-qt4-qmake.exe not qmake.exe
unfortunately I could not sacrifice cygwin and go for a windows distribution. Should I build Qt5 from source code ?
qmake-qt5 belongs to libQt5Core-devel
As usual the search engine is available at
https://cygwin.com/packages/

Error installing Pygame / Python 3.4.1

I'm trying to install Pygame and it returns me the following error "Python version 3.4 required which was not found in the registry". However I already have the Python 3.4.1 installed on my system. Does anyone know how to solve that problem?
I've been using Windows 8.1
Thanks in advance.
Are you using a 64-bit operating system? Try using the 32-bit installer.
Tips I can provide:
Add Python to your Path file in the Advanced settings of your Environmental Variables (just search for it in the control panel)
Something may have gone wrong with the download of Python, so re-install it. Also don't download the 64-bit version, just download the 32-bit version from the main pygame website
Once that's sorted out, transfer the entire Pygame file to the site packages in the Python directory and open up the pygame file and go to this directory in command prompt. Finally, run the Pygame setup from the command prompt which should be something like:
python setup.py
But this will only work if the pygame setup file is called setup.py (it's been a while since I downloaded it), you added Python to the Path file and you're currently in the correct directory in command prompt.
To test if it worked try importing pygame and see if you got an error or not.

Resources