Bug 1556868 - convert <textbox type="number"> to <html:input type="number">. r=Paenglab
authorMagnus Melin <mkmelin+mozilla@iki.fi>
Mon, 24 Jun 2019 09:08:34 +0300
changeset 35932 f8de60138717a74dfb72395da77f38bf926bb8ac
parent 35931 42c2ac13e002495c8061841dfe16de6aba93dff5
child 35933 14390389783d5a46cca22ceafa2ae777028159fa
push id392
push userclokep@gmail.com
push dateMon, 02 Sep 2019 20:17:19 +0000
reviewersPaenglab
bugs1556868
Bug 1556868 - convert <textbox type="number"> to <html:input type="number">. r=Paenglab <html:input type="number"> doesn't have a size attribute. Added class="size2-5" to adjust width.
calendar/base/content/dialogs/calendar-event-dialog-recurrence.xul
calendar/base/content/dialogs/calendar-event-dialog-reminder.xul
calendar/base/content/preferences/alarms.inc.xul
calendar/base/content/preferences/general.inc.xul
calendar/base/content/widgets/calendar-alarm-widget.js
calendar/base/themes/common/dialogs/calendar-event-dialog.css
calendar/lightning/content/lightning-item-iframe.xul
chat/content/imAccountOptionsHelper.js
editor/ui/composer/content/pref-composer.xul
mail/components/preferences/advanced.inc.xul
mail/components/preferences/applications.inc.xul
mail/components/preferences/chat.inc.xul
mail/components/preferences/compose.inc.xul
mail/components/preferences/connection.xul
mail/components/preferences/display.inc.xul
mail/components/preferences/notifications.xul
mail/themes/linux/mail/preferences/aboutPreferences.css
mail/themes/linux/mail/textbox.css
mail/themes/osx/mail/preferences/aboutPreferences.css
mail/themes/osx/mail/textbox.css
mail/themes/shared/mail/incontentprefs/aboutPreferences.css
mail/themes/shared/mail/messenger.css
mail/themes/windows/mail/preferences/aboutPreferences.css
mail/themes/windows/mail/textbox.css
mailnews/addrbook/prefs/content/pref-directory-add.js
mailnews/addrbook/prefs/content/pref-directory-add.xul
mailnews/base/content/folderProps.xul
mailnews/base/prefs/content/AccountWizard.xul
mailnews/base/prefs/content/SmtpServerEdit.xul
mailnews/base/prefs/content/am-junk.xul
mailnews/base/prefs/content/am-offline.xul
mailnews/base/prefs/content/am-server-advanced.xul
mailnews/base/prefs/content/am-server.xul
mailnews/base/search/content/searchWidgets.js
mailnews/extensions/newsblog/content/am-newsblog.xul
mailnews/extensions/newsblog/content/feed-subscriptions.xul
mailnews/news/content/downloadheaders.xul
--- a/calendar/base/content/dialogs/calendar-event-dialog-recurrence.xul
+++ b/calendar/base/content/dialogs/calendar-event-dialog-recurrence.xul
@@ -81,25 +81,21 @@
                  align="top">
               <radiogroup id="daily-group">
                 <box id="daily-period-every-box" orient="horizontal" align="center">
                   <radio id="daily-group-every-radio"
                          label="&event.recurrence.pattern.every.label;"
                          disable-on-readonly="true"
                          disable-on-occurrence="true"
                          selected="true"/>
-                  <textbox id="daily-days"
-                           type="number"
-                           value="1"
-                           min="1"
-                           max="0x7FFF"
-                           size="3"
-                           onkeyup="updateRecurrenceControls();"
-                           disable-on-readonly="true"
-                           disable-on-occurrence="true"/>
+                  <html:input id="daily-days" type="number" class="size3"
+                              min="1" max="32767" value="1"
+                              onkeyup="updateRecurrenceControls();"
+                              disable-on-readonly="true"
+                              disable-on-occurrence="true"/>
                   <label id="daily-group-every-units-label"
                          value="&repeat.units.days.both;"
                          disable-on-readonly="true"
                          disable-on-occurrence="true"/>
                   <spacer id="daily-group-spacer" flex="1"/>
                 </box>
                 <radio id="daily-group-weekday-radio"
                        label="&event.recurrence.pattern.every.weekday.label;"
@@ -110,25 +106,21 @@
             <!-- Weekly -->
             <vbox id="period-deck-weekly-box">
               <hbox id="weekly-period-every-box" align="center">
                 <label id="weekly-period-every-label"
                        value="&event.recurrence.pattern.weekly.every.label;"
                        disable-on-readonly="true"
                        disable-on-occurrence="true"
                        control="weekly-weeks"/>
-                <textbox id="weekly-weeks"
-                         type="number"
-                         value="1"
-                         min="1"
-                         max="0x7FFF"
-                         size="3"
-                         onkeyup="updateRecurrenceControls();"
-                         disable-on-readonly="true"
-                         disable-on-occurrence="true"/>
+                <html:input id="weekly-weeks" type="number" class="size3"
+                            min="1" max="32767" value="1"
+                            onkeyup="updateRecurrenceControls();"
+                            disable-on-readonly="true"
+                            disable-on-occurrence="true"/>
                 <label id="weekly-period-units-label"
                        value="&repeat.units.weeks.both;"
                        disable-on-readonly="true"
                        disable-on-occurrence="true"/>
               </hbox>
               <hbox align="center">
                 <label id="weekly-period-on-label"
                        value="&event.recurrence.on.label;"
@@ -155,25 +147,21 @@
             <!-- Monthly -->
             <vbox id="period-deck-monthly-box">
               <hbox id="montly-period-every-box" align="center">
                 <label id="monthly-period-every-label"
                        value="&event.recurrence.pattern.monthly.every.label;"
                        disable-on-readonly="true"
                        disable-on-occurrence="true"
                        control="monthly-interval"/>
-                <textbox id="monthly-interval"
-                         type="number"
-                         value="1"
-                         min="1"
-                         max="0x7FFF"
-                         size="3"
-                         onkeyup="updateRecurrenceControls();"
-                         disable-on-readonly="true"
-                         disable-on-occurrence="true"/>
+                <html:input id="monthly-interval" type="number" class="size3"
+                            min="1" max="32767" value="1"
+                            onkeyup="updateRecurrenceControls();"
+                            disable-on-readonly="true"
+                            disable-on-occurrence="true"/>
                 <label id="monthly-period-units-label"
                        value="&repeat.units.months.both;"
                        disable-on-readonly="true"
                        disable-on-occurrence="true"/>
               </hbox>
               <radiogroup id="monthly-group">
                 <box id="monthly-period-relative-date-box"
                          orient="horizontal" align="center">
@@ -305,25 +293,21 @@
             <!-- Yearly -->
             <box id="period-deck-yearly-box"
                  orient="vertical"
                  align="top">
               <hbox id="yearly-period-every-box" align="center">
                 <label id="yearly-period-every-label"
                        value="&event.recurrence.every.label;"
                        control="yearly-interval"/>
-                <textbox id="yearly-interval"
-                         type="number"
-                         value="1"
-                         min="1"
-                         max="0x7FFF"
-                         size="3"
-                         onkeyup="updateRecurrenceControls();"
-                         disable-on-readonly="true"
-                         disable-on-occurrence="true"/>
+                <html:input id="yearly-interval" type="number" class="size3"
+                            min="1" max="32767" value="1"
+                            onkeyup="updateRecurrenceControls();"
+                            disable-on-readonly="true"
+                            disable-on-occurrence="true"/>
                 <label id="yearly-period-units-label" value="&repeat.units.years.both;"/>
               </hbox>
               <radiogroup id="yearly-group">
                 <grid id="yearly-period-grid">
                   <columns id="yearly-period-columns">
                     <column id="yearly-period-radio-column"/>
                     <column id="yearly-period-controls-column"/>
                   </columns>
@@ -332,24 +316,21 @@
                       <radio id="yearly-period-absolute-radio"
                              label="&event.recurrence.pattern.yearly.every.month.label;"
                              selected="true"
                              disable-on-readonly="true"
                              disable-on-occurrence="true"/>
                       <box id="yearly-period-absolute-controls"
                            orient="horizontal"
                            align="center">
-                        <textbox id="yearly-days"
-                                 type="number"
-                                 value="1"
-                                 min="1"
-                                 size="3"
-                                 onkeyup="updateRecurrenceControls();"
-                                 disable-on-readonly="true"
-                                 disable-on-occurrence="true"/>
+                        <html:input id="yearly-days" type="number" class="size3"
+                                    min="1" value="1"
+                                    onkeyup="updateRecurrenceControls();"
+                                    disable-on-readonly="true"
+                                    disable-on-occurrence="true"/>
                         <label id="yearly-period-of-month-label"
                                value="&event.recurrence.pattern.yearly.of.label;"
                                control="yearly-month-ordinal"/>
                         <menulist id="yearly-month-ordinal"
                                   disable-on-readonly="true"
                                   disable-on-occurrence="true">
                           <menupopup id="yearly-month-ordinal-menupopup">
                             <menuitem id="yearly-month-ordinal-1"
@@ -532,25 +513,21 @@
         <box id="recurrence-range-count-box"
              orient="horizontal"
              align="center">
           <radio id="recurrence-range-for"
                  label="&event.recurrence.repeat.for.label;"
                  value="ntimes"
                  disable-on-readonly="true"
                  disable-on-occurrence="true"/>
-          <textbox id="repeat-ntimes-count"
-                   type="number"
-                   value="5"
-                   min="1"
-                   max="0x7FFF"
-                   size="3"
-                   onkeyup="updateRecurrenceControls();"
-                   disable-on-readonly="true"
-                   disable-on-occurrence="true"/>
+          <html:input id="repeat-ntimes-count" type="number" class="size3"
+                      min="1" max="32767" value="5"
+                      onkeyup="updateRecurrenceControls();"
+                      disable-on-readonly="true"
+                      disable-on-occurrence="true"/>
           <label id="repeat-appointments-label"
                  value="&event.recurrence.appointments.label;"
                  disable-on-readonly="true"
                  disable-on-occurrence="true"/>
         </box>
         <box id="recurrence-range-until-box"
              orient="horizontal"
              align="center">
