Added section titles that spell out which files the code and layout go in.

I got a little lost working through this example because I made an incorrect assumption about the filename needed for controller.kv. The goal to this change is to draw more attention to the filename and keep future users from making the same mistake.
This commit is contained in:
EdTheDev 2012-10-02 21:19:42 -05:00
parent 54dd5f5ada
commit 4fb4ceab69
1 changed files with 6 additions and 0 deletions

View File

@ -6,6 +6,9 @@
Designing with the Kivy Language
================================
The code goes in main.py
~~~~~~~~~~~~~~~~~~~~~~~~
Let's start with a little example. First, the Python file named `main.py`:
.. include:: ../../../examples/guide/designwithkv/main.py
@ -20,6 +23,9 @@ In addition, we are creating a ``do_action()`` method, that will use both of
these properties. It will change the ``info`` text, and change text in the
``label_wid`` widget.
The layout goes in controller.kv
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Executing this application without a corresponding `.kv` file will work, but
nothing will be shown on the screen. This is expected, because the
``Controller`` class has no widgets in it, it's just a ``FloatLayout``. We can