Index: src/orca/Gecko.py
===================================================================
--- src/orca/Gecko.py	(revision 2201)
+++ src/orca/Gecko.py	(working copy)
@@ -759,6 +759,18 @@
         self._structuralNavigationFunctions = \
             [Script.goNextHeading,
              Script.goPreviousHeading,
+             Script.goNextHeading1,
+             Script.goPreviousHeading1,
+             Script.goNextHeading2,
+             Script.goPreviousHeading2,
+             Script.goNextHeading3,
+             Script.goPreviousHeading3,
+             Script.goNextHeading4,
+             Script.goPreviousHeading4,
+             Script.goNextHeading5,
+             Script.goPreviousHeading5,
+             Script.goNextHeading6,
+             Script.goPreviousHeading6,
              Script.goNextChunk,
              Script.goPreviousChunk,
              Script.goNextList,
@@ -851,6 +863,66 @@
                 Script.goNextHeading,
                 "Goes to next heading.")
 
+        self.inputEventHandlers["goPreviousHeading1Handler"] = \
+            input_event.InputEventHandler(
+                Script.goPreviousHeading1,
+                "Goes to previous heading at level 1.")
+
+        self.inputEventHandlers["goNextHeading1Handler"] = \
+            input_event.InputEventHandler(
+                Script.goNextHeading1,
+                "Goes to next heading at level 1.")
+
+        self.inputEventHandlers["goPreviousHeading2Handler"] = \
+            input_event.InputEventHandler(
+                Script.goPreviousHeading2,
+                "Goes to previous heading at level 2.")
+
+        self.inputEventHandlers["goNextHeading2Handler"] = \
+            input_event.InputEventHandler(
+                Script.goNextHeading2,
+                "Goes to next heading at level 2.")
+
+        self.inputEventHandlers["goPreviousHeading3Handler"] = \
+            input_event.InputEventHandler(
+                Script.goPreviousHeading3,
+                "Goes to previous heading at level 3.")
+
+        self.inputEventHandlers["goNextHeading3Handler"] = \
+            input_event.InputEventHandler(
+                Script.goNextHeading3,
+                "Goes to next heading at level 3.")
+
+        self.inputEventHandlers["goPreviousHeading4Handler"] = \
+            input_event.InputEventHandler(
+                Script.goPreviousHeading4,
+                "Goes to previous heading at level 4.")
+
+        self.inputEventHandlers["goNextHeading4Handler"] = \
+            input_event.InputEventHandler(
+                Script.goNextHeading4,
+                "Goes to next heading at level 4.")
+
+        self.inputEventHandlers["goPreviousHeading5Handler"] = \
+            input_event.InputEventHandler(
+                Script.goPreviousHeading5,
+                "Goes to previous heading at level 5.")
+
+        self.inputEventHandlers["goNextHeading5Handler"] = \
+            input_event.InputEventHandler(
+                Script.goNextHeading5,
+                "Goes to next heading at level 5.")
+
+        self.inputEventHandlers["goPreviousHeading6Handler"] = \
+            input_event.InputEventHandler(
+                Script.goPreviousHeading6,
+                "Goes to previous heading at level 6.")
+
+        self.inputEventHandlers["goNextHeading6Handler"] = \
+            input_event.InputEventHandler(
+                Script.goNextHeading6,
+                "Goes to next heading at level 6.")
+
         self.inputEventHandlers["goPreviousChunkHandler"] = \
             input_event.InputEventHandler(
                 Script.goPreviousChunk,
@@ -1001,6 +1073,114 @@
 
         keyBindings.add(
             keybindings.KeyBinding(
+                "1",
+                (1 << atspi.Accessibility.MODIFIER_SHIFT \
+                 | 1 << atspi.Accessibility.MODIFIER_ALT \
+                 | 1 << atspi.Accessibility.MODIFIER_CONTROL),
+                1 << atspi.Accessibility.MODIFIER_SHIFT,
+                self.inputEventHandlers["goPreviousHeading1Handler"]))
+
+        keyBindings.add(
+            keybindings.KeyBinding(
+                "1",
+                (1 << atspi.Accessibility.MODIFIER_SHIFT \
+                 | 1 << atspi.Accessibility.MODIFIER_ALT \
+                 | 1 << atspi.Accessibility.MODIFIER_CONTROL),
+                0,
+                self.inputEventHandlers["goNextHeading1Handler"]))
+
+        keyBindings.add(
+            keybindings.KeyBinding(
+                "2",
+                (1 << atspi.Accessibility.MODIFIER_SHIFT \
+                 | 1 << atspi.Accessibility.MODIFIER_ALT \
+                 | 1 << atspi.Accessibility.MODIFIER_CONTROL),
+                1 << atspi.Accessibility.MODIFIER_SHIFT,
+                self.inputEventHandlers["goPreviousHeading2Handler"]))
+
+        keyBindings.add(
+            keybindings.KeyBinding(
+                "2",
+                (1 << atspi.Accessibility.MODIFIER_SHIFT \
+                 | 1 << atspi.Accessibility.MODIFIER_ALT \
+                 | 1 << atspi.Accessibility.MODIFIER_CONTROL),
+                0,
+                self.inputEventHandlers["goNextHeading2Handler"]))
+
+        keyBindings.add(
+            keybindings.KeyBinding(
+                "3",
+                (1 << atspi.Accessibility.MODIFIER_SHIFT \
+                 | 1 << atspi.Accessibility.MODIFIER_ALT \
+                 | 1 << atspi.Accessibility.MODIFIER_CONTROL),
+                1 << atspi.Accessibility.MODIFIER_SHIFT,
+                self.inputEventHandlers["goPreviousHeading3Handler"]))
+
+        keyBindings.add(
+            keybindings.KeyBinding(
+                "3",
+                (1 << atspi.Accessibility.MODIFIER_SHIFT \
+                 | 1 << atspi.Accessibility.MODIFIER_ALT \
+                 | 1 << atspi.Accessibility.MODIFIER_CONTROL),
+                0,
+                self.inputEventHandlers["goNextHeading3Handler"]))
+
+        keyBindings.add(
+            keybindings.KeyBinding(
+                "4",
+                (1 << atspi.Accessibility.MODIFIER_SHIFT \
+                 | 1 << atspi.Accessibility.MODIFIER_ALT \
+                 | 1 << atspi.Accessibility.MODIFIER_CONTROL),
+                1 << atspi.Accessibility.MODIFIER_SHIFT,
+                self.inputEventHandlers["goPreviousHeading4Handler"]))
+
+        keyBindings.add(
+            keybindings.KeyBinding(
+                "4",
+                (1 << atspi.Accessibility.MODIFIER_SHIFT \
+                 | 1 << atspi.Accessibility.MODIFIER_ALT \
+                 | 1 << atspi.Accessibility.MODIFIER_CONTROL),
+                0,
+                self.inputEventHandlers["goNextHeading4Handler"]))
+
+        keyBindings.add(
+            keybindings.KeyBinding(
+                "5",
+                (1 << atspi.Accessibility.MODIFIER_SHIFT \
+                 | 1 << atspi.Accessibility.MODIFIER_ALT \
+                 | 1 << atspi.Accessibility.MODIFIER_CONTROL),
+                0,
+                self.inputEventHandlers["goNextHeading5Handler"]))
+
+        keyBindings.add(
+            keybindings.KeyBinding(
+                "5",
+                (1 << atspi.Accessibility.MODIFIER_SHIFT \
+                 | 1 << atspi.Accessibility.MODIFIER_ALT \
+                 | 1 << atspi.Accessibility.MODIFIER_CONTROL),
+                1 << atspi.Accessibility.MODIFIER_SHIFT,
+                self.inputEventHandlers["goPreviousHeading5Handler"]))
+
+        keyBindings.add(
+            keybindings.KeyBinding(
+                "6",
+                (1 << atspi.Accessibility.MODIFIER_SHIFT \
+                 | 1 << atspi.Accessibility.MODIFIER_ALT \
+                 | 1 << atspi.Accessibility.MODIFIER_CONTROL),
+                1 << atspi.Accessibility.MODIFIER_SHIFT,
+                self.inputEventHandlers["goPreviousHeading6Handler"]))
+
+        keyBindings.add(
+            keybindings.KeyBinding(
+                "6",
+                (1 << atspi.Accessibility.MODIFIER_SHIFT \
+                 | 1 << atspi.Accessibility.MODIFIER_ALT \
+                 | 1 << atspi.Accessibility.MODIFIER_CONTROL),
+                0,
+                self.inputEventHandlers["goNextHeading6Handler"]))
+
+        keyBindings.add(
+            keybindings.KeyBinding(
                 "o",
                 (1 << atspi.Accessibility.MODIFIER_SHIFT \
                  | 1 << atspi.Accessibility.MODIFIER_ALT \
@@ -3531,6 +3711,88 @@
         else:
             speech.speak(_("No more headings."))
 
+    def goPreviousHeadingAtLevel(self, inputEvent, desiredLevel):
+        found = False
+        level = 0
+        [obj, characterOffset] = self.getCaretContext()
+        if obj.parent.role == rolenames.ROLE_HEADING:
+            obj = obj.parent
+        while obj and not found:
+            obj = self.findPreviousObject(obj)
+            if obj and (obj.role == rolenames.ROLE_HEADING) and \
+                       (obj.attributes):
+                for attribute in obj.attributes:
+                    if attribute.startswith("level:"):
+                        level = int(attribute.split(":")[1])
+                        break
+                if level == desiredLevel:
+                    found = True
+        if obj:
+            [obj, characterOffset] = self.findFirstCaretContext(obj, 0)
+            self.setCaretPosition(obj, characterOffset)
+            self.speakContents(self.getLineContentsAtOffset(obj,
+                                                            characterOffset))
+        else:
+            speech.speak(_("No more headings at level %d.") % desiredLevel)
+
+    def goNextHeadingAtLevel(self, inputEvent, desiredLevel):
+        found = False
+        level = 0
+        [obj, characterOffset] = self.getCaretContext()
+        while obj and not found:
+            obj = self.findNextObject(obj)
+            if obj and (obj.role == rolenames.ROLE_HEADING) and \
+                       (obj.attributes):
+                for attribute in obj.attributes:
+                    if attribute.startswith("level:"):
+                        level = int(attribute.split(":")[1])
+                        break
+                if level == desiredLevel:
+                    found = True
+        if obj:
+            [obj, characterOffset] = self.findFirstCaretContext(obj, 0)
+            self.setCaretPosition(obj, characterOffset)
+            self.speakContents(self.getLineContentsAtOffset(obj,
+                                                            characterOffset))
+        else:
+            speech.speak(_("No more headings at level %d.") % desiredLevel)
+
+    def goNextHeading1(self, inputEvent):
+        self.goNextHeadingAtLevel(inputEvent, 1)
+
+    def goPreviousHeading1(self, inputEvent):
+        self.goPreviousHeadingAtLevel(inputEvent, 1)
+
+    def goNextHeading2(self, inputEvent):
+        self.goNextHeadingAtLevel(inputEvent, 2)
+
+    def goPreviousHeading2(self, inputEvent):
+        self.goPreviousHeadingAtLevel(inputEvent, 2)
+
+    def goNextHeading3(self, inputEvent):
+        self.goNextHeadingAtLevel(inputEvent, 3)
+
+    def goPreviousHeading3(self, inputEvent):
+        self.goPreviousHeadingAtLevel(inputEvent, 3)
+
+    def goNextHeading4(self, inputEvent):
+        self.goNextHeadingAtLevel(inputEvent, 4)
+
+    def goPreviousHeading4(self, inputEvent):
+        self.goPreviousHeadingAtLevel(inputEvent, 4)
+
+    def goNextHeading5(self, inputEvent):
+        self.goNextHeadingAtLevel(inputEvent, 5)
+
+    def goPreviousHeading5(self, inputEvent):
+        self.goPreviousHeadingAtLevel(inputEvent, 5)
+
+    def goNextHeading6(self, inputEvent):
+        self.goNextHeadingAtLevel(inputEvent, 6)
+
+    def goPreviousHeading6(self, inputEvent):
+        self.goPreviousHeadingAtLevel(inputEvent, 6)
+
     def goPreviousChunk(self, inputEvent):
         [obj, characterOffset] = self.findPreviousRole(OBJECT_ROLES)
         if obj:
