newt 0.9.0 → 0.9.1

Sign up to get free protection for your applications and to get access to all the features.
data/.rvmrc ADDED
@@ -0,0 +1 @@
1
+ rvm system
data/Manifest.txt CHANGED
@@ -1,7 +1,7 @@
1
1
  .autotest
2
+ .rvmrc
2
3
  History.txt
3
4
  Manifest.txt
4
- PostInstall.txt
5
5
  README.rdoc
6
6
  Rakefile
7
7
  examples/test-j.rb
data/README.rdoc CHANGED
@@ -1,6 +1,6 @@
1
1
  = newt
2
2
 
3
- * http://github.com/esperano/ruby-newt
3
+ * http://github.com/ericsperano/ruby-newt
4
4
 
5
5
  == DESCRIPTION:
6
6
 
@@ -21,13 +21,37 @@ See http://github.com/ericsperano/ruby-newt/tree/master/examples for usage examp
21
21
 
22
22
  == REQUIREMENTS:
23
23
 
24
- libnewt
24
+ The Newt library and headers.
25
+
26
+ === Ubuntu
27
+
28
+ $ sudo apt-get install libnewt-dev
29
+
30
+ === Mac OS X
31
+
32
+ $ sudo port install libnewt
33
+
34
+ Then, define this environment variable:
35
+ $ export LIBRARY_PATH="/opt/local/lib/"
36
+
37
+ For some reason this does not fully work:
38
+ $ export C_INCLUDE_PATH="/opt/local/include/"
39
+
40
+ So symlink it:
41
+ $ sudo ln -s /opt/local/include/newt.h /usr/include/
25
42
 
26
43
  == INSTALL:
27
44
 
28
- gem install newgem
45
+ === RugyGems
46
+
47
+ $ gem install newt
48
+
49
+ === Sources
29
50
 
30
- rake install_gem
51
+ $ git clone git://github.com/ericsperano/ruby-newt
52
+ $ cd ruby-newt
53
+ $ gem install newgem
54
+ $ rake install_gem
31
55
 
32
56
  == LICENSE:
33
57
 
@@ -3,4 +3,7 @@ require 'mkmf'
3
3
  dir_config('slang')
4
4
  dir_config('newt')
5
5
 
6
+ have_library("slang", "SLsmg_refresh")
7
+ have_library("newt", "newtInit")
8
+
6
9
  create_makefile("ruby_newt")
@@ -4,7 +4,8 @@
4
4
  * from 2001.04.20
5
5
  *
6
6
  * modified by Eric Sperano
7
- * 2012.02.27
7
+ * from 2012.02.27
8
+ *
8
9
  */
9
10
 
10
11
  #include <ruby.h>
@@ -48,6 +49,10 @@ struct snackWidget_s {
48
49
  };
49
50
 
50
51
 
52
+ /*
53
+ * ReflowText
54
+ *
55
+ */
51
56
  static VALUE
52
57
  rb_ext_ReflowText(VALUE self, VALUE text, VALUE width, VALUE flexDown, VALUE flexUp)
53
58
  {
@@ -64,6 +69,10 @@ rb_ext_ReflowText(VALUE self, VALUE text, VALUE width, VALUE flexDown, VALUE fle
64
69
  return ary;
65
70
  }
66
71
 
72
+ /*
73
+ * Screen_new
74
+ *
75
+ */
67
76
  static VALUE
68
77
  rb_ext_Screen_new()
69
78
  {
@@ -73,6 +82,10 @@ rb_ext_Screen_new()
73
82
  return Qnil;
74
83
  }
75
84
 
85
+ /*
86
+ * Screen_Init
87
+ *
88
+ */
76
89
  static VALUE
77
90
  rb_ext_Screen_Init()
78
91
  {
@@ -80,6 +93,10 @@ rb_ext_Screen_Init()
80
93
  return Qnil;
81
94
  }
82
95
 
96
+ /*
97
+ * Screen_Cls
98
+ *
99
+ */
83
100
  static VALUE
84
101
  rb_ext_Screen_Cls()
85
102
  {
@@ -87,6 +104,10 @@ rb_ext_Screen_Cls()
87
104
  return Qnil;
88
105
  }
89
106
 
107
+ /*
108
+ * Screen_Finished
109
+ *
110
+ */
90
111
  static VALUE
91
112
  rb_ext_Screen_Finished()
92
113
  {
@@ -95,6 +116,10 @@ rb_ext_Screen_Finished()
95
116
  return Qnil;
96
117
  }
97
118
 
119
+ /*
120
+ * Screen_WaitForKey
121
+ *
122
+ */
98
123
  static VALUE
99
124
  rb_ext_Screen_WaitForKey()
100
125
  {
@@ -103,6 +128,10 @@ rb_ext_Screen_WaitForKey()
103
128
  return Qnil;
104
129
  }
105
130
 
131
+ /*
132
+ * Screen_ClearKeyBuffer
133
+ *
134
+ */
106
135
  static VALUE
107
136
  rb_ext_Screen_ClearKeyBuffer()
108
137
  {
@@ -111,6 +140,10 @@ rb_ext_Screen_ClearKeyBuffer()
111
140
  return Qnil;
112
141
  }
113
142
 
143
+ /*
144
+ * Screen_OpenWindow
145
+ *
146
+ */
114
147
  static VALUE
115
148
  rb_ext_Screen_OpenWindow(VALUE self, VALUE left, VALUE top,
116
149
  VALUE width, VALUE height, VALUE title)
@@ -119,12 +152,20 @@ rb_ext_Screen_OpenWindow(VALUE self, VALUE left, VALUE top,
119
152
  NUM2INT(width), NUM2INT(height), StringValuePtr(title)));
