TextEdit.xml 27 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732
  1. <?xml version="1.0" encoding="UTF-8" ?>
  2. <class name="TextEdit" inherits="Control" version="3.3">
  3. <brief_description>
  4. Multiline text editing control.
  5. </brief_description>
  6. <description>
  7. TextEdit is meant for editing large, multiline text. It also has facilities for editing code, such as syntax highlighting support and multiple levels of undo/redo.
  8. </description>
  9. <tutorials>
  10. </tutorials>
  11. <methods>
  12. <method name="add_color_region">
  13. <return type="void">
  14. </return>
  15. <argument index="0" name="begin_key" type="String">
  16. </argument>
  17. <argument index="1" name="end_key" type="String">
  18. </argument>
  19. <argument index="2" name="color" type="Color">
  20. </argument>
  21. <argument index="3" name="line_only" type="bool" default="false">
  22. </argument>
  23. <description>
  24. Adds color region (given the delimiters) and its colors.
  25. </description>
  26. </method>
  27. <method name="add_keyword_color">
  28. <return type="void">
  29. </return>
  30. <argument index="0" name="keyword" type="String">
  31. </argument>
  32. <argument index="1" name="color" type="Color">
  33. </argument>
  34. <description>
  35. Adds a [code]keyword[/code] and its [Color].
  36. </description>
  37. </method>
  38. <method name="can_fold" qualifiers="const">
  39. <return type="bool">
  40. </return>
  41. <argument index="0" name="line" type="int">
  42. </argument>
  43. <description>
  44. Returns if the given line is foldable, that is, it has indented lines right below it.
  45. </description>
  46. </method>
  47. <method name="center_viewport_to_cursor">
  48. <return type="void">
  49. </return>
  50. <description>
  51. Centers the viewport on the line the editing cursor is at. This also resets the [member scroll_horizontal] value to [code]0[/code].
  52. </description>
  53. </method>
  54. <method name="clear_colors">
  55. <return type="void">
  56. </return>
  57. <description>
  58. Clears all custom syntax coloring information previously added with [method add_color_region] or [method add_keyword_color].
  59. </description>
  60. </method>
  61. <method name="clear_undo_history">
  62. <return type="void">
  63. </return>
  64. <description>
  65. Clears the undo history.
  66. </description>
  67. </method>
  68. <method name="copy">
  69. <return type="void">
  70. </return>
  71. <description>
  72. Copy's the current text selection.
  73. </description>
  74. </method>
  75. <method name="cursor_get_column" qualifiers="const">
  76. <return type="int">
  77. </return>
  78. <description>
  79. Returns the column the editing cursor is at.
  80. </description>
  81. </method>
  82. <method name="cursor_get_line" qualifiers="const">
  83. <return type="int">
  84. </return>
  85. <description>
  86. Returns the line the editing cursor is at.
  87. </description>
  88. </method>
  89. <method name="cursor_set_column">
  90. <return type="void">
  91. </return>
  92. <argument index="0" name="column" type="int">
  93. </argument>
  94. <argument index="1" name="adjust_viewport" type="bool" default="true">
  95. </argument>
  96. <description>
  97. Moves the cursor at the specified [code]column[/code] index.
  98. If [code]adjust_viewport[/code] is set to [code]true[/code], the viewport will center at the cursor position after the move occurs.
  99. </description>
  100. </method>
  101. <method name="cursor_set_line">
  102. <return type="void">
  103. </return>
  104. <argument index="0" name="line" type="int">
  105. </argument>
  106. <argument index="1" name="adjust_viewport" type="bool" default="true">
  107. </argument>
  108. <argument index="2" name="can_be_hidden" type="bool" default="true">
  109. </argument>
  110. <argument index="3" name="wrap_index" type="int" default="0">
  111. </argument>
  112. <description>
  113. Moves the cursor at the specified [code]line[/code] index.
  114. If [code]adjust_viewport[/code] is set to [code]true[/code], the viewport will center at the cursor position after the move occurs.
  115. If [code]can_be_hidden[/code] is set to [code]true[/code], the specified [code]line[/code] can be hidden using [method set_line_as_hidden].
  116. </description>
  117. </method>
  118. <method name="cut">
  119. <return type="void">
  120. </return>
  121. <description>
  122. Cut's the current selection.
  123. </description>
  124. </method>
  125. <method name="deselect">
  126. <return type="void">
  127. </return>
  128. <description>
  129. Deselects the current selection.
  130. </description>
  131. </method>
  132. <method name="fold_all_lines">
  133. <return type="void">
  134. </return>
  135. <description>
  136. Folds all lines that are possible to be folded (see [method can_fold]).
  137. </description>
  138. </method>
  139. <method name="fold_line">
  140. <return type="void">
  141. </return>
  142. <argument index="0" name="line" type="int">
  143. </argument>
  144. <description>
  145. Folds the given line, if possible (see [method can_fold]).
  146. </description>
  147. </method>
  148. <method name="get_breakpoints" qualifiers="const">
  149. <return type="Array">
  150. </return>
  151. <description>
  152. Returns an array containing the line number of each breakpoint.
  153. </description>
  154. </method>
  155. <method name="get_keyword_color" qualifiers="const">
  156. <return type="Color">
  157. </return>
  158. <argument index="0" name="keyword" type="String">
  159. </argument>
  160. <description>
  161. Returns the [Color] of the specified [code]keyword[/code].
  162. </description>
  163. </method>
  164. <method name="get_line" qualifiers="const">
  165. <return type="String">
  166. </return>
  167. <argument index="0" name="line" type="int">
  168. </argument>
  169. <description>
  170. Returns the text of a specific line.
  171. </description>
  172. </method>
  173. <method name="get_line_count" qualifiers="const">
  174. <return type="int">
  175. </return>
  176. <description>
  177. Returns the amount of total lines in the text.
  178. </description>
  179. </method>
  180. <method name="get_menu" qualifiers="const">
  181. <return type="PopupMenu">
  182. </return>
  183. <description>
  184. Returns the [PopupMenu] of this [TextEdit]. By default, this menu is displayed when right-clicking on the [TextEdit].
  185. </description>
  186. </method>
  187. <method name="get_selection_from_column" qualifiers="const">
  188. <return type="int">
  189. </return>
  190. <description>
  191. Returns the selection begin column.
  192. </description>
  193. </method>
  194. <method name="get_selection_from_line" qualifiers="const">
  195. <return type="int">
  196. </return>
  197. <description>
  198. Returns the selection begin line.
  199. </description>
  200. </method>
  201. <method name="get_selection_text" qualifiers="const">
  202. <return type="String">
  203. </return>
  204. <description>
  205. Returns the text inside the selection.
  206. </description>
  207. </method>
  208. <method name="get_selection_to_column" qualifiers="const">
  209. <return type="int">
  210. </return>
  211. <description>
  212. Returns the selection end column.
  213. </description>
  214. </method>
  215. <method name="get_selection_to_line" qualifiers="const">
  216. <return type="int">
  217. </return>
  218. <description>
  219. Returns the selection end line.
  220. </description>
  221. </method>
  222. <method name="get_word_under_cursor" qualifiers="const">
  223. <return type="String">
  224. </return>
  225. <description>
  226. Returns a [String] text with the word under the caret (text cursor) location.
  227. </description>
  228. </method>
  229. <method name="has_keyword_color" qualifiers="const">
  230. <return type="bool">
  231. </return>
  232. <argument index="0" name="keyword" type="String">
  233. </argument>
  234. <description>
  235. Returns whether the specified [code]keyword[/code] has a color set to it or not.
  236. </description>
  237. </method>
  238. <method name="insert_text_at_cursor">
  239. <return type="void">
  240. </return>
  241. <argument index="0" name="text" type="String">
  242. </argument>
  243. <description>
  244. Insert the specified text at the cursor position.
  245. </description>
  246. </method>
  247. <method name="is_folded" qualifiers="const">
  248. <return type="bool">
  249. </return>
  250. <argument index="0" name="line" type="int">
  251. </argument>
  252. <description>
  253. Returns whether the line at the specified index is folded or not.
  254. </description>
  255. </method>
  256. <method name="is_line_hidden" qualifiers="const">
  257. <return type="bool">
  258. </return>
  259. <argument index="0" name="line" type="int">
  260. </argument>
  261. <description>
  262. Returns whether the line at the specified index is hidden or not.
  263. </description>
  264. </method>
  265. <method name="is_line_set_as_bookmark" qualifiers="const">
  266. <return type="bool">
  267. </return>
  268. <argument index="0" name="line" type="int">
  269. </argument>
  270. <description>
  271. Returns [code]true[/code] when the specified [code]line[/code] is bookmarked.
  272. </description>
  273. </method>
  274. <method name="is_line_set_as_breakpoint" qualifiers="const">
  275. <return type="bool">
  276. </return>
  277. <argument index="0" name="line" type="int">
  278. </argument>
  279. <description>
  280. Returns [code]true[/code] when the specified [code]line[/code] has a breakpoint.
  281. </description>
  282. </method>
  283. <method name="is_line_set_as_safe" qualifiers="const">
  284. <return type="bool">
  285. </return>
  286. <argument index="0" name="line" type="int">
  287. </argument>
  288. <description>
  289. Returns [code]true[/code] when the specified [code]line[/code] is marked as safe.
  290. </description>
  291. </method>
  292. <method name="is_selection_active" qualifiers="const">
  293. <return type="bool">
  294. </return>
  295. <description>
  296. Returns [code]true[/code] if the selection is active.
  297. </description>
  298. </method>
  299. <method name="menu_option">
  300. <return type="void">
  301. </return>
  302. <argument index="0" name="option" type="int">
  303. </argument>
  304. <description>
  305. Triggers a right-click menu action by the specified index. See [enum MenuItems] for a list of available indexes.
  306. </description>
  307. </method>
  308. <method name="paste">
  309. <return type="void">
  310. </return>
  311. <description>
  312. Paste the current selection.
  313. </description>
  314. </method>
  315. <method name="redo">
  316. <return type="void">
  317. </return>
  318. <description>
  319. Perform redo operation.
  320. </description>
  321. </method>
  322. <method name="remove_breakpoints">
  323. <return type="void">
  324. </return>
  325. <description>
  326. Removes all the breakpoints. This will not fire the [signal breakpoint_toggled] signal.
  327. </description>
  328. </method>
  329. <method name="search" qualifiers="const">
  330. <return type="PoolIntArray">
  331. </return>
  332. <argument index="0" name="key" type="String">
  333. </argument>
  334. <argument index="1" name="flags" type="int">
  335. </argument>
  336. <argument index="2" name="from_line" type="int">
  337. </argument>
  338. <argument index="3" name="from_column" type="int">
  339. </argument>
  340. <description>
  341. Perform a search inside the text. Search flags can be specified in the [enum SearchFlags] enum.
  342. Returns an empty [code]PoolIntArray[/code] if no result was found. Otherwise, the result line and column can be accessed at indices specified in the [enum SearchResult] enum, e.g:
  343. [codeblock]
  344. var result = search(key, flags, line, column)
  345. if result.size() &gt; 0:
  346. # Result found.
  347. var res_line = result[TextEdit.SEARCH_RESULT_LINE]
  348. var res_column = result[TextEdit.SEARCH_RESULT_COLUMN]
  349. [/codeblock]
  350. </description>
  351. </method>
  352. <method name="select">
  353. <return type="void">
  354. </return>
  355. <argument index="0" name="from_line" type="int">
  356. </argument>
  357. <argument index="1" name="from_column" type="int">
  358. </argument>
  359. <argument index="2" name="to_line" type="int">
  360. </argument>
  361. <argument index="3" name="to_column" type="int">
  362. </argument>
  363. <description>
  364. Perform selection, from line/column to line/column.
  365. If [member selecting_enabled] is [code]false[/code], no selection will occur.
  366. </description>
  367. </method>
  368. <method name="select_all">
  369. <return type="void">
  370. </return>
  371. <description>
  372. Select all the text.
  373. If [member selecting_enabled] is [code]false[/code], no selection will occur.
  374. </description>
  375. </method>
  376. <method name="set_line">
  377. <return type="void">
  378. </return>
  379. <argument index="0" name="line" type="int">
  380. </argument>
  381. <argument index="1" name="new_text" type="String">
  382. </argument>
  383. <description>
  384. Sets the text for a specific line.
  385. </description>
  386. </method>
  387. <method name="set_line_as_bookmark">
  388. <return type="void">
  389. </return>
  390. <argument index="0" name="line" type="int">
  391. </argument>
  392. <argument index="1" name="bookmark" type="bool">
  393. </argument>
  394. <description>
  395. Bookmarks the [code]line[/code] if [code]bookmark[/code] is true. Deletes the bookmark if [code]bookmark[/code] is false.
  396. Bookmarks are shown in the [member breakpoint_gutter].
  397. </description>
  398. </method>
  399. <method name="set_line_as_breakpoint">
  400. <return type="void">
  401. </return>
  402. <argument index="0" name="line" type="int">
  403. </argument>
  404. <argument index="1" name="breakpoint" type="bool">
  405. </argument>
  406. <description>
  407. Adds or removes the breakpoint in [code]line[/code]. Breakpoints are shown in the [member breakpoint_gutter].
  408. </description>
  409. </method>
  410. <method name="set_line_as_hidden">
  411. <return type="void">
  412. </return>
  413. <argument index="0" name="line" type="int">
  414. </argument>
  415. <argument index="1" name="enable" type="bool">
  416. </argument>
  417. <description>
  418. If [code]true[/code], hides the line of the specified index.
  419. </description>
  420. </method>
  421. <method name="set_line_as_safe">
  422. <return type="void">
  423. </return>
  424. <argument index="0" name="line" type="int">
  425. </argument>
  426. <argument index="1" name="safe" type="bool">
  427. </argument>
  428. <description>
  429. If [code]true[/code], marks the [code]line[/code] as safe.
  430. This will show the line number with the color provided in the [code]safe_line_number_color[/code] theme property.
  431. </description>
  432. </method>
  433. <method name="toggle_fold_line">
  434. <return type="void">
  435. </return>
  436. <argument index="0" name="line" type="int">
  437. </argument>
  438. <description>
  439. Toggle the folding of the code block at the given line.
  440. </description>
  441. </method>
  442. <method name="undo">
  443. <return type="void">
  444. </return>
  445. <description>
  446. Perform undo operation.
  447. </description>
  448. </method>
  449. <method name="unfold_line">
  450. <return type="void">
  451. </return>
  452. <argument index="0" name="line" type="int">
  453. </argument>
  454. <description>
  455. Unfolds the given line, if folded.
  456. </description>
  457. </method>
  458. <method name="unhide_all_lines">
  459. <return type="void">
  460. </return>
  461. <description>
  462. Unhide all lines that were previously set to hidden by [method set_line_as_hidden].
  463. </description>
  464. </method>
  465. </methods>
  466. <members>
  467. <member name="breakpoint_gutter" type="bool" setter="set_breakpoint_gutter_enabled" getter="is_breakpoint_gutter_enabled" default="false">
  468. If [code]true[/code], the breakpoint gutter is visible.
  469. </member>
  470. <member name="caret_blink" type="bool" setter="cursor_set_blink_enabled" getter="cursor_get_blink_enabled" default="false">
  471. If [code]true[/code], the caret (visual cursor) blinks.
  472. </member>
  473. <member name="caret_blink_speed" type="float" setter="cursor_set_blink_speed" getter="cursor_get_blink_speed" default="0.65">
  474. Duration (in seconds) of a caret's blinking cycle.
  475. </member>
  476. <member name="caret_block_mode" type="bool" setter="cursor_set_block_mode" getter="cursor_is_block_mode" default="false">
  477. If [code]true[/code], the caret displays as a rectangle.
  478. If [code]false[/code], the caret displays as a bar.
  479. </member>
  480. <member name="caret_moving_by_right_click" type="bool" setter="set_right_click_moves_caret" getter="is_right_click_moving_caret" default="true">
  481. If [code]true[/code], a right-click moves the cursor at the mouse position before displaying the context menu.
  482. If [code]false[/code], the context menu disregards mouse location.
  483. </member>
  484. <member name="context_menu_enabled" type="bool" setter="set_context_menu_enabled" getter="is_context_menu_enabled" default="true">
  485. If [code]true[/code], a right-click displays the context menu.
  486. </member>
  487. <member name="draw_spaces" type="bool" setter="set_draw_spaces" getter="is_drawing_spaces" default="false">
  488. If [code]true[/code], the "space" character will have a visible representation.
  489. </member>
  490. <member name="draw_tabs" type="bool" setter="set_draw_tabs" getter="is_drawing_tabs" default="false">
  491. If [code]true[/code], the "tab" character will have a visible representation.
  492. </member>
  493. <member name="focus_mode" type="int" setter="set_focus_mode" getter="get_focus_mode" override="true" enum="Control.FocusMode" default="2" />
  494. <member name="fold_gutter" type="bool" setter="set_draw_fold_gutter" getter="is_drawing_fold_gutter" default="false">
  495. If [code]true[/code], the fold gutter is visible. This enables folding groups of indented lines.
  496. </member>
  497. <member name="hiding_enabled" type="bool" setter="set_hiding_enabled" getter="is_hiding_enabled" default="false">
  498. If [code]true[/code], all lines that have been set to hidden by [method set_line_as_hidden], will not be visible.
  499. </member>
  500. <member name="highlight_all_occurrences" type="bool" setter="set_highlight_all_occurrences" getter="is_highlight_all_occurrences_enabled" default="false">
  501. If [code]true[/code], all occurrences of the selected text will be highlighted.
  502. </member>
  503. <member name="highlight_current_line" type="bool" setter="set_highlight_current_line" getter="is_highlight_current_line_enabled" default="false">
  504. If [code]true[/code], the line containing the cursor is highlighted.
  505. </member>
  506. <member name="minimap_draw" type="bool" setter="draw_minimap" getter="is_drawing_minimap" default="false">
  507. If [code]true[/code], a minimap is shown, providing an outline of your source code.
  508. </member>
  509. <member name="minimap_width" type="int" setter="set_minimap_width" getter="get_minimap_width" default="80">
  510. The width, in pixels, of the minimap.
  511. </member>
  512. <member name="mouse_default_cursor_shape" type="int" setter="set_default_cursor_shape" getter="get_default_cursor_shape" override="true" enum="Control.CursorShape" default="1" />
  513. <member name="override_selected_font_color" type="bool" setter="set_override_selected_font_color" getter="is_overriding_selected_font_color" default="false">
  514. If [code]true[/code], custom [code]font_color_selected[/code] will be used for selected text.
  515. </member>
  516. <member name="readonly" type="bool" setter="set_readonly" getter="is_readonly" default="false">
  517. If [code]true[/code], read-only mode is enabled. Existing text cannot be modified and new text cannot be added.
  518. </member>
  519. <member name="scroll_horizontal" type="int" setter="set_h_scroll" getter="get_h_scroll" default="0">
  520. The current horizontal scroll value.
  521. </member>
  522. <member name="scroll_vertical" type="float" setter="set_v_scroll" getter="get_v_scroll" default="0.0">
  523. The current vertical scroll value.
  524. </member>
  525. <member name="selecting_enabled" type="bool" setter="set_selecting_enabled" getter="is_selecting_enabled" default="true">
  526. If [code]true[/code], text can be selected.
  527. If [code]false[/code], text can not be selected by the user or by the [method select] or [method select_all] methods.
  528. </member>
  529. <member name="shortcut_keys_enabled" type="bool" setter="set_shortcut_keys_enabled" getter="is_shortcut_keys_enabled" default="true">
  530. If [code]true[/code], shortcut keys for context menu items are enabled, even if the context menu is disabled.
  531. </member>
  532. <member name="show_line_numbers" type="bool" setter="set_show_line_numbers" getter="is_show_line_numbers_enabled" default="false">
  533. If [code]true[/code], line numbers are displayed to the left of the text.
  534. </member>
  535. <member name="smooth_scrolling" type="bool" setter="set_smooth_scroll_enable" getter="is_smooth_scroll_enabled" default="false">
  536. If [code]true[/code], sets the [code]step[/code] of the scrollbars to [code]0.25[/code] which results in smoother scrolling.
  537. </member>
  538. <member name="syntax_highlighting" type="bool" setter="set_syntax_coloring" getter="is_syntax_coloring_enabled" default="false">
  539. If [code]true[/code], any custom color properties that have been set for this [TextEdit] will be visible.
  540. </member>
  541. <member name="text" type="String" setter="set_text" getter="get_text" default="&quot;&quot;">
  542. String value of the [TextEdit].
  543. </member>
  544. <member name="v_scroll_speed" type="float" setter="set_v_scroll_speed" getter="get_v_scroll_speed" default="80.0">
  545. Vertical scroll sensitivity.
  546. </member>
  547. <member name="virtual_keyboard_enabled" type="bool" setter="set_virtual_keyboard_enabled" getter="is_virtual_keyboard_enabled" default="true">
  548. If [code]true[/code], the native virtual keyboard is shown when focused on platforms that support it.
  549. </member>
  550. <member name="wrap_enabled" type="bool" setter="set_wrap_enabled" getter="is_wrap_enabled" default="false">
  551. If [code]true[/code], enables text wrapping when it goes beyond the edge of what is visible.
  552. </member>
  553. </members>
  554. <signals>
  555. <signal name="breakpoint_toggled">
  556. <argument index="0" name="row" type="int">
  557. </argument>
  558. <description>
  559. Emitted when a breakpoint is placed via the breakpoint gutter.
  560. </description>
  561. </signal>
  562. <signal name="cursor_changed">
  563. <description>
  564. Emitted when the cursor changes.
  565. </description>
  566. </signal>
  567. <signal name="info_clicked">
  568. <argument index="0" name="row" type="int">
  569. </argument>
  570. <argument index="1" name="info" type="String">
  571. </argument>
  572. <description>
  573. Emitted when the info icon is clicked.
  574. </description>
  575. </signal>
  576. <signal name="request_completion">
  577. <description>
  578. </description>
  579. </signal>
  580. <signal name="symbol_lookup">
  581. <argument index="0" name="symbol" type="String">
  582. </argument>
  583. <argument index="1" name="row" type="int">
  584. </argument>
  585. <argument index="2" name="column" type="int">
  586. </argument>
  587. <description>
  588. </description>
  589. </signal>
  590. <signal name="text_changed">
  591. <description>
  592. Emitted when the text changes.
  593. </description>
  594. </signal>
  595. </signals>
  596. <constants>
  597. <constant name="SEARCH_MATCH_CASE" value="1" enum="SearchFlags">
  598. Match case when searching.
  599. </constant>
  600. <constant name="SEARCH_WHOLE_WORDS" value="2" enum="SearchFlags">
  601. Match whole words when searching.
  602. </constant>
  603. <constant name="SEARCH_BACKWARDS" value="4" enum="SearchFlags">
  604. Search from end to beginning.
  605. </constant>
  606. <constant name="SEARCH_RESULT_COLUMN" value="0" enum="SearchResult">
  607. Used to access the result column from [method search].
  608. </constant>
  609. <constant name="SEARCH_RESULT_LINE" value="1" enum="SearchResult">
  610. Used to access the result line from [method search].
  611. </constant>
  612. <constant name="MENU_CUT" value="0" enum="MenuItems">
  613. Cuts (copies and clears) the selected text.
  614. </constant>
  615. <constant name="MENU_COPY" value="1" enum="MenuItems">
  616. Copies the selected text.
  617. </constant>
  618. <constant name="MENU_PASTE" value="2" enum="MenuItems">
  619. Pastes the clipboard text over the selected text (or at the cursor's position).
  620. </constant>
  621. <constant name="MENU_CLEAR" value="3" enum="MenuItems">
  622. Erases the whole [TextEdit] text.
  623. </constant>
  624. <constant name="MENU_SELECT_ALL" value="4" enum="MenuItems">
  625. Selects the whole [TextEdit] text.
  626. </constant>
  627. <constant name="MENU_UNDO" value="5" enum="MenuItems">
  628. Undoes the previous action.
  629. </constant>
  630. <constant name="MENU_REDO" value="6" enum="MenuItems">
  631. Redoes the previous action.
  632. </constant>
  633. <constant name="MENU_MAX" value="7" enum="MenuItems">
  634. Represents the size of the [enum MenuItems] enum.
  635. </constant>
  636. </constants>
  637. <theme_items>
  638. <theme_item name="background_color" type="Color" default="Color( 0, 0, 0, 0 )">
  639. Sets the background [Color] of this [TextEdit]. [member syntax_highlighting] has to be enabled.
  640. </theme_item>
  641. <theme_item name="bookmark_color" type="Color" default="Color( 0.08, 0.49, 0.98, 1 )">
  642. Sets the [Color] of the bookmark marker. [member syntax_highlighting] has to be enabled.
  643. </theme_item>
  644. <theme_item name="brace_mismatch_color" type="Color" default="Color( 1, 0.2, 0.2, 1 )">
  645. </theme_item>
  646. <theme_item name="breakpoint_color" type="Color" default="Color( 0.8, 0.8, 0.4, 0.2 )">
  647. Sets the [Color] of the breakpoints. [member breakpoint_gutter] has to be enabled.
  648. </theme_item>
  649. <theme_item name="caret_background_color" type="Color" default="Color( 0, 0, 0, 1 )">
  650. </theme_item>
  651. <theme_item name="caret_color" type="Color" default="Color( 0.88, 0.88, 0.88, 1 )">
  652. </theme_item>
  653. <theme_item name="code_folding_color" type="Color" default="Color( 0.8, 0.8, 0.8, 0.8 )">
  654. </theme_item>
  655. <theme_item name="completion" type="StyleBox">
  656. </theme_item>
  657. <theme_item name="completion_background_color" type="Color" default="Color( 0.17, 0.16, 0.2, 1 )">
  658. </theme_item>
  659. <theme_item name="completion_existing_color" type="Color" default="Color( 0.87, 0.87, 0.87, 0.13 )">
  660. </theme_item>
  661. <theme_item name="completion_font_color" type="Color" default="Color( 0.67, 0.67, 0.67, 1 )">
  662. </theme_item>
  663. <theme_item name="completion_lines" type="int" default="7">
  664. </theme_item>
  665. <theme_item name="completion_max_width" type="int" default="50">
  666. </theme_item>
  667. <theme_item name="completion_scroll_color" type="Color" default="Color( 1, 1, 1, 1 )">
  668. </theme_item>
  669. <theme_item name="completion_scroll_width" type="int" default="3">
  670. </theme_item>
  671. <theme_item name="completion_selected_color" type="Color" default="Color( 0.26, 0.26, 0.27, 1 )">
  672. </theme_item>
  673. <theme_item name="current_line_color" type="Color" default="Color( 0.25, 0.25, 0.26, 0.8 )">
  674. Sets the [Color] of the breakpoints. [member breakpoint_gutter] has to be enabled.
  675. </theme_item>
  676. <theme_item name="executing_line_color" type="Color" default="Color( 0.2, 0.8, 0.2, 0.4 )">
  677. </theme_item>
  678. <theme_item name="focus" type="StyleBox">
  679. </theme_item>
  680. <theme_item name="fold" type="Texture">
  681. </theme_item>
  682. <theme_item name="folded" type="Texture">
  683. </theme_item>
  684. <theme_item name="font" type="Font">
  685. Sets the default [Font].
  686. </theme_item>
  687. <theme_item name="font_color" type="Color" default="Color( 0.88, 0.88, 0.88, 1 )">
  688. Sets the font [Color].
  689. </theme_item>
  690. <theme_item name="font_color_readonly" type="Color" default="Color( 0.88, 0.88, 0.88, 0.5 )">
  691. </theme_item>
  692. <theme_item name="font_color_selected" type="Color" default="Color( 0, 0, 0, 1 )">
  693. Sets the [Color] of the selected text. [member override_selected_font_color] has to be enabled.
  694. </theme_item>
  695. <theme_item name="function_color" type="Color" default="Color( 0.4, 0.64, 0.81, 1 )">
  696. </theme_item>
  697. <theme_item name="line_number_color" type="Color" default="Color( 0.67, 0.67, 0.67, 0.4 )">
  698. Sets the [Color] of the line numbers. [member show_line_numbers] has to be enabled.
  699. </theme_item>
  700. <theme_item name="line_spacing" type="int" default="4">
  701. Sets the spacing between the lines.
  702. </theme_item>
  703. <theme_item name="mark_color" type="Color" default="Color( 1, 0.4, 0.4, 0.4 )">
  704. Sets the [Color] of marked text.
  705. </theme_item>
  706. <theme_item name="member_variable_color" type="Color" default="Color( 0.9, 0.31, 0.35, 1 )">
  707. </theme_item>
  708. <theme_item name="normal" type="StyleBox">
  709. Sets the [StyleBox] of this [TextEdit].
  710. </theme_item>
  711. <theme_item name="number_color" type="Color" default="Color( 0.92, 0.58, 0.2, 1 )">
  712. </theme_item>
  713. <theme_item name="read_only" type="StyleBox">
  714. Sets the [StyleBox] of this [TextEdit] when [member readonly] is enabled.
  715. </theme_item>
  716. <theme_item name="safe_line_number_color" type="Color" default="Color( 0.67, 0.78, 0.67, 0.6 )">
  717. </theme_item>
  718. <theme_item name="selection_color" type="Color" default="Color( 0.49, 0.49, 0.49, 1 )">
  719. Sets the highlight [Color] of text selections.
  720. </theme_item>
  721. <theme_item name="space" type="Texture">
  722. </theme_item>
  723. <theme_item name="symbol_color" type="Color" default="Color( 0.94, 0.94, 0.94, 1 )">
  724. </theme_item>
  725. <theme_item name="tab" type="Texture">
  726. Sets a custom [Texture] for tab text characters.
  727. </theme_item>
  728. <theme_item name="word_highlighted_color" type="Color" default="Color( 0.8, 0.9, 0.9, 0.15 )">
  729. Sets the highlight [Color] of multiple occurrences. [member highlight_all_occurrences] has to be enabled.
  730. </theme_item>
  731. </theme_items>
  732. </class>