The attached patch removes the now useless README pane from the support form
UI, fixes a small buglet (missing grid layout on the CUPS pane), adds
trailing slashes to the URIs (otherwise we just make the remote server send
a redirect to *everyone* that uses that form), and renames a button that had
a wrong label.

Please apply.

BTW, Debian will feature a patch (not attached to this email) that adds a
"Debian" pane with points to Debian specific instructions.  Other distros
might want to do something like that too...  if you want the patch, send me
email.

The "Debian pane" will have the "not affiliated with HP" disclaimer, and it
will also be the second pane (just after the HP pane, which is opened by
default), so I guess that should not be a problem for anyone.  In fact, it
replaces the README pane the attached patch deletes... ;-)

-- 
  "One disk to rule them all, One disk to find them. One disk to bring
  them all and in the darkness grind them. In the Land of Redmond
  where the shadows lie." -- The Silicon Valley Tarot
  Henrique Holschuh
#! /bin/sh /usr/share/dpatch/dpatch-run
## 50_ui-supportform-cleanups.dpatch by Henrique de Moraes Holschuh <[EMAIL 
PROTECTED]>
##
## All lines beginning with `## DP:' are a description of the patch.
## DP: 1. Remove unused README file ui pane from support form
## DP: 2. Group in a grid layout the CUPS pane of the support form
## DP: 3. Rename button in CUPS pane of the support form
## DP: 4. Add missing ending / to all URIs, it is much friendlier to servers

@DPATCH@
diff -urNad hplip~/ui/supportform.py hplip/ui/supportform.py
--- hplip~/ui/supportform.py    2006-05-12 16:48:24.000000000 -0300
+++ hplip/ui/supportform.py     2006-05-12 16:50:12.930457587 -0300
@@ -12,14 +12,10 @@
         SupportForm_base.__init__(self,parent,name,modal,fl)
 
     def hpinktjetButton_clicked(self):
-        utils.openURL("http://hpinkjet.sourceforge.net";)
+        utils.openURL("http://hpinkjet.sourceforge.net/";)
 
     def linuxprintingButton_clicked(self):
-        utils.openURL("http://linuxprinting.org";)
+        utils.openURL("http://linuxprinting.org/";)
 
-    def linuxprintingButton_2_clicked(self):
-        utils.openURL("http://cups.org";)
-        
-    def hpinktjetButton_2_clicked(self):
-        utils.openURL("file://" + os.path.join(prop.home_dir 
,"hplip_readme.html"))
-    
+    def cupsButton_clicked(self):
+        utils.openURL("http://cups.org/";)
diff -urNad hplip~/ui/supportform_base.ui hplip/ui/supportform_base.ui
--- hplip~/ui/supportform_base.ui       2006-05-12 16:48:24.000000000 -0300
+++ hplip/ui/supportform_base.ui        2006-05-12 16:49:59.467052891 -0300
@@ -148,10 +148,10 @@
             </widget>
             <widget class="QWidget">
                 <property name="name">
-                    <cstring>tab</cstring>
+                    <cstring>TabPage</cstring>
                 </property>
                 <attribute name="title">
-                    <string>README File</string>
+                    <string>linuxprinting.org</string>
                 </attribute>
                 <grid>
                     <property name="name">
@@ -159,7 +159,7 @@
                     </property>
                     <widget class="Line" row="1" column="0">
                         <property name="name">
-                            <cstring>line2_3_2</cstring>
+                            <cstring>line2</cstring>
                         </property>
                         <property name="frameShape">
                             <enum>HLine</enum>
@@ -171,28 +171,9 @@
                             <enum>Horizontal</enum>
                         </property>
                     </widget>
-                    <widget class="QLabel" row="0" column="0">
-                        <property name="name">
-                            <cstring>textLabel2_2_2</cstring>
-                        </property>
-                        <property name="text">
-                            <string>&lt;b&gt;README File&lt;/b&gt;</string>
-                        </property>
-                    </widget>
-                    <widget class="QLabel" row="2" column="0">
-                        <property name="name">
-                            <cstring>textLabel2_3</cstring>
-                        </property>
-                        <property name="text">
-                            <string>A readme file was shipped with your 
version of HPLIP. This file contains the product support table, a 
troubleshooting guide, and other support resources.</string>
-                        </property>
-                        <property name="alignment">
-                            <set>WordBreak|AlignVCenter</set>
-                        </property>
-                    </widget>
                     <widget class="QPushButton" row="3" column="0">
                         <property name="name">