120
153
  }
121
154
 
155
+ /*
156
+ * Screen_CenteredWindow
157
+ *
158
+ */
122
159
  static VALUE
123
160
  rb_ext_Screen_CenteredWindow(VALUE self, VALUE width, VALUE height, VALUE title)
124
161
  {
125
162
  return INT2NUM(newtCenteredWindow(NUM2INT(width), NUM2INT(height), StringValuePtr(title)));
126
163
  }
127
164
 
165
+ /*
166
+ * Screen_PopWindow
167
+ *
168
+ */
128
169
  static VALUE
129
170
  rb_ext_Screen_PopWindow(VALUE self)
130
171
  {
@@ -133,6 +174,10 @@ rb_ext_Screen_PopWindow(VALUE self)
133
174
  }
134
175
 
135
176
 
177
+ /*
178
+ * Screen_Resume
179
+ *
180
+ */
136
181
  static VALUE
137
182
  rb_ext_Screen_Resume()
138
183
  {
@@ -141,6 +186,10 @@ rb_ext_Screen_Resume()
141
186
  return Qnil;
142
187
  }
143
188
 
189
+ /*
190
+ * Screen_Suspend
191
+ *
192
+ */
144
193
  static VALUE
145
194
  rb_ext_Screen_Suspend()
146
195
  {
@@ -149,6 +198,10 @@ rb_ext_Screen_Suspend()
149
198
  return Qnil;
150
199
  }
151
200
 
201
+ /*
202
+ * Screen_Refresh
203
+ *
204
+ */
152
205
  static VALUE
153
206
  rb_ext_Screen_Refresh()
154
207
  {
@@ -157,6 +210,10 @@ rb_ext_Screen_Refresh()
157
210
  return Qnil;
158
211
  }
159
212
 
213
+ /*
214
+ * Screen_DrawRootText
215
+ *
216
+ */
160
217
  static VALUE
161
218
  rb_ext_Screen_DrawRootText(VALUE self, VALUE col, VALUE row, VALUE text)
162
219
  {
@@ -165,6 +222,10 @@ rb_ext_Screen_DrawRootText(VALUE self, VALUE col, VALUE row, VALUE text)
165
222
  return Qnil;
166
223
  }
167
224
 
225
+ /*
226
+ * Screen_PushHelpLine
227
+ *
228
+ */
168
229
  static VALUE
169
230
  rb_ext_Screen_PushHelpLine(VALUE self, VALUE text)
170
231
  {
@@ -173,6 +234,10 @@ rb_ext_Screen_PushHelpLine(VALUE self, VALUE text)
173
234
  return Qnil;
174
235
  }
175
236
 
237
+ /*
238
+ * Screen_RedrawHelpLine
239
+ *
240
+ */
176
241
  static VALUE
177
242
  rb_ext_Screen_RedrawHelpLine(VALUE self)
178
243
  {
@@ -181,6 +246,10 @@ rb_ext_Screen_RedrawHelpLine(VALUE self)
181
246
  return Qnil;
182
247
  }
183
248
 
249
+ /*
250
+ * Screen_PopHelpLine
251
+ *
252
+ */
184
253
  static VALUE
185
254
  rb_ext_Screen_PopHelpLine(VALUE self)
186
255
  {
@@ -189,6 +258,10 @@ rb_ext_Screen_PopHelpLine(VALUE self)
189
258
  return Qnil;
190
259
  }
191
260
 
261
+ /*
262
+ * Screen_Bell
263
+ *
264
+ */
192
265
  static VALUE
193
266
  rb_ext_Screen_Bell(VALUE self)
194
267
  {
@@ -197,6 +270,10 @@ rb_ext_Screen_Bell(VALUE self)
197
270
  return Qnil;
198
271
  }
