ArticleslgStudy

computer science

LiveCode

LiveCode is a computer science topic covered in the lgStudy science library. This page brings together a partial reference excerpt, illustrations, worked examples, real-world applications and a short study plan, so you can understand LiveCode rather than just read about it. In short: LiveCode (formerly Revolution and MetaCard) is a cross-platform rapid application development runtime system inspired by HyperCard. It features the LiveCode Script (formerly MetaTalk) programming language which belongs to the family of xTalk scripting languages like HyperCard's HyperTalk.

Key takeaways

  • LiveCode belongs to computer science; place it in that map before memorising details.
  • Learn the definition first, then one example that makes the definition concrete.
  • Connect LiveCode to a quantity you can measure, compute or draw — that is where exam questions come from.
  • Reproduce the core statement of LiveCode from memory before moving on to harder problems.

Reference excerpt

LiveCode (formerly Revolution and MetaCard) is a cross-platform rapid application development runtime system inspired by HyperCard. It features the LiveCode Script (formerly MetaTalk) programming language which belongs to the family of xTalk scripting languages like HyperCard's HyperTalk. The environment was introduced in 2001. The "Revolution" development system was based on the MetaCard engine technology which Runtime Revolution later acquired from MetaCard Corporation in 2003. The platform won the Macworld Annual Editor's Choice Award for "Best Development Software" in 2004. "Revolution" was renamed "LiveCode" in the fall of 2010. "LiveCode" is developed and sold by Runtime Revolution Ltd., based in Edinburgh, Scotland. In March 2015, the company was renamed "LiveCode Ltd.", to unify the company name with the product. In April 2013, a free/open source version 'LiveCode Community Edition 6.0' was published after a successful crowdfunding campaign at Kickstarter. The code base was re-licensed and made available as free and open source software with a version in April 2013. LiveCode runs on iOS, Android, OS X, Windows 95 through Windows 10, Raspberry Pi and several variations of Unix, including Linux, Solaris, and BSD. It can be used for mobile, desktop and server/CGI applications. The iOS (iPhone and iPad) version was released in December 2010. The first version to deploy to the Web was released in 2009. It is the most widely used HyperCard/HyperTalk clone, and the only one that runs on all major operating systems. A developer release of v.8 was announced in New York on March 12, 2015. This major enhancement to the product includes a new, separate development language, known as "LiveCode Builder", which is capable of creating new object classes called "widgets". In earlier versions, the set of object classes was fixed, and could be enhanced only via the use of ordinary procedural languages such as C. The new language, which runs in its own IDE, is a departure from the transitional x-talk paradigm in that it permits typing of variables. But the two environments are fully integrated, and apart from the ability to create new objects, development in LiveCode proceeds in the normal way, within the established IDE. A second crowdfunding campaign to Bring HTML5 to LiveCode reached funding goals of nearly US$400,000 on July 31, 2014. LiveCode developer release 8.0 DP4 (August 31, 2015) was the first to include a standalone deployment option to HTML5. On 31 August 2021, starting with version 9.6.4, LiveCode Community edition, licensed under GPL, was discontinued.

Description The LiveCode software creates applications that run in many supported environments, using a compile-free workflow. The same computer code in LiveCode can play across multiple devices and platforms. LiveCode uses a high level, English-like programming language called Transcript that is dynamically typed. Transcript and compile-free workflow generates code that is self-documenting and easy for casual programmers to comprehend. For example, if the following script was executed when the system clock was at 9:00:00 AM:

Ten lines will be loaded into the first text field. (denoted as "field 1"), and seen as:

Hello world at 9:00:00 AM Hello world at 9:00:01 AM Hello world at 9:00:02 AM ...

Notes:

repeat (and the associated end repeat) is a control structure, illustrated here in just one of its various forms. put is a command "Hello World at" is a literal the long time is a function that calls the system time return is a constant equal to ASCII character 10 (linefeed) after is a keyword that is involved with a system known as "chunking", a hallmark of xTalk languages. field 1 is an object reference, here denoted by the layer number of a text field. Almost all standard object classes are supported, and may be referred to in several, highly-intuitive ways. LiveCode's natural English-like syntax is easy for beginners to learn. Variables are typeless, and are typed at compile time based purely on context. This makes the language simple to read and maintain, with relatively minimal loss of speed. The language contains advanced features including associative arrays, regular expressions, multimedia, support for a variety of SQL databases, and TCP/IP libraries. The LiveCode engine supports several common image formats (including BMP, PNG, GIF, and JPEG,), anti-aliased vector graphics, HTML-style text hyperlinks, chained behaviors and embedded web browsers. Accessing these higher-level functions is designed to be straightforward.

