How-Tos Version 5.1.0-1 This is a collection of How-Tos designed to make it easier to get started using Wing with specific 3rd party tools and libraries for Python. You can use these How-Tos to get set up quickly developing desktop UIs, web applications, 2D and 3D movies and games, and to learn how to use Wing with other libraries. These How-Tos assume you are already familiar with the 3rd party library or application and with Wing IDE. To learn more about Wing IDE see the Quick Start Guide or Tutorial.

Wingware, the feather logo, Wing IDE, Wing IDE 101, Wing IDE Personal, Wing IDE Professional, and "The Intelligent Development Environment" are trademarks or registered trademarks of Wingware in the United States and other countries. Disclaimers: The information contained in this document is subject to change without notice. Wingware shall not be liable for technical or editorial errors or omissions contained in this document; nor for incidental or consequential damages resulting from furnishing, performance, or use of this material. Hardware and software products mentioned herein are named for identification purposes only and may be trademarks of their respective owners.

Copyright () 1999-2015 by Wingware. All rights reserved.

Wingware P.O. Box 400527 Cambridge, MA 02140-0006 United States of America Contents How-Tos 1 Wing IDE Quick Start Guide 1 Install Python 1 Set up a Project 1 Configuring the UI 1 Navigating Code 2 Editing Code 2 Code 3 Other Features 3 Related Documents 3 How-Tos for Web Development 4 2.1. Using Wing IDE with 4 Installing Django 4 Quick Start with Wing IDE Professional 5 Existing Django Project 5 New Django Project 5 Notes on Debugger Configuration 6 Django-specific Actions 7 Debugging Django Templates 7 Notes on Auto-Completion 8 Running Unit Tests 8 Django with Buildout 8 Manual Configuration 8 Configuring the Project 8 Configuring the Debugger 9 Launching from Wing 9 Debugging with Auto-reload 9 Related Documents 10 2.2. Using Wing IDE with 10 Introduction 11 Setting up a Project 11 Debugging 11 Setting Run Arguments 12 Hung Cron Processes 12 Better Static Auto-completion 12 Exception Reporting in Old Web2Py Versions 13 Related Documents 13 2.3. Using Wing IDE with 13 Debugging in Wing IDE 14 Related Documents 14 2.4. Using Wing IDE with Pyramid 14 Installing Pyramid 15 Configuring your Wing IDE Project 15 Debugging 16 Notes on Auto-Completion 17 Debugging Mako Templates 18 Debugging without wingdbstub.py (experimental) 18 Related Documents 19 2.5. Using Wing IDE with 19 Introduction 20 Configuring your Project 20 Debugging with WingDBG 20 WingDBG in buildout-based Plone installations 21 WingDBG as an Egg 21 Debugging Plone from the IDE 22 Related Documents 22 2.6. Using Wing IDE with 22 Before Getting Started 23 Upgrading from earlier Wing versions 23 Quick Start on a Single Host 23 Starting the Debugger 24 Test Drive Wing IDE 24 Setting Up Auto-Refresh 25 Alternative Approach to Reloading 26 Setting up Remote Debugging 27 Trouble Shooting Guide 28 Related Documents 28 2.7. Using Wing IDE with Turbogears 29 Installing Turbogears 29 Configuring Turbogears 1.x to use Wing 29 Configuring Turbogears 2.x to use Wing 30 Notes for Turbogears 1.x 31 Notes for Turbogears 2.x 32 Related Documents 32 2.8. Using Wing IDE with Google App Engine 32 Configuring the Environment 33 Using Django 33 Debugging Your Application 34 Configuration Details 35 Improving Auto-Completion and Goto-Definition 35 Improving Responsiveness when Setting Breakpoints or 36 Pausing Related Documents 36 2.9. Using Wing IDE with mod_wsgi 36 Debugging Setup 36 Disabling stdin/stdout Restrictions 37 Related Documents 37 2.10. Using Wing IDE with mod_python 37 Introduction 37 Quick Start 38 Example 38 Notes 39 Related Documents 39 2.11. Using Wing IDE with Paste and Pylons 39 Installing Paste and/or Pylons 40 Debugging in Wing IDE 40 Debugging Mako Templates 40 Related Documents 40 2.12. Using Wing IDE with Webware 40 Introduction 41 Setting up a Project 41 Starting Debug 42 Related Documents 43 2.13. Debugging Web CGIs with Wing IDE 43 Introduction 43 Tips and Tricks 43 How-Tos for GUI Development 45 3.1. Using Wing IDE with wxPython 45 Introduction 45 Installation and Configuration 46 Test Driving the Debugger 46 Using a GUI Builder 47 Related Documents 48 3.2. Using Wing IDE with PyQt 48 Introduction 48 Installation and Configuration 49 Test Driving the Debugger 49 Using a GUI Builder 50 Related Documents 50 3.3. Using Wing IDE with GTK and PyGObject 50 Auto-Completion 51 Related Documents 51 3.4. Using Wing IDE with PyGTK 51 Introduction 52 Installation and Configuration 52 Auto-completion and Source Assistant 53 Using a GUI Builder 53 Details and Notes 54 Related Documents 54 3.5. Using Wing IDE with 54 Working in the Python Shell 54 Working in the Debugger 55 Trouble-shooting 55 Related Documents 56 How-Tos for Modeling, Rendering, and Compositing Systems 56 4.1. Using Wing IDE with Blender 56 Introduction 56 Related Documents 57 4.2. Using Wing IDE with Autodesk Maya 58 Debugging Setup 58 Better Static Auto-completion 58 Additional Information 59 Related Documents 59 4.3. Using Wing IDE with NUKE and NUKEX 59 Project Configuration 60 Configuring for Licensed NUKE/NUKEX 60 Configuring for Personal Learning Edition of NUKE 61 Additional Project Configuration 61 Replacing the NUKE Script Editor with Wing IDE Pro 61 Debugging Python Running Under NUKE 62 Debugger Configuration Detail 63 Limitations and Notes 63 Related Documents 64 4.4. Using Wing IDE with Source Filmmaker 64 Debugging Setup 64 Related Documents 65 How-Tos for Other Libraries 65 5.1. Using Wing IDE with virtualenv 66 Project Configuration 66 Related Documents 66 5.2. Using Wing IDE with Twisted 66 Installing Twisted 67 Debugging in Wing IDE 67 Related Documents 67 5.3. Using Wing IDE with Cygwin 68 Configuration 68 Related Documents 68 5.4. Using Wing IDE with pygame 69 Debugging pygame 69 Related Documents 69 5.5. Using Wing IDE with 69 Debugging scons 70 Related Documents 70 5.6. Using Wing IDE with IDA Python 71 Debugging IDA Python in Wing IDE 71 Related Documents 71 Using Wing IDE with IronPython 72 Project Configuration 72 Related Documents 72 6.1. Handling Large Values and Strings in the Debugger 72 6.2. Debugging C/C++ and Python together 73 6.3. Debugging Extension Modules on /Unix 73 Preparing Python 73 Starting Debug 74 Tips and Tricks 74 6.4. Debugging Code with XGrab* Calls 75 6.5. Debugging Non-Python Mainloops 76 6.6. Debugging Code Running Under Py2exe 78 Wing IDE Quick Start Guide

