Wine Config File
From Wine-Wiki
Contents |
Information
The configuration file for Wine has been deprecated, and has been phased out since June 2005 and replaced with Winecfg. Some are still using the old versions of Wine, but since Wine has made such advances recently, you really should investigate updating your version of wine. Dimi Paun maintains a updated list of where you can now set options for Wine, and the scope they have here http://winehq.org/site/status_options
A user asked [Dec 05] Where is the config [file]? [...and...] Why you have removed it? [In the] config file [..] many users, [could] edit some options, which they can't edit now.
S. Doesinger: You can still edit them in the registry files. Have a look at HKCU/Software/Wine/ This path is stored in ~/.wine/user.reg, which can be edited with any text editor.
Further Reading
The config file was located in the wine directory:
~/.wine/config
A sample configuration file is included with wine source files pre June 2005. To use a config file, copy it accross into the directory
~/.wine
or obtain a copy from Wine CVS Attic:Config File
A config file is automatically installed by some older versions of the the free tool Winetools.
Further Reading
Config File Settings
Windows Version
You can set Wine to emulate a different version of Windows. Change the version by adding a comment: '#' or delete the '#'. While some lines are commented with a ';' the same rule applies: Comment out the versions you no longer desire and remove the ';' or the '#" from the line you want.
Some applications work only with version=win98, another applications work only with version=win2k. If an application won't start and pops up a message like 'This program requires Windows 2000/XP' then you may try to change this setting to get this program to work.
Wine Dll Overrides
Either 'n', or 'native', will guide Wine to select a native Windows dll over a builtin dll.
Care is needed when setting an Applicaton default to native dlls. This is shown in the following example:
;Application called Foo.exe [AppDefaults\\Setup.exe\\DllOverrides] "*comctl32*" = "native" "*commctrl*" = "n"
The ; is used to comment out the application's name "Foo.exe" and is ignored. Wine is interested in the second line starting with:
[AppDefaults\\Setup.exe\\DllOverrrides]
Because this config entry will affect any installation that has a file called Setup.exe it may have unintended consequences.
The current method is to use WINEDLLOVERRIDES from the command line.
Example:
WINEDLLOVERRIDES="comctl32=n;commctrl=n" wine foo.exe
Following native DLLs can't be used in Wine: ntdll.dll, gdi32.dll, kernel32.dll, advapi32.dll, winsock32.dll, and some others. Many DLLs from Windows XP don't work either. Use their Windows 98 equivalents or builtin DLLs instead.
For more information see the environment variable "WINEDLLOVERRIDES" in The Wine Man Pages
Configuring Sound
Sound drivers in WINE
L. Freitag: The [WinMM] section is used to configure which driver is being used by Wine to output sound. You can choose between many options, however for Linux work (i.e. been tested by me and worked) only two: OSS and ALSA driver. You may specify
"Drivers" = "wineoss.drv"
to use OSS sound output and
"Drivers" = "winealsa.drv"
to use ALSA output. OSS will work for most users, since OSS is supposed to be supported on different platforms and ALSA supports OSS emulation. So ALSA users may choose OSS output if they wish to. Both drivers work very well, both have small bugs, however OSS driver seems to have fewer bugs than ALSA driver, but if you have a soundcard which doesn't support hardware mixing (most integrated chips and cheap cards like Creative 128 PCI don't) WINE will block your sound card entirely when playing a sound. In contrast, ALSA allows you to play simultaneous sounds even if your card doesn't support it (see below), but sometimes ALSA driver doesn't work properly where it should (and OSS driver does), however, this is very rare.
Wine and DMIX
This option isn't documented in Wine User Guide.
L. Freitag: In Wine 20050419 and later you can change ALSA device you want wine output the sound to. [DMIX allows Wine to share your sound card (It enables sound mixing even on hardware that doesn't support this directly).] This is useful if you have dmix enabled and wine is trying to access plug:hw and therefore blocks your soundcard from playing any other sounds.
If you have setup alsa to use default as a dmix frontend just add the following in your ~/.wine/config:
[ALSA] "PlaybackDevice" = "default"
(or substitute the PlaybackDevice "default", with your favorite device). If you didn't setup alsa to use "default" as a dmix frontend you may wish to use "plug:dmix" device.
Wine versions prior to 20050419 used the "default" device to access the soundcard by default. It's enough to set DMIX up so that the default device is being used as a dmix frontend.
Further Reading
- http://gentoo-wiki.com/HOWTO_ALSA_sound_mixer_aka_dmix
- http://alsa.opensrc.org/index.php?page=DmixPlugin
Fonts
Truetype Fonts
H. Bostick: The homepage for corefonts: http://corefonts.sourceforge.net/
Apparently these are the MS fonts (Andale Mono,Arial, Comic Sans MS, courier, Georgia, Impact, Times New Roman, Trebuchet, and Verdana), which are allowed to be redistributed unaltered, according to the EULA and FAQ linked to on the page, so the maintainer has done so. These can be installed via Portage, for Gentoo users, but this package is available via all (or most) distribution repositories - Google search for corefonts. Debian even has an msttcorefonts package in its 'contrib' section (stable, testing, and unstable).
The corefonts homepage makes RPMs, the original .exe files and cabextract available. One can always copy the fonts directly to one's drive_c/windows/fonts folder. But of course, this is a waste of space, and likely the reason that the (former) Wine config file allows you to specify where you have any TTF fonts already installed, as well as any font aliases, if you happen not to have a common font (helvetica, for example).
The Wine configuration setting:
[FontDirs] "0"="/usr/share/fonts/TTF" "1"="/usr/share/fonts/corefonts"
The standard location for fonts under X.org is in /usr/share/fonts, but of course other users' locations may be different. If still using XFree86, the fonts may be in /usr/lib/X11/fonts, or /usr/X11R6/lib/X11/fonts/, and any given distro may have a custom location over and above that. However, once the corefonts are installed, a typing on the command line a simple
locate arial.ttf
should indicate what path you'd want to use in the setting above.
Ports
Configuring the Parallel Port
C. Schmitz: To grant the FULL parallel port access to the TopMax program, in the config i write
[ppdev] "378" =3D "/dev/parport0" [ports] "read" =3D "0x779,0x378-0x37f,0x280-0x2a0" "write" =3D "0x779,0x378-0x37f,0x280-0x2a0"
I set the attributes
crw-rw-rw- 1 me root 99, 0 2005-03-19 16:36 /dev/parport0 crw-rw-rw- 1 lp lp 6, 0 2005-03-19 16:36 /dev/lp0
and add Myuser to the lp group. Wine Archive
Printing
Andr Carvalho:[Sept05] For the LPRng work on wine I had to put a session anywhere in the wine config file like this Wine Archive:
[ppd] "printer" = "/usr/share/wine/generic.ppd"
Where "printer" is the name of the printer in /etc/printcap.
Managed Windows
M. Hern Feb 2005: currently the expected behaviour for unmanaged windows is that keyboard input goes to the terminal. If you want to use unmanaged windows, use Desktop mode. "Managed" = "N" in your config file.
Now that the WM rewrite is finished, this is an area which will benefit from more attention.