-                            <cstring>hpinktjetButton_2</cstring>
+                            <cstring>linuxprintingButton</cstring>
                         </property>
                         <property name="paletteForegroundColor">
                             <color>
@@ -211,12 +192,42 @@
                             <cursor>13</cursor>
                         </property>
                         <property name="text">
-                            <string>hplip_readme.html</string>
+                            <string>http://linuxprinting.org</string>
+                        </property>
+                    </widget>
+                    <widget class="QLabel" row="2" column="0">
+                        <property name="name">
+                            <cstring>textLabel4</cstring>
+                        </property>
+                        <property name="text">
+                            <string>General Linux printing assistance is also 
available from open discussion forums, documentation, access to PPD files, etc. 
from:</string>
+                        </property>
+                        <property name="alignment">
+                            <set>WordBreak|AlignVCenter</set>
+                        </property>
+                    </widget>
+                    <widget class="QLabel" row="0" column="0">
+                        <property name="name">
+                            <cstring>textLabel1</cstring>
+                        </property>
+                        <property name="text">
+                            
<string>&lt;b&gt;linuxprinting.org&lt;/b&gt;</string>
+                        </property>
+                    </widget>
+                    <widget class="QLabel" row="5" column="0">
+                        <property name="name">
+                            <cstring>textLabel6_2</cstring>
+                        </property>
+                        <property name="text">
+                            <string>NOTE: Linuxprinting.org is operated 
through the generous efforts of Grant Taylor and Till Kamppeter and is not 
affiliated with HP.</string>
+                        </property>
+                        <property name="alignment">
+                            <set>WordBreak|AlignVCenter</set>
                         </property>
                     </widget>
                     <spacer row="4" column="0">
                         <property name="name">
-                            <cstring>spacer5</cstring>
+                            <cstring>spacer6</cstring>
                         </property>
                         <property name="orientation">
                             <enum>Vertical</enum>
@@ -227,7 +238,7 @@
                         <property name="sizeHint">
                             <size>
                                 <width>20</width>
-                                <height>91</height>
+                                <height>51</height>
                             </size>
                         </property>
                     </spacer>
@@ -238,15 +249,23 @@
                     <cstring>TabPage</cstring>
                 </property>
                 <attribute name="title">
-                    <string>linuxprinting.org</string>
+                    <string>CUPS</string>
                 </attribute>
                 <grid>
                     <property name="name">
                         <cstring>unnamed</cstring>
                     </property>
-                    <widget class="Line" row="1" column="0">
+                    <widget class="QLabel" row="0" column="0">
                         <property name="name">
-                            <cstring>line2</cstring>
+                            <cstring>textLabel1_2</cstring>
+                        </property>
+                        <property name="text">
+                            <string>&lt;b&gt;CUPS&lt;/b&gt;</string>
+                        </property>
+                    </widget>
+                    <widget class="Line" row="1" column="0" rowspan="1" 
colspan="2">
+                        <property name="name">
+                            <cstring>line2_2</cstring>
                         </property>
                         <property name="frameShape">
                             <enum>HLine</enum>
@@ -258,9 +277,20 @@
                             <enum>Horizontal</enum>
                         </property>
                     </widget>
-                    <widget class="QPushButton" row="3" column="0">
+                    <widget class="QLabel" row="2" column="0" rowspan="1" 
colspan="2">
                         <property name="name">
-                            <cstring>linuxprintingButton</cstring>
+                            <cstring>textLabel4_2</cstring>
+                        </property>
+                        <property name="text">
+                            <string>Information about CUPS (Common UNIX 
Printing System) is available at cups.org. This website also contains forums 
and other support resources for printing on Linux:</string>
+                        </property>
+                        <property name="alignment">
+                            <set>WordBreak|AlignVCenter</set>
+                        </property>
+                    </widget>
+                    <widget class="QPushButton" row="3" column="0" rowspan="1" 
colspan="2">
+                        <property name="name">
+                            <cstring>cupsButton</cstring>
                         </property>
                         <property name="paletteForegroundColor">
                             <color>
