个人工具

UbuntuHelp:Wacom.fdi

来自Ubuntu中文

Wikibot讨论 | 贡献2008年12月16日 (二) 20:37的版本 (新页面: {{From|https://help.ubuntu.com/community/Wacom.fdi}} {{Languages|UbuntuHelp:Wacom.fdi}} == Configure Wacom Devices Using the .fdi File Method That Is the Default in Ubuntu 8.10 (Intrepid ...)

(差异) ←上一版本 | 最后版本 (差异) | 下一版本→ (差异)
跳转至: 导航, 搜索

Configure Wacom Devices Using the .fdi File Method That Is the Default in Ubuntu 8.10 (Intrepid Ibex)

To discuss this guide, please use this Ubuntu forums thread. This section is intended as a complement to https://help.ubuntu.com/community/Wacom, in order to help users configure their Wacom device (only the stylus will work) using the default method in Ubuntu 8.10 (Intrepid). While using xorg.conf is still possible (see the guide for details), you can also keep the default method in Ubuntu 8.10 and set up the properties of the stylus manually. However, Ubuntu 9.04 (Jaunty) will probably revert to using xorg.conf by default. With the default setup in Ubuntu 8.10, if you want to change the options for the stylus you can create a custom .fdi file and put it in /etc/hal/fdi/policy/. This preserves hotplugging while enabling you to configure your the stylus. [[UbuntuHelp:[Files|Below]]] are some custom .fdi file for download. Here's one as an example. You can add new options by inserting more x11_options lines (see below for some example ones). Option names are the same as in xorg.conf. Open a terminal, Wacom.fdi?action=AttachFile&do=get&target=Terminal2.png

then type (or copy-paste) this command:
gksudo gedit /etc/hal/fdi/policy/custom_wacom.fdi

or, if you are using KDE:

kdesu kate /etc/hal/fdi/policy/custom_wacom.fdi
Here are some lines extracted from the default 10-wacom.fdi that is installed by the package xserver-xorg-input-wacom in /usr/share/hal/fdi/policy/20thirdparty/. Paste these lines in the new file that opens in the Text Editor.
<?xml version="1.0" encoding="UTF-8"?> <!-- -*- SGML -*- -->

<deviceinfo version="0.2">

  <device>
    <match key="info.capabilities" contains="input">
      <match key="info.product" contains="Wacom">
	<merge key="input.x11_driver" type="string">wacom</merge>
	<merge key="input.x11_options.Type" type="string">stylus</merge>
      </match>
      <match key="info.product" contains="WALTOP">
	<merge key="input.x11_driver" type="string">wacom</merge>
	<merge key="input.x11_options.Type" type="string">stylus</merge>
      </match>
    </match>
    <!-- N-Trig Duosense Electromagnetic Digitizer -->
    <match key="info.product" contains="HID 1b96:0001">
      <match key="info.parent" contains="if0">
       <merge key="input.x11_driver" type="string">wacom</merge>
       <merge key="input.x11_options.Type" type="string">stylus</merge>
      </match>
    </match>
  </device>

</deviceinfo>

You can then add some more options by following the example below where only the setion for the "Wacom" info.product was kept (to check the name your device has, use the command lshal > lshal.txt and check in the file that was created).

In this file the options TPCButton and KeepShape are set (see the Linux Wacom Project documentation for the names of the options, or look at an xorg.conf file that was working for you in previous releases).
<?xml version="1.0" encoding="UTF-8"?> <!-- -*- SGML -*- -->

<deviceinfo version="0.2">

  <device>
    <match key="info.capabilities" contains="input">
      <match key="info.product" contains="Wacom">
	<merge key="input.x11_options.TPCButton" type="string">on</merge>
	<merge key="input.x11_options.KeepShape" type="string">on</merge>
      </match>
    </match>
  </device>

</deviceinfo>

Save your file and unplug / turn off, then plug in / turn on your tablet. <<Anchor(Files)>>

custom_wacom.fdi for download

Here are some modified 10-wacom.fdi to paste in /etc/hal/fdi/policy as custom_wacom.fdi (or any other name ending by .fdi). Only use one file at a time!