--- a/calendar/base/content/dialogs/calendar-event-dialog-reminder.xul
+++ b/calendar/base/content/dialogs/calendar-event-dialog-reminder.xul
@@ -58,21 +58,18 @@
   <radiogroup id="reminder-relation-radiogroup"
                 onselect="setupRadioEnabledState(); updateReminder(event)">
     <hbox id="reminder-relative-box" align="top" flex="1">
       <radio id="reminder-relative-radio"
              value="relative"
              aria-labeledby="reminder-length reminder-unit reminder-relation reminder-origin"/>
       <vbox id="reminder-relative-box" flex="1">
         <hbox id="reminder-relative-length-unit-relation" flex="1">
-          <textbox id="reminder-length"
-                   type="number"
-                   size="1"
-                   min="0"
-                   onkeyup="updateReminder(event)"/>
+          <html:input id="reminder-length" type="number" min="0"
+                      onkeyup="updateReminder(event)"/>
           <menulist id="reminder-unit" oncommand="updateReminder(event)" flex="1">
             <menupopup id="reminder-unit-menupopup">
               <menuitem id="reminder-minutes-menuitem"
                         label="&alarm.units.minutes;"
                         value="minutes"/>
               <menuitem id="reminder-hours-menuitem"
                         label="&alarm.units.hours;"
                         value="hours"/>
--- a/calendar/base/content/preferences/alarms.inc.xul
+++ b/calendar/base/content/preferences/alarms.inc.xul
@@ -69,24 +69,21 @@
                 <html:tr>
                     <html:td>
                         <label value="&pref.defaultsnoozelength.label;"
                                accesskey="&pref.defaultsnoozelength.accesskey;"
                                control="defaultsnoozelength"/>
                     </html:td>
                     <html:td width="30%">
                         <hbox align="center">
-                            <textbox id="defaultsnoozelength"
-                                     preference="calendar.alarms.defaultsnoozelength"
-                                     type="number"
-                                     min="0"
-                                     maxlength="4"
-                                     size="3"
-                                     onselect="updateUnitLabelPlural('defaultsnoozelength', 'defaultsnoozelengthunit', 'minutes')"
-                                     oninput="updateUnitLabelPlural('defaultsnoozelength', 'defaultsnoozelengthunit', 'minutes')"/>
+                            <html:input id="defaultsnoozelength" type="number" class="size3"
+                                        min="0"
+                                        preference="calendar.alarms.defaultsnoozelength"
+                                        onselect="updateUnitLabelPlural('defaultsnoozelength', 'defaultsnoozelengthunit', 'minutes')"
+                                        oninput="updateUnitLabelPlural('defaultsnoozelength', 'defaultsnoozelengthunit', 'minutes')"/>
                             <label id="defaultsnoozelengthunit"/>
                         </hbox>
                     </html:td>
                 </html:tr>
                 <html:tr>
                     <html:td>
                         <label value="&pref.defalarm4events.label;"
                                accesskey="&pref.defalarm4events.accesskey;"
@@ -135,23 +132,20 @@
                         <label value="&pref.defalarmlen4events.label;"
                                accesskey="&pref.defalarmlen4events.accesskey;"
                                control="eventdefalarmlen"/>
                     </html:td>
                     <html:td>
                         <hbox class="defaultTimeBox"
                               align="center"
                               flex="1">
-                            <textbox id="eventdefalarmlen"
-                                      preference="calendar.alarms.eventalarmlen"
-                                      type="number"
-                                      min="0"
-                                      size="3"
-                                      onselect="updateMenuLabelsPlural('eventdefalarmlen', 'eventdefalarmunit')"
-                                      oninput="updateMenuLabelsPlural('eventdefalarmlen', 'eventdefalarmunit')"/>
+                            <html:input id="eventdefalarmlen" type="number" class="size3" min="0"
+                                        preference="calendar.alarms.eventalarmlen"
+                                        onselect="updateMenuLabelsPlural('eventdefalarmlen', 'eventdefalarmunit')"
+                                        oninput="updateMenuLabelsPlural('eventdefalarmlen', 'eventdefalarmunit')"/>
                             <menulist id="eventdefalarmunit"
                                       flex="1"
                                       crop="none"
                                       preference="calendar.alarms.eventalarmunit">
                                 <menupopup id="eventdefalarmunitpopup">
                                     <menuitem id="eventdefalarmunitmin"
                                               value="minutes"
                                               selected="true"/>
@@ -169,23 +163,20 @@
                         <label value="&pref.defalarmlen4todos.label;"
                                accesskey="&pref.defalarmlen4todos.accesskey;"
                                control="tododefalarmlen"/>
                     </html:td>
                     <html:td>
                         <hbox class="defaultTimeBox"
                               align="center"
                               flex="1">
-                            <textbox id="tododefalarmlen"
-                                      preference="calendar.alarms.todoalarmlen"
-                                      type="number"
-                                      min="0"
-                                      size="3"
-                                      onselect="updateMenuLabelsPlural('tododefalarmlen', 'tododefalarmunit')"
-                                      oninput="updateMenuLabelsPlural('tododefalarmlen', 'tododefalarmunit')"/>
+                            <html:input id="tododefalarmlen" type="number" class="size3" min="0"
+                                        preference="calendar.alarms.todoalarmlen"
+                                        onselect="updateMenuLabelsPlural('tododefalarmlen', 'tododefalarmunit')"
+                                        oninput="updateMenuLabelsPlural('tododefalarmlen', 'tododefalarmunit')"/>
                             <menulist id="tododefalarmunit"
                                       flex="1"
                                       crop="none"
                                       preference="calendar.alarms.todoalarmunit">
                                 <menupopup id="tododefalarmunitpopup">
                                     <menuitem id="tododefalarmunitmin"
                                               value="minutes"
                                               selected="true"/>
--- a/calendar/base/content/preferences/general.inc.xul
+++ b/calendar/base/content/preferences/general.inc.xul
@@ -41,24 +41,21 @@
             <label><html:h2 id="defaults-itemtype-caption">&pref.defaults.label;</html:h2></label>
             <vbox id="defaults-itemtype-box">
                 <label><html:h3>&pref.events.label;</html:h3></label>
                 <hbox id="defaults-event-grid-box" align="center">
                     <label id="default-event-length-label"
                             value="&pref.default_event_length.label;"
                             accesskey="&pref.default_event_length.accesskey;"
                             control="defaultlength"/>
-                    <textbox id="defaultlength"
-                              preference="calendar.event.defaultlength"
-                              type="number"
-                              min="0"
-                              maxlength="3"
-                              size="3"
-                              onselect="updateUnitLabelPlural('defaultlength', 'defaultlengthunit', 'minutes')"
-                              oninput="updateUnitLabelPlural('defaultlength', 'defaultlengthunit', 'minutes')"/>
+                    <html:input id="defaultlength" type="number" class="size3"
+                                min="0"
+                                preference="calendar.event.defaultlength"
+                                onselect="updateUnitLabelPlural('defaultlength', 'defaultlengthunit', 'minutes')"
+                                oninput="updateUnitLabelPlural('defaultlength', 'defaultlengthunit', 'minutes')"/>
                     <label id="defaultlengthunit"/>
                 </hbox>
                 <label><html:h3>&pref.tasks.label;</html:h3></label>
                 <html:table id="defaults-task-table">
                     <html:tr id="defaults-task-start-row">
                         <html:td>
                             <label id="default-task-start-label"
                                     value="&read.only.task.start.label;"
@@ -89,24 +86,21 @@
                                     <menuitem id="default_task_start_offset_next_hour"
                                               label="&pref.default_task_offset_next_hour.label;"
                                               value="offsetnexthour"/>
                                 </menupopup>
                             </menulist>
                         </html:td>
                         <html:td>
                             <hbox id="default_task_start_offset" align="center">
-                                <textbox id="default_task_start_offset_text"
-                                          preference="calendar.task.defaultstartoffset"
-                                          type="number"
-                                          min="0"
-                                          maxlength="3"
-                                          size="3"
-                                          onselect="updateMenuLabelsPlural('default_task_start_offset_text', 'default_task_start_offset_units')"
-                                          oninput="updateMenuLabelsPlural('default_task_start_offset_text', 'default_task_start_offset_units')"/>
+                                <html:input id="default_task_start_offset_text" type="number" class="size3"
+                                            min="0"
+                                            preference="calendar.task.defaultstartoffset"
+                                            onselect="updateMenuLabelsPlural('default_task_start_offset_text', 'default_task_start_offset_units')"
+                                            oninput="updateMenuLabelsPlural('default_task_start_offset_text', 'default_task_start_offset_units')"/>
                                 <menulist id="default_task_start_offset_units"
                                           crop="none"
                                           preference="calendar.task.defaultstartoffsetunits">
                                     <menupopup id="default_task_start_offset_units_popup">
                                         <menuitem id="default_task_start_offset_units_minutes"
                                                   value="minutes"
                                                   selected="true"/>
                                         <menuitem id="default_task_start_offset_units_hours"
@@ -149,24 +143,21 @@
                                     <menuitem id="default_task_due_offset_next_hour"
                                               label="&pref.default_task_offset_next_hour.label;"
                                               value="offsetnexthour"/>
                                 </menupopup>
                             </menulist>
                         </html:td>
                         <html:td>
                             <hbox id="default_task_due_offset" align="center">