@@ -279,42 +309,12 @@
                             <cursor>13</cursor>
                         </property>
                         <property name="text">
-                            <string>http://linuxprinting.org</string>
-                        </property>
-                    </widget>
-                    <widget class="QLabel" row="2" column="0">
-                        <property name="name">
-                            <cstring>textLabel4</cstring>
-                        </property>
-                        <property name="text">
-                            <string>General Linux printing assistance is also 
available from open discussion forums, documentation, access to PPD files, etc. 
from:</string>
-                        </property>
-                        <property name="alignment">
-                            <set>WordBreak|AlignVCenter</set>
-                        </property>
-                    </widget>
-                    <widget class="QLabel" row="0" column="0">
-                        <property name="name">
-                            <cstring>textLabel1</cstring>
-                        </property>
-                        <property name="text">
-                            
<string>&lt;b&gt;linuxprinting.org&lt;/b&gt;</string>
-                        </property>
-                    </widget>
-                    <widget class="QLabel" row="5" column="0">
-                        <property name="name">
-                            <cstring>textLabel6_2</cstring>
-                        </property>
-                        <property name="text">
-                            <string>NOTE: Linuxprinting.org is operated 
through the generous efforts of Grant Taylor and Till Kamppeter and is not 
affiliated with HP.</string>
-                        </property>
-                        <property name="alignment">
-                            <set>WordBreak|AlignVCenter</set>
+                            <string>http://cups.org</string>
                         </property>
                     </widget>
-                    <spacer row="4" column="0">
+                    <spacer row="4" column="1">
                         <property name="name">
-                            <cstring>spacer6</cstring>
+                            <cstring>spacer1</cstring>
                         </property>
                         <property name="orientation">
                             <enum>Vertical</enum>
@@ -325,153 +325,23 @@
                         <property name="sizeHint">
                             <size>
                                 <width>20</width>
-                                <height>51</height>
+                                <height>160</height>
                             </size>
                         </property>
                     </spacer>
+                    <widget class="QLabel" row="5" column="0" rowspan="1" 
colspan="2">
+                        <property name="name">
+                            <cstring>textLabel6_2_2</cstring>
+                        </property>
+                        <property name="text">
+                            <string>NOTE: CUPS and the CUPS website is owned 
and operated by Easy Software Products and is not affiliated with HP.</string>
+                        </property>
+                        <property name="alignment">
+                            <set>WordBreak|AlignVCenter</set>
+                        </property>
+                    </widget>
                 </grid>
             </widget>
