Proofing/review: Remove filler words, adhere to style guide

This commit is contained in:
mhilbrunner
2018-05-06 05:23:37 +02:00
parent 9f526a3ea8
commit f215a0cf26
88 changed files with 337 additions and 374 deletions
+2 -2
View File
@@ -258,7 +258,7 @@ Note that the ``get_import_options`` method receives the preset number, so you
can configure the options for each different preset (especially the default
value). In this example we use the ``match`` statement, but if you have lots of
options and the presets only change the value you may want to create the array
of options first and then just change it based on the preset.
of options first and then change it based on the preset.
.. warning:: The ``get_import_options`` method is called even if you don't
define presets (by making ``get_preset_count`` return zero). You
@@ -396,7 +396,7 @@ in a different file:
Trying the plugin
-----------------
This has been very theoretical, but now that the import plugin is done, let's
This has been theoretical, but now that the import plugin is done, let's
test it. Make sure you created the sample file (with the contents described in
the introduction section) and save it as ``test.mtxt``. Then activate the plugin
in the Project Settings.
+6 -6
View File
@@ -187,14 +187,14 @@ Don't forget to add a text to your button.
Save this scene as ``my_dock.tscn``.
Now you need to grab that scene you just created and add it as a dock in the
Now you need to grab that scene you created and add it as a dock in the
editor. For this you can rely on the function
:ref:`add_control_to_dock() <class_EditorPlugin_add_control_to_dock>` from the
:ref:`EditorPlugin <class_EditorPlugin>` class.
The code is very straightforward, you just need to select a dock position to
The code is straightforward, you need to select a dock position to
add it and have a control to add (which is the scene you just created). It is
also very important that you remember to **remove the dock** when the plugin is
also important that you remember to **remove the dock** when the plugin is
deactivated. The code can be like this::
tool
@@ -230,10 +230,10 @@ corner.
.. image:: img/making_plugins-project_settings.png
At the *Status* column, you can see that the plugin is inactive. So you just
At the *Status* column, you can see that the plugin is inactive. So you
need to click on the status to select *Active*. The dock should be immediately
visible, even before you close the settings window. And now, lo and behold, you
have a custom dock! In just a bit of coding and a simple scene.
visible, even before you close the settings window. You should
have a custom dock:
.. image:: img/making_plugins-custom_dock.png
@@ -36,7 +36,7 @@ Before we start you'll need a few things.
2) A C compiler
3) A copy of this repository: https://github.com/GodotNativeTools/godot_headers
The first two pretty much speak for themselves. On Linux, you'll likely have a C compiler, on macOS, it's easiest to just install Xcode from the Mac App Store and, on Windows, we've tested this with both MSVC 2015 and 2017.
The first two pretty much speak for themselves. On Linux, you'll likely have a C compiler, on macOS, it's easiest to install Xcode from the Mac App Store and, on Windows, we've tested this with both MSVC 2015 and 2017.
For number 3, we suggest that you create a folder somewhere that you use to store your code, open up a terminal and CD into that folder. Then execute:
@@ -70,7 +70,7 @@ Let's start by writing our main code. Ideally, we want to end up with a file str
Open up Godot and create a new project called simple. This will create the simple folder and project.godot file. Then manually create a bin and src subfolder in this folder.
We're going to start by having a look at what our simple.c file contains. Now, for our example here we're making a single C source file without a header just to keep things simple. Once you start writing bigger projects it is advisable you break your project up into multiple files. That however falls outside of the scope of this tutorial.
We're going to start by having a look at what our simple.c file contains. Now, for our example here we're making a single C source file without a header to keep things simple. Once you start writing bigger projects it is advisable you break your project up into multiple files. That however falls outside of the scope of this tutorial.
We'll be looking at the source code bit by bit so all the parts below should all be put together into one big file. I'll explain each section as we add it.