-                                <textbox id="default_task_due_offset_text"
-                                          preference="calendar.task.defaultdueoffset"
-                                          type="number"
-                                          min="0"
-                                          maxlength="3"
-                                          size="3"
-                                          onselect="updateMenuLabelsPlural('default_task_due_offset_text', 'default_task_due_offset_units')"
-                                          oninput="updateMenuLabelsPlural('default_task_due_offset_text', 'default_task_due_offset_units')"/>
+                                <html:input id="default_task_due_offset_text" type="number" class="size3"
+                                            min="0"
+                                            preference="calendar.task.defaultdueoffset"
+                                            onselect="updateMenuLabelsPlural('default_task_due_offset_text', 'default_task_due_offset_units')"
+                                            oninput="updateMenuLabelsPlural('default_task_due_offset_text', 'default_task_due_offset_units')"/>
                                 <menulist id="default_task_due_offset_units"
                                           crop="none"
                                           preference="calendar.task.defaultdueoffsetunits">
                                     <menupopup id="default_task_due_offset_units_popup">
                                         <menuitem id="default_task_due_offset_units_minutes"
                                                   value="minutes"
                                                   selected="true"/>
                                         <menuitem id="default_task_due_offset_units_hours"
--- a/calendar/base/content/widgets/calendar-alarm-widget.js
+++ b/calendar/base/content/widgets/calendar-alarm-widget.js
@@ -262,21 +262,19 @@
                 <menuitem label="&calendar.alarm.snooze.2hours.label;"
                           value="120"
                           oncommand="snoozeItem(event)"/>
                 <menuitem label="&calendar.alarm.snooze.1day.label;"
                           value="1440"
                           oncommand="snoozeItem(event)"/>
                 <menuseparator/>
                 <hbox class="snooze-options-box">
-                  <textbox class="snooze-value-textbox"
-                           oninput="updateUIText()"
-                           onselect="updateUIText()"
-                           type="number"
-                           size="3"/>
+                  <html:input type="number" class="size3 snooze-value-textbox"
+                              oninput="updateUIText()"
+                              onselect="updateUIText()"/>
                   <menulist class="snooze-unit-menulist" allowevents="true">
                     <menupopup class="snooze-unit-menupopup menulist-menupopup"
                                position="after_start"
                                ignorekeys="true">
                       <menuitem closemenu="single" class="unit-menuitem" value="1"></menuitem>
                       <menuitem closemenu="single" class="unit-menuitem" value="60"></menuitem>
                       <menuitem closemenu="single" class="unit-menuitem" value="1440"></menuitem>
                     </menupopup>