199
272
 
273
+ /*
274
+ * Screen_Size
275
+ *
276
+ */
200
277
  static VALUE
201
278
  rb_ext_Screen_Size(VALUE self)
202
279
  {
@@ -210,6 +287,10 @@ rb_ext_Screen_Size(VALUE self)
210
287
  return ary;
211
288
  }
212
289
 
290
+ /*
291
+ * Screen_WinMessage
292
+ *
293
+ */
213
294
  static VALUE
214
295
  rb_ext_Screen_WinMessage(VALUE self, VALUE args)
215
296
  {
@@ -223,6 +304,10 @@ rb_ext_Screen_WinMessage(VALUE self, VALUE args)
223
304
  return Qnil;
224
305
  }
225
306
 
307
+ /*
308
+ * Screen_WinChoice
309
+ *
310
+ */
226
311
  static VALUE
227
312
  rb_ext_Screen_WinChoice(VALUE self, VALUE args)
228
313
  {
@@ -237,6 +322,10 @@ rb_ext_Screen_WinChoice(VALUE self, VALUE args)
237
322
  return Qnil;
238
323
  }
239
324
 
325
+ /*
326
+ * Screen_WinMenu
327
+ *
328
+ */
240
329
  static VALUE
241
330
  rb_ext_Screen_WinMenu(VALUE self, VALUE args)
242
331
  {
@@ -286,6 +375,10 @@ rb_ext_Screen_WinMenu(VALUE self, VALUE args)
286
375
  return Qnil;
287
376
  }
288
377
 
378
+ /*
379
+ * Screen_WinEntries
380
+ *
381
+ */
289
382
  static VALUE
290
383
  rb_ext_Screen_WinEntries(VALUE self, VALUE args)
291
384
  {
@@ -356,6 +449,10 @@ rb_ext_Screen_WinEntries(VALUE self, VALUE args)
356
449
  return Qnil;
357
450
  }
358
451
 
452
+ /*
453
+ * Widget_callback_function
454
+ *
455
+ */
359
456
  void
360
457
  rb_ext_Widget_callback_function(newtComponent co, void *proc)
361
458
  {
@@ -370,6 +467,10 @@ rb_ext_Widget_callback_function(newtComponent co, void *proc)
370
467
  };
371
468
  };
372
469
 
470
+ /*
471
+ * Widget_callback
472
+ *
473
+ */
373
474
  static VALUE
374
475
  rb_ext_Widget_callback(int argc, VALUE argv[], VALUE self)
375
476
  {
@@ -393,6 +494,10 @@ rb_ext_Widget_callback(int argc, VALUE argv[], VALUE self)
393
494
  return value;
394
495
  }
395
496
 
497
+ /*
498
+ * Widget_equal
499
+ *
500
+ */
396
501
  static VALUE
397
502
  rb_ext_Widget_equal(VALUE self, VALUE widget)
398
503
  {
@@ -408,6 +513,10 @@ rb_ext_Widget_equal(VALUE self, VALUE widget)
408
513
  return Qfalse;
409
514
  }
410
515
 
516
+ /*
517
+ * Label_new
518
+ *
519
+ */
411
520
  static VALUE
412
521
  rb_ext_Label_new(VALUE self, VALUE left, VALUE top, VALUE text)
413
522
  {
@@ -417,6 +526,10 @@ rb_ext_Label_new(VALUE self, VALUE left, VALUE top, VALUE text)
417
526
  return Data_Wrap_Struct(self, 0, 0, co);
418
527
  }
419
528
 
529
+ /*
530
+ * Label_SetText
531
+ *
532
+ */
420
533
  static VALUE
421
534
  rb_ext_Label_SetText(VALUE self, VALUE text)
422
535
  {
@@ -427,6 +540,10 @@ rb_ext_Label_SetText(VALUE self, VALUE text)
427
540
  return Qnil;
428
541
  }
429
542
 
543
+ /*
544
+ * CompactButton_new
545
+ *
546
+ */
430
547
  static VALUE
431
548
  rb_ext_CompactButton_new(VALUE self, VALUE left, VALUE top, VALUE text)
432
549
  {
@@ -436,6 +553,10 @@ rb_ext_CompactButton_new(VALUE self, VALUE left, VALUE top, VALUE text)
436
553
  return Data_Wrap_Struct(self, 0, 0, co);
437
554
  }
438
555
 
556
+ /*
557
+ * Button_new
558
+ *
559
+ */
439
560
  static VALUE
440
561
  rb_ext_Button_new(VALUE self, VALUE left, VALUE top, VALUE text)
441
562
  {
@@ -445,6 +566,10 @@ rb_ext_Button_new(VALUE self, VALUE left, VALUE top, VALUE text)
445
566
  return Data_Wrap_Struct(self, 0, 0, co);
446
567
  }
