diff options
author | Juan Linietsky <reduzio@gmail.com> | 2017-01-04 01:16:14 -0300 |
---|---|---|
committer | Juan Linietsky <reduzio@gmail.com> | 2017-01-04 01:16:14 -0300 |
commit | b085c40edfac45ec1c8b866c789f6e9bab7e5e08 (patch) | |
tree | fb53cad5fcb37fcad404805fe7330d36fcd4e905 /tools/editor/io_plugins | |
parent | 3fae505128d5bfdeec42244820d0b85d0408f2b7 (diff) |
-Conversion of most properties to a simpler syntax, easier to use by script
-Modified help to display properties
GDScript can still not make use of them, though.
Diffstat (limited to 'tools/editor/io_plugins')
-rw-r--r-- | tools/editor/io_plugins/editor_font_import_plugin.cpp | 6 | ||||
-rw-r--r-- | tools/editor/io_plugins/editor_texture_import_plugin.cpp | 16 |
2 files changed, 11 insertions, 11 deletions
diff --git a/tools/editor/io_plugins/editor_font_import_plugin.cpp b/tools/editor/io_plugins/editor_font_import_plugin.cpp index 02990e9ed0..2bc29039ea 100644 --- a/tools/editor/io_plugins/editor_font_import_plugin.cpp +++ b/tools/editor/io_plugins/editor_font_import_plugin.cpp @@ -418,7 +418,7 @@ class EditorFontImportDialog : public ConfirmationDialog { //print_line("pre src path "+source->get_line_edit()->get_text()); //print_line("src path "+src_path); imd->add_source(src_path); - imd->set_option("font/size",font_size->get_val()); + imd->set_option("font/size",font_size->get_value()); return imd; @@ -619,7 +619,7 @@ public: } source->get_line_edit()->set_text(src); - font_size->set_val(rimd->get_option("font/size")); + font_size->set_value(rimd->get_option("font/size")); } } @@ -658,7 +658,7 @@ public: vbl->add_margin_child(TTR("Source Font Size:"),font_size); font_size->set_min(3); font_size->set_max(256); - font_size->set_val(16); + font_size->set_value(16); font_size->connect("value_changed",this,"_font_size_changed"); dest = memnew( EditorLineEditFileChooser ); // diff --git a/tools/editor/io_plugins/editor_texture_import_plugin.cpp b/tools/editor/io_plugins/editor_texture_import_plugin.cpp index 99ba208226..bab11d7a93 100644 --- a/tools/editor/io_plugins/editor_texture_import_plugin.cpp +++ b/tools/editor/io_plugins/editor_texture_import_plugin.cpp @@ -106,12 +106,12 @@ void EditorImportTextureOptions::set_flags(uint32_t p_flags){ void EditorImportTextureOptions::set_quality(float p_quality) { - quality->set_val(p_quality); + quality->set_value(p_quality); } float EditorImportTextureOptions::get_quality() const { - return quality->get_val(); + return quality->get_value(); } @@ -200,7 +200,7 @@ EditorImportTextureOptions::EditorImportTextureOptions() { hs->set_min(0); hs->set_max(1.0); hs->set_step(0.01); - hs->set_val(0.7); + hs->set_value(0.7); quality=hs; quality_vb->add_margin_child(TTR("Texture Compression Quality (WebP):"),quality_hb); @@ -396,7 +396,7 @@ void EditorTextureImportDialog::_import() { imd->set_option("flags",texture_options->get_flags()); imd->set_option("quality",texture_options->get_quality()); imd->set_option("atlas",true); - imd->set_option("atlas_size",int(size->get_val())); + imd->set_option("atlas_size",int(size->get_value())); imd->set_option("large",false); imd->set_option("crop",crop_source->is_pressed()); imd->set_option("mode",mode); @@ -430,7 +430,7 @@ void EditorTextureImportDialog::_import() { imd->set_option("quality",texture_options->get_quality()); imd->set_option("atlas",false); imd->set_option("large",true); - imd->set_option("large_cell_size",int(size->get_val())); + imd->set_option("large_cell_size",int(size->get_value())); imd->set_option("crop",crop_source->is_pressed()); imd->set_option("mode",mode); @@ -569,7 +569,7 @@ void EditorTextureImportDialog::_mode_changed(int p_mode) { if (p_mode==EditorTextureImportPlugin::MODE_ATLAS) { size_label->set_text(TTR("Max Texture Size:")); - size->set_val(2048); + size->set_value(2048); crop_source->show(); size_label->show(); size->show(); @@ -587,7 +587,7 @@ void EditorTextureImportDialog::_mode_changed(int p_mode) { if (p_mode==EditorTextureImportPlugin::MODE_LARGE) { size_label->set_text(TTR("Cell Size:")); - size->set_val(256); + size->set_value(256); size_label->show(); size->show(); @@ -727,7 +727,7 @@ EditorTextureImportDialog::EditorTextureImportDialog(EditorTextureImportPlugin* size->set_max(16384); - size->set_val(256); + size->set_value(256); size_mc=vbc->add_margin_child(TTR("Cell Size:"),size); size_label=vbc->get_child(size_mc->get_index()-1)->cast_to<Label>(); |