arcadia 0.13.0 → 0.13.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (194) hide show
  1. checksums.yaml +7 -0
  2. data/README +19 -15
  3. data/bin/arc +0 -0
  4. data/conf/LC/en-UK.LANG +1 -1
  5. data/conf/LC/ru-RU.LANG +272 -0
  6. data/conf/theme-dark.conf +3 -3
  7. data/ext/ae-dir-projects/ae-dir-projects.rb +5 -5
  8. data/ext/ae-editor/ae-editor.rb +302 -178
  9. data/ext/ae-subprocess-inspector/ae-subprocess-inspector.rb +2 -2
  10. data/ext/ae-term/ae-term.rb +11 -2
  11. data/lib/a-commons.rb +49 -19
  12. data/lib/a-contracts.rb +13 -0
  13. data/lib/a-core.rb +139 -36
  14. data/lib/a-tkcommons.rb +23 -8
  15. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/ArrowButton.html +0 -0
  16. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/BWidget.html +0 -0
  17. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/Button.html +0 -0
  18. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/ButtonBox.html +0 -0
  19. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/ComboBox.html +8 -0
  20. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/Dialog.html +0 -0
  21. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/DragSite.html +0 -0
  22. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/DropSite.html +0 -0
  23. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/DynamicHelp.html +0 -0
  24. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/Entry.html +0 -0
  25. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/Label.html +0 -0
  26. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/LabelEntry.html +0 -0
  27. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/LabelFrame.html +0 -0
  28. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/ListBox.html +0 -0
  29. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/MainFrame.html +28 -23
  30. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/MessageDlg.html +0 -0
  31. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/NoteBook.html +0 -0
  32. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/PagesManager.html +0 -0
  33. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/PanedWindow.html +0 -0
  34. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/PanelFrame.html +0 -0
  35. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/PasswdDlg.html +0 -0
  36. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/ProgressBar.html +0 -0
  37. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/ProgressDlg.html +0 -0
  38. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/ScrollView.html +0 -0
  39. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/ScrollableFrame.html +0 -0
  40. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/ScrolledWindow.html +0 -0
  41. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/SelectColor.html +0 -0
  42. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/SelectFont.html +0 -0
  43. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/Separator.html +0 -0
  44. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/SpinBox.html +0 -0
  45. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/StatusBar.html +0 -0
  46. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/TitleFrame.html +0 -0
  47. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/Tree.html +0 -0
  48. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/Widget.html +0 -0
  49. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/contents.html +0 -0
  50. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/index.html +0 -0
  51. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/navtree.html +0 -0
  52. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/BWman/options.htm +0 -0
  53. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/CHANGES.txt +0 -0
  54. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/ChangeLog +59 -0
  55. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/LICENSE.txt +0 -0
  56. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/README.txt +0 -0
  57. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/arrow.tcl +0 -0
  58. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/bitmap.tcl +0 -0
  59. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/button.tcl +0 -0
  60. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/buttonbox.tcl +0 -0
  61. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/color.tcl +0 -0
  62. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/combobox.tcl +8 -0
  63. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/demo/basic.tcl +0 -0
  64. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/demo/bwidget.xbm +0 -0
  65. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/demo/demo.tcl +0 -0
  66. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/demo/dnd.tcl +0 -0
  67. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/demo/manager.tcl +0 -0
  68. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/demo/select.tcl +0 -0
  69. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/demo/tmpldlg.tcl +0 -0
  70. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/demo/tree.tcl +0 -0
  71. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/demo/x1.xbm +0 -0
  72. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/dialog.tcl +0 -0
  73. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/dragsite.tcl +0 -0
  74. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/dropsite.tcl +0 -0
  75. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/dynhelp.tcl +0 -0
  76. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/entry.tcl +0 -0
  77. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/font.tcl +0 -0
  78. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/bold.gif +0 -0
  79. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/copy.gif +0 -0
  80. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/cut.gif +0 -0
  81. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/dragfile.gif +0 -0
  82. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/dragicon.gif +0 -0
  83. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/error.gif +0 -0
  84. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/file.gif +0 -0
  85. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/folder.gif +0 -0
  86. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/hourglass.gif +0 -0
  87. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/info.gif +0 -0
  88. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/italic.gif +0 -0
  89. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/minus.xbm +0 -0
  90. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/new.gif +0 -0
  91. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/opcopy.xbm +0 -0
  92. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/open.gif +0 -0
  93. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/openfold.gif +0 -0
  94. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/oplink.xbm +0 -0
  95. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/opmove.xbm +0 -0
  96. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/overstrike.gif +0 -0
  97. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/palette.gif +0 -0
  98. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/passwd.gif +0 -0
  99. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/paste.gif +0 -0
  100. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/plus.xbm +0 -0
  101. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/print.gif +0 -0
  102. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/question.gif +0 -0
  103. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/redo.gif +0 -0
  104. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/save.gif +0 -0
  105. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/target.xbm +0 -0
  106. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/underline.gif +0 -0
  107. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/undo.gif +0 -0
  108. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/images/warning.gif +0 -0
  109. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/init.tcl +9 -8
  110. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/label.tcl +0 -0
  111. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/labelentry.tcl +4 -1
  112. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/labelframe.tcl +0 -0
  113. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/lang/da.rc +0 -0
  114. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/lang/de.rc +0 -0
  115. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/lang/en.rc +0 -0
  116. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/lang/es.rc +0 -0
  117. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/lang/fr.rc +0 -0
  118. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/lang/hu.rc +0 -0
  119. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/lang/nl.rc +0 -0
  120. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/lang/no.rc +0 -0
  121. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/lang/pl.rc +0 -0
  122. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/listbox.tcl +0 -0
  123. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/mainframe.tcl +110 -22
  124. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/messagedlg.tcl +0 -0
  125. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/notebook.tcl +13 -3
  126. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/pagesmgr.tcl +0 -0
  127. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/panedw.tcl +0 -0
  128. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/panelframe.tcl +0 -0
  129. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/passwddlg.tcl +0 -0
  130. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/pkgIndex.tcl +2 -3
  131. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/progressbar.tcl +0 -0
  132. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/progressdlg.tcl +0 -0
  133. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/scrollframe.tcl +0 -0
  134. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/scrollview.tcl +0 -0
  135. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/scrollw.tcl +0 -0
  136. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/separator.tcl +0 -0
  137. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/spinbox.tcl +0 -0
  138. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/statusbar.tcl +0 -0
  139. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/tests/entry.test +0 -0
  140. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/titleframe.tcl +0 -0
  141. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/tree.tcl +0 -0
  142. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/utils.tcl +0 -0
  143. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/widget.tcl +15 -2
  144. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/wizard.tcl +0 -0
  145. data/tcl/{bwidget-1.9.6 → bwidget-1.9.7}/xpm2image.tcl +90 -28
  146. metadata +146 -196
  147. data/tcl/fsdialog/de.msg +0 -30
  148. data/tcl/fsdialog/en.msg +0 -31
  149. data/tcl/fsdialog/fsdialog.tcl +0 -1783
  150. data/tcl/fsdialog/fsdlg-gif.tcl +0 -259
  151. data/tcl/fsdialog/fsdlg-png.tcl +0 -265
  152. data/tcl/fsdialog/sv.msg +0 -32
  153. data/tcl/fsdialog/tclIndex +0 -6
  154. data/tcl/ptwidgets-1.1.0/COPYRIGHT +0 -10
  155. data/tcl/ptwidgets-1.1.0/ChangeLog +0 -194
  156. data/tcl/ptwidgets-1.1.0/README +0 -50
  157. data/tcl/ptwidgets-1.1.0/common/stacktrace.tcl +0 -29
  158. data/tcl/ptwidgets-1.1.0/common/tokenframe.tcl +0 -200
  159. data/tcl/ptwidgets-1.1.0/doc/img/toggleswitch_off.png +0 -0
  160. data/tcl/ptwidgets-1.1.0/doc/img/toggleswitch_on.png +0 -0
  161. data/tcl/ptwidgets-1.1.0/doc/img/tokenentry.png +0 -0
  162. data/tcl/ptwidgets-1.1.0/doc/img/tokensearch_popup_example.png +0 -0
  163. data/tcl/ptwidgets-1.1.0/doc/img/tokensearch_popup_example2.png +0 -0
  164. data/tcl/ptwidgets-1.1.0/doc/img/wmarkentry.png +0 -0
  165. data/tcl/ptwidgets-1.1.0/doc/toggleswitch.html +0 -402
  166. data/tcl/ptwidgets-1.1.0/doc/tokenentry.html +0 -1366
  167. data/tcl/ptwidgets-1.1.0/doc/tokensearch.html +0 -1549
  168. data/tcl/ptwidgets-1.1.0/doc/wmarkentry.html +0 -634
  169. data/tcl/ptwidgets-1.1.0/library/toggleswitch.tcl +0 -432
  170. data/tcl/ptwidgets-1.1.0/library/tokenentry.tcl +0 -2208
  171. data/tcl/ptwidgets-1.1.0/library/tokensearch.tcl +0 -2488
  172. data/tcl/ptwidgets-1.1.0/library/wmarkentry.tcl +0 -630
  173. data/tcl/ptwidgets-1.1.0/pkgIndex.tcl +0 -10
  174. data/tcl/ptwidgets-1.1.0/test/Makefile +0 -3
  175. data/tcl/ptwidgets-1.1.0/test/run.tcl +0 -3
  176. data/tcl/ptwidgets-1.1.0/test/test.tcl +0 -89
  177. data/tcl/ptwidgets-1.1.0/test/toggleswitch.test +0 -562
  178. data/tcl/ptwidgets-1.1.0/test/tokenentry.test +0 -1023
  179. data/tcl/ptwidgets-1.1.0/test/tokensearch.test +0 -1023
  180. data/tcl/ptwidgets-1.1.0/test/wmarkentry.test +0 -1325
  181. data/tcl/themes/altTheme.tcl +0 -101
  182. data/tcl/themes/aquaTheme.tcl +0 -59
  183. data/tcl/themes/clamTheme.tcl +0 -140
  184. data/tcl/themes/classicTheme.tcl +0 -108
  185. data/tcl/themes/pkgIndex.tcl +0 -3
  186. data/tcl/themes/ttk.tcl +0 -176
  187. data/tcl/themes/vistaTheme.tcl +0 -224
  188. data/tcl/themes/winTheme.tcl +0 -80
  189. data/tcl/themes/xpTheme.tcl +0 -65
  190. data/tcl/tkfbox/folder.gif +0 -0
  191. data/tcl/tkfbox/textfile.gif +0 -0
  192. data/tcl/tkfbox/tkfbox.tcl +0 -1
  193. data/tcl/tkfbox/tkfbox.tcl~ +0 -1
  194. data/tcl/tkfbox/updir.xbm +0 -1
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: bdc8532019ab652c829d1ef61d005d637e224afc
4
+ data.tar.gz: 63f193144db90697d89cc854e52ed9561f64b4f2
5
+ SHA512:
6
+ metadata.gz: 776ea21a8bfbf7120d77d7b98b4d51045209a722372bbf85e774b094480e1172031d5ed9e067d2691149aeb9b0c1bff5e5460be9f1d7cd5a5e66f8d218edc618
7
+ data.tar.gz: 7902c5e74ab6df805e8026d5f011f2936c1ef9e52e4f45918c051955b7ec13e6ad4f20aacefdd9ed83cac758466e61d9bd5e48704d14d731ceb3f30883fda5d3
data/README CHANGED
@@ -1,9 +1,8 @@
1
1
  = Arcadia Ide