447
568
 
569
+ /*
570
+ * Checkbox_new
571
+ *
572
+ */
448
573
  static VALUE
449
574
  rb_ext_Checkbox_new(VALUE self, VALUE left, VALUE top, VALUE text,
450
575
  VALUE defValue, VALUE seq)
@@ -461,6 +586,10 @@ rb_ext_Checkbox_new(VALUE self, VALUE left, VALUE top, VALUE text,
461
586
  return Data_Wrap_Struct(self, 0, 0, co);
462
587
  }
463
588
 
589
+ /*
590
+ * Checkbox_GetValue
591
+ *
592
+ */
464
593
  static VALUE
465
594
  rb_ext_Checkbox_GetValue(VALUE self)
466
595
  {
@@ -473,6 +602,10 @@ rb_ext_Checkbox_GetValue(VALUE self)
473
602
  return rb_str_new2(value);
474
603
  }
475
604
 
605
+ /*
606
+ * Checkbox_SetValue
607
+ *
608
+ */
476
609
  static VALUE
477
610
  rb_ext_Checkbox_SetValue(VALUE self, VALUE value)
478
611
  {
@@ -485,6 +618,10 @@ rb_ext_Checkbox_SetValue(VALUE self, VALUE value)
485
618
  return Qnil;
486
619
  }
487
620
 
621
+ /*
622
+ * Checkbox_SetFlags
623
+ *
624
+ */
488
625
  static VALUE
489
626
  rb_ext_Checkbox_SetFlags(VALUE self, VALUE args)
490
627
  {
@@ -505,6 +642,10 @@ rb_ext_Checkbox_SetFlags(VALUE self, VALUE args)
505
642
  return Qnil;
506
643
  }
507
644
 
645
+ /*
646
+ * RadioButton_new
647
+ *
648
+ */
508
649
  static VALUE
509
650
  rb_ext_RadioButton_new(VALUE self, VALUE left, VALUE top, VALUE text,
510
651
  VALUE isDefault, VALUE prevButton)
@@ -522,6 +663,10 @@ rb_ext_RadioButton_new(VALUE self, VALUE left, VALUE top, VALUE text,
522
663
  return Data_Wrap_Struct(self, 0, 0, co);
523
664
  }
524
665
 
666
+ /*
667
+ * Listbox_new
668
+ *
669
+ */
525
670
  static VALUE
526
671
  rb_ext_Listbox_new(VALUE self, VALUE left, VALUE top, VALUE height, VALUE flags)
527
672
  {
@@ -531,6 +676,10 @@ rb_ext_Listbox_new(VALUE self, VALUE left, VALUE top, VALUE height, VALUE flags)
531
676
  return Data_Wrap_Struct(self, 0, 0, co);
532
677
  }
533
678
 
679
+ /*
680
+ * Listbox_GetCurrent
681
+ *
682
+ */
534
683
  static VALUE
535
684
  rb_ext_Listbox_GetCurrent(VALUE self)
536
685
  {
@@ -548,6 +697,10 @@ rb_ext_Listbox_GetCurrent(VALUE self)
548
697
  return INT2NUM(i);
549
698
  }
550
699
 
700
+ /*
701
+ * Listbox_SetCurrent
702
+ *
703
+ */
551
704
  static VALUE
552
705
  rb_ext_Listbox_SetCurrent(VALUE self, VALUE num)
553
706
  {
@@ -558,6 +711,10 @@ rb_ext_Listbox_SetCurrent(VALUE self, VALUE num)
558
711
  return Qnil;
559
712
  }
560
713
 
714
+ /*
715
+ * Listbox_SetCurrentByKey
716
+ *
717
+ */
561
718
  static VALUE
562
719
  rb_ext_Listbox_SetCurrentByKey(VALUE self, VALUE key)
563
720
  {
@@ -579,6 +736,10 @@ rb_ext_Listbox_SetCurrentByKey(VALUE self, VALUE key)
579
736
  return Qnil;
580
737
  }
581
738
 
739
+ /*
740
+ * Listbox_SetEntry
741
+ *
742
+ */
582
743
  static VALUE
583
744
  rb_ext_Listbox_SetEntry(VALUE self, VALUE num, VALUE text)
584
745
  {
@@ -589,6 +750,10 @@ rb_ext_Listbox_SetEntry(VALUE self, VALUE num, VALUE text)
589
750
  return Qnil;
590
751
  }
591
752
 
753
+ /*
754
+ * Listbox_SetWidth
755
+ *
756
+ */
592
757
  static VALUE
593
758
  rb_ext_Listbox_SetWidth(VALUE self, VALUE width)