--- a/calendar/base/themes/common/dialogs/calendar-event-dialog.css
+++ b/calendar/base/themes/common/dialogs/calendar-event-dialog.css
@@ -275,24 +275,16 @@ label.label {
  *   priority "high" image
  *-------------------------------------------------------------------*/
 
 #image-priority-high {
     -moz-image-region: rect(0 48px 16px 32px);
 }
 
 /*--------------------------------------------------------------------
- *   Task completion box
- *-------------------------------------------------------------------*/
-
-#percent-complete-textbox {
-    width: 5em;
-}
-
-/*--------------------------------------------------------------------
  *   Recurrence dialog preview border
  *-------------------------------------------------------------------*/
 #preview-border {
     border: none;
     padding: 0px;
 }
 
 /*--------------------------------------------------------------------
@@ -315,20 +307,16 @@ label.label {
 #freebusy-grid > .dummy-row, #freebusy-grid .dummy-row-cell {
     width: 100%;
 }
 
 #calendar-summary-dialog {
     min-width: 35em;
 }
 
-listbox[disabled="true"] {
-    color: -moz-FieldText;
-}
-
 #daypicker-weekday {
     margin-top: 2px;
 }
 
 .daypicker-monthday {
     margin-top: 2px;
 }
 
--- a/calendar/lightning/content/lightning-item-iframe.xul
+++ b/calendar/lightning/content/lightning-item-iframe.xul
@@ -353,24 +353,21 @@
                         value="CANCELLED"/>
             </menupopup>
           </menulist>
             <datepicker id="completed-date-picker"
                         class="todo-only"
                         disable-on-readonly="true"
                         disabled="true"
                         value=""/>
-            <textbox id="percent-complete-textbox"
-                     type="number"
-                     min="0"
-                     max="100"
-                     disable-on-readonly="true"
-                     size="3"
-                     oninput="updateToDoStatus('percent-changed')"
-                     onselect="updateToDoStatus('percent-changed')"/>
+            <html:input id="percent-complete-textbox" type="number" class="size3"
+                        min="0" max="100"
+                        disable-on-readonly="true"
+                        oninput="updateToDoStatus('percent-changed')"
+                        onselect="updateToDoStatus('percent-changed')"/>
             <label id="percent-complete-label"
                    class="todo-only"
                    disable-on-readonly="true"
                    value="&newtodo.percentcomplete.label;"/>
         </hbox>
       </row>
 
       <separator id="event-grid-recurrence-separator" class="groove"/>
--- a/chat/content/imAccountOptionsHelper.js
+++ b/chat/content/imAccountOptionsHelper.js
@@ -10,17 +10,21 @@ var accountOptionsHelper = {
 
     let label = document.createXULElement("label");
     label.textContent = aLabel;
     label.setAttribute("control", aName);
     label.setAttribute("flex", "1");
     container.appendChild(label);
 
     let hbox = document.createXULElement("hbox");
-    let textbox = document.createXULElement("textbox");
+    let textbox = (aType != "number") ? document.createXULElement("textbox") :
+      document.createElementNS("http://www.w3.org/1999/xhtml", "input");
+    if (aType == "number") {
+      textbox.style.width = "100%";
+    }
     if (aType) {
       textbox.setAttribute("type", aType);
     }
     textbox.setAttribute("value", aValue);
     textbox.setAttribute("id", aName);
     textbox.setAttribute("flex", "1");
     hbox.setAttribute("flex", "1");
     hbox.setAttribute("align", "start");
--- a/editor/ui/composer/content/pref-composer.xul
+++ b/editor/ui/composer/content/pref-composer.xul
@@ -35,25 +35,19 @@
 
     <!-- Recent files menu -->
     <groupbox>
       <label class="header">&recentFiles.title;</label>
       <hbox align="center">
         <label value="&documentsInMenu.label;"
                accesskey="&documentsInMenu.accesskey;"
                control="recentFiles"/>
-        <textbox id="recentFiles"
-                 name="recent string"
-                 type="number"
-                 max="99"
-                 min="0"
-                 maxlength="2"
-                 size="3"
-                 value="10"
-                 preference="editor.history.url_maximum"/>
+        <html:input id="recentFiles" type="number" class="size3"
+                    min="0" max="99" value="10"
+                    preference="editor.history.url_maximum"/>
       </hbox>
     </groupbox>
 
     <!-- HTML formatting on output -->
     <groupbox>
       <label class="header">&savingFiles.title;</label>
       <checkbox id="preserveFormatting"
                 label="&preserveExisting.label;"
--- a/mail/components/preferences/advanced.inc.xul
+++ b/mail/components/preferences/advanced.inc.xul
@@ -245,34 +245,34 @@
                         id="allowSmartSize"
                         onsyncfrompreference="return gAdvancedPane.readSmartSizeEnabled();"
                         label="&overrideSmartCacheSize.label;"
                         accesskey="&overrideSmartCacheSize.accesskey;"/>
             </hbox>
             <hbox align="center" class="indent">
               <label id="useCacheBefore" control="cacheSize"
                      accesskey="&useCacheBefore.accesskey;" value="&useCacheBefore.label;"/>
-              <textbox id="cacheSize" type="number" size="4" max="1024"
-                       preference="browser.cache.disk.capacity"
-                       onsyncfrompreference="return gAdvancedPane.readCacheSize();"
-                       onsynctopreference="return gAdvancedPane.writeCacheSize();"
-                       aria-labelledby="useCacheBefore cacheSize useCacheAfter"/>
+              <html:input id="cacheSize" type="number" class="size4" max="1024"
+                          preference="browser.cache.disk.capacity"
+                          onsyncfrompreference="return gAdvancedPane.readCacheSize();"
+                          onsynctopreference="return gAdvancedPane.writeCacheSize();"
+                          aria-labelledby="useCacheBefore cacheSize useCacheAfter"/>
               <label id="useCacheAfter" flex="1">&useCacheAfter.label;</label>
             </hbox>
             <hbox align="center">
                 <checkbox id="offlineCompactFolder"
                           label="&offlineCompactFolders.label;"
                           accesskey="&offlineCompactFolders.accesskey;"
                           aria-labelledby="offlineCompactFolder offlineCompactFolderMin compactFolderMB"
                           preference="mail.prompt_purge_threshhold"
                           oncommand="gAdvancedPane.updateCompactOptions(this.checked);"/>
-                <textbox id="offlineCompactFolderMin" size="4" value="20"
-                         type="number" min="1" max="2048" increment="10"
-                         preference="mail.purge_threshhold_mb"
-                         aria-labelledby="offlineCompactFolder offlineCompactFolderMin compactFolderMB"/>
+                <html:input id="offlineCompactFolderMin" type="number" class="size4"
+                            min="1" max="2048" value="20"
+                            preference="mail.purge_threshhold_mb"
+                            aria-labelledby="offlineCompactFolder offlineCompactFolderMin compactFolderMB"/>
                 <label id="compactFolderMB" value="&offlineCompactFoldersMB.label;"/>
             </hbox>
           </groupbox>
         </tabpanel>
 
 #ifdef MOZ_UPDATER
         <!-- Update -->
         <tabpanel orient="vertical">
--- a/mail/components/preferences/applications.inc.xul
+++ b/mail/components/preferences/applications.inc.xul
@@ -100,21 +100,20 @@
         </tabpanel>
 
         <tabpanel orient="vertical">
           <vbox flex="1">
             <hbox id="cloudFileToggleAndThreshold" align="center">
               <checkbox id="enableThreshold"
                         label="&enableCloudFileAccountOffer.label;"
                         preference="mail.compose.big_attachments.notify"/>
-              <textbox id="cloudFileThreshold" type="number" increment="1"
-                       maxlength="4" size="2"
-                       preference="mail.compose.big_attachments.threshold_kb"
-                       onsyncfrompreference="return gCloudFileTab.readThreshold();"
-                       onsynctopreference="return gCloudFileTab.writeThreshold();"/>
+              <html:input id="cloudFileThreshold" type="number" class="size3"
+                          preference="mail.compose.big_attachments.threshold_kb"
+                          onsyncfrompreference="return gCloudFileTab.readThreshold();"
+                          onsynctopreference="return gCloudFileTab.writeThreshold();"/>
               <label control="cloudFileThreshold"
                      value="&enableCloudFileAccountOffer.mb;"/>
             </hbox>
             <hbox flex="1">
               <vbox id="provider-listing">
                 <richlistbox id="cloudFileView" orient="vertical" flex="1"
                              seltype="single"
                              onoverflow="gCloudFileTab.onListOverflow();"
--- a/mail/components/preferences/chat.inc.xul
+++ b/mail/components/preferences/chat.inc.xul
@@ -31,22 +31,22 @@
           </hbox>
           <separator/>
 
           <!-- Status -->
           <hbox align="center">
             <checkbox id="reportIdle" label="&reportIdleAfter.label;"
                       accesskey="&reportIdleAfter.accesskey;"
                       preference="messenger.status.reportIdle"/>
-            <textbox id="timeBeforeAway" type="number" min="1" max="720" size="2"
-                     class="idle-reporting-enabled"
-                     preference="messenger.status.timeBeforeIdle"
-                     onsyncfrompreference="var elt = Preferences.get(this.getAttribute('preference'));
-                                           return (elt.instantApply ? elt.valueFromPreferences : elt.value) / 60;"
-                     onsynctopreference="return this.value * 60;"/>
+            <html:input id="timeBeforeAway" type="number" class="size2 idle-reporting-enabled"
+                        min="1" max="720"
+                        preference="messenger.status.timeBeforeIdle"
+                        onsyncfrompreference="var elt = Preferences.get(this.getAttribute('preference'));
+                                              return (elt.instantApply ? elt.valueFromPreferences : elt.value) / 60;"
+                        onsynctopreference="return this.value * 60;"/>
             <label value="&idleTime;" control="timeBeforeAway"/>
           </hbox>
           <vbox class="indent">
             <hbox>
               <checkbox id="autoAway"
                         label="&andSetStatusToAway.label;"
                         class="idle-reporting-enabled"
                         accesskey="&andSetStatusToAway.accesskey;"
--- a/mail/components/preferences/compose.inc.xul
+++ b/mail/components/preferences/compose.inc.xul
@@ -31,20 +31,20 @@
                         accesskey="&addExtension.accesskey;"/>
             </hbox>
 
             <separator class="thin"/>
 
             <hbox align="center" pack="start">
               <checkbox id="autoSave" label="&autoSave.label;" preference="mail.compose.autosave"
                         accesskey="&autoSave.accesskey;"/>
-              <textbox id="autoSaveInterval"
-                       size="2" type="number" min="1" max="35790"
-                       preference="mail.compose.autosaveinterval"
-                       aria-labelledby="autoSave autoSaveInterval autoSaveEnd"/>
+              <html:input id="autoSaveInterval" type="number" class="size2"
+                          min="1" max="35790"
+                          preference="mail.compose.autosaveinterval"
+                          aria-labelledby="autoSave autoSaveInterval autoSaveEnd"/>
               <label id="autoSaveEnd" value="&autoSaveEnd.label;"/>
             </hbox>
             <hbox>
               <checkbox id="mailWarnOnSendAccelKey"
                         label="&warnOnSendAccelKey.label;"
                         preference="mail.warn_on_send_accel_key"
                         accesskey="&warnOnSendAccelKey.accesskey;"/>
               <spacer flex="1"/>
--- a/mail/components/preferences/connection.xul
+++ b/mail/components/preferences/connection.xul
@@ -51,19 +51,19 @@
           <row align="center">
             <hbox pack="end">
               <label value="&http.label;" accesskey="&http.accesskey;" control="networkProxyHTTP"/>
             </hbox>
             <hbox align="center">
               <textbox id="networkProxyHTTP" flex="1" class="uri-element"
                        preference="network.proxy.http" onsyncfrompreference="return gConnectionsDialog.readHTTPProxyServer();"/>
               <label value="&HTTPport.label;" accesskey="&HTTPport.accesskey;" control="networkProxyHTTP_Port"/>
-              <textbox id="networkProxyHTTP_Port" type="number" max="65535" size="5"
-                       preference="network.proxy.http_port"
-                       onsyncfrompreference="return gConnectionsDialog.readHTTPProxyPort();"/>
+              <html:input id="networkProxyHTTP_Port" type="number" class="size5" max="65535"
+                          preference="network.proxy.http_port"
+                          onsyncfrompreference="return gConnectionsDialog.readHTTPProxyPort();"/>
             </hbox>
           </row>
           <row>
             <hbox/>
             <hbox>
               <checkbox id="shareAllProxies" label="&shareproxy.label;" accesskey="&shareproxy.accesskey;"
                         preference="network.proxy.share_proxy_settings"
                         onsyncfrompreference="return gConnectionsDialog.updateProtocolPrefs();"/>
@@ -73,33 +73,33 @@
             <hbox pack="end">
               <label value="&ssl.label;" accesskey="&ssl.accesskey;" control="networkProxySSL"/>
             </hbox>
             <hbox align="center">
               <textbox id="networkProxySSL" flex="1" class="uri-element"
                        preference="network.proxy.ssl"
                        onsyncfrompreference="return gConnectionsDialog.readProxyProtocolPref('ssl', false);"/>
               <label value="&SSLport.label;" accesskey="&SSLport.accesskey;" control="networkProxySSL_Port"/>
-              <textbox id="networkProxySSL_Port" type="number" max="65535" size="5"
-                       preference="network.proxy.ssl_port"
-                       onsyncfrompreference="return gConnectionsDialog.readProxyProtocolPref('ssl', true);"/>
+              <html:input id="networkProxySSL_Port" type="number" class="size5" max="65535"
+                          preference="network.proxy.ssl_port"
+                          onsyncfrompreference="return gConnectionsDialog.readProxyProtocolPref('ssl', true);"/>
             </hbox>
           </row>
           <row align="center">
             <hbox pack="end">
               <label value="&socks.label;" accesskey="&socks.accesskey;" control="networkProxySOCKS"/>
             </hbox>
             <hbox align="center">
               <textbox id="networkProxySOCKS" flex="1" class="uri-element"
                        preference="network.proxy.socks"
                        onsyncfrompreference="return gConnectionsDialog.readProxyProtocolPref('socks', false);"/>
               <label value="&SOCKSport.label;" accesskey="&SOCKSport.accesskey;" control="networkProxySOCKS_Port"/>
-              <textbox id="networkProxySOCKS_Port" type="number" max="65535" size="5"
-                       preference="network.proxy.socks_port"
-                       onsyncfrompreference="return gConnectionsDialog.readProxyProtocolPref('socks', true);"/>
+              <html:input id="networkProxySOCKS_Port" type="number" class="size5" max="65535"
+                          preference="network.proxy.socks_port"
+                          onsyncfrompreference="return gConnectionsDialog.readProxyProtocolPref('socks', true);"/>
             </hbox>
           </row>
           <row>
             <spacer/>
             <radiogroup id="networkProxySOCKSVersion" orient="horizontal"
                         preference="network.proxy.socks_version"
                         onsyncfrompreference="return gConnectionsDialog.updateDNSPref();">
               <radio id="networkProxySOCKSVersion4" value="4" label="&socks4.label;" accesskey="&socks4.accesskey;" />
--- a/mail/components/preferences/display.inc.xul
+++ b/mail/components/preferences/display.inc.xul
@@ -155,20 +155,20 @@
                 <radio id="mark_read_immediately"
                        label="&markAsReadNoDelay.label;"
                        value="false"
                        accesskey="&markAsReadNoDelay.accesskey;"/>
                 <hbox align="center">
                   <radio id="markAsReadAfterDelay" value="true"
                          label="&markAsReadDelay.label;"
                          accesskey="&markAsReadDelay.accesskey;"/>
-                  <textbox id="markAsReadDelay" size="2"
-                           type="number" min="1" max="2147483"
-                           preference="mailnews.mark_message_read.delay.interval"
-                           aria-labelledby="markAsReadAfterDelay markAsReadDelay secondsLabel"/>
+                  <html:input id="markAsReadDelay" type="number" class="size3"
+                              min="1" max="2147483"
+                              preference="mailnews.mark_message_read.delay.interval"
+                              aria-labelledby="markAsReadAfterDelay markAsReadDelay secondsLabel"/>
                   <label id="secondsLabel" value="&secondsLabel.label;"/>
                 </hbox>
               </radiogroup>
             </vbox>
 
             <vbox>
               <hbox>
                 <label value="&openMsgIn.label;"
--- a/mail/components/preferences/notifications.xul
+++ b/mail/components/preferences/notifications.xul
@@ -24,20 +24,20 @@
     <checkbox id="sender"  class="indent" label="&sender.label;" accesskey="&sender.accesskey;" preference="mail.biff.alert.show_sender"/>
 
     <separator/>
     <hbox align="center">
       <label id="totalOpenTimeBefore"
              control="totalOpenTime"
              value="&totalOpenTimeBefore.label;"
              accesskey="&totalOpenTimeBefore.accesskey;"/>
-      <textbox id="totalOpenTime" type="number" size="3" min="1" max="3600" increment="1"
-               preference="alerts.totalOpenTime"
-               onsyncfrompreference="return Preferences.get(this.getAttribute('preference')).value / 1000;"
-               onsynctopreference="return this.value * 1000;"/>
+      <html:input id="totalOpenTime" type="number" class="size3" min="1" max="3600"
+                  preference="alerts.totalOpenTime"
+                  onsyncfrompreference="return Preferences.get(this.getAttribute('preference')).value / 1000;"
+                  onsynctopreference="return this.value * 1000;"/>
       <label id="totalOpenTimeEnd" value="&totalOpenTimeEnd.label;"/>
     </hbox>
     <separator/>
   </prefpane>
 
   <script src="chrome://global/content/preferencesBindings.js"/>
   <script src="chrome://messenger/content/preferences/notifications.js"/>
 </dialog>
--- a/mail/themes/linux/mail/preferences/aboutPreferences.css
+++ b/mail/themes/linux/mail/preferences/aboutPreferences.css
@@ -31,22 +31,16 @@ menulist.actionsMenu > .menulist-dropmar
 
 button[type="menu"] > .button-box > .button-menu-dropmarker {
   margin-inline-end: 4px;
   list-style-image: url("chrome://global/skin/icons/arrow-dropdown-12.svg");
   -moz-context-properties: fill;
   fill: currentColor;
 }
 
-textbox[type="number"] {
-  -moz-appearance: none;
-  border: 1px solid var(--in-content-box-border-color);
-  background-color: var(--in-content-box-background);
-}
-
 html|input[type="number"]::-moz-number-spin-up {
   min-height: 10px;
 }
 
 html|input[type="number"]::-moz-number-spin-down {
   min-height: 11px;
 }
 
--- a/mail/themes/linux/mail/textbox.css
+++ b/mail/themes/linux/mail/textbox.css
@@ -1,14 +1,10 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 @namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul");
 @namespace html url("http://www.w3.org/1999/xhtml");
 
-textbox[type="number"] {
-  padding: 0 !important;
-}
-
 html|input[type="number"]::-moz-number-spin-box {
   margin-inline-start: 5px;
 }
--- a/mail/themes/osx/mail/preferences/aboutPreferences.css
+++ b/mail/themes/osx/mail/preferences/aboutPreferences.css
@@ -23,30 +23,16 @@ html|h2 {
   padding-bottom: 2px !important;
   padding-inline-start: 0;
 }
 
 groupbox > .groupbox-body {
   padding: 0;
 }
 
-textbox[type="number"] {
-  padding-inline-end: 0;
-}
-
-textbox[type="number"]:focus-within {
-  border-color: var(--in-content-border-active);
-  box-shadow: 0 0 0 1px var(--in-content-border-active),
-              0 0 0 4px var(--in-content-border-active-shadow);
-}
-
-html|input[type="number"]:focus {
-  box-shadow: none;
-}
-
 html|input[type="number"]::-moz-number-spin-up,
 html|input[type="number"]::-moz-number-spin-down {
   min-height: 11px;
 }
 
 menulist:not([popuponly="true"]) {
   min-height: 30px;
 }
--- a/mail/themes/osx/mail/textbox.css
+++ b/mail/themes/osx/mail/textbox.css
@@ -1,18 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 @namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul");
 @namespace html url("http://www.w3.org/1999/xhtml");
 
-textbox[type="number"]:focus-within {
-  outline: 2px -moz-mac-focusring solid;
-}
-
 html|input[type="number"] {
   padding-inline-end: 0;
 }
 
 html|input[type="number"]::-moz-number-spin-box {
   margin-inline-start: 3px;
 }
--- a/mail/themes/shared/mail/incontentprefs/aboutPreferences.css
+++ b/mail/themes/shared/mail/incontentprefs/aboutPreferences.css
@@ -77,36 +77,16 @@ groupbox {
 }
 
 tabpanel > label,
 tabpanel > description,
 tabpanel > hbox > description {
   margin-inline-start: 0;
 }
 
-textbox[type="number"][size="1"] {
-  width: 4em;
-}
-
-textbox[type="number"][size="2"] {
-  width: 4.5em;
-}
-
-textbox[type="number"][size="3"] {
-  width: 5em;
-}
-
-textbox[type="number"][size="4"] {
-  width: 5.5em;
-}
-
-textbox[type="number"][size="5"] {
-  width: 6em;
-}
-
 /* Web search menulist */
 #defaultWebSearch > .menulist-label-box > .menulist-icon[src] {
   margin-inline-start: 5px;
   margin-inline-end: 8px;
   width: 16px;
   height: 16px;
 }
 
