├── debian ├── compat ├── vineyard.doc-base ├── rules ├── control └── copyright ├── python-wine ├── debian │ ├── compat │ ├── pycompat │ ├── pyversions │ ├── rules │ ├── control │ └── copyright ├── AUTHORS ├── PACKAGING ├── setup.py ├── test_pe_reader.py └── README ├── data ├── icons │ ├── 16 │ │ ├── wcmd.png │ │ ├── regedit.png │ │ ├── taskmgr.png │ │ └── vineyard-panel.svg │ ├── 22 │ │ ├── regedit.png │ │ └── taskmgr.png │ ├── 32 │ │ ├── regedit.png │ │ └── taskmgr.png │ ├── 48 │ │ ├── wcmd.png │ │ ├── regedit.png │ │ ├── taskmgr.png │ │ ├── vineyard.png │ │ ├── folder-wine.png │ │ └── vineyard-preferences.png │ ├── ie.png │ ├── gecko.png │ ├── wmp.png │ ├── directx.png │ └── firefox.png ├── vineyard-preferences.1.gz ├── locale │ ├── ar │ │ └── LC_MESSAGES │ │ │ └── vineyard.mo │ ├── bg │ │ └── LC_MESSAGES │ │ │ └── vineyard.mo │ ├── cs │ │ └── LC_MESSAGES │ │ │ └── vineyard.mo │ ├── da │ │ └── LC_MESSAGES │ │ │ └── vineyard.mo │ ├── de │ │ └── LC_MESSAGES │ │ │ └── vineyard.mo │ ├── el │ │ └── LC_MESSAGES │ │ │ └── vineyard.mo │ ├── eo │ │ └── LC_MESSAGES │ │ │ └── vineyard.mo │ ├── es │ │ └── LC_MESSAGES │ │ │ └── vineyard.mo │ ├── et │ │ └── LC_MESSAGES │ │ │ └── vineyard.mo │ ├── fr │ │ └── LC_MESSAGES │ │ │ └── vineyard.mo │ ├── gl │ │ └── LC_MESSAGES │ │ │ └── vineyard.mo │ ├── he │ │ └── LC_MESSAGES │ │ │ └── vineyard.mo │ ├── it │ │ └── LC_MESSAGES │ │ │ └── vineyard.mo │ ├── nl │ │ └── LC_MESSAGES │ │ │ └── vineyard.mo │ ├── pl │ │ └── LC_MESSAGES │ │ │ └── vineyard.mo │ ├── ro │ │ └── LC_MESSAGES │ │ │ └── vineyard.mo │ ├── ru │ │ └── LC_MESSAGES │ │ │ └── vineyard.mo │ ├── sk │ │ └── LC_MESSAGES │ │ │ └── vineyard.mo │ ├── tr │ │ └── LC_MESSAGES │ │ │ └── vineyard.mo │ ├── uk │ │ └── LC_MESSAGES │ │ │ └── vineyard.mo │ ├── en_GB │ │ └── LC_MESSAGES │ │ │ └── vineyard.mo │ └── pt_BR │ │ └── LC_MESSAGES │ │ └── vineyard.mo ├── bin │ └── unzip ├── vineyard-autostart.desktop ├── vineyard-indicator.desktop ├── docs │ ├── index.page │ ├── createshortcut.page │ ├── whatisvineyard.page │ ├── runningcommands.page │ ├── problemwinetricks.page │ ├── configureexe.page │ ├── createconf.page │ ├── installprogram.page │ ├── problemprogramwontrun.page │ ├── problemprogramnotshowing.page │ ├── whatisconf.page │ └── differenceprogramconf.page ├── appsupport │ ├── starcraft2.sh │ ├── dotnet35.sh │ ├── torchlight.sh │ ├── klitemega.sh │ ├── avp3.sh │ └── starcraft2.vsc ├── vineyard-launcher.desktop ├── vineyard-preferences.desktop ├── vineyard-preferences.pod ├── script-support-bash.sh ├── vineyard-nautilus-infobar.py └── vineyard-programs.glade ├── tools ├── update_po.sh ├── update_mo.sh ├── update_pot.sh ├── package_manpage.sh ├── check_using_pychecker.sh ├── update_translations.sh ├── package_python-wine.sh └── package_vineyard.sh ├── .gitignore ├── vineyard ├── widgets │ ├── __init__.py │ ├── windows_managed.py │ ├── menu_style.py │ ├── windows_decorated.py │ ├── files_show_hidden.py │ ├── direct3d_pixelshader.py │ ├── font_antialias.py │ ├── sound_directsound_emulation.py │ ├── direct3d_vertexshader.py │ ├── directx_capture_mouse.py │ ├── tool_command_prompt.py │ ├── tool_registry_editor.py │ ├── tool_control_panel.py │ ├── tool_reboot.py │ ├── tool_programs_kill.py │ ├── tool_shutdown.py │ ├── folder_music.py │ ├── tool_programs_end.py │ ├── folder_desktop.py │ ├── folder_videos.py │ ├── folder_pictures.py │ ├── folder_documents.py │ ├── graphics_xrandr.py │ ├── direct3d_antialiasing.py │ ├── tool_open_terminal.py │ ├── tool_open_main_drive.py │ ├── direct3d_allow_multisampling.py │ ├── configuration_name.py │ ├── sound_directsound_samplerate.py │ ├── wine_binary.py │ ├── wine_loader.py │ ├── wine_server.py │ ├── directinput_mouse_warp.py │ ├── version.py │ ├── sound_directsound_acceleration.py │ ├── wine_arch.py │ ├── tool_lowercase_files.py │ ├── sound_directsound_eax.py │ ├── direct3d_dxva2_vaapi.py │ ├── direct3d_csmt.py │ ├── sound_driver.py │ ├── direct3d_offscreen_rendering.py │ ├── sound_directsound_bitdepth.py │ ├── direct3d_check_float_constants.py │ ├── tool_run_executable.py │ ├── direct3d_video_memory_size.py │ └── virtual_desktop.py ├── gtkwidgets │ ├── __init__.py │ └── icondialog.py ├── pages │ ├── __init__.py │ ├── libraries.py │ ├── install.py │ ├── places.py │ ├── programs.py │ ├── general.py │ ├── appearance.py │ ├── tools.py │ └── devices.py ├── __init__.py ├── menus.py └── icons.py ├── exe-helper └── launchers │ ├── desktop.launcher │ ├── java.launcher │ └── wine.launcher ├── tests ├── winetricks_download.py ├── profiling.py ├── executable_link.py ├── executable_get_icon.py ├── treeview_combo.py ├── vineyard_simplelist.py ├── stdout_buffer_exceed.py ├── base_parse_command.py ├── vineyard_widget.py ├── executable_get_program_name.py └── widget_overlay.py ├── .travis.yml ├── AUTHORS ├── snap └── snapcraft.yaml ├── wine ├── winetricks.py ├── __init__.py ├── windows.py ├── desktop.py └── appdb.py ├── README.md ├── rpm └── vineyard.spec ├── setup.py └── vineyard-daemon /debian/compat: -------------------------------------------------------------------------------- 1 | 7 2 | -------------------------------------------------------------------------------- /python-wine/debian/compat: -------------------------------------------------------------------------------- 1 | 7 2 | -------------------------------------------------------------------------------- /python-wine/debian/pycompat: -------------------------------------------------------------------------------- 1 | 2 2 | -------------------------------------------------------------------------------- /python-wine/debian/pyversions: -------------------------------------------------------------------------------- 1 | 2.4- 2 | -------------------------------------------------------------------------------- /data/icons/ie.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/icons/ie.png -------------------------------------------------------------------------------- /data/icons/gecko.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/icons/gecko.png -------------------------------------------------------------------------------- /data/icons/wmp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/icons/wmp.png -------------------------------------------------------------------------------- /data/icons/16/wcmd.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/icons/16/wcmd.png -------------------------------------------------------------------------------- /data/icons/48/wcmd.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/icons/48/wcmd.png -------------------------------------------------------------------------------- /data/icons/directx.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/icons/directx.png -------------------------------------------------------------------------------- /data/icons/firefox.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/icons/firefox.png -------------------------------------------------------------------------------- /data/icons/16/regedit.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/icons/16/regedit.png -------------------------------------------------------------------------------- /data/icons/16/taskmgr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/icons/16/taskmgr.png -------------------------------------------------------------------------------- /data/icons/22/regedit.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/icons/22/regedit.png -------------------------------------------------------------------------------- /data/icons/22/taskmgr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/icons/22/taskmgr.png -------------------------------------------------------------------------------- /data/icons/32/regedit.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/icons/32/regedit.png -------------------------------------------------------------------------------- /data/icons/32/taskmgr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/icons/32/taskmgr.png -------------------------------------------------------------------------------- /data/icons/48/regedit.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/icons/48/regedit.png -------------------------------------------------------------------------------- /data/icons/48/taskmgr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/icons/48/taskmgr.png -------------------------------------------------------------------------------- /data/icons/48/vineyard.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/icons/48/vineyard.png -------------------------------------------------------------------------------- /data/icons/48/folder-wine.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/icons/48/folder-wine.png -------------------------------------------------------------------------------- /data/vineyard-preferences.1.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/vineyard-preferences.1.gz -------------------------------------------------------------------------------- /python-wine/AUTHORS: -------------------------------------------------------------------------------- 1 | Christian Dannie Storgaard 2 | Other parts of code given credit in source. -------------------------------------------------------------------------------- /data/icons/48/vineyard-preferences.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/icons/48/vineyard-preferences.png -------------------------------------------------------------------------------- /data/locale/ar/LC_MESSAGES/vineyard.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/locale/ar/LC_MESSAGES/vineyard.mo -------------------------------------------------------------------------------- /data/locale/bg/LC_MESSAGES/vineyard.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/locale/bg/LC_MESSAGES/vineyard.mo -------------------------------------------------------------------------------- /data/locale/cs/LC_MESSAGES/vineyard.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/locale/cs/LC_MESSAGES/vineyard.mo -------------------------------------------------------------------------------- /data/locale/da/LC_MESSAGES/vineyard.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/locale/da/LC_MESSAGES/vineyard.mo -------------------------------------------------------------------------------- /data/locale/de/LC_MESSAGES/vineyard.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/locale/de/LC_MESSAGES/vineyard.mo -------------------------------------------------------------------------------- /data/locale/el/LC_MESSAGES/vineyard.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/locale/el/LC_MESSAGES/vineyard.mo -------------------------------------------------------------------------------- /data/locale/eo/LC_MESSAGES/vineyard.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/locale/eo/LC_MESSAGES/vineyard.mo -------------------------------------------------------------------------------- /data/locale/es/LC_MESSAGES/vineyard.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/locale/es/LC_MESSAGES/vineyard.mo -------------------------------------------------------------------------------- /data/locale/et/LC_MESSAGES/vineyard.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/locale/et/LC_MESSAGES/vineyard.mo -------------------------------------------------------------------------------- /data/locale/fr/LC_MESSAGES/vineyard.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/locale/fr/LC_MESSAGES/vineyard.mo -------------------------------------------------------------------------------- /data/locale/gl/LC_MESSAGES/vineyard.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/locale/gl/LC_MESSAGES/vineyard.mo -------------------------------------------------------------------------------- /data/locale/he/LC_MESSAGES/vineyard.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/locale/he/LC_MESSAGES/vineyard.mo -------------------------------------------------------------------------------- /data/locale/it/LC_MESSAGES/vineyard.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/locale/it/LC_MESSAGES/vineyard.mo -------------------------------------------------------------------------------- /data/locale/nl/LC_MESSAGES/vineyard.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/locale/nl/LC_MESSAGES/vineyard.mo -------------------------------------------------------------------------------- /data/locale/pl/LC_MESSAGES/vineyard.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/locale/pl/LC_MESSAGES/vineyard.mo -------------------------------------------------------------------------------- /data/locale/ro/LC_MESSAGES/vineyard.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/locale/ro/LC_MESSAGES/vineyard.mo -------------------------------------------------------------------------------- /data/locale/ru/LC_MESSAGES/vineyard.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/locale/ru/LC_MESSAGES/vineyard.mo -------------------------------------------------------------------------------- /data/locale/sk/LC_MESSAGES/vineyard.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/locale/sk/LC_MESSAGES/vineyard.mo -------------------------------------------------------------------------------- /data/locale/tr/LC_MESSAGES/vineyard.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/locale/tr/LC_MESSAGES/vineyard.mo -------------------------------------------------------------------------------- /data/locale/uk/LC_MESSAGES/vineyard.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/locale/uk/LC_MESSAGES/vineyard.mo -------------------------------------------------------------------------------- /data/locale/en_GB/LC_MESSAGES/vineyard.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/locale/en_GB/LC_MESSAGES/vineyard.mo -------------------------------------------------------------------------------- /data/locale/pt_BR/LC_MESSAGES/vineyard.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Vineyard/vineyard/HEAD/data/locale/pt_BR/LC_MESSAGES/vineyard.mo -------------------------------------------------------------------------------- /data/bin/unzip: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | PATH="${PATH/$(dirname "$0"):/}" 4 | 5 | # Update existing files only if newer and add files that don't already exist 6 | exec unzip -u "$@" -------------------------------------------------------------------------------- /tools/update_po.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | path="$(dirname "$0")/../" 3 | 4 | for i in "$path/po/"$1_*.po; do 5 | if [ -f $i ]; then 6 | msgmerge -U $i messages.pot 7 | fi 8 | done 9 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.*~ 2 | *.pyc 3 | *_old.* 4 | *.old.* 5 | test_widget_alpha.py 6 | test_widget_overlay.py 7 | test_winetricks_download.py 8 | python-wine/output.txt 9 | python-wine/print_to_stderr.sh 10 | indicator_example.py 11 | * (copy).svg 12 | -------------------------------------------------------------------------------- /python-wine/debian/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | %: 4 | dh $@ 5 | #!/usr/bin/make -f 6 | 7 | #DEB_PYTHON_SYSTEM=pycentral 8 | 9 | #include /usr/share/cdbs/1/rules/debhelper.mk 10 | #include /usr/share/cdbs/1/class/python-distutils.mk 11 | -------------------------------------------------------------------------------- /vineyard/widgets/__init__.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | # AUTHOR: 7 | # Christian Dannie Storgaard 8 | 9 | from widget import * 10 | -------------------------------------------------------------------------------- /python-wine/PACKAGING: -------------------------------------------------------------------------------- 1 | To package python-wine separately, move or copy the "wine" directory from the 2 | parent of this directory into the one this file is in. 3 | The setup.py script will now work. 4 | 5 | Also see the ../tools/package_python-wine.sh script. 6 | -------------------------------------------------------------------------------- /exe-helper/launchers/desktop.launcher: -------------------------------------------------------------------------------- 1 | [Launcher Entry] 2 | Argument=desktop 3 | Exec=%FILE% 4 | TextPermission=The application launcher "%PROGRAM%"\nrequires permission to run. 5 | TextPermission[da]=Programstarteren "%PROGRAM%"\nkræver tilladelse til at køre. 6 | -------------------------------------------------------------------------------- /data/vineyard-autostart.desktop: -------------------------------------------------------------------------------- 1 | [Desktop Entry] 2 | Name=Vineyard Autorun Prompt 3 | TryExec=vineyard-launcher 4 | Exec=vineyard-launcher %u 5 | Icon=vineyard 6 | NoDisplay=true 7 | Terminal=false 8 | StartupNotify=true 9 | Type=Application 10 | MimeType=x-content/software; -------------------------------------------------------------------------------- /data/vineyard-indicator.desktop: -------------------------------------------------------------------------------- 1 | [Desktop Entry] 2 | Name=Vineyard 3 | Comment=Vineyard Wine program indicator 4 | Comment[da]=Vineyards Wine-programindikator 5 | Icon=vineyard 6 | Exec=vineyard-indicator 7 | Terminal=false 8 | Type=Application 9 | OnlyShowIn=GNOME;XFCE; 10 | X-GNOME-Autostart-enabled=true 11 | -------------------------------------------------------------------------------- /debian/vineyard.doc-base: -------------------------------------------------------------------------------- 1 | Document: vineyard-doc 2 | Title: Vineyard Manual 3 | Author: Christian Dannie Storgaard 4 | Abstract: This manual describes what Vineyard is and how to use it. 5 | Section: System/Package Management 6 | 7 | Format: Mallard 8 | Index: /usr/share/vineyard/docs/index.page 9 | Files: /usr/share/vineyard/docs/*.page 10 | -------------------------------------------------------------------------------- /tools/update_mo.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | path="$(dirname "$0")/../" 3 | 4 | for i in "$path/po/"*.po; do 5 | language=$(basename $i | cut -d. -f1) 6 | if [ ! -d "$path/data/locale/$language" ]; then 7 | mkdir -p "$path/data/locale/$language/LC_MESSAGES" 8 | fi 9 | msgfmt $i -o "$path/data/locale/$language/LC_MESSAGES/vineyard.mo" 10 | done 11 | -------------------------------------------------------------------------------- /tests/winetricks_download.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | 3 | import gtk 4 | from vineyard import installer 5 | 6 | try: 7 | os.remove(os.expanduser('~/.winetrickscache/Xvid-1.2.2-07062009.exe')) 8 | os.remove(os.expanduser('~/.winetrickscache/divx-7/DivXInstaller.exe')) 9 | except: 10 | pass 11 | 12 | installer.Winetricks(['xvid', 'divx']) 13 | gtk.main() -------------------------------------------------------------------------------- /tools/update_pot.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | path="$(dirname "$0")/../" 3 | filename="$(basename "$1")" 4 | 5 | if [ -f "$path/data/$filename.glade" ]; then 6 | intltool-extract --type=gettext/glade "$path/data/$filename.glade" 7 | xgettext --from-code utf-8 -k_ -kN_ -o messages.pot "$path/$filename.py" "$path/data/$filename.glade.h" 8 | else 9 | xgettext --from-code utf-8 -k_ -kN_ -o messages.pot "$path/$filename.py" 10 | fi 11 | -------------------------------------------------------------------------------- /data/docs/index.page: -------------------------------------------------------------------------------- 1 | 4 | Vineyard Help 5 | 6 |
7 | Information 8 |
9 | 10 |
11 | Tasks 12 |
13 | 14 |
15 | Troubleshooting 16 |
17 |
18 | -------------------------------------------------------------------------------- /debian/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | #VERSION := $(shell head debian/changelog -n 1 | cut -d\( -f2 | cut -d\) -f1 | cut -d- -f1) 3 | 4 | #override_dh_auto_build: 5 | # pod2man --section=1 --release=$(VERSION) --center="Windows On Unix" debian/vineyard-preferences.pod > vineyard-#preferences.1 6 | 7 | #DEB_INSTALL_MANPAGES_vineyard = vineyard-preferences.1 8 | 9 | %: 10 | dh $@ 11 | 12 | override_dh_builddeb: 13 | dh_builddeb -- -z9 14 | -------------------------------------------------------------------------------- /data/appsupport/starcraft2.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # If install from CD 4 | sudo umount /media/SC2* 5 | sudo mkdir /media/cdrom 6 | sudo mount -t udf -o ro,unhide,uid=$(id -u) /dev/cdrom /media/cdrom 7 | 8 | INSTALL droid fontfix fontsmooth-rgb gdiplus gecko vcrun2008 vcrun2005 allfonts d3dx9 win7 9 | SET-OVERRIDE mmdevapi disabled 10 | SET-REGISTRY 'HKEY_CURRENT_USER\Software\Wine\Direct3D\UseGLSL' 'disabled' 11 | 12 | RUN 'D:\installer.exe' 13 | -------------------------------------------------------------------------------- /vineyard/gtkwidgets/__init__.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | # AUTHOR: 7 | # Christian Dannie Storgaard 8 | 9 | import os 10 | # Import the pages in this file's directory 11 | for page in os.listdir(os.path.dirname(__file__)): 12 | if page.endswith('.py') and page != '__init__.py': 13 | exec('from %s import *' % '.'.join(page.split('.')[:-1])) -------------------------------------------------------------------------------- /vineyard/pages/__init__.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | # AUTHOR: 7 | # Christian Dannie Storgaard 8 | 9 | import os 10 | # Import the pages in this file's directory 11 | for page in os.listdir(os.path.dirname(__file__)): 12 | if page.endswith('.py') and page != '__init__.py' and page != 'page.py': 13 | exec('import %s' % '.'.join(page.split('.')[:-1])) 14 | -------------------------------------------------------------------------------- /data/vineyard-launcher.desktop: -------------------------------------------------------------------------------- 1 | [Desktop Entry] 2 | Type=Application 3 | Name=Vineyard Wine Launcher 4 | Comment=Launch a Windows program with Wine using Vineyard 5 | Exec=vineyard-launcher %f 6 | MimeType=application/x-ms-dos-executable;application/x-msi;application/x-win-lnk;application/x-ms-shortcut;inode/directory; 7 | Icon=vineyard 8 | Terminal=false 9 | NoDisplay=true 10 | StartupNotify=true 11 | Name[da]=Vineyard Wine-starter 12 | Comment[da]=Start et Windows-program med Wine gennem Vineyard -------------------------------------------------------------------------------- /tools/package_manpage.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | dir="$(basename "$(readlink -f "$(dirname "$0")/../")")" 4 | path="$(readlink -f "$(dirname "$0")/../../")" 5 | 6 | version="$(head "$path/$dir/debian/changelog" -n 1 | cut -d\( -f2 | cut -d\) -f1)" 7 | sourceversion="$(echo $version | cut -d- -f1 | cut -d\~ -f1)" 8 | 9 | pod2man --section=1 --release=$sourceversion --center="Windows On Unix" "$path/$dir/data/vineyard-preferences.pod" > "$path/$dir/data/vineyard-preferences.1" 10 | gzip -9 "$path/$dir/data/vineyard-preferences.1" 11 | -------------------------------------------------------------------------------- /data/appsupport/dotnet35.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # First install previous versions of .NET 4 | # As suggested here: http://appdb.winehq.org/objectManager.php?sClass=version&iId=10166&iTestingId=25041 5 | INSTALL dotnet20 6 | INSTALL dotnet30 7 | 8 | # Download the installer 9 | # FIXME: Figure out best argument support 10 | DOWNLOAD_FROM_SITE 'http://DONT KNOW WHERE!' \ 11 | 'HTTP 1 and sys.argv[1] == 'vineyard': 10 | os.system('./vineyard-preferences --create-profile') 11 | else: 12 | import cProfile 13 | cProfile.run('import wine; wine.programs.list_from_registry()', '/tmp/python-wine-profile.tmp') 14 | import pstats 15 | p = pstats.Stats('/tmp/python-wine-profile.tmp') 16 | p.sort_stats('cumulative').print_stats() 17 | -------------------------------------------------------------------------------- /vineyard/widgets/menu_style.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import widget, wine 7 | 8 | class Widget(widget.VineyardWidgetCheckButton): 9 | def __init__(self): 10 | widget.VineyardWidgetCheckButton.__init__(self, 11 | title = _('Show new flat style menus'), 12 | settings_key = 'graphics-new-menu-style', 13 | get_function = wine.appearance.get_menu_style, 14 | set_function = wine.appearance.set_menu_style) -------------------------------------------------------------------------------- /vineyard/widgets/windows_decorated.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import widget, wine 7 | 8 | class Widget(widget.VineyardWidgetCheckButton): 9 | def __init__(self): 10 | widget.VineyardWidgetCheckButton.__init__(self, 11 | title = _('Show Linux window frames'), 12 | settings_key = 'windows-decorated', 13 | get_function = wine.windows.get_decorated, 14 | set_function = wine.windows.set_decorated) 15 | -------------------------------------------------------------------------------- /vineyard/widgets/files_show_hidden.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import widget, wine 7 | 8 | class Widget(widget.VineyardWidgetCheckButton): 9 | def __init__(self): 10 | widget.VineyardWidgetCheckButton.__init__(self, 11 | title = _('Display hidden files'), 12 | settings_key = 'files-show-hidden', 13 | get_function = wine.drives.get_show_dot_files, 14 | set_function = wine.drives.set_show_dot_files) 15 | -------------------------------------------------------------------------------- /vineyard/pages/libraries.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import page 7 | from vineyard.widgets import libraries_overrides 8 | 9 | id = 'libraries' 10 | position = 0.4 11 | 12 | class Page(page.VineyardPage): 13 | def __init__(self, dev=False): 14 | page.VineyardPage.__init__(self, 15 | name = _("Libraries"), 16 | icon = 'document-properties', 17 | widgets = [ 18 | libraries_overrides 19 | ]) 20 | -------------------------------------------------------------------------------- /vineyard/widgets/direct3d_pixelshader.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import widget, wine 7 | 8 | class Widget(widget.VineyardWidgetCheckButton): 9 | def __init__(self): 10 | widget.VineyardWidgetCheckButton.__init__(self, 11 | title = _('Enable hardware Pixel Shader support'), 12 | settings_key = 'direct3d-pixelshader', 13 | get_function = wine.graphics.get_pixel_shader, 14 | set_function = wine.graphics.set_pixel_shader) 15 | -------------------------------------------------------------------------------- /vineyard/widgets/font_antialias.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import widget, wine 7 | 8 | class Widget(widget.VineyardWidgetCheckButton): 9 | def __init__(self): 10 | widget.VineyardWidgetCheckButton.__init__(self, 11 | title = _('Smooth font edges (anti-alias)'), 12 | settings_key = 'graphics-font-antialias', 13 | get_function = wine.graphics.get_font_antialiasing, 14 | set_function = wine.graphics.set_font_antialiasing) 15 | -------------------------------------------------------------------------------- /vineyard/widgets/sound_directsound_emulation.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import widget, wine 7 | 8 | class Widget(widget.VineyardWidgetCheckButton): 9 | def __init__(self): 10 | widget.VineyardWidgetCheckButton.__init__(self, 11 | title = _('Use driver emulation'), 12 | settings_key = 'sound-directsound-emulation', 13 | get_function = wine.audio.get_driver_emulation, 14 | set_function = wine.audio.set_driver_emulation) 15 | -------------------------------------------------------------------------------- /vineyard/widgets/direct3d_vertexshader.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import widget, wine 7 | 8 | class Widget(widget.VineyardWidgetCheckButton): 9 | def __init__(self): 10 | widget.VineyardWidgetCheckButton.__init__(self, 11 | title = _('Enable hardware Vertex Shader support'), 12 | settings_key = 'direct3d-vertexshader', 13 | get_function = wine.graphics.get_vertex_shader, 14 | set_function = wine.graphics.set_vertex_shader) 15 | -------------------------------------------------------------------------------- /vineyard/widgets/directx_capture_mouse.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import widget, wine 7 | 8 | class Widget(widget.VineyardWidgetCheckButton): 9 | def __init__(self): 10 | widget.VineyardWidgetCheckButton.__init__(self, 11 | title = _('Allow DirectX programs to capture the mouse'), 12 | settings_key = 'directx-capture-mouse', 13 | get_function = wine.windows.get_mouse_grab, 14 | set_function = wine.windows.set_mouse_grab) 15 | -------------------------------------------------------------------------------- /python-wine/test_pe_reader.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | 5 | from wine import binary 6 | from pprint import pprint 7 | 8 | import os 9 | 10 | for i in os.listdir('/home/cybolic/Downloads'): 11 | if i.lower().endswith('.exe'): 12 | print "Getting icon from", i 13 | p = binary.windows_executable('/home/cybolic/Downloads/{0}'.format( 14 | i 15 | )) 16 | p.get_icon(output = '/tmp/TEST-'+i+'.ico') 17 | #p = binary.windows_executable('/home/cybolic/Downloads/derive_setup.exe') 18 | #pprint(p.read_resource_directory_table('.rsrc')) 19 | -------------------------------------------------------------------------------- /vineyard/pages/install.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import page 7 | from vineyard.widgets import installers 8 | 9 | id = 'install' 10 | position = 0.99 11 | 12 | class Page(page.VineyardPage): 13 | def __init__(self, dev=False): 14 | self.no_loading = True 15 | page.VineyardPage.__init__(self, 16 | name = _("Install"), 17 | icon = ['system-software-install', 'system-software-installer', 'system-software-update'], 18 | widgets = [ 19 | installers 20 | ]) 21 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | language: python 2 | python: 3 | - 2.7 4 | script: python setup.py install 5 | deploy: 6 | provider: launchpad 7 | slug: "~cybolic/vineyard/+git/main" 8 | oauth_token: 9 | secure: DAyRBXAEqegxUk1KRn3xtRjpeyiK9+4feZLXJUaWO4VsHw4Qm83Esa3r159EIjKjNXM8lw+VAq0SlnCk8ojr7gGOb2T9ORzkOTtkoJav/5P2jFbfadHU/Zj8fFaFiw8uk3srJeMkTBCvYw/p+S4q29e7hgFDRz+GF3c4xlOVlAQ= 10 | oauth_token_secret: 11 | secure: Mw/W5aIXDpL/KDa8+iOHk7SMbCdXUOtNAdwTWndLKBxkB+zsPGifYOE987xi9j+B6377DPUnkC1NlzHYnGQOVex19ZQGJcjqzlcKrwpT7VRlUcw06M4wAZvNLCXatOTDIya9E+TNCap1VRGvcNXN0fybL80Mq9V5GHGsNdk062Q= 12 | skip_cleanup: false 13 | on: 14 | tags: true 15 | -------------------------------------------------------------------------------- /data/appsupport/torchlight.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # Create configuration and install support libraries 4 | CREATE_CONFIGURATION 'Torchlight' 5 | INSTALL'dcom98 vcrun2008 mono24' 6 | 7 | # Install the game 8 | WINE 'CDROM:\Torchlight_Setup.exe' 9 | 10 | # Setup the screen resolution 11 | echo "VINEYARD INFO: Please select an appropriate game resolution and select ok.\nNote that the game will exit at that point, this is normal." 12 | WINE 'C:\{Program Files}\Runic Games\Torchlight\Torchlight.exe' SAFEMODE=1 13 | SET_VIRTUAL_DESKTOP --text "Now select the same resolution:" 14 | 15 | # Run the game 16 | WINE 'C:\{Program Files}\Runic Games\Torchlight\Torchlight.exe' 17 | -------------------------------------------------------------------------------- /tools/check_using_pychecker.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | if [ -z "$(which pychecker)" ]; then 4 | echo -e "PyChecker doesn't seem to be installed.\nYou can download it from http://pychecker.sourceforge.net/" 5 | exit 1 6 | fi 7 | 8 | path="$(readlink -f "$(dirname "$0")/../")" 9 | 10 | # pychecker needs a .py ending, so we create a symlink 11 | ln -s "$path/vineyard-preferences" "$path/vineyard-preferences.py" 12 | 13 | # run pychecker with the local data dir in the module search path 14 | env PYTHONPATH="$path:$path/data:$PYTHONPATH" pychecker -q --limit 15 "$path/vineyard-preferences.py" 15 | 16 | # we're done, remove the symlink 17 | rm "$path/vineyard-preferences.py*" 18 | -------------------------------------------------------------------------------- /tests/executable_link.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | from __future__ import print_function 5 | 6 | import sys, os 7 | 8 | sys.path.insert(0, os.path.normpath( 9 | os.path.abspath(os.path.dirname(sys.argv[0]))+'/../' 10 | )) 11 | import vineyard 12 | 13 | SHARED_FILES_PATH = vineyard.get_shared_files_path() 14 | 15 | import wine 16 | 17 | if len(sys.argv) > 1: 18 | import pprint 19 | for lnk in sys.argv[1:]: 20 | print("{lnk}:\n\t{info}\n".format( 21 | lnk = lnk, 22 | info = pprint.pformat(wine.binary.windows_link(lnk)) 23 | )) 24 | else: 25 | print("No path to .lnk file given.") 26 | exit(1) 27 | 28 | -------------------------------------------------------------------------------- /vineyard/__init__.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | 7 | import crashhandler 8 | import async 9 | from common import * 10 | import subprocess 11 | 12 | SHARED_FILES_PATH = get_shared_files_path() 13 | 14 | import wine 15 | import widgets 16 | import pages as _pages 17 | from gtkwidgets import * 18 | 19 | pages = [ 20 | i for i in 21 | [ eval('_pages.%s' % i) for i in dir(_pages) if not i.startswith('_') ] 22 | if 'id' in dir(i) 23 | ] 24 | 25 | #SimpleList = simplelist.SimpleList 26 | 27 | def open_help(): 28 | subprocess.Popen(['yelp', '%s/docs' % SHARED_FILES_PATH], stdout=subprocess.PIPE, stderr=subprocess.PIPE) 29 | -------------------------------------------------------------------------------- /data/appsupport/klitemega.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # Download the installer 4 | # FIXME: Figure out best argument support 5 | DOWNLOAD_FROM_SITE 'http://www.codecguide.com/download_k-lite_codec_pack_mega.htm' \ 6 | 'HTTP 4 | 5 | 6 | 7 | 8 | Christian Dannie Storgaard 9 | cybolic@gmail.com 10 | 2010 11 | 12 | 13 | How to create a shortcut or a launcher for a program 14 | 15 | Creating a shortcut or launcher for a program 16 |