594
759
  {
@@ -599,6 +764,10 @@ rb_ext_Listbox_SetWidth(VALUE self, VALUE width)
599
764
  return Qnil;
600
765
  }
601
766
 
767
+ /*
768
+ * Listbox_SetData
769
+ *
770
+ */
602
771
  static VALUE
603
772
  rb_ext_Listbox_SetData(VALUE self, VALUE num, VALUE data)
604
773
  {
@@ -620,6 +789,10 @@ rb_ext_Listbox_SetData(VALUE self, VALUE num, VALUE data)
620
789
  return Qnil;
621
790
  }
622
791
 
792
+ /*
793
+ * Listbox_AppendEntry
794
+ *
795
+ */
623
796
  static VALUE
624
797
  rb_ext_Listbox_AppendEntry(VALUE self, VALUE text, VALUE data)
625
798
  {
@@ -641,6 +814,10 @@ rb_ext_Listbox_AppendEntry(VALUE self, VALUE text, VALUE data)
641
814
  return Qnil;
642
815
  }
643
816
 
817
+ /*
818
+ * Listbox_InsertEntry
819
+ *
820
+ */
644
821
  static VALUE
645
822
  rb_ext_Listbox_InsertEntry(VALUE self, VALUE text, VALUE data, VALUE key)
646
823
  {
@@ -681,6 +858,10 @@ rb_ext_Listbox_InsertEntry(VALUE self, VALUE text, VALUE data, VALUE key)
681
858
  return Qnil;
682
859
  }
683
860
 
861
+ /*
862
+ * Listbox_DeleteEntry
863
+ *
864
+ */
684
865
  static VALUE
685
866
  rb_ext_Listbox_DeleteEntry(VALUE self, VALUE data)
686
867
  {
@@ -702,6 +883,10 @@ rb_ext_Listbox_DeleteEntry(VALUE self, VALUE data)
702
883
  return Qnil;
703
884
  }
704
885
 
886
+ /*
887
+ * Listbox_Clear
888
+ *
889
+ */
705
890
  static VALUE
706
891
  rb_ext_Listbox_Clear(VALUE self)
707
892
  {
@@ -713,6 +898,10 @@ rb_ext_Listbox_Clear(VALUE self)
713
898
  return Qnil;
714
899
  }
715
900
 
901
+ /*
902
+ * Listbox_ClearSelection
903
+ *
904
+ */
716
905
  static VALUE
717
906
  rb_ext_Listbox_ClearSelection(VALUE self)
718
907
  {
@@ -724,6 +913,10 @@ rb_ext_Listbox_ClearSelection(VALUE self)
724
913
  return Qnil;
725
914
  }
726
915
 
916
+ /*
917
+ * Listbox_SelectItem
918
+ *
919
+ */
727
920
  static VALUE
728
921
  rb_ext_Listbox_SelectItem(VALUE self, VALUE key, VALUE sense)
729
922
  {
@@ -745,6 +938,10 @@ rb_ext_Listbox_SelectItem(VALUE self, VALUE key, VALUE sense)
745
938
  return Qnil;
746
939
  }
747
940
 
941
+ /*
942
+ * CheckboxTree_new
943
+ *
944
+ */
748
945
  static VALUE
749
946
  rb_ext_CheckboxTree_new(VALUE self, VALUE left, VALUE top, VALUE height, VALUE flags)
750
947
  {
@@ -754,6 +951,10 @@ rb_ext_CheckboxTree_new(VALUE self, VALUE left, VALUE top, VALUE height, VALUE f
754
951
  return Data_Wrap_Struct(self, 0, 0, co);
755
952
  }
756
953
 
954
+ /*
955
+ * CheckboxTree_AddItem
956
+ *
957
+ */
757
958
  static VALUE
758
959
  rb_ext_CheckboxTree_AddItem(VALUE self, VALUE args)
759
960
  /*rb_ext_CheckboxTree_AddItem(VALUE self, VALUE text, VALUE data, VALUE flags)*/
@@ -809,6 +1010,10 @@ rb_ext_CheckboxTree_AddItem(VALUE self, VALUE args)
809
1010
  #endif
810
1011
  }
811
1012
 
1013
+ /*
1014
+ * CheckboxTreeMulti_new
1015
+ *
1016
+ */
812
1017
  static VALUE
813
1018
  rb_ext_CheckboxTreeMulti_new(VALUE self, VALUE left, VALUE top, VALUE height, VALUE seq, VALUE flags)
814
1019
  {
@@ -822,6 +1027,10 @@ rb_ext_CheckboxTreeMulti_new(VALUE self, VALUE left, VALUE top, VALUE height, VA
822
1027
  return Data_Wrap_Struct(self, 0, 0, co);
823
1028
  }
824
1029
 
1030
+ /*
1031
+ * Textbox_new
1032
+ *
1033
+ */
825
1034
  static VALUE
826
1035
  rb_ext_Textbox_new(VALUE self, VALUE left, VALUE top, VALUE width, VALUE height, VALUE flags)
827
1036
  {
@@ -831,6 +1040,10 @@ rb_ext_Textbox_new(VALUE self, VALUE left, VALUE top, VALUE width, VALUE height,
831
1040
  return Data_Wrap_Struct(self, 0, 0, co);
832
1041
  }
833
1042
 
1043
+ /*
1044
+ * Textbox_SetText
1045
+ *
1046
+ */
834
1047
  static VALUE
835
1048
  rb_ext_Textbox_SetText(VALUE self, VALUE text)
836
1049
  {
@@ -841,6 +1054,10 @@ rb_ext_Textbox_SetText(VALUE self, VALUE text)
841
1054
  return Qnil;
842
1055
  }
843
1056
 
1057
+ /*
1058
+ * Textbox_SetHeight
1059
+ *
1060
+ */
844
1061
  static VALUE
845
1062
  rb_ext_Textbox_SetHeight(VALUE self, VALUE height)
846
1063
  {
@@ -851,6 +1068,10 @@ rb_ext_Textbox_SetHeight(VALUE self, VALUE height)
851
1068
  return Qnil;
852
1069
  }
853
1070
 
1071
+ /*
1072
+ * Textbox_GetNumLines
1073
+ *
1074
+ */
854
1075
  static VALUE
855
1076
  rb_ext_Textbox_GetNumLines(VALUE self)
856
1077
  {
@@ -860,6 +1081,10 @@ rb_ext_Textbox_GetNumLines(VALUE self)
860
1081
  return INT2NUM(newtTextboxGetNumLines(co));
861
1082
  }
862
1083
 
1084
+ /*
1085
+ * TextboxReflowed_new
1086
+ *
1087
+ */
863
1088
  static VALUE
864
1089
  rb_ext_TextboxReflowed_new(VALUE self, VALUE left, VALUE top, VALUE text, VALUE width, VALUE flexDown, VALUE flexUp, VALUE flags)
865
1090
  {
@@ -870,6 +1095,10 @@ rb_ext_TextboxReflowed_new(VALUE self, VALUE left, VALUE top, VALUE text, VALUE
870
1095
  return Data_Wrap_Struct(self, 0, 0, co);
871
1096
  }
872
1097
 
1098
+ /*
1099
+ * Form_Destroy
1100
+ *
1101
+ */
873
1102
  static void
874
1103
  rb_ext_Form_Destroy(VALUE self)
875
1104
  {
@@ -881,6 +1110,10 @@ rb_ext_Form_Destroy(VALUE self)
881
1110
  }
882
1111
  }
883
1112
 
1113
+ /*
1114
+ * Form_new
1115
+ *
1116
+ */
884
1117
  static VALUE
885
1118
  rb_ext_Form_new(VALUE self, VALUE left, VALUE top, VALUE text)
886
1119
  {
@@ -890,6 +1123,10 @@ rb_ext_Form_new(VALUE self, VALUE left, VALUE top, VALUE text)
890
1123
  return Data_Wrap_Struct(self, 0, rb_ext_Form_Destroy, co);
891
1124
  }
892
1125
 
1126
+ /*
1127
+ * Form_SetBackground
1128
+ *
1129
+ */
893
1130
  static VALUE
894
1131
  rb_ext_Form_SetBackground(VALUE self, VALUE color)
895
1132
  {
@@ -913,6 +1150,10 @@ rb_ext_Form_AddComponent(VALUE self, VALUE co)
913
1150
  }
914
1151
  #endif
915
1152
 
1153
+ /*
1154
+ * Form_AddComponents
1155
+ *
1156
+ */
916
1157
  static VALUE
917
1158
  rb_ext_Form_AddComponents(VALUE self, VALUE co)
918
1159
  {
@@ -928,6 +1169,10 @@ rb_ext_Form_AddComponents(VALUE self, VALUE co)
928
1169
  return Qnil;
929
1170
  }
930
1171
 
1172
+ /*
1173
+ * Form_SetHeight
1174
+ *
1175
+ */
931
1176
  static VALUE
932
1177
  rb_ext_Form_SetHeight(VALUE self, VALUE height)
933
1178
  {
@@ -938,6 +1183,10 @@ rb_ext_Form_SetHeight(VALUE self, VALUE height)
938
1183
  return Qnil;
939
1184
  }
940
1185
 
1186
+ /*
1187
+ * Form_SetWidth
1188
+ *
1189
+ */
941
1190
  static VALUE
942
1191
  rb_ext_Form_SetWidth(VALUE self, VALUE width)
943
1192
  {
@@ -948,6 +1197,10 @@ rb_ext_Form_SetWidth(VALUE self, VALUE width)
948
1197
  return Qnil;
949
1198
  }
950
1199
 
1200
+ /*
1201
+ * Run_Form
1202
+ *
1203
+ */
951
1204
  static VALUE
952
1205
  rb_ext_Run_Form(VALUE self)
953
1206
  {
@@ -958,6 +1211,10 @@ rb_ext_Run_Form(VALUE self)
958
1211
  return Data_Wrap_Struct(cWidget, 0, 0, co);
959
1212
  }
960
1213
 
1214
+ /*
1215
+ * Form_DrawForm
1216
+ *
1217
+ */
961
1218
  static VALUE
962
1219
  rb_ext_Form_DrawForm(VALUE self)
963
1220
  {
@@ -968,6 +1225,10 @@ rb_ext_Form_DrawForm(VALUE self)
968
1225
  return Qnil;
969
1226
  }
970
1227
 
1228
+ /*
1229
+ * Form_AddHotKey
1230
+ *
1231
+ */
971
1232
  static VALUE
972
1233
  rb_ext_Form_AddHotKey(VALUE self, VALUE key)
973
1234
  {
@@ -978,6 +1239,10 @@ rb_ext_Form_AddHotKey(VALUE self, VALUE key)
978
1239
  return Qnil;
979
1240
  }
980
1241
 
1242
+ /*
1243
+ * Entry_new
1244
+ *
1245
+ */
981
1246
  static VALUE
982
1247
  rb_ext_Entry_new(VALUE self, VALUE left, VALUE top, VALUE initialValue, VALUE width, VALUE flags)
983
1248
  {
@@ -988,6 +1253,10 @@ rb_ext_Entry_new(VALUE self, VALUE left, VALUE top, VALUE initialValue, VALUE wi
988
1253
  return Data_Wrap_Struct(self, 0, 0, co);
989
1254
  }
990
1255
 
1256
+ /*
1257
+ * Entry_Set
1258
+ *
1259
+ */
991
1260
  static VALUE
992
1261
  rb_ext_Entry_Set(VALUE self, VALUE value, VALUE cursorAtEnd)
993
1262
  {
@@ -1012,6 +1281,10 @@ rb_ext_Entry_Set(VALUE self, VALUE value, VALUE cursorAtEnd)
1012
1281
  return Qnil;
1013
1282
  }
1014
1283
 
1284
+ /*
1285
+ * Entry_GetValue
1286
+ *
1287
+ */
1015
1288
  static VALUE
1016
1289
  rb_ext_Entry_GetValue(VALUE self)
1017
1290
  {
@@ -1021,6 +1294,10 @@ rb_ext_Entry_GetValue(VALUE self)
1021
1294
  return rb_str_new2(newtEntryGetValue(co));
1022
1295
  }
1023
1296
 
1297
+ /*
1298
+ * Entry_SetFlags
1299
+ *
1300
+ */
1024
1301
  static VALUE
1025
1302
  rb_ext_Entry_SetFlags(VALUE self, VALUE args)
1026
1303
  {
@@ -1040,6 +1317,10 @@ rb_ext_Entry_SetFlags(VALUE self, VALUE args)
1040
1317
  return Qnil;
1041
1318
  }
1042
1319
 
1320
+ /*
1321
+ * Scale_new
1322
+ *
1323
+ */
1043
1324
  static VALUE
1044
1325
  rb_ext_Scale_new(VALUE self, VALUE left, VALUE top, VALUE width, VALUE fullValue)
1045
1326
  {
@@ -1049,6 +1330,10 @@ rb_ext_Scale_new(VALUE self, VALUE left, VALUE top, VALUE width, VALUE fullValue
1049
1330
  return Data_Wrap_Struct(self, 0, 0, co);
1050
1331
  }
1051
1332
 
1333
+ /*
1334
+ * Scale_Set
1335
+ *
1336
+ */
1052
1337
  static VALUE
1053
1338
  rb_ext_Scale_Set(VALUE self, VALUE amount)
1054
1339
  {
@@ -1059,6 +1344,10 @@ rb_ext_Scale_Set(VALUE self, VALUE amount)
1059
1344
  return Qnil;
1060
1345
  }
1061
1346
 
1347
+ /*
1348
+ * Grid_free
1349
+ *
1350
+ */
1062
1351
  static void
1063
1352
  rb_ext_Grid_free(VALUE self)
1064
1353
  {
@@ -1070,6 +1359,10 @@ rb_ext_Grid_free(VALUE self)
1070
1359
  }
1071
1360
  }
1072
1361
 
1362
+ /*
1363
+ * Grid_new
1364
+ *
1365
+ */
1073
1366
  static VALUE
1074
1367
  rb_ext_Grid_new(VALUE self, VALUE cols, VALUE rows)
1075
1368
  {
@@ -1080,6 +1373,10 @@ rb_ext_Grid_new(VALUE self, VALUE cols, VALUE rows)
1080
1373
  return Data_Wrap_Struct(self, 0, rb_ext_Grid_free, grid);
1081
1374
  }
1082
1375
 
1376
+ /*
1377
+ * Grid_SetField
1378
+ *
1379
+ */
1083
1380
  static VALUE
1084
1381
  rb_ext_Grid_SetField(VALUE self, VALUE col, VALUE row, VALUE type, VALUE val,
1085
1382
  VALUE padLeft, VALUE padTop, VALUE padRight, VALUE padBottom,
@@ -1096,6 +1393,10 @@ rb_ext_Grid_SetField(VALUE self, VALUE col, VALUE row, VALUE type, VALUE val,
1096
1393
  return Qnil;
1097
1394
  }
1098
1395
 
1396
+ /*
1397
+ * Grid_WrappedWindow
1398
+ *
1399
+ */
1099
1400
  static VALUE
1100
1401
  rb_ext_Grid_WrappedWindow(VALUE self, VALUE args)
1101
1402
  {
@@ -1117,6 +1418,10 @@ rb_ext_Grid_WrappedWindow(VALUE self, VALUE args)
1117
1418
  return Qnil;
1118
1419
  }
1119
1420
 
1421
+ /*
1422
+ * Grid_GetSize
1423
+ *
1424
+ */
1120
1425
  static VALUE
1121
1426
  rb_ext_Grid_GetSize(VALUE self)
1122
1427
  {
@@ -1132,7 +1437,10 @@ rb_ext_Grid_GetSize(VALUE self)
1132
1437
  return ary;
1133
1438
  }
1134
1439
 
1135
-
1440
+ /*
1441
+ * Init_ruby_newt
1442
+ *
1443
+ */
1136
1444
  void
1137
1445
  Init_ruby_newt(){
1138
1446
  mNewt = rb_define_module("Newt");
@@ -1329,5 +1637,4 @@ Init_ruby_newt(){
1329
1637
  rb_define_const(mNewt, "KEY_F10", INT2FIX(NEWT_KEY_F10));
1330
1638
  rb_define_const(mNewt, "KEY_F11", INT2FIX(NEWT_KEY_F11));
1331
1639
  rb_define_const(mNewt, "KEY_F12", INT2FIX(NEWT_KEY_F12));
1332
-
1333
1640
  }
data/lib/newt.rb CHANGED
@@ -2,5 +2,5 @@ $:.unshift(File.dirname(__FILE__)) unless
2
2
  $:.include?(File.dirname(__FILE__)) || $:.include?(File.expand_path(File.dirname(__FILE__)))
3
3
 
4
4
  module Newt
5
- VERSION = '0.9.0'
5
+ VERSION = '0.9.1'
6
6
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: newt
3
3
  version: !ruby/object:Gem::Version
4
- hash: 59
4
+ hash: 57
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 9
9
- - 0
10
- version: 0.9.0
9
+ - 1
10
+ version: 0.9.1
11
11
  platform: ruby
12
12
  authors:
13
13
  - Eric Sperano
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2012-02-29 00:00:00 Z
18
+ date: 2012-03-01 00:00:00 Z
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency
21
21
  name: rdoc
@@ -73,13 +73,12 @@ extensions:
73
73
  extra_rdoc_files:
74
74
  - History.txt
75
75
  - Manifest.txt
76
- - PostInstall.txt
77
76
  - README.rdoc
78
77
  files:
79
78
  - .autotest
79
+ - .rvmrc
80
80
  - History.txt
81
81
  - Manifest.txt
82
- - PostInstall.txt
83
82
  - README.rdoc
84
83
  - Rakefile
85
84
  - examples/test-j.rb
@@ -145,7 +144,7 @@ files:
145
144
  - test/test_newt.rb
146
145
  - test/test_ruby_newt_extn.rb
147
146
  - .gemtest
148
- homepage: http://github.com/esperano/ruby-newt
147
+ homepage: http://github.com/ericsperano/ruby-newt
149
148
  licenses: []
150
149
 
151
150
  post_install_message: PostInstall.txt
data/PostInstall.txt DELETED
@@ -1,7 +0,0 @@
1
-
2
- For more information on newt, see http://newt.rubyforge.org
3
-
4
- NOTE: Change this information in PostInstall.txt
5
- You can also delete it if you don't want it.
6
-
7
-