Examples To load the source code of a web page into a variable takes one line of code:

Uploading a file to an FTP server uses similar syntax:

Depth LiveCode has around 2,950 built-in language terms and keywords, which may be extended by external libraries written in C and other lower level languages.

Outcomes LiveCode project files are binary-compatible across platforms. They inherit each platform's look-and-feel and behaviors. Buttons, scroll bars, progress bars and menus behave as expected on the target platform without any intervention on the part of the one authoring a LiveCode application. Compiling a LiveCode "standalone" produces a single, executable file (minimum size ~1.5MB) for each platform targeted. There is no separate runtime necessary. The Wikipedia article on HyperCard contains a more detailed discussion about the basics of a similar development environment and scripting language. Modern LiveCode is a vast superset of the former HyperCard yet retains its simplicity. LiveCode includes a number of features missing from the original HyperCard program, including multiple platform deployment, communication with external devices and many fundamental language extensions. The LiveCode toolkit, as compared to HyperCard, has the ability to access internet-based text and media resources, which allows the creation of internet-enabled desktop applications.

Compatibility

iOS and Android targets are available in some versions. Note: Complete Linux requirements for 4.5.x–6.x are the following:

… excerpt ends here. Continue reading the full article.

Worked examples

Example 1 — a first encounter with LiveCode

Start with the simplest possible case. Write down what LiveCode claims or describes in one sentence, then invent the smallest concrete situation in which that sentence is true. In computer science, the smallest case is usually a single object, a single equation or a single measurement. Check that every symbol or term in your sentence has a meaning in that case.

Example 2 — changing one variable

Take the situation from Example 1 and change exactly one quantity: double it, halve it, or set it to zero. Predict what should happen to LiveCode before you calculate. Comparing your prediction with the result is the fastest way to find out whether you understand the idea or only the words.

Example 3 — an exam-style question

Typical questions about LiveCode ask you to (a) state it precisely, (b) apply it to given data, and (c) explain a limitation. Practise writing all three answers in under five minutes; the third part is what separates a full-mark answer from an average one.

Applications of LiveCode

In research
LiveCode appears in computer science research whenever the underlying quantities have to be modelled precisely. Papers usually cite it as a starting assumption and then explore where it breaks down.
In technology and industry
Engineering practice reuses LiveCode in design rules, simulations and safety margins. Knowing the idea lets you read a specification sheet and understand why the numbers look the way they do.
In the classroom
LiveCode is common in secondary-school and first-year university syllabi. It links to neighbouring topics 2001 software, Computing platforms, Cross-platform software, so understanding it makes those chapters shorter.
In everyday life
Look for LiveCode outside the textbook — in sport, cooking, traffic, electronics or the sky above you. An example you found yourself is remembered far longer than one you were given.
Ask Teacher Smith questions about this articleOpens your AI tutor with a question about “LiveCode” →

Affiliate

Preply — study more efficiently by working with a personal tutor. 50% off.

How to study LiveCode in 20 minutes

  1. Read the reference excerpt below once, without taking notes.
  2. Close the page and write down what LiveCode means in your own words.
  3. Compare your version with the excerpt and mark what you missed.
  4. Work through the three examples above with pen and paper.
  5. Explain LiveCode out loud to somebody else — or to Teacher Smith in the lgStudy chat.

Frequently asked questions

What is LiveCode in simple terms?

LiveCode (formerly Revolution and MetaCard) is a cross-platform rapid application development runtime system inspired by HyperCard. It features the LiveCode Script (formerly MetaTalk) programming language which belongs to the family of xTalk scripting languages like HyperCard's HyperTalk.

Why does LiveCode matter?

Because it connects several computer science ideas at once: it gives you a definition you can apply, a quantity you can calculate, and a way to check whether a result is plausible.

How should I study LiveCode?

Read the excerpt, restate it from memory, then work through the examples and applications listed on this page. The five-step study plan above takes about twenty minutes.

What does this page cover?

It gives you a compact reference excerpt plus original lgStudy explanations, examples, applications and study material on LiveCode.

Tags

  • 2001 software
  • Computing platforms
  • Cross-platform software
  • Formerly open-source or free software
  • Integrated development environments
  • Programming languages
  • Programming languages created in 2001
  • Scripting languages

Keep exploring