17 | To add a launcher or shortcut on your desktop or desktop panel open Wine Preferences (SystemPreferencesWine Preferences), select the Programs page and simply drag the desired program to where you want the shortcut. 18 |

19 | 20 | -------------------------------------------------------------------------------- /tests/executable_get_icon.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | from __future__ import print_function 5 | 6 | import sys, os 7 | 8 | sys.path.insert(0, os.path.normpath( 9 | os.path.abspath(os.path.dirname(sys.argv[0]))+'/../' 10 | )) 11 | import vineyard 12 | 13 | SHARED_FILES_PATH = vineyard.get_shared_files_path() 14 | 15 | import wine 16 | 17 | if len(sys.argv) > 1: 18 | exe = wine.binary.windows_executable(sys.argv[1]) 19 | icon = exe.get_icon() 20 | if not icon is None: 21 | with open('{0}/wine_test_executable_icon'.format(common.ENV['VINEYARDTMP']), 'w') as _file: 22 | _file.write(icon) 23 | os.system('display {0}/wine_test_executable_icon'.format(common.ENV['VINEYARDTMP'])) 24 | else: 25 | print(exe.read_resource_directory_table()) 26 | else: 27 | print("No file path given.") 28 | exit(1) 29 | 30 | -------------------------------------------------------------------------------- /vineyard/widgets/tool_command_prompt.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import gtk, widget, wine 7 | from vineyard import common 8 | 9 | class Widget(widget.VineyardWidget): 10 | def __init__(self): 11 | widget.VineyardWidget.__init__(self) 12 | self.title = _('Command Prompt') 13 | self.icon = 'wcmd' 14 | self._build_interface() 15 | 16 | def _build_interface(self): 17 | self.button = common.button_new_with_image(self.icon, label=self.title, use_underline=False) 18 | self.pack_start(self.button) 19 | self.show_all() 20 | 21 | self.button.connect('clicked', self.button_clicked) 22 | 23 | def button_clicked(self, button): 24 | if self.gobject.loading: return False 25 | 26 | wine.run('cmd') 27 | -------------------------------------------------------------------------------- /vineyard/widgets/tool_registry_editor.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import gtk, widget, wine 7 | from vineyard import common 8 | 9 | class Widget(widget.VineyardWidget): 10 | def __init__(self): 11 | widget.VineyardWidget.__init__(self) 12 | self.title = _('Registry Editor') 13 | self.icon = 'regedit' 14 | self._build_interface() 15 | 16 | def _build_interface(self): 17 | self.button = common.button_new_with_image(self.icon, label=self.title, use_underline=False) 18 | self.pack_start(self.button) 19 | self.show_all() 20 | 21 | self.button.connect('clicked', self.button_clicked) 22 | 23 | def button_clicked(self, button): 24 | if self.gobject.loading: return False 25 | 26 | wine.run('regedit') 27 | -------------------------------------------------------------------------------- /vineyard/widgets/tool_control_panel.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import gtk, widget, wine 7 | from vineyard import common 8 | 9 | class Widget(widget.VineyardWidget): 10 | def __init__(self): 11 | widget.VineyardWidget.__init__(self) 12 | self.title = _('Control Panel') 13 | self.icon = 'preferences-system' 14 | self._build_interface() 15 | 16 | def _build_interface(self): 17 | self.button = common.button_new_with_image(self.icon, label=self.title, use_underline=False) 18 | self.pack_start(self.button) 19 | self.show_all() 20 | 21 | self.button.connect('clicked', self.button_clicked) 22 | 23 | def button_clicked(self, button): 24 | if self.gobject.loading: return False 25 | 26 | wine.run('control') 27 | -------------------------------------------------------------------------------- /data/docs/whatisvineyard.page: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | 7 | 8 | Christian Dannie Storgaard 9 | cybolic@gmail.com 10 | 2010 11 | 12 | 13 | 0 14 | What is Vineyard - or why isn't this called Wine Preferences? 15 | 16 | What is Vineyard? 17 |

