-
Book Overview & Buying
-
Table Of Contents
Tcl/Tk 8.5 Programming Cookbook
In this chapter, we will cover the following topics:
Creating a list
Joining two lists
Joining list elements
Appending list elements
Assigning list elements to variables
Retrieving an element from a list
Inserting elements into a list
Determining the number of elements
Getting a list element
Repeating elements
Replacing elements
Reversing elements
Searching a list
Editing a list
Sorting a list
Splitting a string into a list
Now that we have a firm grasp on the string type, let's look at the Tcl command list. As you might have discerned from the command name, this command is used to create and manage lists of information. While the various string handling commands allow for the creation of a string containing anything from a single character to larger text files, the list allows you to create, manipulate, and utilize a list of arguments in the same manner as a shopping list. In Tcl, each of the separate items in a list are referred to as elements...
Change the font size
Change margin width
Change background colour