Wing IDE Quick Start Guide This is a minimalist guide for getting started quickly with Wing IDE. For a more in-depth introduction, try the Tutorial.

Install Python If you don't already have it on your system, install Python. You may need to restart Wing after doing so.

Set up a Project After Wing is running, create a new project from the Project menu. Then configure your project with the following steps:

1. Use Add Existing Directory in the Project menu to your sources to the project. It's best to constrain this to the directories you are actively working with and let Wing find the libraries you use through the PYTHONPATH. 2. Use Project Properties in the Project menu to set Python Executable to the python.exe or other interpreter executable you want to use with your project. This is typically the full path that is in sys.executable in the desired Python installation. 3. If your code alters sys.path or loads modules in a non-standard way then you may need to set Python Path so that Wing can find your modules for auto-completion, refactoring, debugging, testing, other features. 4. You may want to right-click on your main entry point in the Project tool and select Set As Main Debug File so that debugging always starts there. 5. Use Save Project As in the Project menu to save your project to disk. Note: Wing may consume significant CPU time when it first analyzes your code base. Progress is indicated in the lower left of the IDE window. Once this is done, the results are cached across sessions and Wing should run with a snappy and responsive interface. See Project-Wide Properties and Per-File Properties for a description of all available properties. See Source Code Analysis for background on how Wing's source analysis system works.

Configuring the UI You are now ready to start working with code, but may want to make a few configuration changes first:

1