You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Aug 31, 2021. It is now read-only.
Copy file name to clipboardExpand all lines: Toolset/palettes/tutorial/courses/First Run/tutorials/Hello World/lessons/App Lesson.txt
+32-83Lines changed: 32 additions & 83 deletions
Original file line number
Diff line number
Diff line change
@@ -5,19 +5,6 @@ prologue
5
5
show you how to create a simple 'Hello World' app.
6
6
end prologue
7
7
8
-
step "Tutorial Intro I"
9
-
In creating this app you will learn:
10
-
11
-
- How to build the user interface(UI) of an app by dragging and dropping objects
12
-
13
-
- The basics of coding in LiveCode to add user interactivity to your app
14
-
15
-
- How to use the features of the LiveCode Integrated Development Environment (IDE)
16
-
action
17
-
interlude
18
-
go to step "Tutorials Intro"
19
-
end step
20
-
21
8
step "Tutorials Intro"
22
9
You can keep track of how much of the tutorial you have completed
23
10
with this progress bar, and exit the tutorial at any time by
@@ -28,7 +15,7 @@ step "Tutorials Intro"
28
15
idea about something or don't want to have to create every last
29
16
part of the user interface, for example.
30
17
31
-
The tutorial will also help you out by disabling the parts of the IDE you
18
+
The tutorial will also help you out by disabling any options you
32
19
don't need for the current step.
33
20
action
34
21
interlude
@@ -39,27 +26,17 @@ end step
39
26
skip point
40
27
41
28
step "Stack Interlude"
42
-
In this first section of the tutorial, we will create the User
43
-
Interface (UI) for the Hello World app.
44
-
45
-
The first step in creating a LiveCode application is creating a
46
-
stack. A stack is the canvas for your app. Every window you see in LiveCode
47
-
is a stack.
29
+
We start by creating the User Interface (UI) for the Hello World app.
48
30
49
-
In this tutorial we will create our stack at the default size.
50
-
action
51
-
interlude
52
-
go to step "Create Mainstack"
53
-
end step
31
+
The first step is to create a new LiveCode app at the default size.
54
32
55
-
step "Create Mainstack"
56
-
Click on the File menu, and select 'New Stack' → 'Default Size'.
33
+
Click on the File menu, and select 'New Stack' → 'Default Size'.
57
34
action
58
-
highlight menu item "Default Size" of menu item "New Stack" of menu "File"
59
-
capture the next new stack as "Mainstack"
60
-
capture the next new card of stack "Mainstack" as "HelloWorld"
61
-
wait until there is a stack "Mainstack"
62
-
go to step "Properties interlude"
35
+
highlight menu item "Default Size" of menu item "New Stack" of menu "File"
36
+
capture the next new stack as "Mainstack"
37
+
capture the next new card of stack "Mainstack" as "HelloWorld"
38
+
wait until there is a stack "Mainstack"
39
+
go to step "Properties interlude"
63
40
end step
64
41
65
42
skip point
@@ -72,35 +49,22 @@ step "Properties interlude"
72
49
The Property Inspector is a window that allows you to control these properties.
73
50
action
74
51
interlude
75
-
go to step "Set Stack Properties"
52
+
go to step "Set Stack Properties"
76
53
end step
77
54
78
55
step "Set Stack Properties"
79
-
Click on the Inspector icon on the toolbar to open the Property
56
+
Click on the 'Inspector' icon on the Toolbar to open the Property
80
57
Inspector.
81
58
action
82
59
highlight toolbar "Inspector"
83
60
wait until there is an inspector for stack "Mainstack"
84
-
go to step "Property Inspector Interlude"
85
-
end step
86
-
87
-
step "Property Inspector Interlude"
88
-
Properties of objects are grouped into sections. You can hover over
89
-
the icons at the top of the Property Inspector to see what each section is
90
-
called.
91
-
action
92
-
interlude
93
-
highlight inspector for stack "Mainstack"
94
61
go to step "Set Stack Title"
95
62
end step
96
63
97
-
skip point
98
-
99
64
step "Set Stack Title"
100
-
The first property we will set is the 'Title' of the stack. You will see the
101
-
title of the stack change after you set the property.
65
+
Set the 'Title' property of the stack to "Hello World" and press 'Enter'.
102
66
103
-
Set the 'Title' of the stack to "Hello World".
67
+
You will see the title of the stack change after you set the property.
104
68
action
105
69
highlight property "title" of section "basic"
106
70
wait until the title of stack "Mainstack" is "Hello World"
@@ -123,7 +87,7 @@ action
123
87
end step
124
88
125
89
step "Create Button"
126
-
The first object we will add is a button icon. Clicking on this button will
90
+
The first object we will add is a button. Clicking on this button will
127
91
show a message to the user.
128
92
129
93
Drag a button from the tools palette onto your stack.
@@ -144,23 +108,18 @@ action
144
108
end step
145
109
146
110
step "Open Property Inspector"
147
-
Next we need to set some properties of the button. Remember that properties
148
-
control how objects look and behave and can be set using the Property Inspector.
149
-
150
-
Click on the "Inspector" button in the toolbar to open the Property Inspector
111
+
Click on the 'Inspector' icon in the Toolbar to open the Property Inspector
151
112
for the button.
113
+
114
+
Remember that properties control how objects look and behave and can be set using the Property Inspector.
152
115
action
153
116
highlight toolbar "Inspector"
154
117
wait until there is an inspector for button "hello"
155
118
go to step "Set button name"
156
119
end step
157
120
158
121
step "Set button name"
159
-
The 'Name' property is what we use when we want to refer to objects in the code we write.
160
-
161
-
We want to use short, unique, descriptive names to make it easier when we start writing code.
162
-
163
-
Set the name property of the button to "Say Hello". You will see the Name appear on the button.
122
+
Set the 'Name' property of the button to "Say Hello" and press 'Enter'. You will see the Name appear on the button.
164
123
action
165
124
highlight property "name" of section "Basic"
166
125
wait until the name of button "Hello" is "Say Hello"
@@ -173,8 +132,7 @@ step "Events and messages interlude"
173
132
Now that the UI is complete the next stage is to add code to the app
174
133
to make it interactive.
175
134
176
-
LiveCode apps work by responding to 'messages', which are usually triggered by
177
-
some kind of user action. A message might tell the app that the user has
135
+
LiveCode apps work by responding to 'messages', which are usually triggered by some kind of user action. A message might tell the app that the user has
178
136
clicked on a button or typed in a field. You add code to tell the app what
179
137
to do when a message is received.
180
138
@@ -186,7 +144,7 @@ action
186
144
end step
187
145
188
146
step "Open Add Script"
189
-
Select the button and click the Code button in the Toolbar.
147
+
Select the button and click the 'Code' button in the Toolbar.
190
148
action
191
149
highlight toolbar "Code"
192
150
wait until there is a script editor for button "Hello"
0 commit comments