PySimpleGUI 2020: Part 1.5 – PyCharm Setup FAST VERSION – EXPERIMENTAL

Posted by


In this tutorial, we will walk through the process of setting up PyCharm for PySimpleGUI 2020 development. This specific version is an experimental fast version that aims to improve the development experience with PySimpleGUI.

Prerequisites:

  • PyCharm installed on your system
  • Basic knowledge of Python programming
  • Familiarity with PySimpleGUI library

Step 1: Installing PySimpleGUI 2020
Before setting up PyCharm for PySimpleGUI development, make sure you have PySimpleGUI 2020 installed on your system. You can install it using pip by running the following command in your terminal:

pip install PySimpleGUI

This will install the latest version of PySimpleGUI on your system.

Step 2: Opening PyCharm
Launch PyCharm on your system. If you don’t have PyCharm installed, you can download and install it from the JetBrains website. Once PyCharm is open, you should see the welcome screen.

Step 3: Creating a New Project
Click on "Create New Project" to create a new project in PyCharm. Choose a location for your project and select the interpreter you want to use for the project. You can either choose an existing interpreter or create a new one. Make sure the interpreter has PySimpleGUI installed.

Step 4: Adding PySimpleGUI to the Project Interpreter
After creating the project, you need to add PySimpleGUI to the project interpreter in PyCharm. To do this, open the project settings by clicking on "File" -> "Settings" or using the shortcut "Ctrl + Alt + S."

In the settings window, navigate to "Project: your_project_name" -> "Python Interpreter." Click on the "+" icon to add a new package to the interpreter. Search for PySimpleGUI in the search bar, select it, and click "Install Package" to add it to the interpreter.

Step 5: Configuring PySimpleGUI 2020 in PyCharm
Now that you have PySimpleGUI installed in your project interpreter, you can start using it in your Python scripts. Create a new Python file in your project by right-clicking on the project directory in the project explorer and selecting "New" -> "Python File."

Next, import PySimpleGUI at the beginning of your Python script using the following import statement:

import PySimpleGUI as sg

You can now start writing PySimpleGUI code in your Python script and run it in PyCharm’s integrated terminal or debugger.

Step 6: Running Your PySimpleGUI Script
To run your PySimpleGUI script in PyCharm, you can either use the integrated terminal or run it in the debugger. To run the script in the debugger, set breakpoints in your code by clicking on the left margin of the code editor next to the line numbers. Then, click on the "Debug" button in the toolbar or press "Shift + F9" to start debugging your script.

You can also run your script in the integrated terminal by clicking on the "Run" button in the toolbar or pressing "Shift + F10." This will run your script and display the output in the PyCharm console.

Congratulations! You have successfully set up PyCharm for PySimpleGUI 2020 development. You can now start building interactive GUI applications using PySimpleGUI in PyCharm. Stay tuned for more tutorials on PySimpleGUI development techniques and best practices.

0 0 votes
Article Rating

Leave a Reply

3 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
@pieterjdw
1 hour ago

Thanks a lot for this video!

@joecox9958
1 hour ago

I hope it can be devided as two categories: color, etc in option; others thing must be setup in setup. e.g., I got PySimpleGUI not found in PyCharm

@jorgegil13283
1 hour ago

Control + G nice keystroke

3
0
Would love your thoughts, please comment.x
()
x