-            <widget class="QWidget">
-                <property name="name">
-                    <cstring>TabPage</cstring>
-                </property>
-                <attribute name="title">
-                    <string>CUPS</string>
-                </attribute>
-                <widget class="Line">
-                    <property name="name">
-                        <cstring>line2_2</cstring>
-                    </property>
-                    <property name="geometry">
-                        <rect>
-                            <x>11</x>
-                            <y>40</y>
-                            <width>773</width>
-                            <height>16</height>
-                        </rect>
-                    </property>
-                    <property name="frameShape">
-                        <enum>HLine</enum>
-                    </property>
-                    <property name="frameShadow">
-                        <enum>Sunken</enum>
-                    </property>
-                    <property name="orientation">
-                        <enum>Horizontal</enum>
-                    </property>
-                </widget>
-                <widget class="QPushButton">
-                    <property name="name">
-                        <cstring>linuxprintingButton_2</cstring>
-                    </property>
-                    <property name="geometry">
-                        <rect>
-                            <x>11</x>
-                            <y>94</y>
-                            <width>773</width>
-                            <height>28</height>
-                        </rect>
-                    </property>
-                    <property name="paletteForegroundColor">
-                        <color>
-                            <red>0</red>
-                            <green>0</green>
-                            <blue>255</blue>
-                        </color>
-                    </property>
-                    <property name="font">
-                        <font>
-                            <family>Courier 10 Pitch</family>
-                            <underline>1</underline>
-                        </font>
-                    </property>
-                    <property name="cursor">
-                        <cursor>13</cursor>
-                    </property>
-                    <property name="text">
-                        <string>http://cups.org</string>
-                    </property>
-                </widget>
-                <widget class="QLabel">
-                    <property name="name">
-                        <cstring>textLabel1_2</cstring>
-                    </property>
-                    <property name="geometry">
-                        <rect>
-                            <x>11</x>
-                            <y>11</y>
-                            <width>384</width>
-                            <height>23</height>
-                        </rect>
-                    </property>
-                    <property name="text">
-                        <string>&lt;b&gt;CUPS&lt;/b&gt;</string>
-                    </property>
-                </widget>
-                <widget class="QLabel">
-                    <property name="name">
-                        <cstring>textLabel4_2</cstring>
-                    </property>
-                    <property name="geometry">
-                        <rect>
-                            <x>11</x>
-                            <y>49</y>
-                            <width>773</width>
-                            <height>39</height>
-                        </rect>
-                    </property>
-                    <property name="text">
-                        <string>Information about CUPS (Common UNIX Printing 
System) is available at cups.org. This website also contains forums and other 
support resources for printing on Linux:</string>
-                    </property>
-                    <property name="alignment">
-                        <set>WordBreak|AlignVCenter</set>
-                    </property>
-                </widget>
-                <spacer>
-                    <property name="name">
-                        <cstring>spacer1</cstring>
-                    </property>
-                    <property name="orientation">
-                        <enum>Vertical</enum>
-                    </property>
-                    <property name="sizeType">
-                        <enum>Expanding</enum>
-                    </property>
-                    <property name="sizeHint">
-                        <size>
-                            <width>20</width>
-                            <height>80</height>
-                        </size>
-                    </property>
-                    <property name="geometry">
-                        <rect>
-                            <x>582</x>
-                            <y>128</y>
-                            <width>20</width>
-                            <height>80</height>
-                        </rect>
-                    </property>
-                </spacer>
-                <widget class="QLabel">
-                    <property name="name">
-                        <cstring>textLabel6_2_2</cstring>
-                    </property>
-                    <property name="geometry">
-                        <rect>
-                            <x>10</x>
-                            <y>260</y>
-                            <width>773</width>
-                            <height>39</height>
-                        </rect>
-                    </property>
-                    <property name="text">
-                        <string>NOTE: CUPS and the CUPS website is owned and 
operated by Easy Software Products and is not affiliated with HP.</string>
-                    </property>
-                    <property name="alignment">
-                        <set>WordBreak|AlignVCenter</set>
-                    </property>
-                </widget>
-            </widget>
         </widget>
     </grid>
 </widget>
@@ -495,23 +365,19 @@
         <slot>linuxprintingButton_clicked()</slot>
     </connection>
     <connection>
-        <sender>linuxprintingButton_2</sender>
-        <signal>clicked()</signal>
-        <receiver>SupportForm_base</receiver>
-        <slot>linuxprintingButton_2_clicked()</slot>
-    </connection>
-    <connection>
-        <sender>hpinktjetButton_2</sender>
+        <sender>cupsButton</sender>
         <signal>clicked()</signal>
         <receiver>SupportForm_base</receiver>
-        <slot>hpinktjetButton_2_clicked()</slot>
+        <slot>cupsButton_clicked()</slot>
     </connection>
 </connections>
+<includes>
+    <include location="local" impldecl="in 
implementation">supportform_base.ui.h</include>
+</includes>
 <slots>
     <slot>hpinktjetButton_clicked()</slot>
     <slot>linuxprintingButton_clicked()</slot>
-    <slot>linuxprintingButton_2_clicked()</slot>
-    <slot>hpinktjetButton_2_clicked()</slot>
+    <slot>cupsButton_clicked()</slot>
 </slots>
 <layoutdefaults spacing="6" margin="11"/>
 </UI>

Reply via email to