aboutsummaryrefslogtreecommitdiff
path: root/src/fltk_binding/fltk-widgets-groups-text_displays-text_editors.adb
diff options
context:
space:
mode:
authorJed Barber <jjbarber@y7mail.com>2016-11-18 21:24:27 +1100
committerJed Barber <jjbarber@y7mail.com>2016-11-18 21:24:27 +1100
commitba19cac8303b22ed415f246ea18dc334dd572343 (patch)
treed8bd5d243dbc1b5c4703263d200564ee3be5afca /src/fltk_binding/fltk-widgets-groups-text_displays-text_editors.adb
parent5045c1fb020480ac1bcc2aca921f886c0057a73f (diff)
Moved Shortcut_Key type to FLTK.Enums, added function to remove key bindings from Text_Editors
Diffstat (limited to 'src/fltk_binding/fltk-widgets-groups-text_displays-text_editors.adb')
-rw-r--r--src/fltk_binding/fltk-widgets-groups-text_displays-text_editors.adb21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/fltk_binding/fltk-widgets-groups-text_displays-text_editors.adb b/src/fltk_binding/fltk-widgets-groups-text_displays-text_editors.adb
index ce7684c..0172128 100644
--- a/src/fltk_binding/fltk-widgets-groups-text_displays-text_editors.adb
+++ b/src/fltk_binding/fltk-widgets-groups-text_displays-text_editors.adb
@@ -38,6 +38,12 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is
(TE : in System.Address);
pragma Import (C, fl_text_editor_delete, "fl_text_editor_delete");
+ procedure fl_text_editor_remove_key_binding
+ (TE : in System.Address;
+ K : in Interfaces.C.unsigned;
+ M : in Interfaces.C.unsigned_long);
+ pragma Import (C, fl_text_editor_remove_key_binding, "fl_text_editor_remove_key_binding");
+
@@ -120,5 +126,20 @@ package body FLTK.Widgets.Groups.Text_Displays.Text_Editors is
end Delete;
+
+
+ procedure Remove_Key_Binding
+ (This : in out Text_Editor;
+ Key : in Shortcut_Key)
+ is
+ use type Interfaces.C.unsigned_long;
+ begin
+ fl_text_editor_remove_key_binding
+ (This.Void_Ptr,
+ Character'Pos (Key.Keypress),
+ Interfaces.C.unsigned_long (Key.Modifier) * 65536);
+ end Remove_Key_Binding;
+
+
end FLTK.Widgets.Groups.Text_Displays.Text_Editors;