2
- version 0.13.0
2
+ version 0.13.1
3
3
 
4
4
  by Antonio Galeone
5
- on Jul 24, 2013
6
-
5
+ on Nov 3, 2013
7
6
 
8
7
  == About
9
8
 
@@ -16,9 +15,26 @@ Some of Arcadia ide project features include:
16
15
  * Debugging support
17
16
  * Highly estensibile architecture.
18
17
 
18
+ == How to install
19
+ * exec on command line "gem install arcadia"
20
+
21
+ NOTE: on some linux distributions like archlinux the default tcl/tk runtime at this time is on versions >= 8.6
22
+ on the other hand ruby-tk supports fully only versions <= 8.5.x.y so to make arcadia working a choice
23
+ can be install ActiveTcl 8.5 and use ruby via rvm.
24
+
25
+ == How to run
26
+ * exec on command line "arcadia"
27
+
28
+ == Wiki
29
+ https://github.com/angal/arcadia/wiki
19
30
 
20
31
  == News
21
32
 
33
+ [0.13.1]
34
+ This realease:
35
+ - added Russian translation (Thanks to Michael)
36
+ - bug fixes and various improvements
37
+
22
38
  [0.13.0]
23
39
  This realease:
24
40
  - improves file-history introducing bookmarks management
@@ -59,16 +75,6 @@ Some of Arcadia ide project features include:
59
75
  - gem win32-process (only on windows)
60
76
  - gem ruby-wmi (only on windows)
61
77
 
62
- == How to install
63
- * exec on command line "gem install arcadia"
64
-
65
- NOTE: on some linux distributions like archlinux the default tcl/tk runtime at this time is on versions >= 8.6
66
- on the other hand ruby-tk supports fully only versions <= 8.5.x.y so to make arcadia working a choice
67
- can be install ActiveTcl 8.5 and use ruby via rvm.
68
-
69
- == How to run
70
- * exec on command line "arcadia"
71
-
72
78
 
73
79
  == Short User guide
74
80
  Application layout is splitted in vertical and horizontal resizable frames.
@@ -156,8 +162,6 @@ I have tested arcadia with ruby 1.8, 1.9, 2.0 on
156
162
  ==Developers e general information
157
163
  Released on arcadia web site (http://arcadia.rubyforge.org)
158
164
 
159
-
160
-
161
165
  == License
162
166
  Arcadia is released under the Ruby License
163
167
 
data/bin/arc CHANGED
File without changes
@@ -199,7 +199,7 @@ ext.file_history.button.show_as_list.hint=Show as list
199
199
  ext.file_history.menu.search_from_here=Search from here
200
200
  ext.file_history.menu.find_in_files=Find in files...
201
201
  ext.file_history.menu.act_in_files=Act in files...
202
- ext.file_history.toggle_bookmark=Toggle boomark
202
+ ext.file_history.toggle_bookmark=Toggle bookmark
203
203
  #output
204
204
  ext.output.menu.output=Output
205
205
  ext.output.menu.save=Save
@@ -0,0 +1,272 @@
1
+ #main.menu.file
2
+ main.menu.file=Файл
3
+ main.menu.file.open=Открыть
4
+ main.menu.file.new=Новый
5
+ main.menu.file.save=Сохранить
6
+ main.menu.file.save_as=Сохранить как ...
7
+ main.menu.file.quit=Выход
8
+ #main.menu.edit
9
+ main.menu.edit=Редактировать
10
+ main.menu.edit.cut=Вырезать
11
+ main.menu.edit.copy=Копировать
12
+ main.menu.edit.paste=Вставить
13
+ main.menu.edit.undo=Отмена
14
+ main.menu.edit.redo=Вернуть
15
+ main.menu.edit.select_all=Выбрать все
16
+ main.menu.edit.invert_selection=Инфертировать выделение
17
+ main.menu.edit.uppercase=ВерхнийРегистр
18
+ main.menu.edit.lowercase=НижнийРегистр
19
+ main.menu.edit.prettify_current=Форматировать
20
+ main.menu.edit.preferences=Настройки
21
+ #main.menu.search
22
+ main.menu.search=Поиск
23
+ main.menu.search.find_replace=Найти/Заменить ...
24
+ main.menu.search.find_in_files=Найти в файлах ...
25
+ main.menu.search.ack_im_file=Ack in files...
26
+ main.menu.search.go_to_line=Перейти к линии № ...
27
+ #main.menu.view
28
+ main.menu.view=Вид
29
+ main.menu.view.show_hide_toolbar=Показать/Спрятать Тулбар
30
+ main.menu.view.close_current_tab=Закрыть текущую вкладку
31
+ #main.menu.tools
32
+ main.menu.tools=Инструменты
33
+ main.menu.tools.keys_test=Проверить-нажатия
34
+ main.menu.tools.edit_prefs=Редактировать пред-настройки
35
+ main.menu.tools.load_from_edited_prefs=Загрузить пред-настройки
36
+ #main.menu.help
37
+ main.menu.help=Помощь
38
+ main.menu.help.about=Описание
39
+ #main.button
40
+ main.button.file.new.hint=Новый файл
41
+ main.button.file.new.submenu.item=Новый $0 файл ...
42
+ main.button.file.open.hint=Открыть файл
43
+ main.button.file.save.hint=Сохранить текущий файл
44
+ main.button.file.find.hint=Поиск в текущем файле
45
+ main.button.run.curr.hint=Запустить
46
+ main.button.run.last.hint=Запустить последний
47
+ main.button.run.submenu.manage_runner.hint=Управление запуском ...
48
+ main.button.run.submenu.manage_runner.caption=Управление запуском ...
49
+ main.button.sys.exit.hint=Выход
50
+ #main.runner
51
+ main.runner.run_selected.title=Запустить выбранный как $0 файл
52
+ main.runner.compile_and_run_selected.title=Скомпилировать и Запустить $0 файл
53
+ #main.splash
54
+ main.splash.creating_extension=... создание $0
55
+ main.splash.initializing_layout=... инициализация внешнего вида
56
+ main.splash.building_extensions=... собираем расширения
57
+ main.splash.loading_common_user_controls=... загрузка пользовательских настроек
58
+ main.splash.loading_keys_binding=... загрузка соответствия нажатий
59
+ main.splash.loading_ext_user_controls=... загружено $0 пользовательских настроек
60
+ main.splash.loading_runners=... загрузка runner-ов
61
+ main.splash.initializing_extensions=... инициализация расширений
62
+ #error
63
+ main.e.during_build_event.msg=Событие во время сборки ($0) : $1 в : $2
64
+ main.e.during_build_event.title=(Arcadia) Событие во время сборки
65
+ main.e.loading_ext.msg=Загрузка "$0" ($1) : $2 в : $3
66
+ main.e.loading_ext.title=(Arcadia) Расширения '$0'
67
+ main.e.creating_ext.msg=Создано "$0" ($1) : $2 в : $3"
68
+ main.e.creating_ext.title=(Arcadia) Расширения '$0'
69
+ main.e.loading_layout.msg=Загрузка вида: ($0 : $1 в : $2)
70
+ main.e.loading_layout.title=(Arcadia) Вид
71
+ main.e.loading_runner.msg=Загружаю загрузчики : probably bud runner conf '$0' : $1
72
+ main.e.loading_runner.title=(Arcadia) Запуск $0
73
+ main.e.loading_user_control.msg=Загружаю $0 ->$1 ($2 : $3 at : $4)
74
+ main.e.loading_user_control.title=(Arcadia) $0
75
+ main.e.runtime.title=Ошибка
76
+ main.e.adding_new_menu_item.msg=Во время сборки пункт меню '$0' или '$1' не найден!
77
+ main.e.adding_new_menu_item.title=(Arcadia) $0
78
+ main.e.gem_missing.msg=Этот gem : '$0' требуется : '$1' не установлен! Установить gem?
79
+ main.e.gem_missing.title=Gem '$0' упущен!
80
+ main.e.dir_not_writable.msg=Локальная деректория "$0" должна иметь права на запись!
81
+ main.e.dir_not_writable.title=($0)
82
+ #dialog
83
+ main.d.confirm_exit.msg=Выйти?
84
+ main.d.confirm_exit.title=(Arcadia) Выход
85
+ main.d.confirm_delete_runner.msg=Вы хотите удалить запущенные $0'?
86
+ main.d.confirm_delete_runner.title=(Arcadia) Управление запусками
87
+ main.d.confirm_delete_ext_instance.msg=Действительно удалить '$0'?
88
+ main.d.confirm_delete_ext_instance.title=(Arcadia) Удалить $0
89
+ main.about.by=by $0
90
+ main.about.version=версия: $0
91
+ main.about.contributors=Разработчики: $0
92
+ main.ps.title=Arcadia проблемы
93
+ main.ps.problem=$0 проблема
94
+ main.ps.problems=$0 проблемы
95
+ main.ps.dependences_missing=Зависимости не удовлетворены
96
+ main.ps.runtime_errors=Ошибки Runtime
97
+ #extensions
98
+ #editor
99
+ ext.editor.menu.view.show_hide_line_number=Позакать/Скрыть номера строк в редакторе
100
+ ext.editor.menu.view.show_hide_tabs=Позакать/Скрыть вкладки редактора
101
+ ext.editor.button.link.hint=Link open editors with content in the Navigator
102
+ ext.editor.button.up.hint=Просмотр родителя
103
+ ext.editor.outline.rebuild_tree=.... пересобрать дерево
104
+ ext.editor.outline.menu.rebuild=Пересобрать
105
+ ext.editor.text_line.menu.title=линия $0
106
+ ext.editor.text_line.menu.toggle_breakpoint=Свернуть закладки
107
+ ext.editor.text.menu.save=Сохранить
108
+ ext.editor.text.menu.save_as=Сохранить как
109
+ ext.editor.text.menu.close=Закрыть
110
+ ext.editor.text.menu.close_others=Закрыть другие
111
+ ext.editor.text.menu.close_all=Закрыть Все
112
+ ext.editor.text.menu.copy=Копировать
113
+ ext.editor.text.menu.cut=Вырезать
114
+ ext.editor.text.menu.paste=Вставить
115
+ ext.editor.text.menu.undo=Отмена
116
+ ext.editor.text.menu.color=Цвет
117
+ ext.editor.text.menu.color_from_data=Просмотр цвета из данных
118
+ ext.editor.text.menu.font=Шрифт
119
+ ext.editor.text.menu.data_from_file=Данные из файла
120
+ ext.editor.text.menu.image_from_data=Просмотр изображения из данных
121
+ ext.editor.text.menu.data_to_file=Данные в файл изображения
122
+ ext.editor.text.menu.eval_selected=Выполнить выбранное
123
+ ext.editor.text.menu.debug=Отладка
124
+ ext.editor.text.menu.set_wrap=Перенос строк
125
+ ext.editor.text.menu.set_nowrap=Без переноса строк
126
+ ext.editor.text.menu.to_uppercase=Выбранное в верхний-регистр
127
+ ext.editor.text.menu.to_downcase=Выбранное в нижний-регистр
128
+ ext.editor.text.menu.show_tabs=Показать Вкладки
129
+ ext.editor.text.menu.hide_tabs=Спрятать Вкладки
130
+ ext.editor.text.menu.show_spaces=Показать пробелы
131
+ ext.editor.text.menu.hide_spaces=Спрятать пробелы
132
+ ext.editor.text.menu.space_to_tab=Пробел вместо Табуляции
133
+ ext.editor.text.menu.tab_to_space=Табуляция вместо пробела
134
+ ext.editor.text.menu.code=Код
135
+ ext.editor.buffer.menu.close=Закрыть
136
+ ext.editor.buffer.menu.close_others=Закрыть другие
137
+ ext.editor.buffer.menu.close_all=Закрыть Все
138
+ ext.editor.search.label.find_what=Что Найти:
139
+ ext.editor.search.label.replace_with=Заменить этим:
140
+ ext.editor.search.label.use_regexp=Использовать Регулярные выражения
141
+ ext.editor.search.label.search_back=Поиск в обратном направлении
142
+ ext.editor.search.label.ignore_case=Игнорировать Регистр
143
+ ext.editor.search.label.replace_all=Заменить Все
144
+ ext.editor.search.label.replace=Замена
145
+ ext.editor.search.label.find_next=Найти Далее
146
+ ext.editor.search.d.replace.msg=Заменить "$0" на "$1" ?
147
+ ext.editor.text.d.save_read-only.title=$0:чтение-только
148
+ ext.editor.text.d.save_read-only.msg=Файл : $0 только для чтения! -- все-равно сохранить?
149
+ ext.editor.text.d.file_changed.title=Файл изменен!
150
+ ext.editor.text.d.file_changed.msg=Файл "$0" изменен! Перезагрузить его?
151
+ ext.editor.text.d.file_deleted.title=Файл удален!
152
+ ext.editor.text.d.file_deleted.msg=Appears that file "$0" was deleted by other process! Do you want to resave it?
153
+ ext.editor.file.save_modified.msg=$0 modified. Сохранить?
154
+ ext.editor.file.save_modified.title=Подтвердить сохранение
155
+ ext.editor.file.close_modified_by_other.msg=$0 modified by other process. Continue closing?
156
+ ext.editor.file.close_modified_by_other.title=Продолжить закрытие
157
+ ext.editor.e.ctags.msg="ctags" пакет требуется для просмотра классов, без этого поддерживается только ruby!
158
+ ext.editor.e.ctags.title=Ctags сбоит!
159
+ ext.editor.e.prettify.title=(Arcadia) форматировать код
160
+ ext.editor.e.prettify.msg=Проблемы при форматировании кода $0
161
+ #dir_projects
162
+ ext.dir_projects.button.link.hint=Link open editors with content in the Navigator
163
+ ext.dir_projects.button.new.hint=Новая папка Проекта
164
+ ext.dir_projects.button.open.hint=Открыть папку как проект
165
+ ext.dir_projects.button.up.hint=Идти в родительскую папку
166
+ ext.dir_projects.button.search.hint=Искать файлы от текущей папки
167
+ ext.dir_projects.button.term.hint=Терминал в текущей папке
168
+ ext.dir_projects.menu.title=Дерево меню
169
+ ext.dir_projects.menu.new=Новый
170
+ ext.dir_projects.menu.new_dir_proj=Новая папка Проекта
171
+ ext.dir_projects.menu.new_folder=Новая папка
172
+ ext.dir_projects.menu.new_file=Новый файл
173
+ ext.dir_projects.menu.refactor=Рефактор
174
+ ext.dir_projects.menu.refactor.rename=Переименовать
175
+ ext.dir_projects.menu.refactor.move=Переместить
176
+ ext.dir_projects.menu.search=Поиск здесь
177
+ ext.dir_projects.menu.search.find=Найти в файлах...
178
+ ext.dir_projects.menu.search.act=Act in files...
179
+ ext.dir_projects.menu.term=Терминал здесь
180
+ ext.dir_projects.menu.open=Открыть папку как проект
181
+ ext.dir_projects.menu.close=Закрыть Проект
182
+ ext.dir_projects.menu.refresh=Обновить
183
+ ext.dir_projects.menu.copy=Копировать
184
+ ext.dir_projects.menu.paste=Вставить
185
+ ext.dir_projects.menu.delete=Удалить
186
+ ext.dir_projects.d.move.msg=Переместить $0 в $1?
187
+ ext.dir_projects.d.move.title=Подтвердить перемещение
188
+ ext.dir_projects.d.paste.msg=Копировать $0 в $1?
189
+ ext.dir_projects.d.paste.title=Подтвердить копирование
190
+ ext.dir_projects.d.delete.msg=Удалить $0 $1 ?
191
+ ext.dir_projects.d.delete.msg2=$0 не пуст. Уверены, что хотите удалить все под ... ?
192
+ ext.dir_projects.d.delete.title=Подтвердить удаление
193
+ ext.dir_projects.d.nosel.msg=Нет выбранных папок!
194
+ ext.dir_projects.d.nosel.title=Инфо
195
+ #file_history
196
+ ext.file_history.button.link.hint=Link open editors with content in the Navigator
197
+ ext.file_history.button.show_as_tree.hint=Показать как дерево
198
+ ext.file_history.button.show_as_list.hint=Показать как список
199
+ ext.file_history.menu.search_from_here=Искать отсюда
200
+ ext.file_history.menu.find_in_files=Найти в файлах...
201
+ ext.file_history.menu.act_in_files=Act in files...
202
+ ext.file_history.toggle_bookmark=Свернуть пометки
203
+ #output
204
+ ext.output.menu.output=Вывод
205
+ ext.output.menu.save=Сохранить
206
+ ext.output.menu.wrap=Перенос строк
207
+ ext.output.menu.nowrap=Без перенос строк
208
+ ext.output.button.clear.hint=Очистить
209
+ #breakpoints
210
+ ext.breakpoints.menu.clear_selected=Очистить выбранные точки останова
211
+ ext.breakpoints.menu.delete_selected=Удалить выбранные точки останова
212
+ ext.breakpoints.menu.delete_all=Удалить все точки останова
213
+ ext.breakpoints.menu.goto_selected=Перейти к выбранным точкам останова
214
+ #ruby-debug
215
+ ext.ruby_debug.button.step_over.hint=step over
216
+ ext.ruby_debug.button.step_into.hint=step into
217
+ ext.ruby_debug.button.step_out.hint=step out
218
+ ext.ruby_debug.button.resume.hint=resume
219
+ ext.ruby_debug.button.quit.hint=выход
220
+ ext.ruby_debug.node.local_var.caption=Локальные переменные
221
+ ext.ruby_debug.node.instance_var.caption=Переменные Экземпляра
222
+ ext.ruby_debug.node.class_var.caption=Переменные Класса
223
+ ext.ruby_debug.node.global_var.caption=Глобальные переменные
224
+ ext.ruby_debug.freeze_at=$0 заморожено на $1
225
+ ext.ruby_debug.node.eval_selected=Выполнить выбранное
226
+ ext.ruby_debug.server.e.on_start=Error on start server : $0:$1
227
+ ext.ruby_debug.server.e.on_kill=Error on kill : $0:$1
228
+ ext.ruby_debug.client.e.on_command=в команде $0:$1
229
+ ext.ruby_debug.client.e.on_command2=Ошибка в команде $0: $1:$2
230
+ ext.ruby_debug.client.e.socket_session.1=Ошибка на socket session : $0
231
+ ext.ruby_debug.client.e.socket_session.2=Ошибка на socket session : $0:$1
232
+ ext.ruby_debug.client.e.close_session=Ошибка на close session : $0:$1
233
+ ext.ruby_debug.client.e.start_session=Ошибка на start_session : $0:$1 $2
234
+ ext.ruby_debug.client.e.stop_session=Ошибка на stop_session : $0:$1
235
+ ext.ruby_debug.client.e.abort_session=Отладка завершила выполнение на команде $0: $1:$2
236
+ ext.ruby_debug.client.e.raise.on_read.1=Отладка завершила выполнение
237
+ ext.ruby_debug.client.e.raise.on_read.2=Ошибка: on command '$0' => $1 : $2
238
+ ext.ruby_debug.e.rdebug=Внимание: Расширение ae-ruby-debug depend upon rdebug command (install it or update system path!)
239
+ ext.ruby_debug.e.do_debug=Начало отладки $0 : $1
240
+ ext.ruby_debug.d.file_not_exist.msg=Файл $0 не существует!
241
+ ext.ruby_debug.d.file_not_exist.title=Файл не существует
242
+ ext.ruby_debug.d.exit_query.msg=Отладка in course, хотите выйти?
243
+ ext.ruby_debug.d.exit_query.title=(Arcadia) Отладка
244
+ ext.ruby_debug.d.quit_if_debug.msg=Отладка in course, остановить до выхода
245
+ ext.ruby_debug.d.quit_if_debug.title=(Arcadia) Отладка
246
+ # search_in_files
247
+ ext.search_in_files.title=Поиск в файлах
248
+ ext.search_in_files.search_result_title=результат поиска для : "$0" из :"$1" [$2]
249
+ ext.search_in_files.progress.title=Поиск
250
+ ext.search_in_files.button.clear.hint=Очистить
251
+ ext.search_in_files.search.label.find_what=Что найти:
252
+ ext.search_in_files.search.label.files_filter=Фильтр файлов:
253
+ ext.search_in_files.search.label.dir=Папки:
254
+ ext.search_in_files.search.button.find=Поиск
255
+ ext.search_in_files.title.1=Ack in files
256
+ ext.search_in_files.ack_result_title=ack результат для : "$0" в :"$1" [$2] $3
257
+ ext.search_in_files.progress.title.1=Запускаем
258
+ ext.search_in_files.progress.title.2=Parsing
259
+ ext.search_in_files.no_search_result=Не найдено
260
+ # shell
261
+ ext.shell.done=Выполенно $0 в $1s
262
+ ext.shell.done.1=Окончание выполнения $0:
263
+ # sub_process_inspector
264
+ ext.spi.d.exit_query.msg=Некоторые под=процессы выполняются! Выйти в любом случае?
265
+ ext.spi.d.exit_query.title=Потвердить выход
266
+ ext.spi.d.kill.msg=Действительно завершить процесс $0 $1 ?
267
+ ext.spi.d.kill.title=Подтвердить снятия задачи
268
+ #term
269
+ ext.term.dependences_missing.xterm.msg="xterm" приложение требуется для Term (Терминала), без этого интеграция не возможна!
270
+ ext.term.dependences_missing.xterm.title=xterm (Терминал) не найден!
271
+ ext.term.dependences_missing.xdotool.msg="xdotool" приложение требуется для XTerm (хТерминала), без этого интеграция не возможна!
272
+ ext.term.dependences_missing.xdotool.title=xdotool не найден!
@@ -1,5 +1,5 @@
1
- #background=#212b48
2
1
  background=#33302e
2
+
3
3
  foreground=gray
4
4
  activebackground=#334b56
5
5
  activeforeground=yellow
@@ -15,7 +15,7 @@ borderwidth=0
15
15
 
16
16
 
17
17
  edit.background=#232323
18
- #edit.background=#0000000030a4
18
+
19
19
  edit.foreground=white
20
20
  edit.relief=flat
21
21
  edit.borderwidth=0
@@ -31,7 +31,7 @@ titlelabel.background=#6a3d6a3d6a3d
31
31
  titlemenu.relief=flat
32
32
  splitter.relief=flat
33
33
  splitter.background=#3c3838
34
- button.relief=flat
34
+ #button.relief=flat
35
35
 
36
36
  treepanel.selectforeground=yellow
37
37
  treepanel.selectbackground=#133e5e
@@ -3,10 +3,10 @@
3
3
  # by Antonio Galeone <antonio-galeone@rubyforge.org>
4
4
  #
5
5
  # &require_dir_ref=../..
6
- # &require_omissis=conf/arcadia.init
7
- # &require_omissis=lib/a-commons
8
- # &require_omissis=lib/a-tkcommons
9
- # &require_omissis=lib/a-core
6
+ # &require_omissis=#{Dir.pwd}/lib/a-core
7
+ # &require_omissis=#{Dir.pwd}/conf/arcadia.init
8
+ # &require_omissis=#{Dir.pwd}/lib/a-commons
9
+ # &require_omissis=#{Dir.pwd}/lib/a-tkcommons
10
10
 
11
11
 
12
12
 
@@ -152,7 +152,7 @@ class DirProjects < ArcadiaExtPlus
152
152
  crosscloseimage Arcadia.image_res(PLUS_GIF)
153
153
  crossopenimage Arcadia.image_res(MINUS_GIF)
154
154
  }
155
- @htree.extend(TkScrollableWidget).show(0,22)
155
+ @htree.extend(TkScrollableWidget).show(0,24)
156
156
  self.pop_up_menu_tree
157
157
  @image_kdir = Arcadia.image_res(ICON_FOLDER_OPEN_GIF)
158
158
  @image_kdir_closed = Arcadia.image_res(FOLDER_GIF)
@@ -7,16 +7,15 @@
7
7
 
8
8
  require 'tk'
9
9
  require 'tktext'
10
- require "#{Dir.pwd}/lib/a-tkcommons"
11
- #require 'lib/a-commons'
12
10
  require "#{Dir.pwd}/lib/a-core"
11
+ require "#{Dir.pwd}/lib/a-tkcommons"
13
12
  require "#{Dir.pwd}/ext/ae-editor/lib/rbeautify"
14
13
 
15
14
  class SourceTreeNode
16
15
  attr_reader :sons
17
16
  attr_reader :parent
18
17
  attr_reader :kind
19
- attr_accessor :rif, :rif_end, :label, :helptext, :sortable
18
+ attr_accessor :rif, :rif_end, :label, :helptext, :sortable, :args
20
19
  def initialize(parent=nil, kind='class', sortable=true)
21
20
  @sons = Array.new
22
21
  @parent = parent
@@ -99,7 +98,7 @@ end
99
98
 
100
99
  class CtagsSourceStructure < SourceStructure
101
100
  SUPPORTED_LANG = ['Ant','Asm','Asp','Awk','Basic','BETA','C','C++','C#','Cobol','DosBatch','Eiffel','Erlang','Flex','Fortran','HTML','Java','JavaScript','Lisp','Lua','Make','MatLab','OCaml','Pascal','Perl','PHP','Python','REXX','Ruby','Scheme','Sh','SLang','SML','SQL','Tcl','Tex','Vera','Verilog','VHDL','Vim','YACC']
102
- def initialize(_file, _ctags_string='ctags', _language=nil)
101
+ def initialize(_file, _ctags_string='ctags', _row_rif = nil, _language=nil)
103
102
  super()
104
103
  @file = _file
105
104
  @ctags_string = _ctags_string
@@ -107,9 +106,20 @@ class CtagsSourceStructure < SourceStructure
107
106
  @classes = Hash.new
108
107
  @last_root = @root
109
108
  @last_class_node = @root
110
- @last_node = @root
109
+ @last_node = @root
110
+ @blank_rows = []
111
+ initialize_blank_rows(_row_rif) if !_row_rif.nil?
111
112
  build_structure
112
113
  end
114
+
115
+ def initialize_blank_rows(_row = nil)
116
+ File::open(@file,'rb'){ |file|
117
+ file.readlines.each_with_index{| line, i |
118
+ @blank_rows << i+1 if line.strip == ''
119
+ }
120
+ }
121
+ @blank_rows << _row if _row
122
+ end
113
123
 
114
124
  def build_structure
115
125
  output = ctags
@@ -118,7 +128,7 @@ class CtagsSourceStructure < SourceStructure
118
128
  b2,b3 = brest.split('$/;"')
119
129
  name,file = b1.strip.split("\t")
120
130
  definition = b2.strip
121
- fields_raw = b3.strip.split("\t")
131
+ fields_raw = b3.nil? ? [] : b3.strip.split("\t")
122
132
  fields = Hash.new