@@ -277,20 +257,31 @@ textbox[type="filefield"][disabled="true
   color: var(--in-content-text-color);
 }
 
 textbox + button {
   margin-inline-start: -4px;
 }
 
 html|input[type="number"] {
-  margin: 0;
-  padding: 0;
-  padding-inline-end: 1px;
-  border-width: 0;
+  margin-inline-start: 4px;
+  padding: 1px;
+}
+/* sizes: chars + 8px padding + 1px borders + spin buttons 25+2+10px  */
+html|input[type="number"].size2 {
+  width: calc(2ch + 55px);
+}
+html|input[type="number"].size3 {
+  width: calc(3ch + 55px);
+}
+html|input[type="number"].size4 {
+  width: calc(4ch + 55px);
+}
+html|input[type="number"].size5 {
+  width: calc(5ch + 55px);
 }
 
 html|input[type="number"]::-moz-number-spin-box {
   margin-inline-start: 10px;
 }
 
 html|input[type="number"]::-moz-number-spin-up,
 html|input[type="number"]::-moz-number-spin-down {
--- a/mail/themes/shared/mail/messenger.css
+++ b/mail/themes/shared/mail/messenger.css
@@ -394,27 +394,25 @@ html|span.ac-emphasize-text {
 .autocomplete-richlistitem:not([ac-comment=""]) > .ac-title {
   -moz-box-ordinal-group: 3;
 }
 
 .ac-url-text {
   max-width: unset !important;
 }
 
-textbox[type="number"][size="1"] {
-  width: 4em;
+html|input[type="number"] {
+  margin-inline-start: 4px;
+}
+/* sizes: chars + 8px padding + 1px borders + spin buttons 14+0+10px  */
+html|input[type="number"].size2 {
+  width: calc(2ch + 44px);
 }
-
-textbox[type="number"][size="2"] {
-  width: 4.5em;
+html|input[type="number"].size3 {
+  width: calc(3ch + 44px);
+}
+html|input[type="number"].size4 {
+  width: calc(4ch + 44px);
+}
+html|input[type="number"].size5 {
+  width: calc(5ch + 44px);
 }
 
-textbox[type="number"][size="3"] {
-  width: 5em;
-}
-
-textbox[type="number"][size="4"] {
-  width: 5.5em;
-}
-
-textbox[type="number"][size="5"] {
-  width: 6em;
-}
--- a/mail/themes/windows/mail/preferences/aboutPreferences.css
+++ b/mail/themes/windows/mail/preferences/aboutPreferences.css
@@ -21,26 +21,16 @@ radio[pane] > .radio-label-box {
 html|h2 {
   background-color: transparent;
 }
 
 .sidebar-footer-label {
   font-size: 1.125em;
 }
 
-textbox[type="number"]:focus-within {
-  border-color: var(--in-content-border-active);
-  box-shadow: 0 0 0 1px var(--in-content-border-active),
-              0 0 0 4px var(--in-content-border-active-shadow);
-}
-
-html|input[type="number"]:focus {
-  box-shadow: none;
-}
-
 html|input[type="number"]::-moz-number-spin-up,
 html|input[type="number"]::-moz-number-spin-down {
   min-height: 13px;
 }
 
 /**
  * Dialog
  */
--- a/mail/themes/windows/mail/textbox.css
+++ b/mail/themes/windows/mail/textbox.css
@@ -1,21 +1,15 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 @namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul");
 @namespace html url("http://www.w3.org/1999/xhtml");
 
-textbox[type="number"] {
-  padding-top: 1px;
-  padding-bottom: 1px;
-  padding-inline-end: 0;
-}
-
 html|input[type="number"]::-moz-number-spin-box {
   margin-inline-start: 4px;
 }
 
 html|input[type="number"]::-moz-number-spin-up,
 html|input[type="number"]::-moz-number-spin-down {
   min-height: .7em;
 }
--- a/mailnews/addrbook/prefs/content/pref-directory-add.js
+++ b/mailnews/addrbook/prefs/content/pref-directory-add.js
@@ -19,17 +19,16 @@ var gReplicationBundle = null;
 var gReplicationService =
   Cc["@mozilla.org/addressbook/ldap-replication-service;1"].
              getService(Ci.nsIAbLDAPReplicationService);
 var gReplicationCancelled = false;
 var gProgressText;
 var gProgressMeter;
 var gDownloadInProgress = false;
 
-var kDefaultMaxHits = 100;
 var kDefaultLDAPPort = 389;
 var kDefaultSecureLDAPPort = 636;
 var kLDAPDirectory = 0;  // defined in nsDirPrefs.h
 
 document.addEventListener("dialogaccept", onAccept);
 document.addEventListener("dialogcancel", onCancel);
 
 var ldapOfflineObserver = {
@@ -245,17 +244,16 @@ function DisableUriFields(aPrefName) {
 function onSecure() {
   document.getElementById("port").value =
     document.getElementById("secure").checked ? kDefaultSecureLDAPPort :
                                                 kDefaultLDAPPort;
 }
 
 function fillDefaultSettings() {
   document.getElementById("port").value = kDefaultLDAPPort;
-  document.getElementById("results").value = kDefaultMaxHits;
   var sub = document.getElementById("sub");
   sub.radioGroup.selectedItem = sub;
 
   // Disable the download button and add some text indicating why.
   document.getElementById("download").disabled = true;
   document.getElementById("downloadWarningMsg").hidden = false;
   document.getElementById("downloadWarningMsg").textContent = document.
                                       getElementById("bundle_addressBook").
--- a/mailnews/addrbook/prefs/content/pref-directory-add.xul
+++ b/mailnews/addrbook/prefs/content/pref-directory-add.xul
@@ -63,19 +63,19 @@
                          <button label="&findButton.label;"
                                  accesskey="&findButton.accesskey;" disabled="true"/>
                      </row>
                      <row align="center">
                          <label value="&portNumber.label;"
                                 accesskey="&portNumber.accesskey;"
                                 control="port"/>
                          <hbox>
-                             <textbox id="port" type="number" size="5" min="1"
-                                       max="65535"
-                                       disableiflocked="true"/>
+                             <html:input id="port" type="number" class="size5"
+                                         min="1" max="65535"
+                                         disableiflocked="true"/>
                          </hbox>
                      </row>
                      <row align="center">
                          <label value="&directoryLogin.label;"
                                 accesskey="&directoryLogin.accesskey;"
                                 control="login"/>
                          <textbox id="login" flex="1" class="uri-element"/>
                      </row>
@@ -105,18 +105,18 @@
              </columns>
 
              <rows>
                <row align="center">
                  <label value="&return.label;"
                         accesskey="&return.accesskey;"
                         control="results"/>
                  <hbox align="center">
-                   <textbox id="results" type="number" size="10" min="1"
-                            max="2147483647" increment="10"/>
+                   <html:input id="results" type="number" class="size5"
+                               min="1" max="2147483647" value="100"/>
                    <label value="&results.label;"/>
                  </hbox>
                </row>
                <row align="center">
                  <label value="&scope.label;" control="scope" accesskey="&scope.accesskey;"/>
                  <radiogroup id="scope" orient="horizontal">
                    <radio id="one" value="1" label="&scopeOneLevel.label;"
                           disableiflocked="true" accesskey="&scopeOneLevel.accesskey;"/>
--- a/mailnews/base/content/folderProps.xul
+++ b/mailnews/base/content/folderProps.xul
@@ -1,14 +1,15 @@
 <?xml version="1.0"?> <!-- -*- Mode: SGML; indent-tabs-mode: nil; -*- -->
 <!-- This Source Code Form is subject to the terms of the Mozilla Public
    - License, v. 2.0. If a copy of the MPL was not distributed with this
    - file, You can obtain one at https://mozilla.org/MPL/2.0/. -->
 
 <?xml-stylesheet href="chrome://global/skin/global.css" type="text/css"?>
+<?xml-stylesheet type="text/css" href="chrome://messenger/skin/messenger.css"?>
 <?xml-stylesheet href="chrome://messenger/skin/preferences/preferences.css" type="text/css"?>
 
 <!DOCTYPE dialog SYSTEM "chrome://messenger/locale/folderProps.dtd">
 
 <dialog
   id="folderPropertiesDialog"
   xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
   xmlns:html="http://www.w3.org/1999/xhtml"
@@ -101,27 +102,27 @@
         <vbox class="indent">
           <hbox class="indent">
             <radiogroup wsm_persist="true" id="retention.keepMsg" aria-labelledby="retention.useDefault">
               <radio wsm_persist="true" value="1" accesskey="&retentionKeepAll.accesskey;"
                       label="&retentionKeepAll.label;" oncommand="onCheckKeepMsg();"/>
               <hbox flex="1" align="center">
                 <radio wsm_persist="true" id="keepNewMsg" accesskey="&retentionKeepRecent.accesskey;"
                         value="3" label="&retentionKeepRecent.label;" oncommand="onCheckKeepMsg();"/>
-                <textbox wsm_persist="true" id="retention.keepNewMsgMin"
-                         type="number" min="1" increment="10" size="4" value="2000"
-                         aria-labelledby="keepNewMsg retention.keepNewMsgMin retention.keepNewMsgMinLabel"/>
+                <html:input id="retention.keepNewMsgMin" type="number" class="size4" min="1" value="2000"
+                            wsm_persist="true"
+                            aria-labelledby="keepNewMsg retention.keepNewMsgMin retention.keepNewMsgMinLabel"/>
                 <label value="&message.label;" control="retention.keepNewMsgMin" id="retention.keepNewMsgMinLabel"/>
               </hbox>
               <hbox flex="1" align="center">
                 <radio wsm_persist="true" id="keepMsg" accesskey="&retentionDeleteMsg.accesskey;"
                         value="2" label="&retentionDeleteMsg.label;" oncommand="onCheckKeepMsg();"/>
-                <textbox wsm_persist="true" id="retention.keepOldMsgMin"
-                         type="number" min="1" size="2" value="30"
-                         aria-labelledby="keepMsg retention.keepOldMsgMin retention.keepOldMsgMinLabel"/>
+                <html:input id="retention.keepOldMsgMin" type="number" class="size4" min="1" value="30"
+                            wsm_persist="true"
+                            aria-labelledby="keepMsg retention.keepOldMsgMin retention.keepOldMsgMinLabel"/>
                 <label value="&daysOld.label;" control="retention.keepOldMsgMin" id="retention.keepOldMsgMinLabel"/>
               </hbox>
             </radiogroup>
           </hbox>
           <hbox class="indent">
             <checkbox id="retention.applyToFlagged" wsm_persist="true"
                       label="&retentionApplyToFlagged.label;"
                       accesskey="&retentionApplyToFlagged.accesskey;"
--- a/mailnews/base/prefs/content/AccountWizard.xul
+++ b/mailnews/base/prefs/content/AccountWizard.xul
@@ -122,17 +122,17 @@
                 <radio id="pop3" group="servertype" value="pop3" label="&popType.label;"
                        wsm_persist="true" oncommand="setServerType();" accesskey="&popType.accesskey;"/>
                 <radio id="imap" group="servertype" value="imap" label="&imapType.label;"
                        wsm_persist="true" oncommand="setServerType();" accesskey="&imapType.accesskey;"/>
             </radiogroup>
             <label id="serverPortLabel" control="serverPort"
                    accesskey="&portNum.accesskey;"
                    value="&portNum.label;"/>
-            <textbox id="serverPort" type="number" size="3" max="65535"/>
+            <html:input id="serverPort" type="number" class="size3" max="65535"/>
             <label id="defaultPortLabel" value="&defaultPortLabel.label;"/>
             <label id="defaultPortValue" value="&defaultPortValue.label;"/>
           </hbox>
           <separator/>
         </vbox>
 
         <vbox id="incomingServerbox">
           <description>&incomingServer.description;</description>
--- a/mailnews/base/prefs/content/SmtpServerEdit.xul
+++ b/mailnews/base/prefs/content/SmtpServerEdit.xul
@@ -50,23 +50,19 @@
                    preftype="string"
                    prefstring="mail.smtpserver.%serverkey%.description"/>
           <textbox id="smtp.hostname"
                    flex="1"
                    preftype="string"
                    class="uri-element"
                    prefstring="mail.smtpserver.%serverkey%.hostname"/>
           <hbox align="center">
-              <textbox id="smtp.port"
-                       type="number"
-                       min="0"
-                       max="65535"
-                       size="5"
-                       preftype="int"
-                       prefstring="mail.smtpserver.%serverkey%.port"/>
+              <html:input id="smtp.port" type="number" class="size5" min="0" max="65535"
+                          preftype="int"
+                          prefstring="mail.smtpserver.%serverkey%.port"/>
               <label value="&serverPortDefault.label;"/>
               <label id="smtp.defaultPort"/>
           </hbox>
         </vbox>
       </hbox>
     </groupbox>
 
     <separator class="thin"/>
@@ -102,17 +98,17 @@
                         disabled="true" hidden="true"/>
               <menuitem value="2" label="&connectionSecurityType-2.label;"/>
               <menuitem value="3" label="&connectionSecurityType-3.label;"/>
             </menupopup>
           </menulist>
           <menulist id="smtp.authMethod"
                     oncommand="authMethodChanged(true);"
                     wsm_persist="true"
-                    preftype="int" type="number"
+                    preftype="int"
                     prefstring="mail.smtpserver.%serverkey%.authMethod">
             <menupopup id="smtp.authMethodPopup">
               <menuitem id="authMethod-no" value="1"/>
               <menuitem id="authMethod-password-cleartext" value="3"/>
               <menuitem id="authMethod-password-encrypted" value="4"/>
               <menuitem id="authMethod-kerberos" value="5"/>
               <menuitem id="authMethod-ntlm" value="6"/>
               <menuitem id="authMethod-oauth2" value="10"/>
--- a/mailnews/base/prefs/content/am-junk.xul
+++ b/mailnews/base/prefs/content/am-junk.xul
@@ -191,26 +191,23 @@
                   genericattr="true"
                   pref="true"
                   wsm_persist="true"
                   preftype="bool"
                   prefstring="mail.server.%serverkey%.purgeSpam"
                   accesskey="&purge1.accesskey;"
                   oncommand="updateJunkRetention();"
                   label="&purge1.label;"/>
-        <textbox size="3"
-                 type="number"
-                 min="1"
-                 id="server.purgeSpamInterval"
-                 genericattr="true"
-                 pref="true"
-                 wsm_persist="true"
-                 preftype="int"
-                 aria-labelledby="server.purgeSpam server.purgeSpamInterval purgeLabel"
-                 prefstring="mail.server.%serverkey%.purgeSpamInterval"/>
+        <html:input id="server.purgeSpamInterval" type="number" class="size3" min="1"
+                    genericattr="true"
+                    pref="true"
+                    wsm_persist="true"
+                    preftype="int"
+                    aria-labelledby="server.purgeSpam server.purgeSpamInterval purgeLabel"
+                    prefstring="mail.server.%serverkey%.purgeSpamInterval"/>
         <label id="purgeLabel"
                value="&purge2.label;"
                control="server.purgeSpamInterval"/>
       </hbox>
 
     </groupbox>
 
     <separator class="thin"/>
--- a/mailnews/base/prefs/content/am-offline.xul
+++ b/mailnews/base/prefs/content/am-offline.xul
@@ -61,19 +61,19 @@
 
     <!-- IMAP Autosync Preference -->
     <radiogroup hidefor="pop3,nntp,movemail,none,rss" id="autosyncSelect" class="indent">
       <radio id="useAutosync.AllMsg" value="0" accesskey="&allAutosync.accesskey;"
              label="&allAutosync.label;" oncommand="onAutosyncChange();"/>
       <hbox flex="1" align="center">
         <radio id="useAutosync.ByAge" accesskey="&ageAutosync.accesskey;"
                value="1" label="&ageAutosyncBefore.label;" oncommand="onAutosyncChange();"/>
-        <textbox id="autosyncValue" type="number" size="4" min="1"
-                 class="autosync" onchange="onAutosyncChange();"
-                 aria-labelledby="ageAutosyncBefore autosyncValue ageAutosyncMiddle autosyncInterval ageAutosyncAfter"/>
+        <html:input id="autosyncValue" type="number" class="size4 autosync" min="1"
+                    onchange="onAutosyncChange();"
+                    aria-labelledby="ageAutosyncBefore autosyncValue ageAutosyncMiddle autosyncInterval ageAutosyncAfter"/>
         <label id="ageAutosyncMiddle" control="autosyncValue" value="&ageAutosyncMiddle.label;"/>
         <menulist id="autosyncInterval" onselect="onAutosyncChange();">
           <menupopup>
             <menuitem label="&dayAgeInterval.label;" value="1"/>
             <menuitem label="&weekAgeInterval.label;" value="7"/>
             <menuitem label="&monthAgeInterval.label;" value="31"/>
             <menuitem label="&yearAgeInterval.label;" value="365"/>
           </menupopup>
@@ -93,30 +93,31 @@
         <checkbox wsm_persist="true" id="offline.notDownload" hidefor="imap"
                   label="&offlineNotDownload.label;"
                   accesskey="&offlineNotDownload.accesskey;"
                   oncommand="onCheckItem('offline.notDownloadMin', 'offline.notDownload');"/>
         <checkbox wsm_persist="true" id="autosync.notDownload" hidefor="pop3,nntp,movemail"
                   label="&autosyncNotDownload.label;"
                   accesskey="&autosyncNotDownload.accesskey;"
                   oncommand="onAutosyncNotDownload();"/>
-        <textbox wsm_persist="true" id="offline.notDownloadMin"
-                 type="number" min="1" increment="10" size="4" value="50"
-                 aria-labelledby="offline.notDownload offline.notDownloadMin kbLabel"/>
+        <html:input id="offline.notDownloadMin" type="number" class="size4"
+                    min="1" value="50"
+                    wsm_persist="true"
+                    aria-labelledby="offline.notDownload offline.notDownloadMin kbLabel"/>
         <label value="&kb.label;" control="offline.notDownloadMin" id="kbLabel"/>
     </hbox>
 
     <hbox align="center" class="indent" hidefor="movemail,pop3,imap,none,rss">
         <checkbox wsm_persist="true" id="nntp.downloadMsg"
                   label="&nntpDownloadMsg.label;"
                   accesskey="&nntpDownloadMsg.accesskey;"
                   oncommand="onCheckItem('nntp.downloadMsgMin', 'nntp.downloadMsg');"/>
-        <textbox wsm_persist="true" id="nntp.downloadMsgMin"
-                 type="number" min="1" size="2" value="30"
-                 aria-labelledby="nntp.downloadMsg nntp.downloadMsgMin daysOldLabel"/>
+        <html:input id="nntp.downloadMsgMin" type="number" class="size2" min="1" value="30"
+                    wsm_persist="true"
+                    aria-labelledby="nntp.downloadMsg nntp.downloadMsgMin daysOldLabel"/>
         <label value="&daysOld.label;" control="nntp.downloadMsgMin"
                id="daysOldLabel"/>
     </hbox>
 
     <vbox align="start">
     <separator hidefor="none,rss"/>
     <label id="retentionDescription" hidefor="imap,pop3" class="desc" control="retention.keepMsg">&retentionCleanup.label;</label>
     <label id="retentionDescriptionImap" hidefor="movemail,pop3,nntp,none,rss" class="desc" control="retention.keepMsg">&retentionCleanupImap.label;</label>
@@ -124,41 +125,39 @@
 
     <radiogroup hidefor="" confirmfor="imap,pop3" id="retention.keepMsg" class="indent"
                 oncommand="warnServerRemove(this);">
         <radio id="retention.keepAllMsg" value="1" accesskey="&retentionKeepAll.accesskey;"
             label="&retentionKeepAll.label;" oncommand="onCheckKeepMsg();"/>
         <hbox flex="1" align="center">
             <radio id="retention.keepNewMsg" accesskey="&retentionKeepRecent.accesskey;"
                 value="3" label="&retentionKeepRecent.label;" oncommand="onCheckKeepMsg();"/>
-            <textbox id="retention.keepNewMsgMin"
-                     type="number" min="1" increment="10" size="4" value="2000"
-                     aria-labelledby="retention.keepNewMsg retention.keepNewMsgMin newMsgLabel"/>
+            <html:input id="retention.keepNewMsgMin" type="number" class="size4"
+                        min="1" value="2000"
+                        aria-labelledby="retention.keepNewMsg retention.keepNewMsgMin newMsgLabel"/>
             <label value="&message.label;" control="retention.keepNewMsgMin" id="newMsgLabel"/>
         </hbox>
         <hbox flex="1" align="center">
             <radio id="retention.keepOldMsg" accesskey="&retentionKeepMsg.accesskey;"
                 value="2" label="&retentionKeepMsg.label;" oncommand="onCheckKeepMsg();"/>
-            <textbox id="retention.keepOldMsgMin"
-                     type="number" min="1" size="4" value="30"
-                     aria-labelledby="retention.keepOldMsg retention.keepOldMsgMin oldMsgLabel"/>
+            <html:input id="retention.keepOldMsgMin" type="number" class="size4"  min="1" value="30"
+                        aria-labelledby="retention.keepOldMsg retention.keepOldMsgMin oldMsgLabel"/>
             <label value="&daysOld.label;" control="retention.keepOldMsgMin" id="oldMsgLabel"/>
         </hbox>
     </radiogroup>
 
     <hbox align="center" class="indent">
       <checkbox id="retention.applyToFlagged"
                 label="&retentionApplyToFlagged.label;" hidefor=""
                 accesskey="&retentionApplyToFlagged.accesskey;"
                 checked="true"/>
     </hbox>
     <hbox align="center" class="indent" hidefor="movemail,pop3,imap,none,rss">
         <checkbox id="nntp.removeBody" accesskey="&nntpRemoveMsgBody.accesskey;"
                   label="&nntpRemoveMsgBody.label;" oncommand="onCheckItem('nntp.removeBodyMin', 'nntp.removeBody');"/>
-        <textbox id="nntp.removeBodyMin" size="2" value="30"
-                 type="number" min="1"
-                 aria-labelledby="nntp.removeBody nntp.removeBodyMin daysOldMsg"/>
+        <html:input id="nntp.removeBodyMin" type="number" class="size2" min="1" value="30"
+                    aria-labelledby="nntp.removeBody nntp.removeBodyMin daysOldMsg"/>
         <label value="&daysOld.label;" control="nntp.removeBodyMin" id="daysOldMsg"/>
     </hbox>
     </vbox>
     </groupbox>
   </vbox>
 </page>
--- a/mailnews/base/prefs/content/am-server-advanced.xul
+++ b/mailnews/base/prefs/content/am-server-advanced.xul
@@ -44,19 +44,19 @@
                 accesskey="&dualUseFolders.accesskey;"/>
 
       <separator class="groove"/>
       <row>
         <hbox align="center">
           <label control="maximumConnectionsNumber"
                  value="&maximumConnectionsNumber.label;"
                  accesskey="&maximumConnectionsNumber.accesskey;"/>
-          <textbox id="maximumConnectionsNumber" type="number"
-                   size="3" min="1" max="1000"
-                   amsa_persist="true"/>
+          <html:input id="maximumConnectionsNumber" type="number" class="size3"
+                      min="1" max="1000"
+                      amsa_persist="true"/>
         </hbox>
       </row>
 
       <separator class="groove"/>
       <description>&namespaceDesc.label;</description>
       <hbox class="indent">
         <vbox>
           <hbox flex="1" align="center">
--- a/mailnews/base/prefs/content/am-server.xul
+++ b/mailnews/base/prefs/content/am-server.xul
@@ -61,20 +61,21 @@
                      prefstring="mail.server.%serverkey%.realhostname"
                      class="uri-element textbox-flex"/>
       </div>
       <div>
         <xul:label hidefor="movemail" value="&port.label;"
                    accesskey="&port.accesskey;" control="server.port"/>
         <xul:label id="fixedServerPort" hidefor="movemail"
                    collapsed="true" use="server.port"/>
-        <xul:textbox id="server.port" wsm_persist="true" size="3"
-                     preftype="int" hidefor="movemail"
-                     prefstring="mail.server.%serverkey%.port"
-                     type="number" min="1" max="65535" increment="1"/>
+        <html:input id="server.port" type="number" class="size3"
+                    min="1" max="65535"
+                    wsm_persist="true"
+                    preftype="int" hidefor="movemail"
+                    prefstring="mail.server.%serverkey%.port"/>
         <xul:label value="&serverPortDefault.label;" hidefor="movemail"/>
         <xul:label id="defaultPort" hidefor="movemail"/>
       </div>
       <div hidefor="nntp">
         <xul:label value="&userName.label;"
                    accesskey="&userName.accesskey;"
                    control="server.realUsername"/>
       </div>
@@ -119,17 +120,17 @@
                           disabled="true"/>
               <menuitem value="2" label="&connectionSecurityType-2.label;"
                           hidefor="nntp"/>
               <menuitem value="3" label="&connectionSecurityType-3.label;"/>
             </menupopup>
           </menulist>
           <menulist id="server.authMethod"
                     wsm_persist="true"
-                    preftype="int" type="number"
+                    preftype="int"
                     prefstring="mail.server.%serverkey%.authMethod"
                     hidefor="nntp,movemail">
             <menupopup id="server.authMethodPopup">
               <menuitem id="authMethod-no" value="1"/>
               <menuitem id="authMethod-old" value="2"/>
               <menuitem id="authMethod-password-cleartext" value="3"/>
               <menuitem id="authMethod-password-encrypted" value="4"/>
               <menuitem id="authMethod-kerberos" value="5"/>
@@ -157,25 +158,21 @@
       <hbox align="center">
         <checkbox wsm_persist="true"
                   id="server.doBiff"
                   label="&biffStart.label;"
                   accesskey="&biffStart.accesskey;"
                   oncommand="onCheckItem('server.biffMinutes', [this.id]);"
                   prefattribute="value"
                   prefstring="mail.server.%serverkey%.check_new_mail"/>
-        <textbox wsm_persist="true"
-                 id="server.biffMinutes"
-                 type="number"
-                 size="3"
-                 min="1"
-                 increment="1"
-                 aria-labelledby="server.doBiff server.biffMinutes biffEnd"
-                 preftype="int"
-                 prefstring="mail.server.%serverkey%.check_time"/>
+        <html:input id="server.biffMinutes" type="number" class="size3" min="1"
+                    wsm_persist="true"
+                    aria-labelledby="server.doBiff server.biffMinutes biffEnd"
+                    preftype="int"
+                    prefstring="mail.server.%serverkey%.check_time"/>
         <label id="biffEnd"
                control="server.biffMinutes"
                value="&biffEnd.label;"/>
       </hbox>
       <vbox align="start"
             hidefor="pop3,nntp,movemail">
         <checkbox wsm_persist="true"
                   id="imap.useIdle"
@@ -208,20 +205,21 @@
                 prefstring="mail.server.%serverkey%.leave_on_server"/>
 
       <hbox align="center">
         <checkbox wsm_persist="true" id="pop3.deleteByAgeFromServer" class="indent"
                   label="&deleteByAgeFromServer.label;" oncommand="setupAgeMsgOnServerUI();"
                   accesskey="&deleteByAgeFromServer.accesskey;"
                   prefattribute="value"
                   prefstring="mail.server.%serverkey%.delete_by_age_from_server"/>
-        <textbox wsm_persist="true" id="pop3.numDaysToLeaveOnServer" size="3"
-                 aria-labelledby="pop3.deleteByAgeFromServer pop3.numDaysToLeaveOnServer daysEnd"
-                 preftype="int" type="number" min="1" increment="1"
-                 prefstring="mail.server.%serverkey%.num_days_to_leave_on_server"/>
+        <html:input id="pop3.numDaysToLeaveOnServer" type="number" class="size3" min="1"
+                    wsm_persist="true"
+                    aria-labelledby="pop3.deleteByAgeFromServer pop3.numDaysToLeaveOnServer daysEnd"
+                    preftype="int"
+                    prefstring="mail.server.%serverkey%.num_days_to_leave_on_server"/>
         <label id="daysEnd" control="pop3.numDaysToLeaveOnServer" value="&daysEnd.label;"/>
       </hbox>
 
       <checkbox wsm_persist="true" id="pop3.deleteMailLeftOnServer" class="indent"
                 label="&deleteOnServer2.label;"
                 accesskey="&deleteOnServer2.accesskey;"
                 prefattribute="value"
                 prefstring="mail.server.%serverkey%.delete_mail_left_on_server"/>
@@ -325,21 +323,20 @@
     <!-- NNTP -->
     <hbox hidefor="pop3,imap,movemail" align="center">
       <checkbox wsm_persist="true" id="nntp.notifyOn"
                 label="&maxMessagesStart.label;"
                 accesskey="&maxMessagesStart.accesskey;"
                 oncommand="onCheckItem('nntp.maxArticles', [this.id]);"
                 prefattribute="value"
                 prefstring="mail.server.%serverkey%.notify.on"/>
-      <textbox wsm_persist="true" id="nntp.maxArticles"
-               type="number" size="4" min="1" increment="10"
-               aria-labelledby="nntp.notifyOn nntp.maxArticles maxMessagesEnd"
-               preftype="int"
-               prefstring="mail.server.%serverkey%.max_articles"/>
+      <html:input id="nntp.maxArticles" type="number" class="size4" min="1"
+                  aria-labelledby="nntp.notifyOn nntp.maxArticles maxMessagesEnd"
+                  preftype="int"
+                  prefstring="mail.server.%serverkey%.max_articles"/>
       <label control="nntp.maxArticles" value="&maxMessagesEnd.label;" id="maxMessagesEnd"/>
     </hbox>
     <checkbox hidefor="pop3,imap,movemail" wsm_persist="true" id="nntp.pushAuth"
               label="&alwaysAuthenticate.label;"
               accesskey="&alwaysAuthenticate.accesskey;"
               prefattribute="value"
               prefstring="mail.server.%serverkey%.always_authenticate"/>
 
--- a/mailnews/base/search/content/searchWidgets.js
+++ b/mailnews/base/search/content/searchWidgets.js
@@ -675,17 +675,17 @@ class MozSearchValue extends MozXULEleme
           <menupopup class="search-value-popup">
             <menuitem value="plugin" stringTag="junkScoreOriginPlugin" class="search-value-menuitem"></menuitem>
             <menuitem value="user" stringTag="junkScoreOriginUser" class="search-value-menuitem"></menuitem>
             <menuitem value="filter" stringTag="junkScoreOriginFilter" class="search-value-menuitem"></menuitem>
             <menuitem value="whitelist" stringTag="junkScoreOriginWhitelist" class="search-value-menuitem"></menuitem>
             <menuitem value="imapflag" stringTag="junkScoreOriginImapFlag" class="search-value-menuitem"></menuitem>
           </menupopup>
         </menulist>
-        <textbox flex="1" class="search-value-textbox" inherits="disabled" type="number"></textbox>
+        <html:input type="number" class="search-value-textbox" inherits="disabled"/>
         <hbox flex="1" class="search-value-custom" inherits="disabled"></hbox>
       `));
 
       // Initialize the priority picker.
       this.fillStringsForChildren(this.childNodes[1].querySelector("menupopup"), bundle);
 
       // Initialize the status picker.
       this.fillStringsForChildren(this.childNodes[2].querySelector("menupopup"), bundle);
--- a/mailnews/extensions/newsblog/content/am-newsblog.xul
+++ b/mailnews/extensions/newsblog/content/am-newsblog.xul
@@ -64,23 +64,19 @@
     <groupbox>
       <label class="header">&newFeedSettings.label;</label>
 
       <hbox align="center">
         <checkbox id="updateEnabled"
                   label="&biffStart.label;"
                   accesskey="&biffStart.accesskey;"
                   oncommand="setPrefs(this)"/>
-        <textbox id="updateValue"
-                 type="number"
-                 size="3"
-                 min="1"
-                 increment="1"
-                 aria-labelledby="updateEnabled updateValue biffMinutes biffDays"
-                 onchange="setPrefs(this)"/>
+        <html:input id="updateValue"type="number" class="size3" min="1"
+                    aria-labelledby="updateEnabled updateValue biffMinutes biffDays"
+                    onchange="setPrefs(this)"/>
         <radiogroup id="biffUnits"
                     orient="horizontal"
                     oncommand="setPrefs(this)">
           <radio id="biffMinutes" value="min" label="&biffMinutes.label;"
                  accesskey="&biffMinutes.accesskey;">
             <observes element="updateValue" attribute="disabled"/>
           </radio>
           <radio id="biffDays" value="d" label="&biffDays.label;"
--- a/mailnews/extensions/newsblog/content/feed-subscriptions.xul
+++ b/mailnews/extensions/newsblog/content/feed-subscriptions.xul
@@ -141,24 +141,20 @@
           </vbox>
         </hbox>
 
         <hbox align="center">
           <checkbox id="updateEnabled"
                     label="&biffStart.label;"
                     accesskey="&biffStart.accesskey;"
                     oncommand="FeedSubscriptions.setPrefs(this);"/>
-          <textbox id="updateValue"
-                   type="number"
-                   size="3"
-                   min="1"
-                   increment="1"
-                   aria-labelledby="updateEnabled updateValue biffMinutes biffDays recommendedUnits recommendedUnitsVal"
-                   oninput="FeedSubscriptions.setPrefs(this);"
-                   onchange="FeedSubscriptions.setPrefs(this);">
+          <html:input id="updateValue" type="number" class="size3" min="1"
+                      aria-labelledby="updateEnabled updateValue biffMinutes biffDays recommendedUnits recommendedUnitsVal"
+                      oninput="FeedSubscriptions.setPrefs(this);"
+                      onchange="FeedSubscriptions.setPrefs(this);">
               <observes element="updateEnabled" attribute="disabled"/>
           </textbox>
           <radiogroup id="biffUnits"
                       orient="horizontal"
                       oncommand="FeedSubscriptions.setPrefs(this);">
             <radio id="biffMinutes" value="min" label="&biffMinutes.label;"
                    accesskey="&biffMinutes.accesskey;"/>
             <radio id="biffDays" value="d" label="&biffDays.label;"
--- a/mailnews/news/content/downloadheaders.xul
+++ b/mailnews/news/content/downloadheaders.xul
@@ -23,24 +23,20 @@
       <radio id="all" label="&all.label;" accesskey="&all.accesskey;"
              oncommand="setupDownloadUI(false);"/>
       <separator class="thin"/>
       <hbox align="center" valign="middle">
         <radio id="some" selected="true" label="&download.label;"
                accesskey="&download.accesskey;"
                oncommand="setupDownloadUI(true);"
                aria-labelledby="some number headers"/>
-        <textbox id="number"
-                 size="7"
-                 type="number"
-                 min="1"
-                 increment="10"
-                 aria-labelledby="some number headers"/>
-        <label value="&headers.label;" accesskey="&headers.accesskey;"
-               id="headers" control="number"/>
+        <html:input id="number" type="number" min="1"
+                    aria-labelledby="some number headers"/>
+        <label id="headers" control="number"
+               value="&headers.label;" accesskey="&headers.accesskey;"/>
       </hbox>
     </radiogroup>
 
     <hbox class="indent" align="start">
       <checkbox id="markread" label="&mark.label;" accesskey="&mark.accesskey;"/>
     </hbox>
   </vbox>