From 2d20fc39aaa3a3e48f25cbb95f38f54fe2bcdd9f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Verschelde?= Date: Sun, 26 Jan 2020 16:01:49 +0100 Subject: doc: Drop unused 'category' property from header We already removed it from the online docs with #35132. Currently it can only be "Built-In Types" (Variant types) or "Core" (everything else), which is of limited use. We might also want to consider dropping it from `ClassDB` altogether in Godot 4.0. --- editor/doc/doc_data.cpp | 13 ++++--------- editor/doc/doc_dump.cpp | 8 +++----- 2 files changed, 7 insertions(+), 14 deletions(-) (limited to 'editor/doc') diff --git a/editor/doc/doc_data.cpp b/editor/doc/doc_data.cpp index 26970446f5..4f90517936 100644 --- a/editor/doc/doc_data.cpp +++ b/editor/doc/doc_data.cpp @@ -251,7 +251,6 @@ void DocData::generate(bool p_basic_types) { ClassDoc &c = class_list[cname]; c.name = cname; c.inherits = ClassDB::get_parent_class(name); - c.category = ClassDB::get_category(name); List properties; List own_properties; @@ -536,7 +535,6 @@ void DocData::generate(bool p_basic_types) { class_list[cname] = ClassDoc(); ClassDoc &c = class_list[cname]; c.name = cname; - c.category = "Built-In Types"; Variant::CallError cerror; Variant v = Variant::construct(Variant::Type(i), NULL, 0, cerror); @@ -853,8 +851,6 @@ Error DocData::_load(Ref parser) { c.name = name; if (parser->has_attribute("inherits")) c.inherits = parser->get_attribute_value("inherits"); - if (parser->has_attribute("category")) - c.category = parser->get_attribute_value("category"); while (parser->read() == OK) { @@ -1044,25 +1040,24 @@ Error DocData::save_classes(const String &p_default_path, const Map"); _write_string(f, 2, c.brief_description.strip_edges().xml_escape()); _write_string(f, 1, ""); + _write_string(f, 1, ""); _write_string(f, 2, c.description.strip_edges().xml_escape()); _write_string(f, 1, ""); + _write_string(f, 1, ""); for (int i = 0; i < c.tutorials.size(); i++) { _write_string(f, 2, "" + c.tutorials.get(i).xml_escape() + ""); } _write_string(f, 1, ""); + _write_string(f, 1, ""); c.methods.sort(); diff --git a/editor/doc/doc_dump.cpp b/editor/doc/doc_dump.cpp index edb1a536c3..d7e1d257f2 100644 --- a/editor/doc/doc_dump.cpp +++ b/editor/doc/doc_dump.cpp @@ -93,16 +93,14 @@ void DocDump::dump(const String &p_file) { String inherits = ClassDB::get_parent_class(name); if (inherits != "") header += " inherits=\"" + inherits + "\""; - String category = ClassDB::get_category(name); - if (category == "") - category = "Core"; - header += " category=\"" + category + "\""; - header += ">"; _write_string(f, 0, header); + _write_string(f, 1, ""); _write_string(f, 1, ""); + _write_string(f, 1, ""); _write_string(f, 1, ""); + _write_string(f, 1, ""); List method_list; -- cgit v1.2.3