123
133
  fields_raw.each{|item|
124
134
  k,v=item.split(":")
@@ -133,12 +143,17 @@ class CtagsSourceStructure < SourceStructure
133
143
  else
134
144
  parent = @last_root
135
145
  end
136
-
137
146
  node = SourceTreeNode.new(parent, fields['kind'])
138
147
  node.label = name
139
148
  node.helptext = definition
149
+ node.args = ''
150
+ definition.split(name)[1..-1].each { |part| node.args += "#{part}" }
140
151
  node.rif = fields['line']
141
- @last_node.rif_end = (node.rif.to_i-1).to_s
152
+ ln_rif = node.rif.to_i - 1
153
+ while @blank_rows.include?(ln_rif) && ln_rif > 0
154
+ ln_rif = ln_rif - 1
155
+ end
156
+ @last_node.rif_end = ln_rif.to_s
142
157
 
143
158
  if ['class','module','interface','package'].include?(fields['kind'])
144
159
  if fields['class'] != nil
@@ -176,8 +191,8 @@ end
176
191
  class RubyCtagsSourceStructure < CtagsSourceStructure
177
192
  attr_reader :injected_row
178
193
 
179
- def initialize(_file, _ctags_string='ctags')
180
- super(_file, _ctags_string, 'Ruby')
194
+ def initialize(_file, _ctags_string='ctags', _row_rif = nil)
195
+ super(_file, _ctags_string, _row_rif, 'Ruby')
181
196
  end
182
197
 
183
198
  def scheletor_from_node(_node, _source='', _injected_source='', _injected_class='')
@@ -190,8 +205,8 @@ class RubyCtagsSourceStructure < CtagsSourceStructure
190
205
  _hinner_source = "#{_hinner_source}#{_son.helptext}\n"
191
206
  elsif _son.kind == 'module'
192
207
  _hinner_source = "#{_hinner_source}#{_son.helptext}\n"
193
- elsif _son.kind == 'method' && _son.label != 'initialize'
194
- _hinner_source = "#{_hinner_source} def #{_son.label}\n"
208
+ elsif _son.kind == 'method' && ((_son.label != 'initialize') || (_son.label == 'initialize') && _son.args)
209
+ _hinner_source = "#{_hinner_source} def #{_son.label}#{_son.args}\n"
195
210
  _hinner_source = "#{_hinner_source} end\n"
196
211
  elsif _son.kind == 'singleton method'
197
212
  _hinner_source = "#{_hinner_source} def #{_son.label}\n"
@@ -203,6 +218,8 @@ class RubyCtagsSourceStructure < CtagsSourceStructure
203
218
  if _node.kind == 'class' && _node.label == _injected_class
204
219
  _source = "#{_source} def initialize\n #{_injected_source} end\n"
205
220
  @injected_row = _source.split("\n").length-2
221
+ elsif _node.kind == 'class'
222
+ _source = "#{_source} def initialize\n end\n"
206
223
  end
207
224
  _source = "#{_source}end\n" if _node.kind == 'class' || _node.kind == 'module'
208
225
  _source
@@ -352,34 +369,131 @@ class RubySourceStructure < SourceStructure
352
369
  end
353
370
  end
354
371
 
355
-
356
- class SafeCompleteCode
357
- attr_reader :modified_row, :modified_col
372
+ class CompleteCode
358
373
  attr_reader :filter
359
374
  def initialize(_editor, _row, _col)
360
375
  @editor = _editor
361
376
  @source = _editor.text_value
362
- #@file = _file
363
377
  @row = _row.to_i
364
378
  @col = _col.to_i
379
+ @filter=''
380
+ @words = Array.new
381
+ @is_dot = nil
382
+ end
383
+
384
+ def focus_word(focus_segment)
385
+ focus_world = ''
386
+ char = focus_segment[-1..-1]
387
+ while [")","]","}"].include?(char)
388
+ char=focus_segment[-2..-2]
389
+ focus_segment = focus_segment[0..-2]
390
+ end
391
+ j = focus_segment.length - 1
392
+ while !["\s","\t",";",",","(","[","{",">"].include?(char) && j >= 0
393
+ focus_world = "#{char}#{focus_world}"
394
+ j=j-1
395
+ char = focus_segment[j..j]
396
+ end
397
+ focus_world
398
+ end
399
+
400
+ def process_source
401
+ @source_array = @source.split("\n")
402
+ @focus_line = @source_array[@row-1]
403
+ @focus_line = @focus_line[0..@col] if @focus_line
404
+ @focus_line = '' if @focus_line.nil?
405
+ @focus_world = ''
406
+ if @focus_line && @focus_line.strip.length > 0
407
+ if @focus_line[@col-1..@col-1] == '.'
408
+ #@is_dot=true
409
+ focus_segment = @focus_line[0..@col-2]
410
+ elsif @focus_line.include?('.')
411
+ #@is_dot=true
412
+ focus_segment_array = @focus_line.split('.')
413
+ focus_segment = ''
414
+ focus_segment_array[0..-2].each{|seg|
415
+ if focus_segment.strip.length > 0
416
+ focus_segment = focus_segment+'.'
417
+ end
418
+ focus_segment = focus_segment+seg
419
+ }
420
+ @filter = focus_word(focus_segment_array[-1].strip)
421
+ else
422
+ focus_segment = ''
423
+ @filter = focus_word(@focus_line[0..@col-1].strip)
424
+ end
425
+ @focus_world = focus_word(focus_segment)
426
+ end
427
+
428
+ if @filter.strip.length > 0 && !is_dot?
429
+ refresh_words
430
+ end
431
+ @words.sort
432
+ end
433
+
434
+ def refresh_words
435
+ @words.clear
436
+ _re = /[\s\t\n"'(\[\{=><]#{@filter}[a-zA-Z0-9\-_]*/
437
+ m = _re.match(@source)
438
+ while m && (_txt=m.post_match)
439
+ can = m[0].strip
440
+ if can.include?(' ')
441
+ can = can.split[1].strip
442
+ end
443
+ if ['"','(','[','{',"'",'=','>','<'].include?(can[0..0])
444
+ can = can[1..-1].strip
445
+ end
446
+ @words << can if can != @filter && !@words.include?(can)
447
+ m = _re.match(_txt)
448
+ end
449
+ end
450
+
451
+ def is_dot?
452
+ if @is_dot == nil
453
+ fline = @editor.text.get('insert linestart', 'insert')
454
+ @is_dot = fline != nil && fline.length > 0 && fline[-1..-1] == '.'
455
+ end
456
+ @is_dot
457
+ end
458
+
459
+ def candidates(_show_error = false)
460
+ process_source
461
+ end
462
+ end
463
+
464
+ class RubyCompleteCode < CompleteCode
465
+ attr_reader :modified_row, :modified_col
466
+ RESERVED_WORDS = ["__FILE__","and","def","end","in","or","self","unless",
467
+ "__LINE__","begin","defined?","ensure","module","redo","super","until",
468
+ "BEGIN","break","do","false","next","rescue","then","when",
469
+ "END","case","else","for","nil","retry","true","while",
470
+ "alias","class","elsif","if","not","return","undef","yield"]
471
+ def initialize(_editor, _row, _col)
472
+ # @editor = _editor
473
+ # @source = _editor.text_value
474
+ # @row = _row.to_i
475
+ # @col = _col.to_i
476
+ super
365
477
  if _editor && _editor.has_ctags?
366
478
  tmp_file = _editor.create_temp_file
367
479
  begin
368
- @ss = RubyCtagsSourceStructure.new(tmp_file, _editor.ctags_string)
480
+ @ss = RubyCtagsSourceStructure.new(tmp_file, _editor.ctags_string, _row.to_i)
369
481
  ensure
370
482
  File.delete(tmp_file)
371
483
  end
372
484
  else
373
- @ss = RubySourceStructure.new(_source)
485
+ @ss = RubySourceStructure.new(@source)
374
486
  end
375
- @filter=''
376
- @words = Array.new
377
- process_source
487
+ # @filter=''
488
+ # @words = Array.new
489
+ # process_source
378
490
  end
379
491
 
380
492
  def dot_trip(_var_name)
381
- ret = "_class=#{_var_name}.class.name\n"
382
- ret = ret +"_methods=#{_var_name}.methods\n"
493
+ # ret = "_class=#{_var_name}.class.name\n"
494
+ ret = "_class=#{_var_name}.class.to_s\n"
495
+ # ret = ret +"_methods=#{_var_name}.methods\n"
496
+ ret = ret +"_methods=#{_var_name}.public_methods(includeSuper=true)\n"
383
497
  ret = ret +"owner_on = Method.instance_methods.include?('owner')\n"
384
498
  ret = ret +"_methods.each{|m|\n"
385
499
  ret = ret +"meth = #{_var_name}.method(m)\n"
@@ -402,7 +516,7 @@ class SafeCompleteCode
402
516
  end
403
517
 
404
518
  def scope_trip
405
- ret = "ObjectSpace.each_object(Class){|o|\n"
519
+ ret = "ObjectSpace.each_object(Module){|o|\n"
406
520
  ret = ret + " o_name = o.name\n"
407
521
  ret = ret + " print '#'+o_name+'\n' if o_name && o_name.strip.length>0 \n"
408
522
  ret = ret + "}\n"
@@ -444,59 +558,21 @@ class SafeCompleteCode
444
558
  dec_line_processed
445
559
  end
446
560
 
447
- def is_dot?
448
- @is_dot
449
- end
450
-
451
- def refresh_words
452
- @words.clear
453
- _re = /[\s\t\n"'(\[\{=><]#{@filter}[a-zA-Z0-9\-_]*/
454
- m = _re.match(@source)
455
- while m && (_txt=m.post_match)
456
- can = m[0].strip
457
- if ['"','(','[','{',"'",'=','>','<'].include?(can[0..0])
458
- can = can[1..-1]
459
- end
460
- @words << can if can != @filter
461
- m = _re.match(_txt)
462
- end
463
- end
561
+ # def is_dot?
562
+ # @is_dot
563
+ # end
464
564
 
465
565
  def process_source
466
- @modified_source = ""
467
- @modified_row = @row
566
+ super
567
+ @modified_source = "begin\n"
568
+ @modified_row = @row+1
468
569
  @modified_col = @col
469
- source_array = @source.split("\n")
470
- focus_line = source_array[@row-1]
471
- focus_line = focus_line[0..@col] if focus_line
472
- focus_line = '' if focus_line.nil?
473
- focus_world = ''
474
- if focus_line && focus_line.strip.length > 0
475
- if focus_line[@col-1..@col-1] == '.'
476
- @is_dot=true
477
- focus_segment = focus_line[0..@col-2]
478
- elsif focus_line.include?('.')
479
- @is_dot=true
480
- focus_segment_array = focus_line.split('.')
481
- focus_segment = ''
482
- focus_segment_array[0..-2].each{|seg|
483
- if focus_segment.strip.length > 0
484
- focus_segment = focus_segment+'.'
485
- end
486
- focus_segment = focus_segment+seg
487
- }
488
- @filter = focus_word(focus_segment_array[-1].strip)
489
- else
490
- focus_segment = ''
491
- @filter = focus_word(focus_line[0..@col-1].strip)
492
- end
493
- focus_world= focus_word(focus_segment)
494
- end
495
570
  @class_node = @ss.class_node_by_line(@row)
496
- focus_line_to_evaluate = focus_line
571
+ focus_line_to_evaluate = @focus_line
497
572
  @modified_source = "#{@modified_source}Dir.chdir('#{File.dirname(@editor.file)}')\n" if @editor.file
498
573
  @modified_row = @modified_row+1
499
- source_array.each_with_index{|line,j|
574
+ require_tk = false
575
+ @source_array.each_with_index{|line,j|
500
576
  # 0) if a comment I do not consider it
501
577
  if line.strip.length > 0 && line.strip[0..0]=='#'
502
578
  @modified_row = @modified_row-1
@@ -512,13 +588,12 @@ class SafeCompleteCode
512
588
  @modified_source = "#{@modified_source}require \"#{require_omissis}\"\n"
513
589
  @modified_row = @modified_row+1
514
590
  end
515
-
516
-
517
591
  # 1) include require
518
592
  elsif line.strip.length>7 && (line.strip[0..7]=="require " || line.strip[0..7]=="require(")
519
593
  @modified_source = "#{@modified_source}#{line}\n"
520
- if line.strip[8..-1].include?("tk")
521
- @modified_source = "#{@modified_source}Tk.root.destroy if Tk && Tk.root\n"
594
+ if !require_tk && line.strip[8..-1].include?("tk")
595
+ require_tk = true
596
+ # @modified_source = "#{@modified_source}Tk.root.destroy if Tk && Tk.root\n"
522
597
  end
523
598
  # 2) include evalueting row with a $SAFE 3
524
599
  elsif j.to_i == @row-1
@@ -530,12 +605,16 @@ class SafeCompleteCode
530
605
  end
531
606
  break if j.to_i >= @row - 1
532
607
  }
608
+ if require_tk
609
+ @modified_source = "#{@modified_source}Tk.root.destroy if Tk && Tk.root\n"
610
+ @modified_row = @modified_row+1
611
+ end
533
612
  if focus_line_to_evaluate
534
613
  # search an optional declaration
535
- if focus_world && focus_world.strip.length > 0
614
+ if @focus_world && @focus_world.strip.length > 0
536
615
  begin
537
- re = Regexp::new('[\s\n\t\;]('+focus_world.strip+')[\s\t]*=(.)*')
538
- source_array.each_with_index do |line,j|
616
+ re = Regexp::new('[\s\n\t\;]('+@focus_world.strip+')[\s\t]*=(.)*')
617
+ @source_array.each_with_index do |line,j|
539
618
  #m = /[\s\n\t\;](#{focus_world})[\s\t]*=(.)*/.match(line)
540
619
  if j >= @row-1
541
620
  break
@@ -559,8 +638,8 @@ class SafeCompleteCode
559
638
  if @class_dec_line_node && @class_dec_line_node.label == @class_node.label
560
639
  to_iniect = "#{to_iniect}#{declaration(@dec_line)}\n"
561
640
  end
562
- if focus_world.length > 0
563
- to_iniect = "#{to_iniect}#{dot_trip(focus_world)}\n"
641
+ if @focus_world.length > 0
642
+ to_iniect = "#{to_iniect}#{dot_trip(@focus_world)}\n"
564
643
  else
565
644
  to_iniect = "#{to_iniect}#{scope_trip}\n"
566
645
  end
@@ -592,8 +671,8 @@ class SafeCompleteCode
592
671
  @modified_row = @modified_row+1
593
672
  end
594
673
  #@modified_source = "#{@modified_source}_candidates=@candidates\n"
595
- if focus_world.length > 0
596
- @modified_source = "#{@modified_source}#{dot_trip(focus_world)}\n"
674
+ if @focus_world.length > 0
675
+ @modified_source = "#{@modified_source}#{dot_trip(@focus_world)}\n"
597
676
  else
598
677
  @modified_source = "#{@modified_source}#{scope_trip}\n"
599
678
  end
@@ -604,9 +683,16 @@ class SafeCompleteCode
604
683
  @modified_row = @modified_row+1+ss_len
605
684
  end
606
685
  end
607
- if @filter.strip.length > 0 && !is_dot?
608
- refresh_words
609
- end
686
+ @modified_source = "#{@modified_source}rescue Exception => e\n"
687
+ @modified_source = "#{@modified_source} if e.class != SystemExit\n"
688
+ @modified_source = "#{@modified_source} p :ARCADIA_CC_ERROR\n"
689
+ @modified_source = "#{@modified_source} p e.message\n"
690
+ @modified_source = "#{@modified_source} end\n"
691
+ @modified_source = "#{@modified_source}end\n"
692
+ @modified_row = @modified_row+6
693
+ # if @filter.strip.length > 0 && !is_dot?
694
+ # refresh_words
695
+ # end
610
696
 
611
697
  # Arcadia.console(self, 'msg'=>@modified_source)
612
698
  # Arcadia.console(self, 'msg'=>"@modified_row=#{@modified_row}")
@@ -616,38 +702,40 @@ class SafeCompleteCode
616
702
  # Arcadia.console(self, 'msg'=>"@dec_line=#{@dec_line}") if @dec_line
617
703
  # Arcadia.console(self, 'msg'=>"declaration(@dec_line)=#{declaration(@dec_line)}") if @dec_line
618
704
  end
619
-
620
- def focus_word(focus_segment)
621
- focus_world = ''
622
- char = focus_segment[-1..-1]
623
- while [")","]","}"].include?(char)
624
- char=focus_segment[-2..-2]
625
- focus_segment = focus_segment[0..-2]
626
- end
627
- j = focus_segment.length - 1
628
- while !["\s","\t",";",",","(","[","{",">"].include?(char) && j >= 0
629
- focus_world = "#{char}#{focus_world}"
630
- j=j-1
631
- char = focus_segment[j..j]
632
- end
633
- focus_world
634
- end
635
705
 
636
706
  def candidates(_show_error = false)
707
+ super
637
708
  temp_file = create_modified_temp_file(@editor.file)
638
709
  begin
639
710
  Arcadia.is_windows??ruby='rubyw':ruby=Arcadia.ruby
640
- _cmp_s = "|#{ruby} '#{temp_file}'"
711
+ _cmp_s = "|#{ruby} '#{temp_file}' 2>&1"
641
712
  _ret = nil
642
- open(_cmp_s,"r") do |f|
643
- _ret = f.readlines.collect!{| line |
644
- #line.chomp
645
- line.strip
646
- }
713
+ onlyw = []
714
+ begin
715
+ open(_cmp_s,"r") do |f|
716
+ _ret = f.readlines.collect!{| line |
717
+ #line.chomp
718
+ anlyl = line.split('#')[1]
719
+ onlyw << anlyl.strip if anlyl
720
+ line.strip
721
+ }
722
+ end
723
+ rescue
724
+ _ret = []
725
+ end
726
+ if _ret.include?(':ARCADIA_CC_ERROR')
727
+ _ret = []
647
728
  end
648
729
  if @filter.strip.length > 0 && !is_dot?
649
730
  @words.each{|w|
650
- if !(_ret.include?(w) || _ret.include?("##{w}"))
731
+ if !(onlyw.include?(w) || onlyw.include?("##{w}"))
732
+ _ret << w
733
+ end
734
+ }
735
+ end
736
+ if !is_dot?
737
+ RESERVED_WORDS.each{|w|
738
+ if !onlyw.include?(w) && !@words.include?(w)
651
739
  _ret << w
652
740
  end
653
741
  }
@@ -663,8 +751,8 @@ class SafeCompleteCode
663
751
 
664
752
  def create_modified_temp_file(_base_file=nil)
665
753
  if _base_file
666
- File.basename(_base_file)
667
- _file = File.join(File.dirname(_base_file),'~~'+File.basename(_base_file))
754
+ # _file = File.join(File.dirname(_base_file),'~~'+File.basename(_base_file))
755
+ _file = File.join(Arcadia.instance.local_dir,'~~'+File.basename(_base_file))
668
756
  else
669
757
  _file = File.join(Arcadia.instance.local_dir,'~~buffer')
670
758
  end
@@ -1023,8 +1111,6 @@ class AgEditorOutline
1023
1111
  # workaround on windows
1024
1112
  @tree_exp.delete(@tree_exp.nodes('root'))
1025
1113
  end
1026
-
1027
-
1028
1114
  _txt = @editor.text.get('1.0','end')
1029
1115
  if @editor.has_ctags?
1030
1116
  if @editor.file && !@editor.modified?
@@ -1303,7 +1389,12 @@ class AgEditor
1303
1389
  @do_complete = @do_complete && @controller.accept_complete_code
1304
1390
  if @do_complete
1305
1391
  line, col = @text.index('insert').split('.')
1306
- mss = SafeCompleteCode.new(self, line.to_i, col.to_i)
1392
+ case @lang
1393
+ when 'ruby'
1394
+ mss = RubyCompleteCode.new(self, line.to_i, col.to_i)
1395
+ else
1396
+ mss = CompleteCode.new(self, line.to_i, col.to_i)
1397
+ end
1307
1398
  candidates = mss.candidates
1308
1399
  raise_complete_code(candidates, line.to_s, col.to_s, mss.filter) if candidates && candidates.length > 0
1309
1400
  end
@@ -1364,20 +1455,21 @@ class AgEditor
1364
1455
  extra_len = 0
1365
1456
  end
1366
1457
  if _filter.length > 0
1367
- begin_index_for_delete = "insert - #{_filter.length}chars"
1458
+ begin_index_for_complete = @text.index("insert - #{_filter.length}chars")
1368
1459
  else
1369
- for_delete = @text.get(_begin_index,"insert")
1370
- if for_delete && ['.','(','[','{','=','<','!','>'].include?(for_delete.strip[-1..-1])
1371
- begin_index_for_delete = "insert"
1372
- elsif for_delete && for_delete.include?('.')
1373
- begin_index_for_delete = "insert - #{for_delete.split('.')[-1].length}chars"
1460
+ processing_string = @text.get(_begin_index,"insert")
1461
+ if processing_string && ['.','(','[','{','=','<','!','>'].include?(processing_string.strip[-1..-1])
1462
+ begin_index_for_complete = @text.index("insert")
1463
+ elsif processing_string && processing_string.include?('.')
1464
+ begin_index_for_complete = @text.index("insert - #{processing_string.split('.')[-1].length}chars")
1374
1465
  else
1375
- begin_index_for_delete = _begin_index
1466
+ begin_index_for_complete = _begin_index
1376
1467
  end
1377
1468
  end
1378
1469
 
1379
1470
  if _candidates.length >= 1
1380
- _rx, _ry, _width, heigth = @text.bbox(_begin_index);
1471
+ #_rx, _ry, _width, heigth = @text.bbox(_begin_index);
1472
+ _rx, _ry, _width, heigth = @text.bbox(begin_index_for_complete);
1381
1473
  _x = _rx + TkWinfo.rootx(@text)
1382
1474
  _y = _ry + TkWinfo.rooty(@text) + @font_metrics[2][1]
1383
1475
  _xroot = _x - TkWinfo.rootx(Arcadia.instance.layout.root)
@@ -1446,8 +1538,7 @@ class AgEditor
1446
1538
  @raised_listbox_frame.destroy
1447
1539
  #_menu.destroy
1448
1540
  @text.focus
1449
- @text.delete(begin_index_for_delete,'insert')
1450
-
1541
+ @text.delete("#{begin_index_for_complete} wordstart",'insert')
1451
1542
  # workaround for @ char
1452
1543
  _value = _value.strip
1453
1544
  if _value[0..0] !=_target[0..0] && _value[1..1] == _target[0..0]
@@ -1488,7 +1579,8 @@ class AgEditor
1488
1579
  _height = 15*_char_height
1489
1580
  _height = _max_height if _height > _max_height
1490
1581
 
1491
- _buffer = @text.get(_begin_index, 'insert')
1582
+ #_buffer = @text.get(_begin_index, 'insert')
1583
+ _buffer = @text.get(begin_index_for_complete, 'insert')
1492
1584
  _buffer_ini_length = _buffer.length
1493
1585
  @raised_listbox_frame.place('x'=>_xroot,'y'=>_yroot, 'width'=>_width, 'height'=>_height)
1494
1586
  @raised_listbox.extend(TkScrollableWidget).show(0,0)
@@ -1518,11 +1610,13 @@ class AgEditor
1518
1610
  _insert_selected_value.call
1519
1611
  end
1520
1612
  Tk.callback_break
1521
- when 'A'..'Z','equal','greater'
1613
+ when 'A'..'Z','equal','greater','underscore'
1522
1614
  if e.keysym == 'equal'
1523
1615
  ch = '='
1524
1616
  elsif e.keysym == 'greater'
1525
1617
  ch = '>'
1618
+ elsif e.keysym == 'underscore'
1619
+ ch = '_'
1526
1620
  else
1527
1621
  ch = e.keysym
1528
1622
  end
@@ -1567,11 +1661,13 @@ class AgEditor
1567
1661
  Tk.callback_break
1568
1662
  when 'BackSpace'
1569
1663
  if _buffer.length > _buffer_ini_length
1570
- @text.delete("#{_begin_index} + #{_buffer.length-1} chars" ,'insert')
1571
- _buffer = _buffer[0..-2]
1572
- Tk.update
1573
- _update_list.call(_buffer)
1574
- Tk.callback_break
1664
+ if @text.index('insert').split('.')[0] == _row
1665
+ @text.delete("insert -1 chars" ,'insert')
1666
+ end
1667
+ _buffer = _buffer[0..-2]
1668
+ Tk.update
1669
+ _update_list.call(_buffer)
1670
+ Tk.callback_break
1575
1671
  end
1576
1672
  when 'Next', 'Prior'
1577
1673
  else
@@ -1585,7 +1681,7 @@ class AgEditor
1585
1681
  end
1586
1682
  }
1587
1683
  elsif _candidates.length == 1 && _candidates[0].length>0
1588
- @text.delete(begin_index_for_delete,'insert');
1684
+ @text.delete(begin_index_for_complete,'insert');
1589
1685
  @text.insert('insert',_candidates[0].split[0])
1590
1686
  complete_code_end
1591
1687
  end
@@ -1616,30 +1712,31 @@ class AgEditor
1616
1712
  @do_complete = false
1617
1713
  end
1618
1714
  }
1619
-
1620
- @text.bind_append("KeyRelease"){|e|
1621
- case e.keysym
1622
- when 'period'
1623
- _focus_line = @text.get('insert linestart','insert')
1624
- if _focus_line.strip[0..0] != '#'
1625
- Thread.new do
1626
- @do_complete = true
1627
- sleep(1)
1628
- if @do_complete && @n_complete_task == 0
1629
- complete_code
1715
+ case @lang
1716
+ when 'ruby'
1717
+ @text.bind_append("KeyRelease"){|e|
1718
+ case e.keysym
1719
+ when 'period'
1720
+ _focus_line = @text.get('insert linestart','insert')
1721
+ if _focus_line.strip[0..0] != '#'
1722
+ Thread.new do
1723
+ @do_complete = true
1724
+ sleep(1)
1725
+ if @do_complete && @n_complete_task == 0
1726
+ complete_code
1727
+ end
1728
+ end
1630
1729
  end
1631
- end
1632
1730
  end
1633
- end
1634
- }
1635
-
1731
+ }
1732
+ end
1636
1733
  end
1637
1734
 
1638
1735
  #
1639
1736
  # setup all key bindings (normal, +control, etc)
1640
1737
  #
1641
1738
  def activate_key_binding
1642
- activate_complete_code_key_binding if @is_ruby
1739
+ activate_complete_code_key_binding #if @is_ruby
1643
1740
 
1644
1741
  @text.bind_append("Control-KeyPress"){|e|
1645
1742
  case e.keysym
@@ -3626,13 +3723,30 @@ class AgMultiEditorView
3626
3723
  end
3627
3724
  end
3628
3725
 
3726
+ def add_menu_button(_name, _buffer_string)
3727
+ @buffer_menu_button = @frame.root.add_menu_button(
3728
+ _name, 'files', nil, 'right',
3729
+ {'relief'=>:flat,
3730
+ 'borderwidth'=>1,
3731
+ 'compound'=> 'left',
3732
+ 'anchor'=>'w',
3733
+ 'font'=> "#{Arcadia.conf('titlelabel.font')} italic",
3734
+ 'activebackground'=>Arcadia.conf('titlelabel.background'),
3735
+ 'foreground' => Arcadia.conf('titlecontext.foreground'),
3736
+ 'textvariable'=> _buffer_string
3737
+ }
3738
+ )
3739
+ end
3740
+
3629
3741
  def page_bind(_event, _proc)
3630
3742
  @page_binds[_event] = _proc
3631
3743
  if @usetabs
3632
3744
  @enb.tabbind_append("Button-3",_proc)
3633
3745
  @frame.root.top_text_bind_remove("Button-3")
3746
+ @buffer_menu_button.bind_remove("Button-3") if @buffer_menu_button
3634
3747
  else
3635
- @frame.root.top_text_bind_append("Button-3", _proc)
3748
+ @frame.root.top_text_bind_append("Button-3", _proc)
3749
+ @buffer_menu_button.bind_append("Button-3", _proc) if @buffer_menu_button
3636
3750
  end
3637
3751
  end
3638
3752
 
@@ -3708,7 +3822,8 @@ class HighlightScanner
3708
3822
 
3709
3823
  def initialize(_langs_conf)
3710
3824
  @langs_conf = _langs_conf
3711
- @lang=@langs_conf['language'].to_sym if @langs_conf['language']
3825
+ #@lang=@langs_conf['language'].to_sym if @langs_conf['language']
3826
+ @lang=@langs_conf['language'] if @langs_conf['language']
3712
3827
  end
3713
3828
 
3714
3829
  def highlight_tags(_row_begin,_code)
@@ -4097,11 +4212,6 @@ class AgMultiEditor < ArcadiaExtPlus
4097
4212
  @main_frame = AgMultiEditorView.new(self, self.frame, @usetabs)
4098
4213
  @@outline_bar = AgEditorOutlineToolbar.new(self) if !defined?(@@outline_bar)
4099
4214
  create_find # this is the "find within current file" one
4100
- begin
4101
- pop_up_menu
4102
- rescue RuntimeError => e
4103
- Arcadia.runtime_error(e)
4104
- end
4105
4215
  frame.root.add_button(
4106
4216
  self.name,
4107
4217
  'Close current',
@@ -4113,20 +4223,25 @@ class AgMultiEditor < ArcadiaExtPlus
4113
4223
  @buffer_string.value = ''
4114
4224
  # @buffer_string = ''
4115
4225
  @buffer_number.value = 0
4116
- @buffer_menu_button = frame.root.add_menu_button(
4117
- # self.name, 'files', DOCUMENT_COMBO_GIF, 'right',
4118
- self.name, 'files', nil, 'right',
4119
- # {'relief'=>:raised, 'borderwidth'=>1, 'compound'=> 'left','anchor'=>'w', 'textvariable'=> @buffer_string, 'width'=>40})
4120
- {'relief'=>:flat,
4121
- 'borderwidth'=>1,
4122
- 'compound'=> 'left',
4123
- 'anchor'=>'w',
4124
- 'font'=> "#{Arcadia.conf('titlelabel.font')} italic",
4125
- 'activebackground'=>Arcadia.conf('titlelabel.background'),
4126
- 'foreground' => Arcadia.conf('titlecontext.foreground'),
4127
- 'textvariable'=> @buffer_string
4128
- #'text'=> @buffer_string
4129
- })
4226
+ @buffer_menu_button = @main_frame.add_menu_button(self.name, @buffer_string)
4227
+
4228
+ begin
4229
+ pop_up_menu
4230
+ rescue RuntimeError => e
4231
+ Arcadia.runtime_error(e)
4232
+ end
4233
+
4234
+ # @buffer_menu_button = frame.root.add_menu_button(
4235
+ # self.name, 'files', nil, 'right',
4236
+ # {'relief'=>:flat,
4237
+ # 'borderwidth'=>1,
4238
+ # 'compound'=> 'left',
4239
+ # 'anchor'=>'w',
4240
+ # 'font'=> "#{Arcadia.conf('titlelabel.font')} italic",
4241
+ # 'activebackground'=>Arcadia.conf('titlelabel.background'),
4242
+ # 'foreground' => Arcadia.conf('titlecontext.foreground'),
4243
+ # 'textvariable'=> @buffer_string
4244
+ # })
4130
4245
  @buffer_menu = @buffer_menu_button.cget('menu')
4131
4246
  @buffer_menu_button.pack('fill'=>'x', 'expand'=>'true', 'side'=> 'left','anchor'=> 'w')
4132
4247
  # TkWinfo.parent(TkWinfo.parent(@buffer_menu_button).frame).pack('fill'=>'x', 'expand'=>'true', 'side'=> 'right','anchor'=> 'w')
@@ -5848,14 +5963,14 @@ class Finder < Findview
5848
5963
  @controller = _controller
5849
5964
  @forwards = true
5850
5965
  @find_action = proc{
5851
- do_find_next
5852
5966
  hide
5967
+ do_find_next
5853
5968
  }
5854
5969
  @b_go.bind('1', @find_action)
5855
5970
 
5856
- @b_replace.bind('1', proc{do_replace})
5971
+ @b_replace.bind('1', proc{hide; do_replace})
5857
5972
 
5858
- @b_replace_all.bind('1', proc{do_replace_all})
5973
+ @b_replace_all.bind('1', proc{hide; do_replace_all})
5859
5974
 
5860
5975
  @e_what_entry.bind_append('KeyRelease'){|e|
5861
5976
  case e.keysym
@@ -5888,8 +6003,8 @@ class Finder < Findview
5888
6003
 
5889
6004
  def do_replace
5890
6005
  if do_find_next
5891
- _message = Arcadia.text('ext.editor.search.d.replace.msg'[@e_what.value, @e_with.value])
5892
- if TkDialog2.new('message'=>_message, 'buttons'=>['Yes','No']).show() == 0
6006
+ _message = Arcadia.text('ext.editor.search.d.replace.msg', [@e_what.value, @e_with.value])
6007
+ if Arcadia.hinner_dialog(self, 'type'=>'yes_no', 'msg'=> _message, 'title' => "Replace", 'level' => 'question')=='yes'
5893
6008
  self.editor.text.delete(@idx1,@idx2)
5894
6009
  self.editor.text.insert(@idx1,@e_with.value)
5895
6010
  self.editor.check_modify
@@ -5898,14 +6013,21 @@ class Finder < Findview
5898
6013
  end
5899
6014
 
5900
6015
  def do_replace_all
6016
+ show_dialog = true
6017
+ founds = []
5901
6018
  while do_find_next
5902
- _message = Arcadia.text('ext.editor.search.d.replace.msg'[@e_what.value, @e_with.value])
5903
- _rc = TkDialog2.new('message'=>_message, 'buttons'=>['Yes','No','Annulla']).show()
5904
- if _rc == 0
6019
+ break if founds.include?(@idx1)
6020
+ founds << @idx1
6021
+ if show_dialog
6022
+ _message = Arcadia.text('ext.editor.search.d.replace.msg', [@e_what.value, @e_with.value])
6023
+ _rc = Arcadia.hinner_dialog(self, 'type'=>'yes_yesall_no_cancel', 'msg'=> _message, 'title' => "Replace", 'level' => 'question')
6024
+ end
6025
+ if _rc == 'yes' || _rc == 'yesall'
5905
6026
  self.editor.text.delete(@idx1,@idx2)
5906
6027
  self.editor.text.insert(@idx1,@e_with.value)
5907
6028
  self.editor.check_modify
5908
- elsif _rc == 2
6029
+ show_dialog = _rc != 'yesall'
6030
+ elsif _rc == 'cancel'
5909
6031
  break
5910
6032
  end
5911
6033
  end
@@ -6017,7 +6139,9 @@ class Finder < Findview
6017
6139
  @controller.chrono_bookmark_add(self.editor.file, _index)
6018
6140
  else
6019
6141
  _message = '"'+@e_what.value+'" not found'
6020
- TkDialog2.new('message'=>_message, 'buttons'=>['Ok']).show()
6142
+ Arcadia.hinner_dialog(self, 'type'=>'ok', 'msg'=> _message)
6143
+
6144
+ # TkDialog2.new('message'=>_message, 'buttons'=>['Ok']).show()
6021
6145
  end
6022
6146
 
6023
6147
  else