summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorreduz <juan@okamstudio.com>2015-12-26 10:25:17 -0300
committerreduz <juan@okamstudio.com>2015-12-26 10:25:17 -0300
commit13964f59c1359473980916ea1f930fef1c28331a (patch)
tree4f6abe95e9762e9b566d65e32e8cf38b13b9cd6b /tools
parentb989d4f887b6c823850e92ab7c5d47311de59b9d (diff)
-Added table support to RichTextLabel
-Made help more readable, closes #2851
Diffstat (limited to 'tools')
-rw-r--r--tools/editor/editor_help.cpp22
1 files changed, 18 insertions, 4 deletions
diff --git a/tools/editor/editor_help.cpp b/tools/editor/editor_help.cpp
index a5a3890129..1905ab731f 100644
--- a/tools/editor/editor_help.cpp
+++ b/tools/editor/editor_help.cpp
@@ -690,16 +690,28 @@ Error EditorHelp::_goto_desc(const String& p_class,int p_vscr) {
class_desc->pop();
//class_desc->add_newline();
- class_desc->add_newline();
+// class_desc->add_newline();
class_desc->push_indent(1);
+ class_desc->push_table(2);
+ class_desc->set_table_column_expand(1,1);
for(int i=0;i<cd.methods.size();i++) {
+ class_desc->push_cell();
+
+
method_line[cd.methods[i].name]=class_desc->get_line_count()-2; //gets overriden if description
+ class_desc->push_align(RichTextLabel::ALIGN_RIGHT);
class_desc->push_font(doc_code_font);
_add_type(cd.methods[i].return_type);
- class_desc->add_text(" ");
+ //class_desc->add_text(" ");
+ class_desc->pop(); //align
+ class_desc->pop(); //font
+ class_desc->pop(); //cell
+ class_desc->push_cell();
+ class_desc->push_font(doc_code_font);
+
if (cd.methods[i].description!="") {
method_descr=true;
class_desc->push_meta("@"+cd.methods[i].name);
@@ -742,12 +754,14 @@ Error EditorHelp::_goto_desc(const String& p_class,int p_vscr) {
}
class_desc->pop();//monofont
- class_desc->add_newline();
+// class_desc->add_newline();
+ class_desc->pop(); //cell
}
-
+ class_desc->pop(); //table
class_desc->pop();
class_desc->add_newline();
+ class_desc->add_newline();
}