18 | Vineyard is a collection of tools for configuring and using Wine (http://winehq.org). 19 | At the core there is python-wine, the library that does all the hard work. 20 | On top of this there is nautilus-wine, which provide the integration with the Gnome file manager, and Wine Preferences that is a multi-configuration (~bottles) Wine configuration tool that includes program management. 21 |

22 |
23 | -------------------------------------------------------------------------------- /vineyard/pages/places.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import page 7 | from vineyard.widgets import drives 8 | from vineyard.widgets import folder_desktop, folder_documents, folder_pictures, folder_music, folder_videos 9 | 10 | id = 'places' 11 | position = 0.2 12 | 13 | class Page(page.VineyardPage): 14 | def __init__(self, dev=False): 15 | page.VineyardPage.__init__(self, 16 | name = _("Places"), 17 | icon = 'folder', 18 | pages = [ 19 | (_('Drives'), [ 20 | drives 21 | ]), 22 | (_('Folders'), [ 23 | folder_desktop, 24 | folder_documents, 25 | folder_pictures, 26 | folder_music, 27 | folder_videos 28 | ]) 29 | ]) 30 | -------------------------------------------------------------------------------- /vineyard/widgets/tool_reboot.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import gtk, widget, wine 7 | from vineyard import common 8 | 9 | class Widget(widget.VineyardWidget): 10 | def __init__(self): 11 | widget.VineyardWidget.__init__(self) 12 | self.title = _('Simulate Reboot') 13 | self.icon = 'view-refresh' 14 | self.widget_should_expand = True 15 | self._build_interface() 16 | 17 | def _build_interface(self): 18 | self.button = common.button_new_with_image(self.icon, label=self.title, use_underline=False) 19 | self.pack_start(self.button) 20 | self.show_all() 21 | 22 | self.button.connect('clicked', self.button_clicked) 23 | 24 | def button_clicked(self, button): 25 | if self.gobject.loading: return False 26 | 27 | wine.prefixes.reboot() 28 | -------------------------------------------------------------------------------- /vineyard/widgets/tool_programs_kill.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import gtk, widget, wine 7 | from vineyard import common 8 | 9 | class Widget(widget.VineyardWidget): 10 | def __init__(self): 11 | widget.VineyardWidget.__init__(self) 12 | self.title = _('Kill all programs') 13 | self.icon = 'edit-delete' 14 | self.widget_should_expand = True 15 | self._build_interface() 16 | 17 | def _build_interface(self): 18 | self.button = common.button_new_with_image(self.icon, label=self.title, use_underline=False) 19 | self.pack_start(self.button) 20 | self.show_all() 21 | 22 | self.button.connect('clicked', self.button_clicked) 23 | 24 | def button_clicked(self, button): 25 | if self.gobject.loading: return False 26 | 27 | wine.prefixes.kill() 28 | -------------------------------------------------------------------------------- /vineyard/widgets/tool_shutdown.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import gtk, widget, wine 7 | from vineyard import common 8 | 9 | class Widget(widget.VineyardWidget): 10 | def __init__(self): 11 | widget.VineyardWidget.__init__(self) 12 | self.title = _('Simulate Shutdown') 13 | self.icon = 'application-exit' 14 | self.widget_should_expand = True 15 | self._build_interface() 16 | 17 | def _build_interface(self): 18 | self.button = common.button_new_with_image(self.icon, label=self.title, use_underline=False) 19 | self.pack_start(self.button) 20 | self.show_all() 21 | 22 | self.button.connect('clicked', self.button_clicked) 23 | 24 | def button_clicked(self, button): 25 | if self.gobject.loading: return False 26 | 27 | wine.prefixes.shutdown() 28 | -------------------------------------------------------------------------------- /vineyard/widgets/folder_music.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import widget, wine, gtk 7 | 8 | class Widget(widget.VineyardWidgetFileChooserButton): 9 | def __init__(self): 10 | widget.VineyardWidgetFileChooserButton.__init__(self, 11 | title = '%s: ' % _('My Music'), 12 | settings_key = 'shellfolder-music', 13 | get_function = self._get_function, 14 | set_function = self._set_function, 15 | mode=gtk.FILE_CHOOSER_ACTION_SELECT_FOLDER) 16 | self.foldername = 'My Music' 17 | 18 | def _get_function(self): 19 | folder = wine.shellfolders.get(self.foldername) 20 | if folder == None: 21 | return wine.util.get_real_home() 22 | return folder 23 | 24 | def _set_function(self, value): 25 | return wine.shellfolders.set(self.foldername, value) 26 | -------------------------------------------------------------------------------- /vineyard/widgets/tool_programs_end.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import gtk, widget, wine 7 | from vineyard import common 8 | 9 | class Widget(widget.VineyardWidget): 10 | def __init__(self): 11 | widget.VineyardWidget.__init__(self) 12 | self.title = _('Close all programs') 13 | self.icon = 'window-close' 14 | self.widget_should_expand = True 15 | self._build_interface() 16 | 17 | def _build_interface(self): 18 | self.button = common.button_new_with_image(self.icon, label=self.title, use_underline=False) 19 | self.pack_start(self.button) 20 | self.show_all() 21 | 22 | self.button.connect('clicked', self.button_clicked) 23 | 24 | def button_clicked(self, button): 25 | if self.gobject.loading: return False 26 | 27 | wine.prefixes.end_session() 28 | -------------------------------------------------------------------------------- /vineyard/widgets/folder_desktop.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import widget, wine, gtk 7 | 8 | class Widget(widget.VineyardWidgetFileChooserButton): 9 | def __init__(self): 10 | widget.VineyardWidgetFileChooserButton.__init__(self, 11 | title = '%s: ' % _('Desktop'), 12 | settings_key = 'shellfolder-desktop', 13 | get_function = self._get_function, 14 | set_function = self._set_function, 15 | mode=gtk.FILE_CHOOSER_ACTION_SELECT_FOLDER) 16 | self.foldername = 'Desktop' 17 | 18 | def _get_function(self): 19 | folder = wine.shellfolders.get(self.foldername) 20 | if folder == None: 21 | return wine.util.get_real_home() 22 | return folder 23 | 24 | def _set_function(self, value): 25 | return wine.shellfolders.set(self.foldername, value) 26 | -------------------------------------------------------------------------------- /vineyard/widgets/folder_videos.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import widget, wine, gtk 7 | 8 | class Widget(widget.VineyardWidgetFileChooserButton): 9 | def __init__(self): 10 | widget.VineyardWidgetFileChooserButton.__init__(self, 11 | title = '%s: ' % _('My Videos'), 12 | settings_key = 'shellfolder-videos', 13 | get_function = self._get_function, 14 | set_function = self._set_function, 15 | mode=gtk.FILE_CHOOSER_ACTION_SELECT_FOLDER) 16 | self.foldername = 'My Videos' 17 | 18 | def _get_function(self): 19 | folder = wine.shellfolders.get(self.foldername) 20 | if folder == None: 21 | return wine.util.get_real_home() 22 | return folder 23 | 24 | def _set_function(self, value): 25 | return wine.shellfolders.set(self.foldername, value) 26 | -------------------------------------------------------------------------------- /data/appsupport/avp3.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # Create configuration and install support libraries 4 | CREATE_CONFIGURATION 'Alien vs. Predator 3' 5 | RUN 'winetricks d3dx9 d3dx10 physx vcrun2005' 6 | 7 | # Install the game 8 | WINE 'CDROM:\install.exe' 9 | 10 | # Stop running dxdllreg.exe on startup (it doesn't work anyway, and doesn't seem to be needed) 11 | SET_REGISTRY 'HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\dxregsvc' 'Start' 'dword:00000003' 12 | 13 | # Find and run the game 14 | if [ -f $(WIN_TO_UNIX 'C:\%ProgramFiles%\Aliens vs. Predator\AvP.exe') ]; then 15 | WINE 'C:\%ProgramFiles%\Aliens vs. Predator\AvP.exe' 16 | elif [ -f $(WIN_TO_UNIX 'C:\~\Aliens vs. Predator\AvP.exe') ]; then 17 | WINE 'C:\~\Aliens vs. Predator\AvP.exe' 18 | else 19 | cat < 4 | 5 | 6 | 7 | 8 | Christian Dannie Storgaard 9 | cybolic@gmail.com 10 | 2010 11 | 12 | 13 | How to run shell commands for Vineyard configurations. 14 | 15 | Running shell commands 16 |

If you want to run a shell command that should operate on the default Wine configuration, you can safely run it as normally, but if you want the command(s) to operate on a configuration, you should select the configuration in Wine Preferences (SystemPreferencesWine Preferences), open a terminal from the Tools page by clicking Open a Terminal in this Configuration and run the commands from there. 17 |

18 | 19 | -------------------------------------------------------------------------------- /python-wine/debian/control: -------------------------------------------------------------------------------- 1 | Source: python-wine 2 | Section: python 3 | Priority: optional 4 | Maintainer: Christian Dannie Storgaard 5 | Build-Depends: debhelper (>= 7), python-support 6 | XS-Python-Version: >= 2.4 7 | Standards-Version: 3.9.1 8 | Vcs-Bzr: lp:vineyard 9 | Vcs-Browser: https://code.launchpad.net/~ubuntu-wine/vineyard/trunk 10 | Homepage: https://launchpad.net/vineyard 11 | 12 | Package: python-wine 13 | Architecture: all 14 | Depends: wine, icoutils, cabextract, unzip, ${misc:Depends}, ${python:Depends} 15 | XB-Python-Version: ${python:Versions} 16 | Description: Configure and use Wine through Python 17 | python-wine is a module that let's you run and configure Windows program run 18 | by Wine directly from Python. 19 | . 20 | It has support for all that winecfg can do (except themes) and also includes 21 | advanced functions like retrieving icons based on registry, XDG menu 22 | information and program information based on an executable's metadata. 23 | -------------------------------------------------------------------------------- /vineyard/menus.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | # AUTHOR: 7 | # Christian Dannie Storgaard 8 | 9 | import xdg.Menu 10 | import xdg.DesktopEntry 11 | 12 | def get_menu(path = None, deep = True): 13 | menu = xdg.Menu.parse() 14 | 15 | if path == None: 16 | return get_menu_entries(menu) 17 | else: 18 | for entry in menu.getEntries(): 19 | if isinstance(entry, xdg.Menu.Menu) and entry.getPath() == path: 20 | return get_menu_entries(entry) 21 | 22 | def get_menu_entries(menu_obj): 23 | ret_dict = {} 24 | for entry in menu_obj.getEntries(): 25 | if isinstance(entry, xdg.Menu.Menu): 26 | ret_dict[menu_obj.getPath()] = get_menu_entries(entry) 27 | elif isinstance(entry, xdg.Menu.MenuEntry): 28 | ret_dict[entry.DesktopFileID] = entry 29 | return ret_dict 30 | 31 | show_menu(xdg.Menu.parse()) 32 | -------------------------------------------------------------------------------- /vineyard/widgets/graphics_xrandr.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import widget, wine 7 | 8 | class Widget(widget.VineyardWidgetCheckButton): 9 | def __init__(self): 10 | widget.VineyardWidgetCheckButton.__init__(self, 11 | title = _('Allow switching resolution using XRandR'), 12 | settings_key = 'direct3d-antialiasing', 13 | get_function = self._get_function, 14 | set_function = self._set_function) 15 | self.set_tooltip_text(_( 16 | "Allow using the XRandR extension to change screen resolution." + 17 | "\n\n" + 18 | "If you see a lot of errors with \"X11DRV_XRandR_SetCurrentMode\" try disabling this." 19 | )) 20 | 21 | def _get_function(self): 22 | return wine.graphics.get_allow_xrandr() 23 | 24 | def _set_function(self, value): 25 | return wine.graphics.set_allow_xrandr(value) 26 | -------------------------------------------------------------------------------- /vineyard/widgets/direct3d_antialiasing.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import widget, wine 7 | 8 | class Widget(widget.VineyardWidgetCheckButton): 9 | def __init__(self): 10 | widget.VineyardWidgetCheckButton.__init__(self, 11 | title = _('Allow font antialiasing'), 12 | settings_key = 'direct3d-antialiasing', 13 | get_function = self._get_function, 14 | set_function = self._set_function) 15 | self.set_tooltip_text(_( 16 | "Enable or disable smooth edges on fonts." + 17 | "\n\n" + 18 | "Disabling this will force all programs to not use font anti-aliasing, " + 19 | "even if they ask for it." 20 | )) 21 | 22 | def _get_function(self): 23 | return not wine.graphics.get_antialiasing_disabled() 24 | 25 | def _set_function(self, value): 26 | return wine.graphics.set_antialiasing_disabled(not value) 27 | -------------------------------------------------------------------------------- /vineyard/widgets/tool_open_terminal.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import gtk, widget, wine 7 | from vineyard import common 8 | 9 | class Widget(widget.VineyardWidget): 10 | def __init__(self): 11 | widget.VineyardWidget.__init__(self) 12 | self.title = _('Open a Terminal in this Configuration') 13 | self.icon = 'terminal' 14 | self._build_interface() 15 | 16 | def _build_interface(self): 17 | self.button = common.button_new_with_image(self.icon, label=self.title, use_underline=False) 18 | self.pack_start(self.button) 19 | self.show_all() 20 | 21 | self.button.connect('clicked', self.button_clicked) 22 | 23 | def button_clicked(self, button): 24 | if self.gobject.loading: return False 25 | 26 | conf_name = wine.prefixes.get_name() 27 | if conf_name == None: 28 | conf_name = _('Default') 29 | wine.util.open_terminal(configuration_name=conf_name) 30 | -------------------------------------------------------------------------------- /tests/vineyard_simplelist.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | 7 | import gtk 8 | import vineyard 9 | 10 | def on_toggled(simplelist, row, column_nr, content): 11 | print simplelist, row, column_nr, content 12 | 13 | def on_changed(simplelist, row, column_nr, content): 14 | print simplelist, row, column_nr, content 15 | 16 | win = gtk.Window() 17 | 18 | simplelist = vineyard.SimpleList( 19 | headers = ["Pixbuf", "Str", "State", "Combo2", "Active"], 20 | types = [int, gtk.gdk.Pixbuf, str, list, list, bool], 21 | combos = [["On", "Off"], ["Yo", "World"]] 22 | ) 23 | simplelist.fill([ 24 | [2, 'vineyard-panel-idle', 'Hi!', [0], [0], True], 25 | [4, 'vineyard', "World!", [1], [1], False] 26 | ]) 27 | simplelist.connect('toggled', on_toggled) 28 | simplelist.connect('changed', on_toggled) 29 | 30 | win.add(simplelist) 31 | 32 | win.set_size_request(640, 300) 33 | win.show_all() 34 | 35 | win.connect('destroy', lambda *args: gtk.main_quit()) 36 | 37 | gtk.main() -------------------------------------------------------------------------------- /AUTHORS: -------------------------------------------------------------------------------- 1 | Design, programming and original icons by: 2 | Christian Dannie Storgaard 3 | 4 | Various utility functions by (or based on work by): 5 | Endolith / KillerKiwi / Johannes Roith (Gtk/Gnome colour scraper) 6 | Sébastien Keim (bitfield manipulator) 7 | Simon Vermeersch (DBus example code) 8 | 9 | Monochrome indicator icon by: 10 | Connor Carney 11 | 12 | Icons modified for better view in different sizes and original regedit icon by: 13 | Joel Holdsworth 14 | 15 | For translation credits please see Vineyard's Launchpad page: 16 | https://translations.launchpad.net/vineyard 17 | 18 | Translation corrections by: 19 | Tom Jansen (Dutch) 20 | 21 | Other icons are by the Tango Project and/or the Wine-Doors Project. 22 | 23 | Parts of Vineyard were inspired by ideas posted by Scott Ritchie at: 24 | https://wiki.ubuntu.com/karmic-wine-integration 25 | 26 | BeautifulSoup is created and copyrighted by Leonard Richardson, more info at: 27 | http://www.crummy.com/software/BeautifulSoup/ 28 | -------------------------------------------------------------------------------- /data/docs/problemwinetricks.page: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | 7 | 8 | Christian Dannie Storgaard 9 | cybolic@gmail.com 10 | 2010 11 | 12 | 13 | How to get Winetricks to work with Vineyard configurations. 14 | 15 | Help with Winetricks 16 |

Winetricks doesn't know about Vineyards configurations and will try to operate on the default Wine configuration.

17 |

To make Winetricks function with Vineyard configurations, open a terminal from the Tools page in Wine Preferences (SystemPreferencesWine Preferences) by clicking Open a Terminal in this Configuration. You can now run Winetricks in this terminal and have it operate on the correct configuration. Note that other commands will work on the configuration as well, not only Winetricks. 18 |

19 |
20 | -------------------------------------------------------------------------------- /vineyard/pages/general.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import page 7 | from vineyard.widgets import configuration_name, version, files_show_hidden, wine_arch, wine_binary, wine_loader, wine_server 8 | 9 | id = 'general' 10 | position = 0.0 11 | 12 | class Page(page.VineyardPage): 13 | def __init__(self, dev=False): 14 | page.VineyardPage.__init__(self, 15 | name = _("General"), 16 | icon = 'computer', 17 | widgets = [ 18 | (_('Configuration Settings'), [ 19 | configuration_name 20 | ]), 21 | (_('Windows Version'), [ 22 | version 23 | ]), 24 | (_('Hidden Files'), [ 25 | files_show_hidden 26 | ]), 27 | (_('Wine Environment'), [ 28 | wine_arch, 29 | wine_binary, 30 | wine_loader, 31 | wine_server 32 | ]) 33 | ]) 34 | -------------------------------------------------------------------------------- /python-wine/README: -------------------------------------------------------------------------------- 1 | python-wine allows you to configure Wine through Python. 2 | 3 | For example, to set the default version of Windows to emulate, you can call: 4 | wine.version.set('win2k') 5 | or to set the default version for a program, you could call: 6 | wine.version.set('win2k', 'notepad.exe') 7 | 8 | python-wine also contains functions for more advanced usage, like getting icons 9 | for programs. An example could be: 10 | wine.programs.list()['WinRAR archiver']['programicon'] 11 | python-wine will scan both the Windows registry and the XDG menu paths for 12 | information and cross-reference it for you. 13 | 14 | With the exception of theme support, python-wine supports everything that 15 | winecfg does and tries to do its operations in a compatible way. 16 | 17 | The library has been developed for use in Vineyard available at 18 | https://launchpad.net/vineyard but will work just fine for other uses. 19 | 20 | At the moment there is no documentation, but the library should be fairly 21 | intuitive to use, and if not, feel free to contact me at 22 | 23 | - Christian Dannie Storgaard - 2010 24 | -------------------------------------------------------------------------------- /debian/control: -------------------------------------------------------------------------------- 1 | Source: vineyard 2 | Section: misc 3 | Priority: optional 4 | Maintainer: Christian Dannie Storgaard 5 | Build-Depends: debhelper (>= 7), python (>= 2.4), dh-python | python-support, perl 6 | X-Python-Version: >= 2.4 7 | Standards-Version: 3.9.6 8 | Vcs-Bzr: lp:vineyard 9 | Vcs-Git: https://github.com/Cybolic/vineyard.git 10 | Vcs-Browser: https://github.com/Cybolic/vineyard 11 | Homepage: http://vineyardproject.org 12 | 13 | Package: vineyard 14 | Architecture: all 15 | Depends: wine | wine-staging, icoutils, cabextract, winetricks, unzip, python (>= 2.4), python-glade2, python-dbus, python-appindicator, ${misc:Depends} 16 | Provides: wine-preferences, nautilus-wine, python-wine 17 | Replaces: wine-preferences, nautilus-wine, python-wine 18 | X-Python-Version: >= 2.4 19 | Description: Easy to use Wine configuration program 20 | Vineyard is a user friendly configuration tool for Wine that offers all the 21 | features of winecfg (with the exception of the unfinished theme-support) as 22 | well as prefix-handling and program-management in an easy to use program 23 | designed to blend in with the GNOME desktop. 24 | -------------------------------------------------------------------------------- /vineyard/widgets/tool_open_main_drive.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import gtk, widget, wine 7 | from vineyard import common 8 | 9 | class Widget(widget.VineyardWidget): 10 | def __init__(self): 11 | widget.VineyardWidget.__init__(self) 12 | self.title = _('Open Main Drive') 13 | self.icon = 'folder' 14 | self._build_interface() 15 | 16 | def _build_interface(self): 17 | self.button = common.button_new_with_image(self.icon, label=self.title, use_underline=False) 18 | self.pack_start(self.button) 19 | self.show_all() 20 | 21 | self.button.connect('clicked', self.button_clicked) 22 | 23 | def button_clicked(self, button): 24 | if self.gobject.loading: return False 25 | 26 | # Open the mapped dir of the first (in alphabetical order) drive 27 | try: 28 | mapping = wine.drives.get_main_drive(use_registry=False)['mapping'] 29 | wine.util.run_command(["xdg-open", mapping]) 30 | except: 31 | return False 32 | -------------------------------------------------------------------------------- /tests/stdout_buffer_exceed.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | 5 | test = 2 6 | 7 | if test == 0: 8 | 9 | from subprocess import Popen, PIPE 10 | 11 | p1 = Popen(["grep", "-v", "not"], stdin=PIPE, stdout=PIPE) # bufsize does not change the outcome 12 | #p2 = Popen(["cut", "-c", "1-10"], stdin=p1.stdout, stdout=PIPE, close_fds=True) 13 | p1.stdin.write('Hello World\n' * 20000) 14 | p1.stdin.close() 15 | p1.poll() 16 | #result = p2.stdout.read() 17 | print "Got the output, buffer not exceeded." 18 | 19 | elif test == 1: 20 | 21 | import pexpect 22 | 23 | p1 = pexpect.spawn('grep -v not', maxread=1) 24 | p1.send('Hello World\n' * 10000) 25 | print "Is alive:", p1.isalive() 26 | 27 | elif test == 2: 28 | 29 | from subprocess import Popen, PIPE 30 | 31 | p = Popen(["python", '-c', 'import sys; sys.stdout.write(\'Hello World\\n\'* 200000)'], stdin=PIPE, stdout=PIPE) 32 | print p.poll() 33 | o,e = p.communicate() 34 | print "Got the output, buffer not exceeded." 35 | 36 | else: 37 | 38 | import sys 39 | sys.stdout.write('Hello World\n' * 20000) 40 | -------------------------------------------------------------------------------- /vineyard/widgets/direct3d_allow_multisampling.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import widget, wine 7 | 8 | class Widget(widget.VineyardWidgetCheckButton): 9 | def __init__(self): 10 | widget.VineyardWidgetCheckButton.__init__(self, 11 | title = _('Allow multisample anti-alias'), 12 | settings_key = 'direct3d-allow-multisampling', 13 | get_function = wine.graphics.get_allow_multisampling, 14 | set_function = wine.graphics.set_allow_multisampling) 15 | self.set_tooltip_text(_( 16 | "Multisample anti-aliasing (MSAA) is technique for doing full-screen anti-aliasing." + 17 | "\n\n" + 18 | "Some graphic drivers exhibit issues when this is enabled (mostly NVIDIA), " + 19 | "and there are known issues with using it together with the frame buffer " + 20 | "offscreen renderer, " + 21 | "for this reason this setting is disabled by default." + 22 | "\n\n" + 23 | "If this setting is enabled and you get GLXBadDrawable errors, try disabling it." 24 | )) 25 | 26 | -------------------------------------------------------------------------------- /vineyard/widgets/configuration_name.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import widget, wine, os 7 | 8 | class Widget(widget.VineyardWidgetEntry): 9 | def __init__(self): 10 | widget.VineyardWidgetEntry.__init__(self, 11 | title = '%s:' % _('Name'), 12 | settings_key = 'configuration-name', 13 | get_function = self.get_name, 14 | set_function = wine.prefixes.set_name, 15 | hidden_on_load = True) 16 | 17 | def get_name(self): 18 | prefix = wine.common.ENV['WINEPREFIX'] 19 | if os.path.expanduser(prefix) == os.path.expanduser('~/.wine'): 20 | name = None 21 | else: 22 | name = wine.common.ENV['WINEPREFIXNAME'] 23 | 24 | self.settings[self.settings_key] = name 25 | return name 26 | 27 | def fill_widgets(self): 28 | if self.settings[self.settings_key] is None: 29 | self.hide() 30 | else: 31 | self.entry.set_text(self.settings[self.settings_key]) 32 | self.show() 33 | self.gobject.emit('settings-loaded', self.settings_key, (self.settings[self.settings_key],)) 34 | -------------------------------------------------------------------------------- /vineyard/pages/appearance.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import page 7 | from vineyard.widgets import virtual_desktop, menu_style 8 | from vineyard.widgets import windows_decorated, windows_managed, font_antialias 9 | from vineyard.widgets import themes 10 | 11 | id = 'appearance' 12 | position = 0.1 13 | 14 | class Page(page.VineyardPage): 15 | def __init__(self, dev=False): 16 | page.VineyardPage.__init__(self, 17 | name = _("Appearance"), 18 | icon = ['preferences-theme', 'preferences-desktop-theme'], 19 | pages = [ 20 | (_('Windows'), [ 21 | (_('Appearance'), [ 22 | windows_decorated, 23 | windows_managed, 24 | font_antialias, 25 | menu_style 26 | ]), 27 | (_('Behavior'), [ 28 | virtual_desktop 29 | ]) 30 | ]), 31 | #(_('Colors'), [ 32 | #]), 33 | (_('Theme'), [ 34 | themes 35 | ]) 36 | ]) 37 | 38 | -------------------------------------------------------------------------------- /exe-helper/launchers/java.launcher: -------------------------------------------------------------------------------- 1 | [Launcher Entry] 2 | Argument=java 3 | Package=default-jre "Default JRE\nStandard Java or Java compatible Runtime", openjdk-6-jre "OpenJDK\nOpenJDK Java runtime, using Hotspot JIT", java-gcj-compat "GCJ\nThe GNU Compiler for Java", sun-java6-jre "Sun Java 6\nJava 6 from Sun Microsystems" 4 | Icon=gnome-mime-application-x-jar 5 | VirusScan=true 6 | TryExec=java 7 | Exec=java -jar %FILE% 8 | 9 | Title=This is a Java Application 10 | TextHandler=Java 11 | TextInstall=The program %PROGRAM% is written for Java.\nIn order to run it you need to install a Java compiler. 12 | 13 | Title[da]=Dette er et Java-program 14 | TextInstall[da]=Programmet %PROGRAM% er skrevet til Java.\nFor at kunne køre det er du nødt til at installere en Java-oversætter. 15 | TextFirstRun[da]=Opretter ny Windows-konfiguration, vent venligst... 16 | Package[da]=java-gcj-compat "GCJ\nGNUs oversætter til Java", sun-java5-jre "Sun Java 5\nJava 5 fra Sun Microsystems", sun-java6-jre "Sun Java 6\nJava 6 fra Sun Microsystems" 17 | 18 | 19 | [Desktop Entry] 20 | Type=Application 21 | Name=Java 22 | Exec=exe-handler --java %f 23 | MimeType=application/x-jar; 24 | NoDisplay=true 25 | -------------------------------------------------------------------------------- /snap/snapcraft.yaml: -------------------------------------------------------------------------------- 1 | # This file is not yet ready. 2 | 3 | name: vineyard 4 | version: '1.5.1+git' 5 | summary: Easy to use Wine configuration program 6 | description: | 7 | Libraries and graphical utilities for using and configuring Wine. 8 | Includes a Gtk2 replacement for Winecfg with extra functionality and utilities to make using Wine easier, 9 | a Wine process managent indicator and a Python library for interacting with Wine. 10 | 11 | grade: stable 12 | confinement: devmode # use 'strict' once you have the right plugs and slots 13 | 14 | parts: 15 | my-part: 16 | # See 'snapcraft plugins' 17 | plugin: nil 18 | 19 | apps: 20 | vineyard-preferences: 21 | command: vineyard-preferences 22 | vineyard-cli: 23 | command: vineyard-cli 24 | vineyard-launcher: 25 | command: vineyard-launcher 26 | vineyard-indicator: 27 | command: vineyard-indicator 28 | vineyard-daemon: 29 | command: vineyard-daemon 30 | 31 | parts: 32 | vineyard-preferences: 33 | source: https://github.com/Cybolic/vineyard.git 34 | source-type: git 35 | plugin: python 36 | python-version: 'python2' 37 | python-packages: 38 | - glade2 39 | - dbus 40 | - appindicator 41 | stage-packages: 42 | - wine | wine-staging 43 | - icoutils 44 | - cabextract 45 | - winetricks 46 | - unzip 47 | -------------------------------------------------------------------------------- /vineyard/widgets/sound_directsound_samplerate.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import operator 7 | import widget, wine 8 | 9 | class Widget(widget.VineyardWidgetComboBox): 10 | def __init__(self): 11 | """ Compile a list of the available settings, our preferred first """ 12 | our_settings = ['48000', '44100', '22050', '16000', '11025', '8000'] 13 | 14 | settings = [] 15 | # Use only the drivers that are available on this system 16 | for setting in our_settings: 17 | if int(setting) in wine.audio.RATES: 18 | settings.append(setting) 19 | # Add drivers that weren't on our sorted list 20 | for setting in wine.audio.RATES: 21 | if str(setting) not in our_settings: 22 | settings.append(str(setting)) 23 | 24 | match_values = [ (i, i) for i in settings ] 25 | 26 | widget.VineyardWidgetComboBox.__init__(self, 27 | title = '%s:' % _('Default sample rate'), 28 | values = settings, 29 | match_values = match_values, 30 | settings_key = 'sound-directsound-samplerate', 31 | get_function = wine.audio.get_sample_rate, 32 | set_function = wine.audio.set_sample_rate) 33 | -------------------------------------------------------------------------------- /tools/update_translations.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | path="$(readlink -f "$(dirname "$0")/../")" 3 | 4 | echo -n "Extracting translatable strings..." 5 | cd "$path" 6 | intltool-extract --type=gettext/glade \ 7 | "data/vineyard-preferences.glade" \ 8 | 1>/dev/null 9 | xgettext --language Python --from-code utf-8 -k_ -kN_ -o "$path/po/vineyard.pot" \ 10 | "$path/vineyard-preferences" \ 11 | "$path/vineyard-indicator" \ 12 | "$path/vineyard-launcher" \ 13 | 1>/dev/null 14 | xgettext --from-code utf-8 -k_ -kN_ -o "$path/po/vineyard.pot" \ 15 | "$path/vineyard/"*.py \ 16 | "$path/data/vineyard-nautilus-infobar.py" \ 17 | "$path/data/vineyard-nautilus-property-page.py" \ 18 | "$path/data/vineyard-preferences.glade.h" \ 19 | 1>/dev/null 20 | rm "$path/data/vineyard-preferences.glade.h" 21 | echo " done." 22 | 23 | echo -n "Merging newly extracted strings with previous translations..." 24 | for i in "$path/po/"*.po; do 25 | if [ -f "$i" ]; then 26 | msgmerge -U "$i" "$path/po/vineyard.pot" 1>/dev/null 27 | fi 28 | done 29 | echo " done." 30 | 31 | echo -n "Compiling message catalogs to binary format..." 32 | for i in "$path/po/"*.po; do 33 | language="$(basename $i | cut -d. -f1)" 34 | if [ ! -d "$path/data/locale/$language" ]; then 35 | mkdir -p "$path/data/locale/$language/LC_MESSAGES" 1>/dev/null 36 | fi 37 | msgfmt $i -o "$path/data/locale/$language/LC_MESSAGES/vineyard.mo" 1>/dev/null 38 | done 39 | echo " done." 40 | -------------------------------------------------------------------------------- /data/vineyard-preferences.desktop: -------------------------------------------------------------------------------- 1 | 2 | [Desktop Entry] 3 | Name=Windows Applications 4 | Comment=Configure how Windows programs behave when running through Wine 5 | Exec=vineyard-preferences 6 | Icon=vineyard-preferences 7 | Terminal=false 8 | Type=Application 9 | StartupNotify=true 10 | Categories=GNOME;GTK;Settings;DesktopSettings; 11 | Name[da_DK]=Windows-programmer 12 | 13 | X-Ayatana-Desktop-Shortcuts=General;Appearance;Places;Devices;Libraries;Programs;Install;Tools; 14 | 15 | [General Shortcut Group] 16 | Name=General 17 | Exec=vineyard-preferences -s general 18 | TargetEnvironment=Unity 19 | 20 | [Appearance Shortcut Group] 21 | Name=Appearance 22 | Exec=vineyard-preferences -s appearance 23 | TargetEnvironment=Unity 24 | 25 | [Places Shortcut Group] 26 | Name=Places 27 | Exec=vineyard-preferences -s places 28 | TargetEnvironment=Unity 29 | 30 | [Devices Shortcut Group] 31 | Name=Devices 32 | Exec=vineyard-preferences -s devices 33 | TargetEnvironment=Unity 34 | 35 | [Libraries Shortcut Group] 36 | Name=Libraries 37 | Exec=vineyard-preferences -s libraries 38 | TargetEnvironment=Unity 39 | 40 | [Programs Shortcut Group] 41 | Name=Programs 42 | Exec=vineyard-preferences -s programs 43 | TargetEnvironment=Unity 44 | 45 | [Install Shortcut Group] 46 | Name=Install 47 | Exec=vineyard-preferences -s install 48 | TargetEnvironment=Unity 49 | 50 | [Tools Shortcut Group] 51 | Name=Tools 52 | Exec=vineyard-preferences -s tools 53 | TargetEnvironment=Unity 54 | -------------------------------------------------------------------------------- /wine/winetricks.py: -------------------------------------------------------------------------------- 1 | # AUTHOR: 2 | # Christian Dannie Storgaard 3 | 4 | from __future__ import print_function 5 | 6 | import common, util 7 | import re 8 | 9 | 10 | REGEX_STRING_VERBS_TEMPLATE = ( 11 | '(?ms)^w_metadata (?P[^ ]*) {cat} (?P.*?)^\S' 12 | ) 13 | REGEX_VERBS = {} 14 | for category in ( 15 | 'apps', 16 | 'benchmarks', 17 | 'dlls', 18 | 'fonts', 19 | 'games', 20 | 'settings' 21 | ): 22 | REGEX_VERBS[category] = re.compile(REGEX_STRING_VERBS_TEMPLATE.format( 23 | cat = category 24 | )) 25 | REGEX_VERBS[None] = re.compile(REGEX_STRING_VERBS_TEMPLATE.format( 26 | cat = '\\S+' 27 | )) 28 | 29 | def read_winetricks(): 30 | winetricks = common.which('winetricks') 31 | with open(winetricks, 'r') as _file: 32 | data = _file.read() 33 | if 'w_metadata' not in data: 34 | raise EnvironmentError, "Winetricks is too old, can't parse." 35 | return data 36 | 37 | def list_all(category=None): 38 | winetricks = read_winetricks() 39 | verbs = {} 40 | for name, info_str in re.findall(REGEX_VERBS[category], winetricks): 41 | info = {} 42 | info_iter = iter(util.string_split(info_str)) 43 | for key in info_iter: 44 | value = next(info_iter, None) 45 | if value is None: 46 | break 47 | info[key[:-1]] = util.string_remove_escapes(value) 48 | verbs[name] = info 49 | return verbs 50 | -------------------------------------------------------------------------------- /vineyard/widgets/wine_binary.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | # 7 | # ww_wineloader="/opt/wine-staging/bin/wine" 8 | # ww_wineserver="/opt/wine-staging/bin/wineserver" 9 | # ww_wine="/opt/wine-staging/bin/wine" 10 | # ww_winearch="win32" 11 | 12 | import gtk, glib, widget, wine 13 | from vineyard import common 14 | 15 | class Widget(widget.VineyardWidget): 16 | def __init__(self): 17 | widget.VineyardWidget.__init__(self) 18 | self.title = _('Wine Binary') 19 | self.settings_key = 'wine-environment-binary' 20 | self._build_interface() 21 | 22 | def _build_interface(self): 23 | self.hbox = gtk.HBox() 24 | self.label = gtk.Label('%s: ' % self.title) 25 | self.hbox.pack_start(self.label, False, False) 26 | self.label_arch = gtk.Label('') 27 | self.hbox.pack_end(self.label_arch, False, False) 28 | self.pack_start(self.hbox, True, False) 29 | self.show_all() 30 | 31 | def load_settings(self): 32 | self.settings[self.settings_key] = wine.common.ENV['WINE'] 33 | 34 | def fill_widgets(self): 35 | if self.settings[self.settings_key] is None: 36 | self.hide() 37 | else: 38 | self.label_arch.set_text(self.settings[self.settings_key]) 39 | self.show() 40 | self.gobject.emit('settings-loaded', self.settings_key, (self.settings[self.settings_key],)) 41 | -------------------------------------------------------------------------------- /vineyard/widgets/wine_loader.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | # 7 | # ww_wineloader="/opt/wine-staging/bin/wine" 8 | # ww_wineserver="/opt/wine-staging/bin/wineserver" 9 | # ww_wine="/opt/wine-staging/bin/wine" 10 | # ww_winearch="win32" 11 | 12 | import gtk, glib, widget, wine 13 | from vineyard import common 14 | 15 | class Widget(widget.VineyardWidget): 16 | def __init__(self): 17 | widget.VineyardWidget.__init__(self) 18 | self.title = _('Wine Loader') 19 | self.settings_key = 'wine-environment-loader' 20 | self._build_interface() 21 | 22 | def _build_interface(self): 23 | self.hbox = gtk.HBox() 24 | self.label = gtk.Label('%s: ' % self.title) 25 | self.hbox.pack_start(self.label, False, False) 26 | self.label_arch = gtk.Label('') 27 | self.hbox.pack_end(self.label_arch, False, False) 28 | self.pack_start(self.hbox, True, False) 29 | self.show_all() 30 | 31 | def load_settings(self): 32 | self.settings[self.settings_key] = wine.common.ENV['WINELOADER'] 33 | 34 | def fill_widgets(self): 35 | if self.settings[self.settings_key] is None: 36 | self.hide() 37 | else: 38 | self.label_arch.set_text(self.settings[self.settings_key]) 39 | self.show() 40 | self.gobject.emit('settings-loaded', self.settings_key, (self.settings[self.settings_key],)) 41 | -------------------------------------------------------------------------------- /vineyard/widgets/wine_server.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | # 7 | # ww_wineloader="/opt/wine-staging/bin/wine" 8 | # ww_wineserver="/opt/wine-staging/bin/wineserver" 9 | # ww_wine="/opt/wine-staging/bin/wine" 10 | # ww_winearch="win32" 11 | 12 | import gtk, glib, widget, wine 13 | from vineyard import common 14 | 15 | class Widget(widget.VineyardWidget): 16 | def __init__(self): 17 | widget.VineyardWidget.__init__(self) 18 | self.title = _('Wine Server') 19 | self.settings_key = 'wine-environment-server' 20 | self._build_interface() 21 | 22 | def _build_interface(self): 23 | self.hbox = gtk.HBox() 24 | self.label = gtk.Label('%s: ' % self.title) 25 | self.hbox.pack_start(self.label, False, False) 26 | self.label_arch = gtk.Label('') 27 | self.hbox.pack_end(self.label_arch, False, False) 28 | self.pack_start(self.hbox, True, False) 29 | self.show_all() 30 | 31 | def load_settings(self): 32 | self.settings[self.settings_key] = wine.common.ENV['WINESERVER'] 33 | 34 | def fill_widgets(self): 35 | if self.settings[self.settings_key] is None: 36 | self.hide() 37 | else: 38 | self.label_arch.set_text(self.settings[self.settings_key]) 39 | self.show() 40 | self.gobject.emit('settings-loaded', self.settings_key, (self.settings[self.settings_key],)) 41 | -------------------------------------------------------------------------------- /tests/base_parse_command.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | from __future__ import print_function 5 | 6 | import sys, os 7 | 8 | sys.path.insert(0, os.path.normpath( 9 | os.path.abspath(os.path.dirname(sys.argv[0]))+'/../' 10 | )) 11 | import vineyard 12 | 13 | SHARED_FILES_PATH = vineyard.get_shared_files_path() 14 | 15 | import wine 16 | import pprint 17 | 18 | def dict_diff(dict_a, dict_b): 19 | return dict([ 20 | (key, dict_b.get(key, dict_a.get(key))) 21 | for key in set(dict_a.keys()+dict_b.keys()) 22 | if ( 23 | (key in dict_a and (not key in dict_b or dict_a[key] != dict_b[key])) or 24 | (key in dict_b and (not key in dict_a or dict_a[key] != dict_b[key])) 25 | ) 26 | ]) 27 | 28 | if len(sys.argv) < 2: 29 | args = [ 30 | 'wine C:\\Program Files\\IExplorer\\iexplorer.exe', 31 | 'wine "C:\\Program Files\\IExplorer\\iexplorer.exe"', 32 | 'wine \'C:\\Program Files\\IExplorer\\iexplorer.exe\'', 33 | 'wine "$WINEPREFIX/drive_c/Program Files/IExplorer/iexplorer.exe\"', 34 | 'env WINEDEBUG= wine regedit.exe', 35 | 'start "c:\\Windows\\Profiles\\All Users\\Start Menu\\Programs\\WinRAR/WinRAR.lnk"' 36 | ] 37 | else: 38 | args = sys.argv[1:] 39 | 40 | for arg in args: 41 | print("{args}\n\nparses to:".format( 42 | args = arg 43 | )) 44 | result = wine.parse_command(arg) 45 | result['env'] = dict_diff(wine.common.ENV, result['env']) 46 | print('{0}\n\n'.format(result)) 47 | -------------------------------------------------------------------------------- /vineyard/widgets/directinput_mouse_warp.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import widget, wine 7 | 8 | class Widget(widget.VineyardWidgetComboBox): 9 | def __init__(self): 10 | """ Compile a list of the available settings, our preferred first """ 11 | settings = ['enable', 'force', 'disable'] 12 | names = [_('Yes'), _('Yes, force it'), _('No')] 13 | 14 | match_values = zip(names, settings) 15 | 16 | widget.VineyardWidgetComboBox.__init__(self, 17 | title = '%s: ' % _('DirectInput programs can warp the mouse pointer'), 18 | values = names, 19 | match_values = match_values, 20 | settings_key = 'directinput-mouse-warp', 21 | get_function = wine.graphics.get_mouse_warp, 22 | set_function = wine.graphics.set_mouse_warp 23 | ) 24 | self.set_tooltip_text(_( 25 | "Programs that use DirectInput often requires the " + 26 | "mouse pointer position to be translated to a relative position " + 27 | "instead of an absolute one, also called mouse warping." + 28 | "\n\n" + 29 | "If you are having problems with the mouse leaving the window or " + 30 | "seem to hit the screen edge in games, try setting this setting to "+ 31 | "Force, if not, set according to your preference." + 32 | "\n\n" + 33 | "The default is Enabled" 34 | )) 35 | 36 | -------------------------------------------------------------------------------- /vineyard/widgets/version.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import operator 7 | import widget, wine 8 | 9 | class Widget(widget.VineyardWidgetComboBox): 10 | def __init__(self): 11 | # Get a list of the Windows versions sorted by version number, newest first 12 | _windowsversions = wine.version.windowsversions_sorted.copy() 13 | default_windowsversion = wine.version.get_default() 14 | # Vineyard regards WinXP as one version, python-wine deals with the 64 bit difference 15 | default_windowsversion = default_windowsversion.replace('winxp64', 'winxp') 16 | windows_versions = [ 17 | _('%s (default)') % v[0] if k == default_windowsversion else v[0] 18 | for (k,v) in _windowsversions 19 | if k is not "winxp64" # python-wine knows to set "winxp" as "winxp64" on 64bit prefixes 20 | ] 21 | match_values = [ 22 | ('*%s*' % value[0], key) 23 | for key, value in sorted( 24 | _windowsversions.iteritems(), 25 | cmp=lambda x,y: y[1][3]-x[1][3] 26 | ) 27 | ] 28 | widget.VineyardWidgetComboBox.__init__(self, 29 | title = '%s:' % _('Operate as'), 30 | values = windows_versions, 31 | match_values = match_values, 32 | settings_key = 'windows-version', 33 | get_function = wine.version.get, 34 | set_function = wine.version.set) 35 | -------------------------------------------------------------------------------- /data/docs/configureexe.page: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | 7 | 8 | 9 | Christian Dannie Storgaard 10 | cybolic@gmail.com 11 | 2010 12 | 13 | 14 | How to configure the settings for a single program (executable) 15 | 16 | Configuring a single executable (program settings)/title> 17 | <p>Configuring a single executable (program settings) 18 | You may have noticed that the Properties dialog for files in Nautilus (the file manager) has a new page named Compatibility. 19 | On this page you can configure the settings used for this specific filename. 20 | Any settings you set on this page will be applied to any executable you run that has this name, so if you set an executable named SETUP.EXE to be run as Windows 98 and open in a virtual desktop then all files named "SETUP.EXE" (and "setup.exe", "setup.EXE", etc.) will be run like this. 21 | This is useful for executables like install programs or programs that use the same launcher (like f.x. Steam games), but can be annoying if you just want the single program to behave in a certain way, if this is the case you should look at <link xref="createconf">creating a new configuration</link>. 22 | Note that settings for an executable are only applied to executables run from the same configuration. 23 | </p> 24 | </page> 25 | -------------------------------------------------------------------------------- /data/docs/createconf.page: -------------------------------------------------------------------------------- 1 | <page xmlns="http://projectmallard.org/1.0/" 2 | type="topic" 3 | id="createconf"> 4 | <info> 5 | <link type="guide" xref="index#task"/> 6 | <link type="topic" xref="whatisconf"/> 7 | <link type="seealso" xref="differenceprogramconf"/> 8 | 9 | <credit type="author"> 10 | <name>Christian Dannie Storgaard</name> 11 | <email>cybolic@gmail.com</email> 12 | <years>2010</years> 13 | </credit> 14 | 15 | <desc>How to create a new configuration.</desc> 16 | </info> 17 | <title>Creating a new configuration 18 |

To create a new configuration, you have two options:

19 | 20 |

Open the Wine Preferences (from SystemPreferencesWine Preferences), and click the Advanced check box in the lower left corner. In the top of the window you can now click the newly appeared "Add new configuration" button (look for a plus sign or similar, depending on your desktop appearance).

21 |

Right click a Microsoft Windows executable, select Run in Wine configuration and select to create a new configuration. Note that the selected executable will be run when clicking OK, so it's advisable to select an installation executable and then cancel the installation as soon as you can or better yet, a program you can quickly exit without any change to your system, a good example of this is something like Notepad.

22 |
23 |
24 | -------------------------------------------------------------------------------- /vineyard/pages/tools.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import page 7 | from vineyard.widgets import ( 8 | tool_registry_editor, 9 | tool_control_panel, 10 | tool_command_prompt, 11 | tool_reboot, 12 | tool_shutdown, 13 | tool_programs_end, 14 | tool_programs_kill, 15 | tool_open_main_drive, 16 | tool_open_terminal, 17 | tool_lowercase_files, 18 | tool_run_executable 19 | ) 20 | 21 | id = 'tools' 22 | position = 1.0 23 | 24 | class Page(page.VineyardPage): 25 | def __init__(self, dev=False): 26 | self.no_loading = True 27 | page.VineyardPage.__init__(self, 28 | name = _("Tools"), 29 | icon = 'applications-accessories', 30 | widgets = [ 31 | (_('Windows accessories'), [ 32 | tool_registry_editor, 33 | tool_control_panel, 34 | tool_command_prompt 35 | ]), 36 | (_('Windows functions'), [( 37 | tool_reboot, 38 | tool_shutdown 39 | ),( 40 | tool_programs_end, 41 | tool_programs_kill 42 | )]), 43 | (_('Configuration functions'), [ 44 | tool_open_main_drive, 45 | tool_open_terminal, 46 | tool_lowercase_files, 47 | tool_run_executable 48 | ]) 49 | ]) 50 | -------------------------------------------------------------------------------- /wine/__init__.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | # AUTHOR: 7 | # Christian Dannie Storgaard 8 | 9 | from __future__ import print_function 10 | 11 | import os, sys, string 12 | import common 13 | import logging as _logging 14 | 15 | logging = _logging.getLogger("python-wine") 16 | debug = logging.debug 17 | error = logging.error 18 | 19 | if not len(common.ENV['WINE']): 20 | print("ERROR: Couldn't locate WINE, please make sure it is installed and in your PATH.", 21 | file=sys.stderr) 22 | exit(1) 23 | 24 | 25 | __modules = [ 26 | 'common', 27 | 'registry', 28 | 'util', 29 | 'command', 30 | 'monitor', 31 | 'audio', 32 | 'prefixes', 33 | 'drives', 34 | 'desktop', 35 | 'graphics', 36 | 'icons', 37 | 'appearance', 38 | 'appdb', 39 | 'programs', 40 | 'shellfolders', 41 | 'libraries', 42 | 'version', 43 | 'windows', 44 | 'winetricks' 45 | ] 46 | 47 | RUNNING_PROGRAMS = {} 48 | 49 | _openargs = [] 50 | 51 | import _cache 52 | cache = _cache.Cache() 53 | 54 | for module_name in __modules: 55 | # Load the module 56 | exec('import %s' % module_name) 57 | # Assign the module to a value in the local namespace 58 | _module = eval(module_name) 59 | # Set the global attributes of the module 60 | setattr(_module, 'CACHE', cache) 61 | 62 | # Set up the Wine prefix paths 63 | prefixes.use(None) # Same as using ~/.wine actually 64 | 65 | 66 | from base import * 67 | 68 | -------------------------------------------------------------------------------- /vineyard/widgets/sound_directsound_acceleration.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import operator 7 | import widget, wine 8 | 9 | class Widget(widget.VineyardWidgetComboBox): 10 | def __init__(self): 11 | """ Compile a list of the available settings, our preferred first """ 12 | our_settings = ['Full', 'Standard', 'Basic', 'Emulation'] 13 | our_settings_lowered = [ n.lower() for n in our_settings ] 14 | 15 | settings = [] 16 | # Use only the drivers that are available on this system 17 | for setting in our_settings: 18 | if setting.lower() in wine.audio.ACCELERATIONS: 19 | settings.append(setting) 20 | # Add drivers that weren't on our sorted list 21 | for setting in wine.audio.ACCELERATIONS: 22 | if setting.lower() not in our_settings_lowered: 23 | settings.append(setting.capitalize()) 24 | 25 | match_values = [ (i, i.lower()) for i in settings ] 26 | 27 | widget.VineyardWidgetComboBox.__init__(self, 28 | title = '%s:' % _('Hardware acceleration'), 29 | values = settings, 30 | match_values = match_values, 31 | settings_key = 'sound-directsound-acceleration', 32 | get_function = self._get_function, 33 | set_function = wine.audio.set_acceleration) 34 | 35 | def _get_function(self): 36 | value = wine.audio.get_acceleration() 37 | return value.lower() 38 | -------------------------------------------------------------------------------- /debian/copyright: -------------------------------------------------------------------------------- 1 | This package was debianized by Christian Dannie Storgaard on 2 | Tue, 13 Oct 2009 05:39:25 +0200. 3 | 4 | The current Debian/Ubuntu maintainer is Christian Dannie Storgaard 5 | 6 | It was downloaded from https://launchpad.net/vineyard 7 | 8 | Upstream Author: 9 | 10 | Christian Dannie Storgaard 11 | 12 | Copyright: 13 | 14 | Copyright (C) 2007-2009 Christian Dannie Storgaard 15 | 16 | License: 17 | 18 | This package is free software; you can redistribute it and/or 19 | modify it under the terms of the GNU Lesser General Public 20 | License as published by the Free Software Foundation; either 21 | version 2 of the License, or (at your option) any later version. 22 | 23 | This package is distributed in the hope that it will be useful, 24 | but WITHOUT ANY WARRANTY; without even the implied warranty of 25 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 26 | Lesser General Public License for more details. 27 | 28 | You should have received a copy of the GNU Lesser General Public 29 | License along with this package; if not, write to the Free Software 30 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 31 | 32 | On Debian systems, the complete text of the GNU Lesser General 33 | Public License can be found in `/usr/share/common-licenses/LGPL-2'. 34 | 35 | The Debian packaging is: 36 | 37 | Copyright (C) 2009 Christian Dannie Storgaard 38 | 39 | and is licensed under the GPL version 3, 40 | see `/usr/share/common-licenses/GPL-3'. 41 | -------------------------------------------------------------------------------- /vineyard/widgets/wine_arch.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | # 7 | # ww_wineloader="/opt/wine-staging/bin/wine" 8 | # ww_wineserver="/opt/wine-staging/bin/wineserver" 9 | # ww_wine="/opt/wine-staging/bin/wine" 10 | # ww_winearch="win32" 11 | 12 | import gtk, glib, widget, wine 13 | from vineyard import common 14 | 15 | class Widget(widget.VineyardWidget): 16 | def __init__(self): 17 | widget.VineyardWidget.__init__(self) 18 | self.title = _('Architecture') 19 | self.settings_key = 'wine-environment-arch' 20 | self._build_interface() 21 | 22 | def _build_interface(self): 23 | self.hbox = gtk.HBox() 24 | self.label = gtk.Label('%s: ' % self.title) 25 | self.hbox.pack_start(self.label, False, False) 26 | self.label_arch = gtk.Label('') 27 | self.hbox.pack_end(self.label_arch, False, False) 28 | self.pack_start(self.hbox, True, False) 29 | self.show_all() 30 | 31 | def load_settings(self): 32 | self.settings[self.settings_key] = wine.common.ENV['WINEARCH'] 33 | 34 | def fill_widgets(self): 35 | if self.settings[self.settings_key] is None: 36 | self.hide() 37 | else: 38 | if self.settings[self.settings_key] == 'win64': 39 | self.label_arch.set_text(_("64-bit")) 40 | else: 41 | self.label_arch.set_text(_("32-bit")) 42 | self.show() 43 | self.gobject.emit('settings-loaded', self.settings_key, (self.settings[self.settings_key],)) 44 | -------------------------------------------------------------------------------- /vineyard/widgets/tool_lowercase_files.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import gtk, widget, wine 7 | from vineyard import common 8 | 9 | class Widget(widget.VineyardWidget): 10 | def __init__(self): 11 | widget.VineyardWidget.__init__(self) 12 | self.title = _('Lowercase files and folders in Main Drive') 13 | self.tooltip = _('Since Windows does not differentiate between upper and lowercase file names, this could help with performance (especially when used with ciopfs)') 14 | self.icon = 'edit-find-replace' 15 | self._build_interface() 16 | self.button.set_sensitive(False) 17 | 18 | def _build_interface(self): 19 | self.button = common.button_new_with_image(self.icon, label=self.title, use_underline=False) 20 | self.button.set_tooltip_text(self.tooltip) 21 | self.pack_start(self.button) 22 | self.show_all() 23 | 24 | self.button.connect('clicked', self.button_clicked) 25 | 26 | def button_clicked(self, button): 27 | if self.gobject.loading: return False 28 | 29 | self.threading.run_in_thread(self._find_files, callback = self._find_files_done) 30 | print "Looking for files with uppercase filenames..." 31 | 32 | def _find_files(self): 33 | self.files = wine.util.find_uppercase_filenames() 34 | 35 | def _find_files_done(self, return_value): 36 | print "Found %s files:" % len(self.files) 37 | print '\n'.join([ '\t%s' % i for i in self.files ]) 38 | #self.pulse.stop() 39 | -------------------------------------------------------------------------------- /tests/vineyard_widget.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | from __future__ import print_function 7 | 8 | import sys, os 9 | 10 | sys.path.insert(0, os.path.normpath( 11 | os.path.abspath(os.path.dirname(sys.argv[0]))+'/../' 12 | )) 13 | import gtk 14 | import vineyard 15 | #import wine 16 | 17 | class Main(): 18 | def __init__(self, widget): 19 | self.window = gtk.Window() 20 | self.window.set_position(gtk.WIN_POS_CENTER_ALWAYS) 21 | self.widget = vineyard.widgets.themes.Widget() 22 | self.widget = eval('vineyard.widgets.{0}'.format(widget)).Widget() 23 | self.window.add(self.widget) 24 | self.window.show_all() 25 | 26 | self.window.connect( 27 | 'destroy', lambda *args: gtk.main_quit() 28 | ) 29 | 30 | self.widget.configure() 31 | gtk.main() 32 | 33 | if len(sys.argv) > 1: 34 | if sys.argv[1] in ('--list', '-l'): 35 | print( 36 | '\n'.join(sorted([ 37 | i for i 38 | in dir(vineyard.widgets) 39 | if 'Widget' in dir(eval('vineyard.widgets.{0}'.format(i))) 40 | ])) 41 | ) 42 | elif sys.argv[1] in dir(vineyard.widgets): 43 | main = Main(sys.argv[1]) 44 | else: 45 | print("widget \"{0}\" not found.", file=sys.stderr) 46 | else: 47 | print(( 48 | "Usage: {self} WIDGET\n"+ 49 | "Run {self} with the argument --list or -l to see "+ 50 | "the list of available widgets." 51 | ).format( 52 | self = os.path.basename(sys.argv[0]) 53 | )) 54 | -------------------------------------------------------------------------------- /python-wine/debian/copyright: -------------------------------------------------------------------------------- 1 | This package was debianized by Christian Dannie Storgaard on 2 | Tue, 13 Oct 2009 05:39:25 +0200. 3 | 4 | The current Debian/Ubuntu maintainer is Christian Dannie Storgaard 5 | 6 | It was downloaded from https://launchpad.net/vineyard 7 | 8 | Upstream Author: 9 | 10 | Christian Dannie Storgaard 11 | Indivual parts of code copyrighted in the appropriate places. 12 | 13 | Copyright: 14 | 15 | Copyright (C) 2007-2009 Christian Dannie Storgaard 16 | 17 | License: 18 | 19 | This package is free software; you can redistribute it and/or 20 | modify it under the terms of the GNU Lesser General Public 21 | License as published by the Free Software Foundation; either 22 | version 2 of the License, or (at your option) any later version. 23 | 24 | This package is distributed in the hope that it will be useful, 25 | but WITHOUT ANY WARRANTY; without even the implied warranty of 26 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 27 | Lesser General Public License for more details. 28 | 29 | You should have received a copy of the GNU Lesser General Public 30 | License along with this package; if not, write to the Free Software 31 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 32 | 33 | On Debian systems, the complete text of the GNU Lesser General 34 | Public License can be found in `/usr/share/common-licenses/LGPL-2'. 35 | 36 | The Debian packaging is: 37 | 38 | Copyright (C) 2009 Christian Dannie Storgaard 39 | 40 | and is licensed under the GPL version 3, 41 | see `/usr/share/common-licenses/GPL-3'. 42 | -------------------------------------------------------------------------------- /tests/executable_get_program_name.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | from __future__ import print_function 5 | 6 | import sys, os 7 | 8 | sys.path.insert(0, os.path.normpath( 9 | os.path.abspath(os.path.dirname(sys.argv[0]))+'/../' 10 | )) 11 | import vineyard 12 | 13 | SHARED_FILES_PATH = vineyard.get_shared_files_path() 14 | 15 | import wine 16 | 17 | if len(sys.argv) > 1: 18 | verbose = False 19 | if '--verbose' or '-v' in sys.argv: 20 | import pprint 21 | verbose = True 22 | try: sys.argv.pop(sys.argv.index('--verbose')) 23 | except ValueError: pass 24 | try: sys.argv.pop(sys.argv.index('-')) 25 | except ValueError: pass 26 | 27 | for exe in sys.argv[1:]: 28 | full_info = '' 29 | if verbose: 30 | full_info = [] 31 | version_info = wine.binary.windows_executable(exe).get_version_fast() 32 | if 'ProductName' in version_info: 33 | full_info.append(('ProductName', version_info['ProductName'])) 34 | if 'FileDescription' in version_info: 35 | full_info.append(('FileDescription', version_info['FileDescription'])) 36 | if 'Comments' in version_info: 37 | full_info.append(('Comments', version_info['Comments'])) 38 | full_info = '\t{0}\n{1}'.format('\n\t'.join([ 39 | 'Tried \'{0}\' : \'{1}\''.format(i[0], i[1]) 40 | for i in full_info 41 | ]), pprint.pformat(version_info)) 42 | 43 | print("{exe}:\n{full_info}\t{name}\n".format( 44 | exe = exe, 45 | full_info = full_info, 46 | name = wine.util.get_program_name(exe) 47 | )) 48 | else: 49 | print("No file path given.") 50 | exit(1) 51 | 52 | -------------------------------------------------------------------------------- /data/vineyard-preferences.pod: -------------------------------------------------------------------------------- 1 | =head1 NAME 2 | 3 | Vineyard - easy to use Wine configuration program 4 | 5 | =head1 SYNOPSIS 6 | 7 | vineyard-preferences [I] 8 | 9 | =head1 DESCRIPTION 10 | 11 | B is a user friendly configuration tool for WINE(1) that offers all the 12 | features of winecfg (with the exception of the unfinished theme-support) as 13 | well as configuration handling and program management in an easy to use program 14 | designed to blend in with the GNOME desktop. 15 | 16 | =head1 OPTIONS 17 | 18 | =over 8 19 | 20 | =item B<--enable-configurations> 21 | 22 | Show the controls for managing configurations. 23 | 24 | =item B<--select-configuration I> 25 | 26 | Select the configuration named CONFIGURATION at program startup. 27 | 28 | =item B<--select-page I> 29 | 30 | Select the configuration page PAGE at program startup. 31 | 32 | =item B<--debug I> 33 | 34 | Vineyard will print debugging information of a certain level. 35 | Accepted levels are: debug, info, warning, error and critical. 36 | 37 | =back 38 | 39 | =head1 BUGS 40 | 41 | Please report bugs at https://bugs.launchpad.net/vineyard. 42 | 43 | =head1 AUTHORS 44 | 45 | B was written by Christian Dannie Storgaard . 46 | 47 | Other credits can be found in the file AUTHORS in the top-level directory 48 | of the source distribution. 49 | 50 | =head1 COPYRIGHT 51 | 52 | This program is free software; you can redistribute it and/or modify it 53 | under the terms of the GNU Lesser General Public License as published 54 | by the Free Software Foundation; either version 2, or (at your option) 55 | any later version. 56 | 57 | On Debian GNU/Linux systems, the complete text of the GNU Lesser General 58 | Public License can be found in `/usr/share/common-licenses/LGPL'. 59 | 60 | =cut 61 | -------------------------------------------------------------------------------- /data/docs/installprogram.page: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | Christian Dannie Storgaard 11 | cybolic@gmail.com 12 | 2010 13 | 14 | 15 | How to install a Windows program. 16 | 17 | Installing a program 18 |

19 | By default, running an installer will install the program in the default Wine configuration, 20 | if you want to install several non-related programs it might be a better idea to install each into its own configuration. 21 |

22 | 23 |
24 | Installing a program in to the default configuration 25 |

Double click the installation executable and follow the same procedure that you would in Microsoft Windows.

26 |

As the program will be installed in a virtual Microsoft Windows installation, in most cases you don't need to worry about the location of the installation, and can safely use the defaults.

27 |
28 | 29 |
30 | Installing a program in to a new or existing configuration 31 |

Right click the installation executable and select Run in Wine configuration. 32 | In the dialog that appears you can now select the configuration you wish to install the program to, or select New to create a new configuration for the program. If you select to create a new configuration you can adjust a few basic settings like which Windows version to function as and whether or not to run the program in a virtual desktop.

33 |
34 |
35 | -------------------------------------------------------------------------------- /vineyard/widgets/sound_directsound_eax.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import widget, wine 7 | 8 | class Widget(widget.VineyardWidgetCheckButton): 9 | def __init__(self): 10 | widget.VineyardWidgetCheckButton.__init__(self, 11 | title = _('Enable EAX support'), 12 | settings_key = 'sound-directsound-eax', 13 | get_function = self._get_function, 14 | set_function = self._set_function) 15 | self._tooltip_text = _( 16 | "Enable support for Environmental Audio Extensions." + 17 | "\n\n" + 18 | "Enabling this experimental feature emulates driver support for EAX " + 19 | "using software emulation. This enables (mostly older) games to have " + 20 | "audio effects, such as reverb or equalisation." 21 | ) 22 | self._tooltip_text_unavailable = _("Not supported in this version of Wine.") 23 | self.set_tooltip_text(self._tooltip_text) 24 | 25 | def _get_function(self): 26 | return wine.audio.get_eax_support() 27 | 28 | def _set_function(self, value): 29 | return wine.audio.set_eax_support(value) 30 | 31 | self.settings[self.settings_key] = wine.audio.get_eax_support() 32 | 33 | def fill_widgets(self): 34 | if self.settings[self.settings_key] == None: 35 | self.checkbutton.set_active(False) 36 | self.checkbutton.set_sensitive(False) 37 | self.set_tooltip_text(self._tooltip_text_unavailable) 38 | else: 39 | self.checkbutton.set_active( self.settings[self.settings_key] == True ) 40 | self.checkbutton.set_sensitive(True) 41 | self.set_tooltip_text(self._tooltip_text) 42 | self.gobject.emit('settings-loaded', self.settings_key, (self.settings[self.settings_key],)) 43 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Vineyard 2 | 3 | [![Build Status](https://travis-ci.org/Cybolic/vineyard.svg?branch=master)](https://travis-ci.org/Cybolic/vineyard) 4 | [![RPM Build Status](https://copr.fedorainfracloud.org/coprs/cybolic/Vineyard/package/vineyard/status_image/last_build.png)](https://copr.fedorainfracloud.org/coprs/cybolic/Vineyard/package/vineyard/) 5 | 6 | ## Easy to use Wine configuration programs and libraries 7 | 8 | Libraries and graphical utilities for using and configuring Wine from the Gnome desktop. 9 | Incorporates many of the ideas found at [the Ubuntu Wiki](https://wiki.ubuntu.com/karmic-wine-integration). 10 | 11 | If you would like to learn more about how it works, please visit the [project website](http://vineyardproject.org). 12 | 13 | ### Distribution Packages 14 | 15 | If you would like to install in Ubuntu/Debian, you can use [the PPA](https://code.launchpad.net/~cybolic/+archive/ubuntu/ppa): 16 | 17 | ```bash 18 | sudo add-apt-repository ppa:cybolic/vineyard-testing 19 | sudo apt update 20 | sudo apt install vineyard 21 | ``` 22 | 23 | To install in Fedora, you can use the COPR [respository](https://copr.fedorainfracloud.org/coprs/cybolic/Vineyard/): 24 | 25 | ```bash 26 | sudo dnf copr enable cybolic/Vineyard 27 | sudo dnf install vineyard 28 | ``` 29 | 30 | Vineyard is also [available in the Aurch User Repository (AUR)](https://aur.archlinux.org/packages/vineyard-git/). 31 | 32 | ### Install From Source 33 | 34 | If you would like to help test the development version of Vineyard, please open a terminal and write: 35 | 36 | ```bash 37 | sudo apt install git 38 | git clone git@github.com:Cybolic/vineyard.git 39 | ``` 40 | 41 | To run this development version, use these commands (this will open Vineyard Preferences): 42 | 43 | ```bash 44 | cd vineyard 45 | ./vineyard-preferences 46 | ``` 47 | 48 | Please report any errors, problems, thoughts or ideas you have concerning Vineyard [here on GitHub](https://github.com/Cybolic/vineyard/issues). 49 | -------------------------------------------------------------------------------- /vineyard/widgets/direct3d_dxva2_vaapi.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import widget, wine 7 | 8 | class Widget(widget.VineyardWidgetCheckButton): 9 | def __init__(self): 10 | widget.VineyardWidgetCheckButton.__init__(self, 11 | title = _('Use VAAPI for DXVA2 GPU decoding'), 12 | settings_key = 'direct3d-dxva2-vaapi', 13 | get_function = self._get_function, 14 | set_function = self._set_function) 15 | self._tooltip_text = _( 16 | "Use VAAPI as the backend for DXVA2 GPU decoding." + 17 | "\n\n" + 18 | "Enabling this experimental feature allows video decoding to be " + 19 | "performed by the GPU on compatible graphics cards." + 20 | "\n\n" + 21 | "Note: This may crash on Intel GPUs; NVIDIA GPUs are known to work well." 22 | ) 23 | self._tooltip_text_unavailable = _("Not supported in this version of Wine.") 24 | self.set_tooltip_text(self._tooltip_text) 25 | 26 | def _get_function(self): 27 | return wine.graphics.get_dxva2_vaapi() 28 | 29 | def _set_function(self, value): 30 | return wine.graphics.set_dxva2_vaapi(value) 31 | 32 | self.settings[self.settings_key] = wine.graphics.get_dxva2_vaapi() 33 | 34 | def fill_widgets(self): 35 | if self.settings[self.settings_key] == None: 36 | self.checkbutton.set_active(False) 37 | self.checkbutton.set_sensitive(False) 38 | self.set_tooltip_text(self._tooltip_text_unavailable) 39 | else: 40 | self.checkbutton.set_active( self.settings[self.settings_key] == True ) 41 | self.checkbutton.set_sensitive(True) 42 | self.set_tooltip_text(self._tooltip_text) 43 | self.gobject.emit('settings-loaded', self.settings_key, (self.settings[self.settings_key],)) 44 | -------------------------------------------------------------------------------- /vineyard/widgets/direct3d_csmt.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import widget, wine 7 | 8 | class Widget(widget.VineyardWidgetCheckButton): 9 | def __init__(self): 10 | widget.VineyardWidgetCheckButton.__init__(self, 11 | title = _('Use CSMT'), 12 | settings_key = 'direct3d-csmt', 13 | get_function = self._get_function, 14 | set_function = self._set_function) 15 | self._tooltip_text = _( 16 | "Use command stream multi-threading for Direct3D calls." + 17 | "\n\n" + 18 | "Enabling this experimental feature allows calls to OpenGL to be made " + 19 | "in separate threads, similar to how Direct3D works on Windows.\n" + 20 | "This can give significant performance improvements and fix " + 21 | "flickering geometry in games, but may cause other issues." 22 | ) 23 | self._tooltip_text_unavailable = _("Not supported in this version of Wine.") 24 | self.set_tooltip_text(self._tooltip_text) 25 | 26 | def _get_function(self): 27 | return wine.graphics.get_csmt() 28 | 29 | def _set_function(self, value): 30 | return wine.graphics.set_csmt(value) 31 | 32 | self.settings[self.settings_key] = wine.graphics.get_csmt() 33 | 34 | def fill_widgets(self): 35 | if self.settings[self.settings_key] == None: 36 | self.checkbutton.set_active(False) 37 | self.checkbutton.set_sensitive(False) 38 | self.set_tooltip_text(self._tooltip_text_unavailable) 39 | else: 40 | self.checkbutton.set_active( self.settings[self.settings_key] == True ) 41 | self.checkbutton.set_sensitive(True) 42 | self.set_tooltip_text(self._tooltip_text) 43 | self.gobject.emit('settings-loaded', self.settings_key, (self.settings[self.settings_key],)) 44 | -------------------------------------------------------------------------------- /data/docs/problemprogramwontrun.page: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | 7 | 8 | 9 | Christian Dannie Storgaard 10 | cybolic@gmail.com 11 | 2010 12 | 13 | 14 | How to help get troublesome programs running 15 | 16 | Help with running programs 17 |

If a program doesn't run or exists before it should, try looking at the error information that Vineyard gives you. 18 | Common problems include missing DLL files (libraries), some of which Vineyard is able to identify for you, or simply incompatibility with a specific version of Windows.

19 | 20 |

Try changing the Windows version that Vineyard should function as and see if this helps, or in the case of DLL files, try finding the missing DLL file (try online or from an old Windows installation or CD) and copy it to C:\Windows\System32 in the configuration. 21 | Note that Vineyard offers automated installation of many common libraries from the Install page.

22 | 23 |

If you are still stuck, you can often find help in Wine's application database, but remember that you should run any commands listed in a terminal launched from Vineyard, not just the regular terminal if you want the commands to operate on something other than the default configuration.

24 | 25 | 26 |

Note that Vineyard has no way of knowing if a program has a graphical user interface or not, and you may therefor experience that command prompt programs will not open in their own window.

27 |

One way to get around this is to run Wine Preferences from a terminal, run the program from there and switch back to the terminal where your program should now be running.

28 |
29 | 30 |
31 | -------------------------------------------------------------------------------- /vineyard/widgets/sound_driver.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | 7 | from __future__ import print_function 8 | 9 | import operator 10 | import widget, wine 11 | 12 | class Widget(widget.VineyardWidgetComboBox): 13 | def __init__(self): 14 | """ Compile a list of the available audio drivers, our preferred first """ 15 | our_drivers = ['ALSA', 'OSS', 'Jack', 'Pulse', 'NAS', 'CoreAudio', 'AudioIO'] 16 | our_drivers_lowered = [ n.lower() for n in our_drivers ] 17 | 18 | drivers = [] 19 | # Use only the drivers that are available on this system 20 | for driver in our_drivers: 21 | if driver.lower() in wine.audio.DRIVERS: 22 | drivers.append(driver) 23 | # Add drivers that weren't on our sorted list 24 | for driver in wine.audio.DRIVERS: 25 | if driver.lower() not in our_drivers_lowered: 26 | drivers.append(driver.capitalize()) 27 | 28 | match_values = [] 29 | for driver in drivers: 30 | if driver.lower() == 'pulse': 31 | match_values.append(('PulseAudio', 'pulse')) 32 | else: 33 | match_values.append((driver, driver.lower())) 34 | 35 | widget.VineyardWidgetComboBox.__init__(self, 36 | title = '%s:' % _('Driver'), 37 | values = [ name for (name, value) in match_values ], 38 | match_values = match_values, 39 | settings_key = 'sound-drivers', 40 | get_function = self._get_setting, 41 | set_function = self._set_setting) 42 | 43 | def _get_setting(self): 44 | try: 45 | driver = wine.audio.get_enabled_drivers()[0] 46 | except IndexError: 47 | driver = '' 48 | if len(driver.strip()): 49 | return driver 50 | else: 51 | return 'alsa' 52 | def _set_setting(self, driver): 53 | wine.audio.set_enabled_drivers([driver]) 54 | -------------------------------------------------------------------------------- /vineyard/widgets/direct3d_offscreen_rendering.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import operator 7 | import widget, wine 8 | 9 | class Widget(widget.VineyardWidgetComboBox): 10 | def __init__(self): 11 | """ Compile a list of the available settings, our preferred first """ 12 | settings = ['fbo', 'backbuffer', 'pbuffer'] 13 | names = ['Frame Buffer', 'Back Buffer', 'Pixel buffer'] 14 | 15 | # Add any legal settings that we don't know about 16 | for setting in wine.graphics.OFFSCREEN_RENDERING_MODES: 17 | if setting not in settings: 18 | settings.append(setting) 19 | names.append(setting) 20 | 21 | # Remove any settings that are now deprecated 22 | for index, setting in enumerate(settings): 23 | if setting in wine.graphics.OFFSCREEN_RENDERING_MODES_DEPRECATED: 24 | settings.pop(index) 25 | names.pop(index) 26 | 27 | # Use the values from our_names and append any extra setting values added above 28 | match_values = zip(names, settings) 29 | 30 | widget.VineyardWidgetComboBox.__init__(self, 31 | title = '%s:' % _('Render offscreen images using the'), 32 | values = names, 33 | match_values = match_values, 34 | settings_key = 'direct3d-offscreen-rendering', 35 | get_function = self._get_function, 36 | set_function = self._set_function) 37 | self.set_tooltip_text(_( 38 | "Some programs and games work better or faster with one setting, others with another." + 39 | "\n\n" + 40 | "If you are experiencing issues with the speed of 3D in a program or game, try changing this setting." 41 | )) 42 | 43 | def _get_function(self): 44 | value = wine.graphics.get_offscreen_rendering_mode() 45 | return value.lower() 46 | 47 | def _set_function(self, value): 48 | wine.graphics.set_offscreen_rendering_mode(value) 49 | -------------------------------------------------------------------------------- /vineyard/widgets/sound_directsound_bitdepth.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import gtk, widget, wine 7 | 8 | class Widget(widget.VineyardWidget): 9 | def __init__(self): 10 | widget.VineyardWidget.__init__(self) 11 | self.title = _('Default bit depth') 12 | self.settings_key = 'sound-directsound-bitdepth' 13 | self.set_function = wine.audio.set_bit_depth 14 | self._build_interface() 15 | 16 | def _build_interface(self): 17 | self.table = gtk.Table(rows=2, columns=3, homogeneous=False) 18 | 19 | if self.title != None: 20 | self.label = gtk.Label(self.title) 21 | self.label.set_alignment(0.0, 0.5) 22 | self.table.attach(self.label, 0,1, 0,1, gtk.FILL|gtk.EXPAND,0, 0,0) 23 | self.radiobutton8 = gtk.RadioButton(label='8') 24 | self.table.attach(self.radiobutton8, 1,2, 0,1, 0,0, 6,0) 25 | self.radiobutton16 = gtk.RadioButton(label='16', group=self.radiobutton8) 26 | self.table.attach(self.radiobutton16, 2,3, 0,1, 0,0, 0,0) 27 | 28 | self.pack_start(self.table) 29 | self.show_all() 30 | 31 | self.radiobutton8.connect('toggled', self.radiobutton8_toggled, 32 | self.settings_key, self.set_function) 33 | 34 | def radiobutton8_toggled(self, radiobutton, settings_key, function): 35 | if self.gobject.loading: return False 36 | 37 | self.settings[settings_key] = '8' if radiobutton.get_active() else '16' 38 | self.gobject.emit('settings-changed', settings_key, function, (self.settings[settings_key],)) 39 | 40 | def load_settings(self): 41 | self.settings[self.settings_key] = wine.audio.get_bit_depth() 42 | 43 | def fill_widgets(self): 44 | if self.settings[self.settings_key] == '8': 45 | self.radiobutton8.set_active(True) 46 | else: 47 | self.radiobutton16.set_active(True) 48 | 49 | self.gobject.emit('settings-loaded', self.settings_key, (self.settings[self.settings_key],)) 50 | -------------------------------------------------------------------------------- /vineyard/widgets/direct3d_check_float_constants.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import widget, wine 7 | 8 | class Widget(widget.VineyardWidgetCheckButton): 9 | def __init__(self): 10 | widget.VineyardWidgetCheckButton.__init__(self, 11 | title = _('Check shader float constants'), 12 | settings_key = 'direct3d-check-float-constants', 13 | get_function = self._get_function, 14 | set_function = self._set_function) 15 | self._tooltip_text = _( 16 | "Check whether shader constants are outside the " + 17 | "valid constant range (0-255) and return 0,0 if they are." + 18 | "\n\n" + 19 | "This issue can occur on NVIDIA drivers in a few games " + 20 | "(The Witcher, Grim Dawn, Might & Magic Heroes VI and " + 21 | "the King's Bounty games are known to be affected). " + 22 | "\n\n" + 23 | "If you are seeing polygons displayed oddly, enabling " + 24 | "this feature may help.\n" + 25 | "Note that it has a minor impact on framerate." 26 | ) 27 | self._tooltip_text_unavailable = _("Not supported in this version of Wine.") 28 | self.set_tooltip_text(self._tooltip_text) 29 | 30 | def _get_function(self): 31 | return wine.graphics.get_check_float_constants() 32 | 33 | def _set_function(self, value): 34 | return wine.graphics.set_check_float_constants(value) 35 | 36 | self.settings[self.settings_key] = wine.graphics.get_check_float_constants() 37 | 38 | def fill_widgets(self): 39 | if self.settings[self.settings_key] == None: 40 | self.checkbutton.set_active(False) 41 | self.checkbutton.set_sensitive(False) 42 | self.set_tooltip_text(self._tooltip_text_unavailable) 43 | else: 44 | self.checkbutton.set_active( self.settings[self.settings_key] == True ) 45 | self.checkbutton.set_sensitive(True) 46 | self.set_tooltip_text(self._tooltip_text) 47 | self.gobject.emit('settings-loaded', self.settings_key, (self.settings[self.settings_key],)) 48 | -------------------------------------------------------------------------------- /wine/windows.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | # AUTHOR: 7 | # Christian Dannie Storgaard 8 | 9 | import registry 10 | import _cache 11 | 12 | CACHE = _cache.Cache() 13 | 14 | def get_decorated(): 15 | if 'windows-decorated' in CACHE: 16 | return CACHE['windows-decorated'] 17 | 18 | settings = registry.get('HKEY_CURRENT_USER\\Software\\Wine\\X11 Driver', quiet=True) 19 | if "Decorated" in settings and "n" in settings["Decorated"].lower(): 20 | value = False 21 | else: 22 | value = True 23 | CACHE['windows-decorated'] = value 24 | return value 25 | 26 | def set_decorated(state): 27 | if state: 28 | reg_state = "Y" 29 | else: 30 | reg_state = "N" 31 | registry.set({'HKEY_CURRENT_USER\\Software\\Wine\\X11 Driver': {"Decorated": reg_state}}) 32 | CACHE['windows-decorated'] = (state == True) 33 | 34 | def get_managed(): 35 | if 'windows-managed' in CACHE: 36 | return CACHE['windows-managed'] 37 | 38 | settings = registry.get('HKEY_CURRENT_USER\\Software\\Wine\X11 Driver', quiet=True) 39 | if "Managed" in settings and "n" in settings["Managed"].lower(): 40 | value = False 41 | else: 42 | value = True 43 | CACHE['windows-managed'] = value 44 | return value 45 | 46 | def set_managed(state): 47 | if state: 48 | reg_state = "Y" 49 | else: 50 | reg_state = "N" 51 | registry.set({'HKEY_CURRENT_USER\\Software\\Wine\\X11 Driver': {"Managed": reg_state}}) 52 | CACHE['windows-managed'] = (state == True) 53 | 54 | def get_mouse_grab(): 55 | if 'windows-mouse-grab' in CACHE: 56 | return CACHE['windows-mouse-grab'] 57 | 58 | settings = registry.get('HKEY_CURRENT_USER\\Software\\Wine\\X11 Driver', quiet=True) 59 | if "DXGrab" in settings and "n" in settings["DXGrab"].lower(): 60 | value = False 61 | else: 62 | value = True 63 | CACHE['windows-mouse-grab'] = value 64 | return value 65 | 66 | def set_mouse_grab(state): 67 | if state: 68 | reg_state = "Y" 69 | else: 70 | reg_state = "N" 71 | registry.set({'HKEY_CURRENT_USER\\Software\\Wine\\X11 Driver': {"DXGrab": reg_state}}) 72 | CACHE['windows-mouse-grab'] = (state == True) 73 | 74 | -------------------------------------------------------------------------------- /exe-helper/launchers/wine.launcher: -------------------------------------------------------------------------------- 1 | [Launcher Entry] 2 | Argument=wine 3 | Package=wine 4 | Icon=wine 5 | VirusScan=true 6 | TryExec=wine 7 | FirstRunExec=wineboot 8 | TryFirstRunExec=[ -d ${WINEPREFIX:-~/.wine}/dosdevices/c\:/windows/system32 ] && [ -f ${WINEPREFIX:-~/.wine}/system.reg ] && [ -f ${WINEPREFIX:-~/.wine}/userdef.reg ] && [ -f ${WINEPREFIX:-~/.wine}/user.reg ] 9 | Exec=wine start /unix %FILE% 10 | 11 | Title=This is a Windows Application 12 | TextHandler=Wine 13 | TextInstall=The program %PROGRAM% was originally designed\nfor Microsoft Windows.\n\nYou can attempt to run it by using the program Wine, however\nbe warned that some Windows applications may not function\ncorrectly. 14 | TextPermission=The Windows program %PROGRAM%\nrequires permission to run. 15 | TextFirstRun=Creating Windows configuration, please wait... 16 | 17 | Title[da]=Dette er et Windows-program 18 | TextInstall[da]=Programmet %PROGRAM% er oprindeligt designet\ntil Microsoft Windows.\n\nDu kan prøve at køre det ved at bruge programmet Wine,\nbemærk dog at det ikke er sikkert at alle Windows-programmer\nvil fungere korrekt. 19 | TextPermission[da]=Windows-programmet %PROGRAM%\nkræver tilladelse for at starte. 20 | TextFirstRun[da]=Opretter ny Windows-konfiguration, vent venligst... 21 | 22 | 23 | [Desktop Entry] 24 | Type=Application 25 | Name=Wine Windows Program Loader 26 | Name[de]=Wine Windows-Programmstarter 27 | Name[es]=Wine Cargador de programas de Windows 28 | Name[nl]=Wine Windows programmalader 29 | Name[sv]=Wine Windows Programstartare 30 | Name[ru]=Wine - загрузчик Windows программ 31 | Name[uk]=Wine - завантажувач Windows програм 32 | Name[fr]=Wine Exécuter des programmes Windows 33 | Name[ca]=Wine - Carregador d'aplicacions del Windows 34 | Name[pt]=Carregador de aplicativos Windows Wine 35 | Name[pt_br]=Carregador de aplicativos Windows Wine 36 | Name[it]=Wine Carica Programmi Windows 37 | Name[da]=Wine, Programstarter til Windows-programmer 38 | Name[nb]=Wine Programlaster for Windowsapplikasjoner 39 | Name[nn]=Wine Programlaster for Windowsapplikasjoner 40 | Exec=exe-handler --wine %f 41 | MimeType=application/x-ms-dos-executable;application/x-msdos-program;application/x-msdownload;application/exe;application/x-exe;application/dos-exe;vms/exe;application/x-winexe;application/msdos-windows;application/x-zip-compressed;application/x-executable;application/x-msi; 42 | NoDisplay=true 43 | -------------------------------------------------------------------------------- /data/appsupport/starcraft2.vsc: -------------------------------------------------------------------------------- 1 | # /usr/bin/env vineyard-script 2 | # The comments before the first command will be read by Vineyard. 3 | # A line starting with ## will be considered a field name. 4 | # A line starting with ### will be considered a field value. 5 | # If a field name line contains [...] at the end, this will be considered the 6 | # language for the value. 7 | # All fields defined in this section will also be available to the script in 8 | # their capitalised form. 9 | # 10 | ## Type 11 | ### Application 12 | ## Name 13 | ### StarCraft II: Wings of Liberty 14 | # 15 | ## Description 16 | ### The first part of the three part sequel to the award winning 1998 real-time strategy game StarCraft. 17 | ## Description [da] 18 | ### Den første del af den tre-delte efterfølger til det prisbelønnede realtids-strategispil StarCraft fra 1998. 19 | ## Category 20 | ### Games, Strategy 21 | # 22 | #FIXME: These are not good places to get the icons from, and is probably not legal either. 23 | #SUGGESTION: Make new ones from scratch. 24 | ## Icon 25 | ### http://macin.files.wordpress.com/2010/07/starcraft-ii-icon.png 26 | ## IconSmall 27 | ### http://img.brothersoft.com/icon/softimage/s/starcraft_ii-_wings_of_liberty_%5Bkorea%5D-387147-1280215720.jpeg 28 | # 29 | ## License 30 | ### Commercial 31 | 32 | KERNELVERSION="$(uname -r)" 33 | if [ OLDEST-VERSION "$KERNELVERSION" "2.6.35" == "$KERNELVERSION" ]; then 34 |     PRENOTE="You are running version $KERNELVERSION of the Linux kernel. This game is known to have issues on Linux kernels older than 2.6.35. If you experience crashes before the loading screen or after logging in, please consider upgrading your kernel." 35 | fi 36 | SHOW --text "Installing dependancies..." -status "waiting" 37 | INSTALL droid fontfix fontsmooth-rgb allfonts gdiplus gecko vcrun2008 vcrun2005 d3dx9 win7 38 | SET-LIBRARY-OVERRIDE mmdevapi disabled 39 | SET-REGISTRY 'HKEY_CURRENT_USER\Software\Wine\Direct3D\UseGLSL' 'disabled' 40 | 41 | INFO --text "Copying installation files..." -status "waiting" 42 | 43 | # Copy files from CDROM, polling the size and thereby the progress in percentage 44 | # Not fully implemented yet. 45 | 46 | INFO --text "Installing StarCraft II..." -status "waiting" 47 | 48 | RUN 'CDROM:\installer.exe' 49 | if ASK 'StarCraft II has been successfully installed.\n\nWould you like to start the game now?'; then 50 |     RUN 'C:\%ProgramFiles%\StarCraft~\StarCraft II.exe' 51 | fi -------------------------------------------------------------------------------- /vineyard/pages/devices.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import page 7 | from vineyard.widgets import direct3d_vertexshader, direct3d_pixelshader, direct3d_allow_multisampling, direct3d_antialiasing, direct3d_offscreen_rendering, direct3d_video_memory_size, directx_capture_mouse, directinput_mouse_warp, graphics_xrandr, direct3d_csmt, direct3d_dxva2_vaapi, direct3d_check_float_constants 8 | from vineyard.widgets import sound_driver, sound_directsound_acceleration, sound_directsound_samplerate, sound_directsound_bitdepth, sound_directsound_emulation, sound_directsound_eax 9 | 10 | id = 'devices' 11 | position = 0.3 12 | 13 | class Page(page.VineyardPage): 14 | def __init__(self, dev=False): 15 | page.VineyardPage.__init__(self, 16 | name = _("Devices"), 17 | icon = 'applications-multimedia', 18 | pages = [ 19 | (_('Graphics'), [ 20 | (_('Direct3D'), [ 21 | direct3d_vertexshader, 22 | direct3d_pixelshader, 23 | direct3d_antialiasing, 24 | direct3d_allow_multisampling, 25 | directx_capture_mouse, 26 | graphics_xrandr, 27 | directinput_mouse_warp, 28 | direct3d_offscreen_rendering 29 | ]), 30 | (_('Direct3D Video Memory size'), [ 31 | direct3d_video_memory_size 32 | ]), 33 | (_('Direct3D Extra Features'), [ 34 | direct3d_csmt, 35 | direct3d_dxva2_vaapi, 36 | direct3d_check_float_constants 37 | ]) 38 | ]), 39 | (_('Sound'), [ 40 | (_('Sound Output'), [ 41 | sound_driver 42 | ]), 43 | (_('DirectSound Emulation'), [ 44 | sound_directsound_acceleration, 45 | sound_directsound_samplerate, 46 | sound_directsound_bitdepth, 47 | sound_directsound_emulation 48 | ]), 49 | (_('DirectSound Extra Features'), [ 50 | sound_directsound_eax 51 | ]) 52 | ]) 53 | ]) 54 | 55 | -------------------------------------------------------------------------------- /tools/package_python-wine.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | name="python-wine" 4 | dir="python-wine" 5 | 6 | 7 | path="$(readlink -f "$(dirname "$0")/../")" 8 | version="$(head "$path/$dir/debian/changelog" -n 1 | cut -d\( -f2 | cut -d\) -f1)" 9 | distros=( $(head "$path/$dir/debian/changelog" -n 1 | cut -d\) -f2 | cut -d\; -f1) ) 10 | package_name="$(head "$path/$dir/debian/changelog" -n 1 | cut -d\ -f1)" 11 | package_priority="$(head "$path/$dir/debian/changelog" -n 1 | cut -d\; -f2)" 12 | sourceversion="$(echo $version | cut -d- -f1)" 13 | 14 | sourcedir="$name"-"$sourceversion" 15 | sourcetar="$name"_"$sourceversion.orig.tar.gz" 16 | 17 | cd "$path" 18 | 19 | echo -n "Copying the $name directory to /tmp..." 20 | if [ -d "/tmp/$sourcedir" ]; then 21 | rm -R "/tmp/$sourcedir" 22 | fi 23 | cp -R "$dir" "/tmp/$sourcedir" 24 | rm -R "/tmp/$sourcedir/.bzr" 25 | echo " done." 26 | 27 | cd /tmp 28 | 29 | echo -n "Creating TAR.GZ archive of $name version $sourceversion..." 30 | tar --exclude "$sourcedir/.bzr" --exclude "$sourcedir/.bzrignore" --exclude "$sourcedir/debian" -czf "$sourcetar" "$sourcedir" 31 | cp "$sourcetar" "$sourcedir.tar.gz" 32 | echo " done." 33 | 34 | echo -n "Signing TAR.GZ archive..." 35 | gpg --armor --yes --sign --detach-sig "$sourcedir.tar.gz" 36 | echo " done." 37 | 38 | echo -n "Creating binary package of $name version $version..." 39 | cd "$sourcedir" 40 | debuild -sa > "/tmp/$package_name-$version~${distros[${#distros[@]}-1]}.build-log-binary" 41 | cd .. 42 | echo " done." 43 | 44 | 45 | # If length of distros is more than one then we have to create a package for 46 | # each distribution, otherwise Launchpad/soyuz won't accept it (though it should >:( ) 47 | if [ ${#distros[@]} -gt 1 ]; then 48 | echo "Package supports more than one distribution, creating multiple source packages..." 49 | for i in $(seq 0 $((${#distros[@]} - 1))); do 50 | echo -ne "\t${distros[$i]}..." 51 | echo "$package_name ($version~${distros[$i]}) ${distros[$i]};$package_priority" > "$sourcedir/debian/changelog" 52 | tail "$path/$dir/debian/changelog" -n +2 >> "$sourcedir/debian/changelog" 53 | echo " done." 54 | echo -n "Creating source package of $name version $version for ${distros[$i]}..." 55 | cd "$sourcedir" 56 | debuild -S -sa > "/tmp/$package_name-$version~${distros[$i]}.build-log-source" 57 | cd .. 58 | echo " done." 59 | done 60 | else 61 | echo -n "Creating source package of $name version $version for ${distros[0]}..." 62 | cd "$sourcedir" 63 | debuild -S -sa > "/tmp/$package_name-$version~${distros[$0]}.build-log-source" 64 | cd .. 65 | echo " done." 66 | fi -------------------------------------------------------------------------------- /vineyard/gtkwidgets/icondialog.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | 7 | import gobject, gtk 8 | import vineyard 9 | 10 | class IconDialog(gtk.Dialog): 11 | def __init__(self, *args, **kwargs): 12 | dialog_kwargs = kwargs.copy() 13 | for arg in ('image', 'pixbuf', 'text', 'text_secondary'): 14 | try: 15 | del dialog_kwargs[arg] 16 | except: 17 | pass 18 | gtk.Dialog.__init__(self, *args, **dialog_kwargs) 19 | 20 | self.set_icon_name('vineyard') 21 | 22 | self.hbox = gtk.HBox() 23 | self.hbox.set_spacing(6) 24 | self.hbox.set_border_width(6) 25 | 26 | self.innervbox = gtk.VBox() 27 | self.innervbox.set_spacing(6) 28 | 29 | self.hbox.pack_end(self.innervbox) 30 | 31 | self.vbox.add(self.hbox) 32 | 33 | self.image = gtk.Image() 34 | 35 | if 'image' in kwargs: 36 | if kwargs['image'][0] == '/': 37 | pixbuf = vineyard.pixbuf_new_from_any_file( 38 | kwargs['image'], 39 | size = gtk.icon_size_lookup(gtk.ICON_SIZE_DIALOG)[1] 40 | ) 41 | else: 42 | pixbuf = vineyard.pixbuf_new_from_string( 43 | kwargs['image'], 44 | icon_size = gtk.ICON_SIZE_DIALOG, 45 | return_first = True 46 | ) 47 | elif 'pixbuf' in kwargs: 48 | pixbuf = kwargs['pixbuf'] 49 | else: 50 | pixbuf = vineyard.pixbuf_new_from_string( 51 | 'vineyard', 52 | icon_size = gtk.ICON_SIZE_DIALOG 53 | ) 54 | 55 | self.image.set_from_pixbuf(pixbuf) 56 | 57 | self.image.set_alignment(0.5, 0.0) 58 | self.hbox.pack_start(self.image, expand=False, fill=False) 59 | 60 | self.label_first = gtk.Label() 61 | self.label_first.set_alignment(0.0, 0.5) 62 | self.innervbox.pack_start(self.label_first, expand=False, fill=True) 63 | 64 | if 'text' in kwargs: 65 | self.set_markup(kwargs['text']) 66 | 67 | self.label_second = gtk.Label() 68 | self.label_second.set_alignment(0.0, 0.5) 69 | self.innervbox.pack_start(self.label_second, expand=False, fill=True) 70 | 71 | if 'text_secondary' in kwargs: 72 | self.set_markup_second(kwargs['text_secondary']) 73 | 74 | def set_markup(self, text): 75 | self.label_first.set_markup( 76 | '{0}'.format( 77 | text 78 | ) 79 | ) 80 | 81 | def set_markup_second(self, text): 82 | self.label_second.set_markup(text) -------------------------------------------------------------------------------- /vineyard/widgets/tool_run_executable.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import gtk, glib, widget, wine, os 7 | from vineyard import common, program_handler 8 | 9 | class Widget(widget.VineyardWidget): 10 | def __init__(self): 11 | widget.VineyardWidget.__init__(self) 12 | self.title = _("Run executable") 13 | self.icon = 'gtk-execute' 14 | self._build_interface() 15 | 16 | def _build_interface(self): 17 | self.hbox = gtk.HBox() 18 | self.label = gtk.Label('%s: ' % self.title) 19 | self.hbox.pack_start(self.label, False, False) 20 | self.filechooser = gtk.FileChooserButton(_("Select an executable")) 21 | self.filechooser.add_filter(common.filefilters['all']) 22 | self.filechooser.add_filter(common.filefilters['windows_executables']) 23 | self.filechooser.set_filter(common.filefilters['windows_executables']) 24 | self.filechooser.connect('file-set', self._on_filechooser_file_set) 25 | try: 26 | main_drive = wine.drives.get_main_drive(use_registry=False)['mapping'] 27 | self.filechooser.add_shortcut_folder(main_drive) 28 | except: 29 | pass 30 | self.hbox.pack_start(self.filechooser, True, True) 31 | self.button_run = common.button_new_with_image(self.icon, label=_("_Run"), use_underline=True) 32 | self.hbox.pack_end(self.button_run, False, False) 33 | self.pack_start(self.hbox, True, False) 34 | self.button_run.set_sensitive(False) 35 | self.show_all() 36 | 37 | self.button_run.connect('clicked', self.button_clicked) 38 | 39 | def on_reset(self): 40 | try: 41 | folders = [ i for i in self.filechooser.list_shortcut_folders() ] 42 | except TypeError: 43 | folders = [] 44 | for folder in self.filechooser.list_shortcut_folders(): 45 | self.filechooser.remove_shortcut_folder(folder) 46 | try: 47 | main_drive = wine.drives.get_main_drive(use_registry=False)['mapping'] 48 | self.filechooser.add_shortcut_folder(main_drive) 49 | except glib.GError: 50 | pass 51 | 52 | def button_clicked(self, button): 53 | if self.gobject.loading: return False 54 | 55 | filename = self.filechooser.get_filename() 56 | if filename != None: 57 | program_handler.MonitoredProgram([filename], os.path.basename(filename)) 58 | 59 | def _on_filechooser_file_set(self, filechooser): 60 | file_name = filechooser.get_filename() 61 | if file_name is not None: 62 | self.button_run.set_sensitive(True) 63 | else: 64 | self.button_run.set_sensitive(False) 65 | 66 | -------------------------------------------------------------------------------- /rpm/vineyard.spec: -------------------------------------------------------------------------------- 1 | #### NOTE: if building locally you may need to do the following: 2 | #### 3 | #### yum install rpmdevtools -y 4 | #### spectool -g -R rpm/quads.spec 5 | #### 6 | #### At this point you can use rpmbuild -ba quads.spec 7 | #### (this is because our Source0 is a remote Github location 8 | #### 9 | #### Our upstream repository is located here: 10 | #### https://copr.fedorainfracloud.org/coprs/cybolic/Vineyard 11 | 12 | %define srcname vineyard 13 | %define version 0.1.6 14 | %define build_timestamp %{lua: print(os.date("%Y%m%d"))} 15 | 16 | Summary: Easy to use Wine configuration program and utility library 17 | Name: %{srcname} 18 | Version: %{version} 19 | Release: %{build_timestamp} 20 | Source0: https://github.com/Cybolic/vineyard/archive/master.zip#/%{srcname}-%{version}-%{release}.tar.gz 21 | License: GPLv2+ 22 | BuildRequires: python2-devel 23 | BuildArch: noarch 24 | Vendor: Christian Dannie Storgaard 25 | %{?python_provide:%python_provide python-wine} 26 | Requires: (wine or wine-staging) 27 | Requires: cabextract 28 | Requires: winetricks 29 | Requires: unzip 30 | Requires: pygtk2 31 | Requires: pygtk2-libglade 32 | Recommends: python2-dbus 33 | Recommends: mallard-rng 34 | Recommends: nautilus-python 35 | Url: https://github.com/Cybolic/vineyard 36 | 37 | %description 38 | 39 | Vineyard is a user friendly configuration tool for Wine that offers all the 40 | features of winecfg (with the exception of the unfinished theme-support) as 41 | well as bottle-handling and program-management in an easy to use program 42 | designed to blend in with the GNOME desktop. 43 | 44 | %prep 45 | %autosetup -n %{srcname}-master 46 | 47 | %build 48 | # python setup.py build 49 | %py2_build 50 | 51 | %install 52 | %py2_install 53 | mkdir -p ${RPM_BUILD_ROOT}%{_datadir}/nautilus-python 54 | # rpmlint will complain if we write the library path normally, hence the [i] 55 | mv ${RPM_BUILD_ROOT}/usr/l[i]b/nautilus/extensions-2.0 ${RPM_BUILD_ROOT}%{_datadir}/nautilus-python/extensions 56 | 57 | %clean 58 | rm -rf $RPM_BUILD_ROOT 59 | 60 | %files 61 | %defattr(-,root,root) 62 | %license COPYING 63 | %doc README.md 64 | %docdir %{_datadir}/vineyard/docs 65 | %{python2_sitelib}/* 66 | %{_bindir}/vineyard* 67 | %{_datadir}/vineyard 68 | %{_datadir}/applications 69 | %{_datadir}/icons 70 | %{_sysconfdir}/xdg/autostart 71 | %{_datadir}/man 72 | %{_datadir}/nautilus-python/extensions 73 | 74 | %changelog 75 | 76 | * Tue Dec 5 2017 - 0.1.6: Christian Dannie Storgaard 77 | - Spec updated to work better in regards to outdated packages 78 | 79 | * Sat Dec 2 2017 - 0.1.6: Christian Dannie Storgaard 80 | - Initial spec file and RPM package 81 | - This will be available in Fedora COPR, updated in sync with master 82 | - https://copr.fedorainfracloud.org/coprs/cybolic/Vineyard/ 83 | -------------------------------------------------------------------------------- /vineyard/widgets/direct3d_video_memory_size.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import gtk, widget, wine 7 | 8 | class Widget(widget.VineyardWidget): 9 | def __init__(self): 10 | widget.VineyardWidget.__init__(self) 11 | self.title = "Direct3D Video Memory size" 12 | self.settings_key = 'direct3d-video-memory-size' 13 | self.set_function = wine.graphics.set_video_memory_size 14 | self._build_interface() 15 | 16 | def _build_interface(self): 17 | self.table = gtk.Table(rows=2, columns=2, homogeneous=False) 18 | 19 | self.radiobutton_auto = gtk.RadioButton(label=_("Auto detected")) 20 | self.radiobutton_auto.set_alignment(0.0, 0.5) 21 | self.table.attach(self.radiobutton_auto, 0,1, 0,1, gtk.FILL|gtk.EXPAND,0, 0,0) 22 | 23 | self.radiobutton_absolute = gtk.RadioButton(label='%s: ' % _("Absolute in MB"), group=self.radiobutton_auto) 24 | self.radiobutton_absolute.set_alignment(0.0, 0.5) 25 | self.table.attach(self.radiobutton_absolute, 0,1, 1,2, gtk.FILL|gtk.EXPAND,0, 0,0) 26 | 27 | self.spinbutton = gtk.SpinButton(climb_rate=16.0, digits=0) 28 | self.spinbutton.set_numeric(True) 29 | self.spinbutton.get_adjustment().set_lower(1) 30 | self.spinbutton.get_adjustment().set_upper(262144) # 256 GB, this should hold for some time 31 | self.spinbutton.get_adjustment().set_step_increment(1) 32 | self.table.attach(self.spinbutton, 1,2, 1,2, gtk.FILL|gtk.EXPAND,0, 0,0) 33 | 34 | self.pack_start(self.table) 35 | self.show_all() 36 | 37 | self.radiobutton_auto.connect('toggled', self.radiobutton_auto_toggled) 38 | self.spinbutton.connect_after('value-changed', self.spinbutton_changed) 39 | 40 | def radiobutton_auto_toggled(self, radiobutton): 41 | if self.gobject.loading: return False 42 | 43 | self.settings[self.settings_key] = None if radiobutton.get_active() else self.spinbutton.get_value_as_int() 44 | self.gobject.emit('settings-changed', self.settings_key, self.set_function, (self.settings[self.settings_key],)) 45 | 46 | def spinbutton_changed(self, spinbutton): 47 | if self.gobject.loading: return False 48 | 49 | self.radiobutton_absolute.set_active(True) 50 | self.settings[self.settings_key] = spinbutton.get_value_as_int() 51 | self.gobject.emit('settings-changed', self.settings_key, self.set_function, (self.settings[self.settings_key],)) 52 | 53 | def load_settings(self): 54 | self.settings[self.settings_key] = wine.graphics.get_video_memory_size() 55 | 56 | def fill_widgets(self): 57 | if self.settings[self.settings_key] == None: 58 | self.radiobutton_auto.set_active(True) 59 | else: 60 | self.radiobutton_absolute.set_active(True) 61 | self.spinbutton.set_value(int(self.settings[self.settings_key])) 62 | 63 | self.gobject.emit('settings-loaded', self.settings_key, (self.settings[self.settings_key],)) 64 | -------------------------------------------------------------------------------- /tools/package_vineyard.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | name="vineyard" 4 | #dir="trunk" 5 | dir="$(basename "$(readlink -f "$(dirname "$0")/../")")" 6 | 7 | path="$(readlink -f "$(dirname "$0")/../../")" 8 | version="$(head "$path/$dir/debian/changelog" -n 1 | cut -d\( -f2 | cut -d\) -f1)" 9 | distros=( $(head "$path/$dir/debian/changelog" -n 1 | cut -d\) -f2 | cut -d\; -f1) ) 10 | package_name="$(head "$path/$dir/debian/changelog" -n 1 | cut -d\ -f1)" 11 | package_priority="$(head "$path/$dir/debian/changelog" -n 1 | cut -d\; -f2)" 12 | sourceversion="$(echo $version | cut -d- -f1)" 13 | 14 | sourcedir="$name"-"$sourceversion" 15 | sourcetar="$name"_"$sourceversion.orig.tar.gz" 16 | 17 | cd "$path" 18 | 19 | echo -n "Copying the $name directory to /tmp..." 20 | if [ -d "/tmp/$sourcedir" ]; then 21 | rm -R "/tmp/$sourcedir" 22 | fi 23 | cp -R "$dir" "/tmp/$sourcedir" 24 | rm -R "/tmp/$sourcedir/.bzr" "/tmp/$sourcedir/tools" "/tmp/$sourcedir/python-wine" 25 | echo " done." 26 | 27 | echo -n "Compiling MAN page..." 28 | pod2man --section=1 --release=$sourceversion --center="Windows On Unix" "/tmp/$sourcedir/data/vineyard-preferences.pod" > "/tmp/$sourcedir/data/vineyard-preferences.1" 29 | gzip -9 "/tmp/$sourcedir/data/vineyard-preferences.1" 30 | echo " done." 31 | 32 | cd /tmp 33 | 34 | echo -n "Creating TAR.GZ archive of $name version $sourceversion..." 35 | tar --exclude "$sourcedir/.bzr" --exclude "$sourcedir/.bzrignore" --exclude "$sourcedir/debian" --exclude "$sourcedir/python-wine" --exclude "$sourcedir/tools" --exclude "$sourcedir/data/cache.pyc" -czf "$sourcetar" "$sourcedir" 36 | cp "$sourcetar" "$sourcedir.tar.gz" 37 | echo " done." 38 | 39 | echo -n "Signing TAR.GZ archive..." 40 | gpg --armor --yes --sign --detach-sig "$sourcedir.tar.gz" 41 | echo " done." 42 | 43 | echo -n "Creating binary package of $name version $version..." 44 | cd "$sourcedir" 45 | if ! $(debuild -sa > "/tmp/$package_name-$version~${distros[${#distros[@]}-1]}.build-log-binary"); then 46 | echo "Build failed. Check /tmp/$package_name-$version~${distros[${#distros[@]}-1]}.build-log-binary for details." 47 | exit 1 48 | fi 49 | cd .. 50 | echo " done." 51 | 52 | 53 | # If length of distros is more than one then we have to create a package for 54 | # each distribution, otherwise Launchpad/soyuz won't accept it (though it should >:( ) 55 | if [ ${#distros[@]} -gt 1 ]; then 56 | echo "Package supports more than one distribution, creating multiple source packages..." 57 | for i in $(seq 0 $((${#distros[@]} - 1))); do 58 | echo -ne "\t${distros[$i]}..." 59 | echo "$package_name ($version~${distros[$i]}) ${distros[$i]};$package_priority" > "$sourcedir/debian/changelog" 60 | tail "$path/$dir/debian/changelog" -n +2 >> "$sourcedir/debian/changelog" 61 | echo " done." 62 | echo -n "Creating source package of $name version $version for ${distros[$i]}..." 63 | cd "$sourcedir" 64 | debuild -S -sa > "/tmp/$package_name-$version~${distros[$i]}.build-log-source" 65 | cd .. 66 | echo " done." 67 | done 68 | else 69 | echo -n "Creating source package of $name version $version for ${distros[0]}..." 70 | cd "$sourcedir" 71 | debuild -S -sa > "/tmp/$package_name-$version~${distros[$0]}.build-log-source" 72 | cd .. 73 | echo " done." 74 | fi 75 | -------------------------------------------------------------------------------- /data/docs/problemprogramnotshowing.page: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | 7 | 8 | 9 | Christian Dannie Storgaard 10 | cybolic@gmail.com 11 | 2010 12 | 13 | 14 | How to get a program to show up in the programs listing. 15 | 16 | Missing a program? 17 |

18 | If a program has installed itself in the registry or created an item in the virtual Start Menu then Vineyard should be able to find it. In some cases this fails, f.x. when the menu item has a different name than the registry information, if the registry information is now written according to the (known) Microsoft Windows standards or in case you manually installed, extracted or copied the program in to the configuration. 19 | If this happens you can help Vineyard along by either creating the relevant information in the registry or defining a program override (not fully implemented yet). 20 |

21 | 22 | Adding information about a program to the registry (yes, this will be automated in a future version): 23 |

Open the Wine Preferences (SystemPreferencesWine Preferences)

24 |

Select the configuration you have installed the program in to (if applicable)

25 |

Go to the Tools page

26 |

Open the registry editor (by clicking Registry Editor)

27 |

Navigate to HKEY_LOCAL_MACHINESoftwareMicrosoftWindowsCurrentVersionUninstall (make sure you end up with Uninstall selected)

28 |

Right click in the right side of the window, select NewKey and write a short name for the program

29 |

With your program name selected (it already should be) right click the right side again, select NewString Value and write DisplayName

30 |

Double click the "DisplayName" line in the right side area and write the full name of the program

31 |

Repeat step 7-8 and instead of "DisplayName", write DisplayIcon and then the path to the program's icon - note that this is in Windows path style (e.g. C:\Program Files\program.exe - note that you can use an exe as an icon)

32 |
33 | 34 |

If you already know how to use the registry editor, these are the keys you should create:

35 | 36 | [HKEY_LOCAL_MACHINE\\Software\\Microsoft\\Windows\\CurrentVersion\\Uninstall] 37 | [HKEY_LOCAL_MACHINE\\Software\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\SHORT_PROGRAM_NAME] 38 | "DisplayName"="The Name of the Program" 39 | "DisplayIcon"="C:\\Path\\to\\where\\the\\program\\is\\located\\PROGRAM_ICON.exe" 40 | "VineyardProgramExe"="C:\\Path\\to\\where\\the\\program\\is\\located\\program.exe" 41 | 42 |
43 |
44 | -------------------------------------------------------------------------------- /data/script-support-bash.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # Exit at any command failure 4 | set -e 5 | # Exit if any unused variable is attempted used 6 | set -u 7 | 8 | SCRIPT_DIR="$(cd "$(dirname "$0")//..//" && echo $PWD)" 9 | echo $SCRIPT_DIR 10 | VINEYARD_CLI="$(which vineyard-cli || echo "")" 11 | echo "$SCRIPT_DIR/vineyard-cli" 12 | if [ -z $VINEYARD_CLI ]; then 13 | if [ -x "$SCRIPT_DIR/vineyard-cli" ]; then 14 | VINEYARD_CLI="$SCRIPT_DIR/vineyard-cli" 15 | elif [ -x "$SCRIPT_DIR/../vineyard-cli" ]; then 16 | VINEYARD_CLI="$SCRIPT_DIR/../vineyard-cli" 17 | else 18 | echo "Couldn't find vineyard-cli, exiting." 19 | exit 1 20 | fi 21 | fi 22 | 23 | CONFIGURATION_DIR="$HOME" 24 | PYTHON_WINE_START='import sys, os; sys.path.insert(0, '"'%s/python-wine'"' % os.path.abspath(os.path.dirname(sys.argv[0]))); import wine; ' 25 | 26 | function CREATE_CONFIGURATION() { 27 | if [ -z "$OVERRIDE_CONFIGURATION_NAME" ]; then 28 | CONFIGURATION_NAME="$1" 29 | else 30 | CONFIGURATION_NAME="$OVERRIDE_CONFIGURATION_NAME" 31 | fi 32 | $VINEYARD_CLI --add-conf "$CONFIGURATION_NAME" 33 | 34 | CONFIGURATION_DIR="$($VINEYARD_CLI --list-confs | grep "$CONF_NAME")" 35 | CONFIGURATION_DIR="$(echo $CONFIGURATION_DIR | grep -E --color=never -o '/home/.*/\..*')" 36 | } 37 | 38 | function USE_CONFIGURATION() { 39 | CONFIGURATION_NAME="$1" 40 | $VINEYARD_CLI --use-conf "$CONFIGURATION_NAME" 41 | 42 | CONFIGURATION_DIR="$($VINEYARD_CLI --list-confs | grep "$CONF_NAME")" 43 | CONFIGURATION_DIR="$(echo $CONFIGURATION_DIR | grep -E --color=never -o '/home/.*/\..*')" 44 | } 45 | 46 | function RUN() { 47 | $VINEYARD_CLI --use-conf "$CONFIGURATION_NAME" --run "$@" 48 | } 49 | 50 | function INSTALL() { 51 | $VINEYARD_CLI --use-conf "$CONFIGURATION_NAME" --run "install $1" 52 | } 53 | 54 | function SET_REGISTRY() { 55 | $VINEYARD_CLI --set-registry "$@" 56 | } 57 | 58 | function SET_OVERRIDE() { 59 | python -c "$PYTHON_WINE_START"' wine.libraries.set_override(sys.argv[1], sys.argv[2])' "$1" "$2" 60 | } 61 | 62 | function SET_VERSION() { 63 | python -c "$PYTHON_WINE_START"' wine.prefixes.use("'$CONFIGURATION_NAME'"); wine.version.set(sys.argv[1])' "$@" 64 | } 65 | 66 | function WINE() { 67 | env WINEPREFIX="$CONFIGURATION_DIR/.wine" HOME="$CONFIGURATION_DIR" wine "$@" 68 | } 69 | 70 | function REGEDIT() { 71 | env WINEPREFIX="$CONFIGURATION_DIR/.wine" HOME="$CONFIGURATION_DIR" wine regedit "$@" 72 | } 73 | 74 | function WIN_TO_UNIX() { 75 | python -c "$PYTHON_WINE_START"' wine.prefixes.use("$CONFIGURATION_NAME"); print wine.util.wintounix(sys.argv[1])' "$@" 76 | } 77 | 78 | function UNIX_TO_WIN() { 79 | python -c "$PYTHON_WINE_START"' wine.prefixes.use("$CONFIGURATION_NAME"); print wine.util.unixtowin(sys.argv[1])' "$@" 80 | } 81 | 82 | function NOTIFY_OF_DRM() { 83 | # Pop up a dialog with the following: 84 | # "This game or program is known to use copy-protection or Digital Rights Management." 85 | # "Due to legality issues, this cannot be supported directly." 86 | # "You might be able to run the game by applying an unofficial patch (often called a NoCD patch or crack)." 87 | # "Again, this is a legal grey area, but you may have luck searching for it on the internet." 88 | } 89 | 90 | echo "Done" 91 | 92 | echo "$(WIN_TO_UNIX "%ProgramFiles%/Star Craft 2")" 93 | SET_OVERRIDE "multidllfiletest" "builtin, native" 94 | WINE winecfg -------------------------------------------------------------------------------- /vineyard/icons.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import gtk, glib 7 | try: 8 | import gio 9 | except ImportError: 10 | # Older systems might not have gio, 11 | # that's okay, we only use it to check why an icon fails to load. 12 | # Ff a system doesn't have gio, there will be no fallback icon 13 | pass 14 | import wine 15 | import logging 16 | 17 | logger = logging.getLogger("Wine Preferences - Icons") 18 | debug = logger.debug 19 | info = logger.info 20 | warning = logger.warning 21 | error = logger.error 22 | critical = logger.critical 23 | 24 | def get_icon_pixbuf_from_program(program=None, executable=None, size=32, force_update=False): 25 | # Fill the programs listview 26 | icon = wine.programs.get_icon( 27 | program = program, 28 | executable = executable, 29 | force_update = force_update 30 | ) 31 | #self.debug("Icon lookup for \"%s\" returns \"%s\"." % (info['name'], icon)) 32 | if icon is not None: 33 | icon = wine.icons.convert(icon) 34 | #if wine.util.isTempIcon(icon): 35 | # #self.debug("\tIcon is template, removing and looking up again...") 36 | # os.remove(icon) 37 | # icon = wine.programs.getIcon(program, force_update=force_update) 38 | if icon is not None: 39 | if type(icon) == list: 40 | """ Manual icon replacement for script files """ 41 | if icon == ['text-x-generic'] and 'programexe' in program and program['programexe'].lower().endswith('.bat'): 42 | icon = gtk.icon_theme_get_default().load_icon('text-x-script', size, 0) 43 | else: 44 | for iconname in icon: 45 | try: 46 | icon = gtk.icon_theme_get_default().load_icon(iconname, size, 0) 47 | break 48 | except glib.GError: 49 | continue 50 | else: 51 | try: 52 | icon = gtk.gdk.pixbuf_new_from_file_at_size(icon, size,size) 53 | except glib.GError: 54 | warning("Tried to read \"%s\" as an icon and failed." % icon) 55 | icon = None 56 | pass 57 | if icon is None: 58 | #self.debug("\tIcon lookup returned nothing.") 59 | try: 60 | try: 61 | icon = gtk.icon_theme_get_default().load_icon("application-x-ms-dos-executable", size, 0) 62 | except glib.GError, gio.Error: 63 | icon = gtk.icon_theme_get_default().load_icon("application-x-executable", size, 0) 64 | except: 65 | icon = None 66 | #self.debug("\tUsing template icon.") 67 | return icon 68 | 69 | def readPixbufFromFile(filename, size=None, only_programs=False): 70 | icon_file = wine.programs.getIcon({'name': 'vineyard-filepreview', 'icon': filename}, force_update=True) 71 | if icon_file == None: 72 | return None 73 | else: 74 | try: 75 | if size == None: 76 | return gtk.gdk.pixbuf_new_from_file(icon_file) 77 | else: 78 | return gtk.gdk.pixbuf_new_from_file_at_size(icon_file, size,size) 79 | except glib.GError: 80 | return None 81 | -------------------------------------------------------------------------------- /data/docs/whatisconf.page: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | 7 | 8 | 9 | Christian Dannie Storgaard 10 | cybolic@gmail.com 11 | 2010 12 | 13 | 14 | What exactly is a configuration? 15 | 16 | What is a configuration? 17 |

A configuration can be very closely compared to a separate installation of Microsoft Windows; it has a separate virtual hard-disk, complete with its own virtual Windows installation and registry, but unlike a separate installation of Microsoft Windows, it can still see your files and even the files of other configurations if you let it.

18 |

You may have seen almost the same concept in other Wine utilities (like CrossOver, Bordeaux, qWine or Cedega) under names like bottles, virtual harddisks or simply a wineprefix - note though that Vineyard's implementation is slightly different and copying installations from other solutions may not work completely.

19 | 20 |

In short, a configuration is similar to a separate Microsoft Windows installation or computer in the following ways:

21 | 22 |

It has its own main drive (C drive)

23 |

It has its own registry

24 |

It's programs can only see and talk to the programs in the same configuration

25 |
26 | 27 |

But unlike a real separate installation, it can:

28 | 29 |

See the same files as any other configuration (your home directory f.x.)

30 |

Have the same extra (virtual) hard-disks as another configuration

31 |
32 | 33 |
Detailed information 34 |

So Vineyard's configurations are different from other implementations, but how?

35 |

To answer this we first need to look at how Wine traditionally lay out its files.

36 | 37 |

The most basic directory structure of a normal Wine configuration simply has its files in $HOME/.wine, 38 | here you'll find the dosdevices directory that contains the virtual drives, including the C: drive.

39 |

Things get a bit more complicated when you start installing programs that in Windows would place themselves in the Start Menu since Wine will convert these files to FreeDesktop.org .desktop files and place them in various directories in $HOME/.local and let them show up in your Application menu.

40 |

As you may know, Windows programs usually create a submenu for themselves in which they place entries, not just for the programs installed, but also for documentation, links to the program's web page and various other entries.

41 |

Now, other implementations like bottles, virtual harddisks or wineprefixes simply allow for the creation of separate .wine directories, but allow the menu entries (and MIME type files) to mix with all other bottles/virtual harddisks/prefixes. This is not how Vineyard does it.

42 |

Vineyard instead treats a configuration as a separate HOME directory with it's own .wine directory, own .local directory and so on, avoiding the cross-polution that would otherwise incur while also keeping your Application menu clean.

43 |
44 |
45 | -------------------------------------------------------------------------------- /data/docs/differenceprogramconf.page: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | 7 | 8 | Christian Dannie Storgaard 9 | cybolic@gmail.com 10 | 2010 11 | 12 | 13 | The difference between program settings and configuration settings 14 | 15 | Program and Configuration settings 16 | 17 | 18 | Program settings 19 |

Program settings are basic settings that are applied to all executables that have the same name and that are run from the same configuration.

20 |
21 | 22 | Configurations 23 |

A configuration is basically a separate Windows installation and it's settings applies to all programs within it, except of course executables that have their own program settings.

24 |
25 |
26 | 27 |

In short, the settings are applied hierarchically, as in this example featuring:

28 | 29 | Game of Snakes 30 | Configuration settings 31 | Level editor 32 | Text editor 33 | Music program 34 | Program settings for engine.exe 35 | engine.exe (the actual game) 36 | 37 | 38 | 39 | Parrot Game 40 | Configuration settings 41 | engine.exe 42 | 43 | 44 | 45 | 46 |

To make it a bit more clear imagine that we have two configurations, one named Game of Snakes and one named Parrot Game (their full structure is displayed above).

47 |

In the Game of Snakes configuration we have installed a great game about snakes which executable is named engine.exe and in the Parrot Game configuration we have another game about parrots installed which executable is also named engine.exe. 48 | If we now set our Game of Snakes configuration to operate as Windows XP, the engine.exe and therefor the game will be run as if in Windows XP, but if we afterwards set the program settings for the engine.exe in the Game of Snakes to operate as Windows 98, then engine.exe and its game will be run as in Windows 98, even though the configuration is set to run as Windows XP.

49 | 50 |

The difference between the two settings is that if you install another program into the Game of Snakes configuration, then that program will still be run with the settings for the configuration, not for engine.exe. This can be useful in case you f.x. install a level editor, a text-editor and let's say a music program for making your own levels for the snake game and they should all be run as in Windows XP, but the game itself functions better when run as Windows 98.

51 | 52 |

Now, let's get back to the Parrot Game. Because this is a completely different configuration, the program settings for engine.exe we did in the Game of Snakes configuration has no effect here, instead the settings for the actual configuration (Parrot Game) will be used.

53 | 54 |

Also, as you may have guessed, if we install another program in to the Game of Snakes configuration that also has an executable named engine.exe (f.x. the sequel: Clash of the Pythons) then this will run with the same settings as the first game since program settings are applied to all programs with the same executable filename. 55 |

56 |
57 | -------------------------------------------------------------------------------- /tests/widget_overlay.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | 6 | import gtk, gobject, cairo, pango 7 | 8 | def set_loading_overlay(widget, state=True): 9 | def _expose_event(widget, event): 10 | # Setup Cairo drawing area 11 | context = widget.window.cairo_create() 12 | region = gtk.gdk.region_rectangle(gtk.gdk.Rectangle(0,0, widget.allocation.width, widget.allocation.height)) 13 | region_exposed = gtk.gdk.region_rectangle(event.area) 14 | region.intersect(region_exposed) 15 | context.region(region) 16 | context.clip() 17 | 18 | # Fill with window background color at 0.5 opacity 19 | context.set_source_rgb(*gdk_color_to_float(widget.get_style().bg[gtk.STATE_NORMAL])) 20 | context.fill_preserve() 21 | context.paint_with_alpha(0.5) 22 | 23 | # Draw loading label 24 | cairo_add_text_in_widget_style(context, "Loading...", widget, size_factor=1.4, weight='bold', alignment='center') 25 | 26 | if state: 27 | widget.overlayed = True 28 | widget._overlay_signal_id = widget.connect_after('expose-event', _expose_event) 29 | elif 'overlayed' in dir(widget): 30 | widget.overlayed = False 31 | widget.disconnect(widget._overlay_signal_id) 32 | widget.window.invalidate_rect(gtk.gdk.Rectangle(0,0, widget.allocation.width, widget.allocation.height), True) 33 | widget.window.process_updates(True) 34 | 35 | def pixbuf_from_widget(widget): 36 | widget.window.process_updates(True) 37 | x, y, width, height, bit_depth = widget.window.get_geometry() 38 | pixbuf = gtk.gdk.Pixbuf(gtk.gdk.COLORSPACE_RGB, False, 8, width, height) 39 | pixbuf.get_from_drawable(widget.window, 40 | widget.window.get_colormap(), 41 | 0, 0, 0, 0, width, height) 42 | return pixbuf 43 | 44 | def cairo_add_text_in_widget_style(context, text, widget=None, size_factor=1.2, weight='normal', alignment='left'): 45 | weight = {'normal':cairo.FONT_WEIGHT_NORMAL, 'bold':cairo.FONT_WEIGHT_BOLD}[weight.lower()] 46 | 47 | if widget != None: 48 | context.set_source_rgb(*gdk_color_to_float(widget.get_style().text[gtk.STATE_NORMAL])) 49 | context.select_font_face(widget.get_style().font_desc.get_family(), 50 | cairo.FONT_SLANT_NORMAL, weight) 51 | context.set_font_size(pango.PIXELS(widget.get_style().font_desc.get_size())*size_factor) 52 | 53 | x_bearing, y_bearing, width, height = context.text_extents(text)[:4] 54 | 55 | if alignment.lower() == 'left': 56 | context.move_to( 57 | x_bearing, 58 | widget.allocation.height/2 - height / 2 - y_bearing 59 | ) 60 | elif alignment.lower() == 'right': 61 | context.move_to( 62 | widget.allocation.width - width - x_bearing, 63 | widget.allocation.height/2 - height / 2 - y_bearing 64 | ) 65 | elif alignment.lower() == 'center': 66 | context.move_to( 67 | widget.allocation.width/2 - width / 2 - x_bearing, 68 | widget.allocation.height/2 - height / 2 - y_bearing 69 | ) 70 | 71 | context.show_text(text) 72 | 73 | def gdk_color_to_float(gdk_color): 74 | return gdk_color.red/65535., gdk_color.green/65535., gdk_color.blue/65535. 75 | 76 | #pixbuf = gtk.gdk.Pixbuf( gtk.gdk.COLORSPACE_RGB, False, 8, 640, 480) 77 | #> pixbuf.get_from_drawable( self.movie_window.window, 78 | #> self.movie_window.get_colormap(), 0, 0, 0, 0, 640, 480) 79 | 80 | def toggle(*args): 81 | set_loading_overlay(b, not b.overlayed) 82 | 83 | w = gtk.Window() 84 | v = gtk.VBox(spacing=6) 85 | w.add(v) 86 | b = gtk.Button("Hello World") 87 | v.pack_start(b) 88 | b.overlayed = False 89 | b2 = gtk.Button("Toggle") 90 | b2.connect('clicked', toggle) 91 | v.pack_start(b2) 92 | w.show_all() 93 | 94 | #gobject.idle_add(pixbuf_from_widget, b) 95 | 96 | #gobject.timeout_add(50, gtk.main_quit) 97 | gtk.main() 98 | -------------------------------------------------------------------------------- /data/icons/16/vineyard-panel.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 19 | 21 | 22 | 24 | image/svg+xml 25 | 27 | 28 | 29 | 30 | 31 | 54 | 57 | 58 | 60 | 67 | 74 | 75 | 79 | 80 | -------------------------------------------------------------------------------- /vineyard/widgets/virtual_desktop.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | import gobject, gtk, widget 7 | import wine 8 | 9 | class Widget(widget.VineyardWidget): 10 | def __init__(self): 11 | widget.VineyardWidget.__init__(self, {'desktop': None}) 12 | self._build_interface() 13 | 14 | def _build_interface(self): 15 | self.table = gtk.Table(rows=2, columns=1, homogeneous=False) 16 | 17 | self.checkbutton = gtk.CheckButton(_('Open program windows in a virtual desktop')) 18 | self.table.attach(self.checkbutton, 0,1, 0,1, gtk.FILL,0, 0,0) 19 | 20 | self.table_values = gtk.Table(rows=2, columns=3, homogeneous=False) 21 | self.table.attach(self.table_values, 0,1, 1,2, gtk.FILL,gtk.FILL, 0,0) 22 | 23 | self.label_desktop_width = gtk.Label(_('Desktop width: ')) 24 | self.label_desktop_width.set_padding(24,0) 25 | self.label_desktop_width.set_alignment(0.0, 0.5) 26 | self.table_values.attach(self.label_desktop_width, 0,1, 0,1, gtk.FILL,0, 0,0) 27 | 28 | self.spinbutton_width = gtk.SpinButton(climb_rate=1.0) 29 | self.spinbutton_width.get_adjustment().set_all(1024.0, lower=0, upper=10000, step_increment=1, page_increment=10, page_size=0) 30 | self.table_values.attach(self.spinbutton_width, 1,2, 0,1, gtk.FILL,0, 0,0) 31 | 32 | self.label_desktop_width_pixels = gtk.Label(_('pixels')) 33 | self.label_desktop_width_pixels.set_padding(6,0) 34 | self.table_values.attach(self.label_desktop_width_pixels, 2,3, 0,1, gtk.FILL,0, 0,0) 35 | 36 | self.label_desktop_width = gtk.Label(_('Desktop height: ')) 37 | self.label_desktop_width.set_padding(24,0) 38 | self.label_desktop_width.set_alignment(0.0, 0.5) 39 | self.table_values.attach(self.label_desktop_width, 0,1, 1,2, gtk.FILL,0, 0,0) 40 | 41 | self.spinbutton_height = gtk.SpinButton(climb_rate=1.0) 42 | self.spinbutton_height.get_adjustment().set_all(768.0, lower=0, upper=10000, step_increment=1, page_increment=10, page_size=0) 43 | self.table_values.attach(self.spinbutton_height, 1,2, 1,2, gtk.FILL,0, 0,0) 44 | 45 | self.label_desktop_height_pixels = gtk.Label(_('pixels')) 46 | self.label_desktop_height_pixels.set_padding(6,0) 47 | self.table_values.attach(self.label_desktop_height_pixels, 2,3, 1,2, gtk.FILL,0, 0,0) 48 | 49 | self.table.show_all() 50 | self.pack_start(self.table) 51 | 52 | self.checkbutton.connect('toggled', self._on_change) 53 | self.spinbutton_width.connect('value-changed', self._on_change) 54 | self.spinbutton_height.connect('value-changed', self._on_change) 55 | 56 | def fill_widgets(self): 57 | if self.settings['desktop'] == None: 58 | # Set width to 75% of the screen 59 | desktop_width = int(gtk.gdk.get_default_root_window().get_geometry()[2]*0.75) 60 | # Set height to 75% of the screen 61 | desktop_height = int(gtk.gdk.get_default_root_window().get_geometry()[3]*0.75) 62 | else: 63 | desktop_width = int(self.settings['desktop'][0]) 64 | # Set height to 75% of the screen 65 | desktop_height = int(self.settings['desktop'][1]) 66 | 67 | self.checkbutton.set_active(self.settings['desktop'] != None) 68 | self.table_values.set_sensitive(self.settings['desktop'] != None) 69 | self.spinbutton_width.set_value(desktop_width) 70 | self.spinbutton_height.set_value(desktop_height) 71 | 72 | self.gobject.emit('settings-loaded', 'virtual-desktop', (self.settings['desktop'],)) 73 | 74 | """ 75 | Signal handlers 76 | """ 77 | 78 | def _on_change(self, widget = None): 79 | if self.gobject.loading: return False 80 | 81 | if self.checkbutton.get_active(): 82 | self.table_values.set_sensitive(True) 83 | self.settings['desktop'] = ( 84 | self.spinbutton_width.get_value_as_int(), 85 | self.spinbutton_height.get_value_as_int() 86 | ) 87 | else: 88 | self.table_values.set_sensitive(False) 89 | self.settings['desktop'] = None 90 | self.gobject.emit('settings-changed', 'virtual-desktop', self.save_settings, (self.settings['desktop'],)) 91 | 92 | def load_settings(self): 93 | self.settings['desktop'] = wine.desktop.get() 94 | 95 | def save_settings(self, setting): 96 | if setting is None: 97 | wine.desktop.set(False) 98 | else: 99 | wine.desktop.set(True, setting) 100 | -------------------------------------------------------------------------------- /wine/desktop.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | # AUTHOR: 7 | # Christian Dannie Storgaard 8 | 9 | import registry, common, util 10 | 11 | _openargs = [] 12 | 13 | GNOME_A11Y_DEFAULT_STATE = None 14 | 15 | def get(program=None): 16 | if program: 17 | program = program.lower() 18 | # Does this program use a virtual desktop? 19 | desktop = registry.get('HKEY_CURRENT_USER\\Software\\Wine\\AppDefaults\\%s\\Explorer' % program.lower(), "Desktop", quiet=True) 20 | if desktop: 21 | desktop = registry.get('HKEY_CURRENT_USER\\Software\\Wine\\Explorer\\Desktops', desktop, quiet=True) 22 | if desktop: 23 | return tuple([ int(i) for i in desktop.lower().split('x') ]) 24 | else: 25 | return None 26 | else: 27 | # Does the default configuration use a virtual desktop? 28 | desktop = registry.get('HKEY_CURRENT_USER\\Software\\Wine\\Explorer', "Desktop", quiet=True) 29 | if desktop: 30 | desktop = util.string_remove_escapes(desktop) 31 | desktop = registry.get('HKEY_CURRENT_USER\\Software\\Wine\\Explorer\\Desktops', desktop, quiet=True) 32 | if desktop: 33 | return tuple([ int(i) for i in desktop.lower().split('x') ]) 34 | else: 35 | return None 36 | 37 | def set(boolean, size=None, program=None): 38 | """ 39 | Set whether Wine should emulate a virtual desktop 40 | 41 | @param boolean whether the virtual desktop should be used 42 | @type boolean 43 | @param size the size of the the virtual desktop in pixels 44 | @type tuple (width,height) - defaults to 800x600 (like winecfg) 45 | @param program if set, the virtual desktop should only be set for this program 46 | @type string "explorer.exe" 47 | 48 | """ 49 | if program is not None: 50 | program = program.lower() 51 | 52 | if common.ENV['VINEYARDCONFNAME'] == '': 53 | conf_name = 'Default' 54 | else: 55 | conf_name = common.ENV['VINEYARDCONFNAME'] 56 | 57 | print("Size:", size) 58 | if size is None: 59 | if program: 60 | size = registry.get('HKEY_CURRENT_USER\\Software\\Wine\\Explorer\\Desktops', program, quiet=True) 61 | else: 62 | size = registry.get( 63 | 'HKEY_CURRENT_USER\\Software\\Wine\\Explorer\\Desktops', 64 | conf_name, quiet=True) 65 | if not size: 66 | size = registry.get( 67 | 'HKEY_CURRENT_USER\\Software\\Wine\\Explorer\\Desktops', 68 | 'Desktops', quiet=True) 69 | if not size: 70 | size = (800, 600) 71 | else: 72 | size = tuple([ int(i) for i in size.split('x') ]) 73 | else: 74 | size = tuple(size) 75 | 76 | print("Set desktop {0} as {1}".format(conf_name, size)) 77 | if boolean: 78 | if program: 79 | registry.set({'HKEY_CURRENT_USER\\Software\\Wine\\Explorer\\Desktops': { 80 | program: '%sx%s' % size}}) 81 | registry.set({'HKEY_CURRENT_USER\\Software\\Wine\\AppDefaults\\%s\\Explorer' % program : { 82 | "Desktop": program}}) 83 | else: 84 | registry.set({'HKEY_CURRENT_USER\\Software\\Wine\\Explorer\\Desktops': { 85 | conf_name: '%sx%s' % size}}) 86 | registry.set({'HKEY_CURRENT_USER\\Software\\Wine\\Explorer': { 87 | "Desktop": conf_name}}) 88 | else: 89 | if program: 90 | registry.set({'HKEY_CURRENT_USER\\Software\\Wine\\AppDefaults\\%s\\Explorer' % program : { 91 | "Desktop": None}}) 92 | else: 93 | registry.set({'HKEY_CURRENT_USER\\Software\\Wine\\Explorer': { 94 | "Desktop": None}}) 95 | 96 | def set_open(name, size): 97 | _openargs.append("explorer") 98 | _openargs.append("/desktop=%s,%s" % ('-'.join(name.split(' ')), size.lower())) 99 | 100 | def get_repeat_key(): 101 | return common.value_as_bool(common.run([ 102 | 'gconftool', 103 | '--get', '/desktop/gnome/peripherals/keyboard/repeat' 104 | ])[0]) 105 | 106 | def set_repeat_key(state): 107 | global GNOME_A11Y_DEFAULT_STATE 108 | # If this is the first time (in this session) that we touch this value 109 | # get its default 110 | if GNOME_A11Y_DEFAULT_STATE is None: 111 | GNOME_A11Y_DEFAULT_STATE = common.value_as_bool(common.run([ 112 | 'gconftool', 113 | '--get', '/apps/gnome_settings_daemon/plugins/a11y-keyboard/active' 114 | ])[0]) 115 | 116 | state = common.value_as_bool(state) 117 | # Only enable/disable a11y if it was previously enabled 118 | if GNOME_A11Y_DEFAULT_STATE: 119 | common.run([ 120 | 'gconftool', 121 | '--set', '/apps/gnome_settings_daemon/plugins/a11y-keyboard/active', 122 | '--type', 'bool', 123 | str(state).lower() 124 | ]) 125 | common.run([ 126 | 'gconftool', 127 | '--set', '/desktop/gnome/peripherals/keyboard/repeat', 128 | '--type', 'bool', 129 | str(state).lower() 130 | ]) 131 | return state 132 | -------------------------------------------------------------------------------- /data/vineyard-nautilus-infobar.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | # AUTHOR: 7 | # Christian Dannie Storgaard 8 | # 9 | # NOTE: 10 | # This file belongs in /usr/lib/nautilus/extensions-2.0/python/ 11 | 12 | import nautilus 13 | import gtk 14 | import os, subprocess 15 | import wine 16 | 17 | import gettext as _gettext 18 | from locale import getdefaultlocale 19 | 20 | SHARED_FILES_PATH = None 21 | for path in [ os.path.sep.join(i.split(os.path.sep)[:-1]) for i in os.environ['PATH'].split(':') ]: 22 | if os.path.isdir( "%s/share/vineyard" % path): 23 | SHARED_FILES_PATH = "%s/share/vineyard" % path 24 | 25 | APP_NAME = "vineyard" 26 | 27 | languages = ( [getdefaultlocale()[0]] or [] ) 28 | if 'LANGUAGE' in os.environ: 29 | languages = os.environ['LANGUAGE'].split(':') + languages 30 | elif 'LANG' in os.environ: 31 | languages = os.environ['LANG'].split(':') + languages 32 | 33 | _gettext.bindtextdomain(APP_NAME, "%s/%s" % (SHARED_FILES_PATH, "locale")) 34 | _gettext.textdomain(APP_NAME) 35 | 36 | gettext = _gettext.translation(APP_NAME, "%s/%s" % (SHARED_FILES_PATH, "locale"), languages=languages, fallback=True) 37 | _ = gettext.gettext 38 | 39 | class LocationProviderVineyard(nautilus.LocationWidgetProvider): 40 | def __init__(self): 41 | pass 42 | 43 | def get_widget(self, uri, window): 44 | widget = BarWidget(self, uri) 45 | if widget.configuration is None: 46 | return None 47 | else: 48 | return widget 49 | 50 | def configure(widget=None, configuration=None): 51 | try: 52 | if configuration == 'default': 53 | subprocess.Popen( 54 | ['vineyard-preferences'] 55 | ) 56 | else: 57 | subprocess.Popen( 58 | ['vineyard-preferences', '-c', configuration] 59 | ) 60 | except: 61 | pass 62 | 63 | def show_help(widget=None): 64 | subprocess.Popen( 65 | ['yelp', '{0}/docs'.format(SHARED_FILES_PATH)], 66 | stdout=subprocess.PIPE, 67 | stderr=subprocess.PIPE 68 | ) 69 | 70 | class BarWidget(gtk.HBox): 71 | def __init__(self, parent, uri): 72 | gtk.HBox.__init__(self) 73 | self._parent = parent 74 | 75 | path = '://'.join(uri.split('://')[1:]) 76 | if ( 77 | path == os.path.expanduser('~/.wine') or 78 | path.startswith(os.path.expanduser('~/.wine/')) 79 | ): 80 | configuration = 'default' 81 | else: 82 | configuration = wine.prefixes.get_prefixpath_from_filepath(path) 83 | if configuration is not None: 84 | configuration = configuration['WINEPREFIXNAME'] 85 | self.configuration = configuration 86 | 87 | if configuration is not None: 88 | self.icon = gtk.Image() 89 | try: 90 | pixbuf = gtk.icon_theme_get_default().load_icon( 91 | 'vineyard', 92 | 32, 93 | 0) 94 | self.icon.set_from_pixbuf(pixbuf) 95 | except glib.GError: 96 | pass 97 | self.pack_start(self.icon, expand=False, fill=False, padding=4) 98 | 99 | if configuration == 'default': 100 | self.label = gtk.Label( 101 | _('This directory is in the default Wine/Vineyard configuration') 102 | ) 103 | else: 104 | self.label = gtk.Label( 105 | _('This directory is in the Vineyard configuration {0}').format( 106 | configuration 107 | ) 108 | ) 109 | 110 | self.label.set_use_markup(True) 111 | self.label.set_alignment(0.0, 0.5) 112 | self.label.set_line_wrap(False) 113 | self.pack_start(self.label, expand=True, fill=True, padding=4) 114 | 115 | self.button_configure = gtk.Button(_('Configure')) 116 | self.button_configure.connect('clicked', configure, configuration) 117 | self.pack_end(self.button_configure, expand=False, fill=False, padding=4) 118 | 119 | self.button_help = gtk.Button() 120 | image = gtk.Image() 121 | try: 122 | pixbuf = self.render_icon(gtk.STOCK_HELP, gtk.ICON_SIZE_BUTTON) 123 | image.set_from_pixbuf(pixbuf) 124 | except glib.GError: 125 | pass 126 | self.button_help.add(image) 127 | self.button_help.connect('clicked', show_help) 128 | self.pack_end(self.button_help, expand=False, fill=False, padding=4) 129 | 130 | self.show_all() 131 | 132 | def __set_image_from_name(self, image, image_name): 133 | try: 134 | pixbuf = gtk.icon_theme_get_default().load_icon(image_name, 32, 0) 135 | image.set_from_pixbuf(pixbuf) 136 | except glib.GError: 137 | pass 138 | -------------------------------------------------------------------------------- /setup.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | 3 | import os, sys 4 | from distutils.core import setup 5 | 6 | script_dir = os.path.abspath(os.path.dirname(sys.argv[0])) 7 | with open('%s/debian/changelog' % script_dir, 'r') as file_obj: 8 | lines = file_obj.readlines() 9 | deb_version = lines[0].split('(')[1].split(')')[0] 10 | 11 | if 'TRAVIS' in os.environ and 'CI' in os.environ: 12 | etc_dir = '../etc' 13 | deb_version = os.environ['TRAVIS_TAG'] 14 | else: 15 | etc_dir = '/etc' 16 | 17 | 18 | setup( name = "vineyard", 19 | version = deb_version, 20 | description = "Easy to use Wine configuration program", 21 | maintainer = "Christian Dannie Storgaard", 22 | maintainer_email = "cybolic@gmail.com", 23 | url = "https://launchpad.net/vineyard", 24 | license = "LGPL-2", 25 | scripts = ['vineyard-preferences', 'vineyard-cli', 'vineyard-launcher', 'vineyard-indicator'], 26 | packages = ['wine', 'vineyard', 'vineyard.pages', 'vineyard.widgets', 'vineyard.gtkwidgets'], 27 | data_files = [ 28 | ('share/vineyard', [ 29 | 'data/vineyard-preferences.glade', 30 | ]), 31 | ('share/vineyard/bin', [ 32 | 'data/bin/%s' % i for i 33 | in os.listdir('%s/data/bin' % script_dir) 34 | ]), 35 | ('share/vineyard/docs', [ 36 | 'data/docs/%s' % i for i 37 | in os.listdir('%s/data/docs' % script_dir) 38 | ]), 39 | ('share/man/man1', [ 40 | 'data/vineyard-preferences.1.gz' 41 | ]), 42 | ('%s/xdg/autostart' % etc_dir, [ 43 | 'data/vineyard-indicator.desktop' 44 | ]), 45 | ('lib/nautilus/extensions-2.0/python', [ 46 | 'data/%s' % i for i 47 | in os.listdir('%s/data' % script_dir) 48 | if 'nautilus' in i and i.endswith('.py') 49 | ]), 50 | ('share/applications', [ 51 | 'data/vineyard-preferences.desktop', 52 | 'data/vineyard-launcher.desktop' 53 | ]), 54 | ('share/vineyard/icons', [ 55 | 'data/icons/%s' % i for i 56 | in os.listdir('%s/data/icons' % script_dir) 57 | if i.split('.')[-1].lower() in ('svg', 'png') 58 | ]), 59 | ('share/icons/hicolor/16x16/apps', [ 60 | 'data/icons/16/regedit.png', 61 | 'data/icons/16/taskmgr.png', 62 | 'data/icons/16/wcmd.png' 63 | ]), 64 | ('share/icons/hicolor/22x22/apps', [ 65 | 'data/icons/22/vineyard-preferences.svg', 66 | 'data/icons/22/regedit.png', 67 | 'data/icons/22/taskmgr.png', 68 | 'data/icons/22/wcmd.svg' 69 | ]), 70 | ('share/icons/hicolor/32x32/apps', [ 71 | 'data/icons/32/vineyard-preferences.svg', 72 | 'data/icons/32/regedit.png', 73 | 'data/icons/32/taskmgr.png', 74 | 'data/icons/32/wcmd.svg' 75 | ]), 76 | ('share/icons/hicolor/48x48/apps', [ 77 | 'data/icons/48/vineyard-preferences.svg', 78 | 'data/icons/48/vineyard.svg', 79 | 'data/icons/48/regedit.png', 80 | 'data/icons/48/taskmgr.png', 81 | 'data/icons/48/wcmd.svg' 82 | ]), 83 | ('share/icons/Faenza/apps/scalable', [ 84 | 'data/icons/Faenza/scalable/vineyard.svg', 85 | 'data/icons/Faenza/scalable/vineyard-preferences.svg' 86 | ]), 87 | ('share/icons/Faenza/status/22', [ 88 | 'data/icons/Faenza/status/22/vineyard-panel-alert.svg', 89 | 'data/icons/Faenza/status/22/vineyard-panel-idle.svg' 90 | ]), 91 | ('share/icons/Faenza-Dark/status/22', [ 92 | 'data/icons/Faenza-Dark/status/22/vineyard-panel-alert.svg', 93 | 'data/icons/Faenza-Dark/status/22/vineyard-panel-idle.svg' 94 | ]), 95 | ('share/icons/Humanity/status/22', [ 96 | 'data/icons/Humanity/status/22/vineyard-panel-alert.svg', 97 | 'data/icons/Humanity/status/22/vineyard-panel-idle.svg' 98 | ]), 99 | ('share/icons/ubuntu-mono-dark/status/22', [ 100 | 'data/icons/ubuntu-mono-dark/status/22/vineyard-panel-alert.svg', 101 | 'data/icons/ubuntu-mono-dark/status/22/vineyard-panel-idle.svg' 102 | ]), 103 | ('share/icons/ubuntu-mono-light/status/22', [ 104 | 'data/icons/ubuntu-mono-light/status/22/vineyard-panel-alert.svg', 105 | 'data/icons/ubuntu-mono-light/status/22/vineyard-panel-idle.svg' 106 | ]), 107 | ] + [ 108 | ( 109 | 'share/vineyard/locale/%s/LC_MESSAGES' % l, 110 | [ 111 | 'data/locale/%s/LC_MESSAGES/%s' % (l, f) for f 112 | in os.listdir('%s/data/locale/%s/LC_MESSAGES' % (script_dir, l)) 113 | if f.lower().endswith('.mo') 114 | ] 115 | ) for l 116 | in os.listdir('%s/data/locale' % script_dir) 117 | ] 118 | ) 119 | -------------------------------------------------------------------------------- /vineyard-daemon: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | # AUTHOR: 7 | # Christian Dannie Storgaard 8 | # 9 | # vineyard is free software; you can redistribute it and/or 10 | # modify it under the terms of the GNU General Public License as published 11 | # by the Free Software Foundation; either version 2 of the License, or (at 12 | # your option) any later version. 13 | # 14 | # vineyard is distributed in the hope that it will be useful, 15 | # but WITHOUT ANY WARRANTY; without even the implied warranty of 16 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 17 | # General Public License for more details. 18 | # 19 | # You should have received a copy of the GNU General Public License 20 | # along with wine-preferences; if not, write to the Free Software 21 | # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 22 | # 23 | # DBus code based on the Python snippet by Simon Vermeersch 24 | # 25 | 26 | import os, sys 27 | import gobject, gtk 28 | import dbus, dbus.service, dbus.glib 29 | from optparse import OptionParser 30 | import subprocess 31 | 32 | DBUS_NAME = 'org.vineyardproject.Server' 33 | 34 | SHARED_FILES_PATH = None 35 | APP_NAME = "vineyard" 36 | # If we are running from the development directory 37 | if os.path.isfile( "%s/data/vineyard-preferences.xml" % os.path.abspath(os.path.dirname(sys.argv[0])) ): 38 | SHARED_FILES_PATH = "%s/data" % os.path.abspath(os.path.dirname(sys.argv[0])) 39 | sys.path.insert(0, '%s/../python-wine' % SHARED_FILES_PATH) 40 | else: 41 | for path in [ os.path.sep.join(i.split(os.path.sep)[:-1]) for i in os.environ['PATH'].split(':') ]: 42 | if os.path.isdir( "%s/share/%s" % (path, APP_NAME) ): 43 | SHARED_FILES_PATH = "%s/share/%s" % (path, APP_NAME) 44 | 45 | if SHARED_FILES_PATH == None: 46 | print "Something is wrong with the installation, can't find required files. Exiting." 47 | exit(1) 48 | sys.path.append(SHARED_FILES_PATH) 49 | 50 | import vineyard 51 | _ = vineyard.common.setup_translation() 52 | 53 | class MainApp: 54 | def __init__(self): 55 | self.window = gtk.Window(gtk.WINDOW_TOPLEVEL) 56 | self.window.set_size_request(350, 350) 57 | self.label = gtk.Label("label") 58 | 59 | self.window.add(self.label) 60 | self.window.show_all() 61 | 62 | self.window.connect("destroy", self.destroy) 63 | 64 | def destroy(self, sender): 65 | gtk.main_quit() 66 | 67 | class DBusService(dbus.service.Object): 68 | def __init__(self, app): 69 | global wine 70 | import wine 71 | self.app = app 72 | bus_name = dbus.service.BusName(DBUS_NAME, bus = dbus.SessionBus()) 73 | dbus.service.Object.__init__(self, bus_name, '/') 74 | 75 | @dbus.service.method(dbus_interface=DBUS_NAME) 76 | def show_window(self): 77 | self.app.window.present() 78 | 79 | @dbus.service.method(dbus_interface=DBUS_NAME, out_signature='i') 80 | def get_running_programs(self): 81 | return wine.monitor.list() 82 | 83 | @dbus.service.method(dbus_interface=DBUS_NAME, out_signature='i') 84 | def get_n_running_programs(self): 85 | return len(wine.monitor.list()) 86 | 87 | def run_method(method): 88 | method() 89 | return False 90 | 91 | if __name__ == "__main__": 92 | usage = _("usage")+": %prog [-h | --help] | [ [-c|--select-configuration CONFIGURATION] ] [--debug LOGGING_LEVEL] ]" 93 | parser = OptionParser(usage) 94 | parser.add_option("-c", "--use-configuration", 95 | action="store", dest="configuration", 96 | help=_("Use the given configuration (bottle)")) 97 | parser.add_option("-w", "--show-window", 98 | action="store_true", dest="show_window", 99 | help=_("Show the main window")) 100 | parser.add_option("-p", "--get-running-programs", 101 | action="store_true", dest="get_running_programs", 102 | help=_("Get a list of running programs")) 103 | parser.add_option("-n", "--get-number-of-running-programs", 104 | action="store_true", dest="get_n_running_programs", 105 | help=_("Get the number of running programs")) 106 | parser.add_option("--debug", 107 | action="store", dest="logging_level", 108 | help=_("print debug information of level (one of debug, info, warning, error, critical)")) 109 | (options, args) = parser.parse_args() 110 | 111 | if dbus.SessionBus().request_name(DBUS_NAME) != dbus.bus.REQUEST_NAME_REPLY_PRIMARY_OWNER: 112 | """ Vineyard is already running """ 113 | enabled_options = [ k for (k,v) in dict(eval(options.__str__())).iteritems() if v != None ] 114 | 115 | for method_name in enabled_options: 116 | method = dbus.SessionBus().get_object(DBUS_NAME, "/").get_dbus_method(method_name) 117 | if method_name.startswith('get_'): 118 | print method() 119 | else: 120 | method() 121 | else: 122 | """ Vineyard is not running, starting... """ 123 | app = MainApp() 124 | service = DBusService(app) 125 | """ Now running methods """ 126 | subprocess.Popen(sys.argv, stdin=sys.stdin, stdout=sys.stdout, close_fds=True) 127 | gtk.main() 128 | -------------------------------------------------------------------------------- /wine/appdb.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | # -*- coding: utf-8 -*- 3 | # 4 | # Copyright (c) 2007-2010 Christian Dannie Storgaard 5 | # 6 | # AUTHOR: 7 | # Christian Dannie Storgaard 8 | 9 | import re 10 | import urllib2, urllib 11 | from BeautifulSoup import BeautifulSoup 12 | 13 | APPDB_CACHE = {} 14 | 15 | class Request(urllib2.Request): 16 | # To fix this bug: http://bugs.python.org/issue8280 17 | def get_selector(self): 18 | return self.__r_host.split('#')[0] 19 | 20 | def get_version_lookup_url(app, gotofirst=True): 21 | url = 'http://www.google.com/search' 22 | data = { 23 | 'q': '"{0}" inurl:sClass=version site:http://appdb.winehq.org'.format( 24 | app 25 | ), 26 | } 27 | if gotofirst: 28 | data['btnI'] = '' 29 | url_values = urllib.urlencode(data) 30 | return '{0}?{1}'.format(url, url_values) 31 | 32 | def get_application_lookup_url(app, gotofirst=True): 33 | url = 'http://www.winehq.org/search' 34 | data = { 35 | #'q': '"{0}" inurl:sClass=application site:http://appdb.winehq.org'.format( 36 | # app 37 | #) 38 | 'cx': 'partner-pub-0971840239976722:w9sqbcsxtyf', 39 | 'cof': 'FORID:10', 40 | 'ie': 'UTF-8', 41 | 'q': '"{0}" inurl:sClass=application'.format(app), 42 | 'siteurl': 'appdb.winehq.org' 43 | } 44 | if gotofirst: 45 | data['btnI'] = '' 46 | url_values = urllib.urlencode(data) 47 | return '{0}?{1}'.format(url, url_values) 48 | 49 | def _get_appdb_page(app): 50 | if app in APPDB_CACHE: 51 | return APPDB_CACHE[app] 52 | else: 53 | url = 'http://www.google.com/search' 54 | data = { 55 | 'q': '"{0}" inurl:sClass=application site:http://appdb.winehq.org'.format(app), 56 | 'btnI': '' 57 | } 58 | url_values = urllib.urlencode(data) 59 | 60 | request = Request('{0}?{1}'.format(url, url_values), None, { 61 | 'User-Agent': 'Vineyard Web Reader', 62 | 'Accept': 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8', 63 | 'Accept-Language': 'en-us,en;q=0.5', 64 | 'Referer': 'http://www.google.com/ig' 65 | }) 66 | content = urllib2.urlopen(request).read() 67 | APPDB_CACHE[app] = content 68 | return content 69 | 70 | def get_application_info(app): 71 | page = _get_appdb_page(app) 72 | soup = BeautifulSoup(page) 73 | 74 | header = soup.find('td', 'white') 75 | sections = [ tag.text for tag in header.findAll('a') ] 76 | name = str(header).split('
')[-1].split('<')[0].replace('>','').strip() 77 | 78 | versions = {} 79 | for tr in soup.findAll('tr', onmouseover=True): 80 | if 'OBSOLETE - ' not in str(tr): 81 | (version, description, rating, 82 | wine_version, test_results, comments) = tr.findChildren('td') 83 | 84 | link = version.find('a').attrs[0][1] 85 | version = str(version.text) 86 | description = description.text 87 | rating = str(rating.text) 88 | wine_version = str(wine_version.text) 89 | test_results = test_results.text 90 | comments = comments.text 91 | 92 | versions[version] = Version({ 93 | 'description': description, 94 | 'rating': rating, 95 | 'wine_version': wine_version, 96 | 'test_results': test_results, 97 | 'comments': comments, 98 | 'url': link 99 | }) 100 | 101 | return {'sections':sections, 'name':name, 'versions':versions} 102 | 103 | def get_application_link_and_name(app): 104 | appdb_page = _get_appdb_page(app) 105 | match = re.search('(.*?)<', appdb_page) 106 | if match: 107 | url, name = match.groups() 108 | if not url.lower().startswith('http'): 109 | url = 'http://http://appdb.winehq.org/%s' % url 110 | return url, name 111 | 112 | def get_version_info_from_url(url): 113 | if url in APPDB_CACHE: 114 | page = APPDB_CACHE[url] 115 | else: 116 | page = urllib2.urlopen(url).read() 117 | APPDB_CACHE[url] = page 118 | soup = BeautifulSoup(page) 119 | 120 | header = soup.find('td', 'white') 121 | sections = [ tag.text for tag in header.findAll('a') ] 122 | name = sections[-1] 123 | sections = sections[:-1] 124 | version = str(header).split('')[-1].split('<')[0].replace('>','').strip() 125 | 126 | infobox = soup.find('td', 'color4') 127 | infobox_start = BeautifulSoup(str(infobox).split('screenshot')[0]) 128 | 129 | info = {'sections': sections} 130 | for tr in infobox_start.findAll('tr'): 131 | tds = tr.findAll('td') 132 | if len(tds) == 2: 133 | info[ tds[0].text.lower() ] = tds[1].text 134 | # The following is getting a bit too much, since every program has several 135 | # versions than in return each have several test results, the user really 136 | # should use appdb.winehq.org directly instead. 137 | """ 138 | results = dict([ 139 | (div.find('div', 'title_class').text, div.find('div', 'info_contents')) 140 | for div 141 | in soup.findAll('td', 'topMenu')[1].findAll('div', 'info_container') 142 | ])""" 143 | return info 144 | 145 | 146 | class Version(dict): 147 | def retrieve(self): 148 | if 'url' in self: 149 | return get_version_info_from_url(self['url']) -------------------------------------------------------------------------------- /data/vineyard-programs.glade: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | True 9 | 10 | 11 | True 12 | 0 13 | none 14 | 15 | 16 | True 17 | 12 18 | 19 | 20 | True 21 | 22 | 23 | True 24 | True 25 | 26 | 27 | 0 28 | 29 | 30 | 31 | 32 | True 33 | 2 34 | 2 35 | 3 36 | 3 37 | 38 | 39 | _Run 40 | True 41 | True 42 | True 43 | image3 44 | True 45 | 46 | 47 | 48 | 49 | Uninstall 50 | True 51 | True 52 | True 53 | image2 54 | 55 | 56 | 1 57 | 2 58 | 59 | 60 | 61 | 62 | A_dd unlisted program 63 | True 64 | True 65 | True 66 | image1 67 | True 68 | 69 | 70 | 2 71 | 1 72 | 2 73 | 74 | 75 | 76 | 77 | False 78 | 1 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | True 88 | <b>Installed Programs</b> 89 | True 90 | 91 | 92 | 93 | 94 | 0 95 | 96 | 97 | 98 | 99 | 100 | 101 | True 102 | gtk-add 103 | 104 | 105 | True 106 | gtk-remove 107 | 108 | 109 | True 110 | gtk-execute 111 | 112 | 113 | --------------------------------------------------------------------------------