diff options
author | Aneesh Dogra <lionaneesh@gmail.com> | 2012-12-19 17:09:41 (GMT) |
---|---|---|
committer | Aneesh Dogra <lionaneesh@gmail.com> | 2012-12-19 17:17:22 (GMT) |
commit | 80ed781c8824748b31ddbc329bf854b8603b9d57 (patch) | |
tree | 5b568f3e5ab225a6b5bd206bd9b58d84f20a10b8 /readtoolbar.py | |
parent | 4a3d773bc2635486fad190d1b5eb1f9b4f44977d (diff) |
Fix the pitch and rate adjuster.
Diffstat (limited to 'readtoolbar.py')
-rw-r--r-- | readtoolbar.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/readtoolbar.py b/readtoolbar.py index 3132b3f..bc32975 100644 --- a/readtoolbar.py +++ b/readtoolbar.py @@ -415,6 +415,7 @@ class SpeechToolbar(Gtk.Toolbar): self.pitchadj = Gtk.Adjustment(0, -100, 100, 1, 10, 0) pitchbar = Gtk.HScale() + pitchbar.set_adjustment(self.pitchadj) pitchbar.set_draw_value(False) # pitchbar.set_update_policy(Gtk.UpdatePolicy.ALWAYS) pitchbar.set_size_request(150,15) @@ -426,6 +427,7 @@ class SpeechToolbar(Gtk.Toolbar): self.rateadj = Gtk.Adjustment(0, -100, 100, 1, 10, 0) ratebar = Gtk.HScale() + ratebar.set_adjustment(self.rateadj) ratebar.set_draw_value(False) #ratebar.set_update_policy(Gtk.UpdatePolicy.ALWAYS) ratebar.set_size_request(150,15) @@ -449,7 +451,7 @@ class SpeechToolbar(Gtk.Toolbar): speech.say(speech.voice[0]) def pitch_adjusted_cb(self, get): - speech.pitch = int(get.value) + speech.pitch = int(get.get_value()) speech.say(_("pitch adjusted")) f = open(os.path.join(self.activity.get_activity_root(), 'instance', 'pitch.txt'), 'w') try: @@ -458,7 +460,7 @@ class SpeechToolbar(Gtk.Toolbar): f.close() def rate_adjusted_cb(self, get): - speech.rate = int(get.value) + speech.rate = int(get.get_value()) speech.say(_("rate adjusted")) f = open(os.path.join(self.activity.get_activity_root(), 'instance', 'rate.txt'), 'w') try: |