You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-17 14:11:06 +00:00
Bring that Whole New World to the Old Continent too
Applies the clang-format style to the 2.1 branch as done for master in
5dbf1809c6.
This commit is contained in:
@@ -30,24 +30,23 @@
|
||||
#define EDITOR_HELP_H
|
||||
|
||||
#include "editor/editor_plugin.h"
|
||||
#include "scene/gui/menu_button.h"
|
||||
#include "scene/gui/panel_container.h"
|
||||
#include "scene/gui/rich_text_label.h"
|
||||
#include "scene/gui/split_container.h"
|
||||
#include "scene/gui/tab_container.h"
|
||||
#include "scene/gui/text_edit.h"
|
||||
#include "scene/gui/split_container.h"
|
||||
#include "scene/gui/menu_button.h"
|
||||
#include "scene/gui/rich_text_label.h"
|
||||
#include "scene/gui/panel_container.h"
|
||||
#include "scene/gui/tree.h"
|
||||
|
||||
#include "scene/main/timer.h"
|
||||
#include "editor/code_editor.h"
|
||||
#include "editor/doc/doc_data.h"
|
||||
|
||||
#include "scene/main/timer.h"
|
||||
|
||||
class EditorNode;
|
||||
|
||||
class EditorHelpSearch : public ConfirmationDialog {
|
||||
|
||||
OBJ_TYPE(EditorHelpSearch,ConfirmationDialog )
|
||||
OBJ_TYPE(EditorHelpSearch, ConfirmationDialog)
|
||||
|
||||
EditorNode *editor;
|
||||
LineEdit *search_box;
|
||||
@@ -56,56 +55,51 @@ class EditorHelpSearch : public ConfirmationDialog {
|
||||
|
||||
void _update_search();
|
||||
|
||||
void _sbox_input(const InputEvent& p_ie);
|
||||
void _sbox_input(const InputEvent &p_ie);
|
||||
|
||||
void _confirmed();
|
||||
void _text_changed(const String& p_newtext);
|
||||
|
||||
void _text_changed(const String &p_newtext);
|
||||
|
||||
protected:
|
||||
|
||||
void _notification(int p_what);
|
||||
static void _bind_methods();
|
||||
public:
|
||||
|
||||
public:
|
||||
void popup();
|
||||
void popup(const String& p_term);
|
||||
void popup(const String &p_term);
|
||||
|
||||
EditorHelpSearch();
|
||||
};
|
||||
|
||||
class EditorHelpIndex : public ConfirmationDialog {
|
||||
OBJ_TYPE( EditorHelpIndex, ConfirmationDialog );
|
||||
OBJ_TYPE(EditorHelpIndex, ConfirmationDialog);
|
||||
|
||||
LineEdit *search_box;
|
||||
Tree *class_list;
|
||||
HashMap<String,TreeItem*> tree_item_map;
|
||||
HashMap<String, TreeItem *> tree_item_map;
|
||||
|
||||
void _tree_item_selected();
|
||||
void _text_changed(const String& p_text);
|
||||
void _sbox_input(const InputEvent& p_ie);
|
||||
void _text_changed(const String &p_text);
|
||||
void _sbox_input(const InputEvent &p_ie);
|
||||
|
||||
void _update_class_list();
|
||||
|
||||
void add_type(const String& p_type,HashMap<String,TreeItem*>& p_types,TreeItem *p_root);
|
||||
protected:
|
||||
void add_type(const String &p_type, HashMap<String, TreeItem *> &p_types, TreeItem *p_root);
|
||||
|
||||
protected:
|
||||
void _notification(int p_what);
|
||||
static void _bind_methods();
|
||||
|
||||
public:
|
||||
|
||||
void select_class(const String& p_class);
|
||||
void select_class(const String &p_class);
|
||||
|
||||
void popup();
|
||||
|
||||
EditorHelpIndex();
|
||||
};
|
||||
|
||||
|
||||
class EditorHelp : public VBoxContainer {
|
||||
OBJ_TYPE( EditorHelp, VBoxContainer );
|
||||
|
||||
OBJ_TYPE(EditorHelp, VBoxContainer);
|
||||
|
||||
enum Page {
|
||||
|
||||
@@ -118,7 +112,6 @@ class EditorHelp : public VBoxContainer {
|
||||
|
||||
};
|
||||
|
||||
|
||||
bool select_locked;
|
||||
|
||||
String prev_search;
|
||||
@@ -126,63 +119,55 @@ class EditorHelp : public VBoxContainer {
|
||||
String edited_class;
|
||||
|
||||
EditorNode *editor;
|
||||
Map<String,int> method_line;
|
||||
Map<String,int> signal_line;
|
||||
Map<String,int> property_line;
|
||||
Map<String,int> theme_property_line;
|
||||
Map<String,int> constant_line;
|
||||
Map<String, int> method_line;
|
||||
Map<String, int> signal_line;
|
||||
Map<String, int> property_line;
|
||||
Map<String, int> theme_property_line;
|
||||
Map<String, int> constant_line;
|
||||
int description_line;
|
||||
|
||||
|
||||
RichTextLabel *class_desc;
|
||||
HSplitContainer *h_split;
|
||||
static DocData *doc;
|
||||
|
||||
|
||||
ConfirmationDialog *search_dialog;
|
||||
LineEdit *search;
|
||||
|
||||
|
||||
String base_path;
|
||||
|
||||
void _help_callback(const String &p_topic);
|
||||
|
||||
void _help_callback(const String& p_topic);
|
||||
|
||||
void _add_text(const String& p_text);
|
||||
void _add_text(const String &p_text);
|
||||
bool scroll_locked;
|
||||
|
||||
//void _button_pressed(int p_idx);
|
||||
void _add_type(const String& p_type);
|
||||
void _add_type(const String &p_type);
|
||||
|
||||
void _scroll_changed(double p_scroll);
|
||||
void _class_list_select(const String& p_select);
|
||||
void _class_desc_select(const String& p_select);
|
||||
void _class_desc_input(const InputEvent& p_input);
|
||||
void _class_list_select(const String &p_select);
|
||||
void _class_desc_select(const String &p_select);
|
||||
void _class_desc_input(const InputEvent &p_input);
|
||||
|
||||
Error _goto_desc(const String& p_class, int p_vscr=-1);
|
||||
Error _goto_desc(const String &p_class, int p_vscr = -1);
|
||||
//void _update_history_buttons();
|
||||
void _update_doc();
|
||||
|
||||
void _request_help(const String& p_string);
|
||||
void _search(const String& p_str);
|
||||
void _request_help(const String &p_string);
|
||||
void _search(const String &p_str);
|
||||
void _search_cbk();
|
||||
|
||||
void _unhandled_key_input(const InputEvent& p_ev);
|
||||
|
||||
|
||||
void _unhandled_key_input(const InputEvent &p_ev);
|
||||
|
||||
protected:
|
||||
|
||||
|
||||
void _notification(int p_what);
|
||||
static void _bind_methods();
|
||||
public:
|
||||
|
||||
public:
|
||||
static void generate_doc();
|
||||
static DocData *get_doc_data() { return doc; }
|
||||
|
||||
void go_to_help(const String& p_help);
|
||||
void go_to_class(const String& p_class,int p_scroll=0);
|
||||
void go_to_help(const String &p_help);
|
||||
void go_to_class(const String &p_class, int p_scroll = 0);
|
||||
|
||||
void popup_search();
|
||||
void search_again();
|
||||
@@ -198,24 +183,20 @@ public:
|
||||
~EditorHelp();
|
||||
};
|
||||
|
||||
|
||||
|
||||
class EditorHelpBit : public Panel {
|
||||
|
||||
OBJ_TYPE( EditorHelpBit, Panel);
|
||||
OBJ_TYPE(EditorHelpBit, Panel);
|
||||
|
||||
RichTextLabel *rich_text;
|
||||
void _go_to_help(String p_what);
|
||||
void _meta_clicked(String p_what);
|
||||
|
||||
|
||||
protected:
|
||||
|
||||
static void _bind_methods();
|
||||
void _notification(int p_what);
|
||||
public:
|
||||
|
||||
void set_text(const String& p_text);
|
||||
public:
|
||||
void set_text(const String &p_text);
|
||||
EditorHelpBit();
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user