"What would you do with a brain if you had one?" -- Judy Garland, in The Wizard of Oz
Using WINMM.DLL - by Gordon Sweet
Liberty BASIC Default Variables - By John Richardson
Updating in LB - By John Richardson
Internet Corner - Downloading a File to Disk - By Alyce Watson
API Corner - Easy Font Manipulations - By Alyce Watson
Multiple Windows and Displays - by Gordon Sweet
Mapping Real World Coordinates to Screen Coordinates - by Tom Nally
Linear and Non-Linear Equation Systems - by Ingemar Bjerle
About Ingemar Bjerle - A "first person" account
Board the roller coaster on the left, kids! Make sure the restraining bar is in the locked position!
My friends, the [Scarecrow] received his brain in the nick of time! And can he put it to good use extracting goodies from Newsletter 112? Read below and see for yourself!
Gordon Sweet has an auspicious beginning as a contributor to the newsletter with Using WINMM.DLL. Did you think that the incorporation of midi voices into your Liberty BASIC games was beyond LB's capabilities? Well, "Ha, ha, ha" laugh I in a sinister voice! It's not beyond our capabilities at all. See Gordon's terrific article and demo program. With 128 different voices, there's gotta be one in there that you like!
Have you ever written an LB GUI program without using WindowHeight, WindowWidth, UpperLeftX and UpperLeftY? We can all agree that Carl deserves thanks for establishing these and other default variables for easy control of programs. And in this issue, John Richardson provides a very nice article in which each of Liberty BASIC's default variables is discussed. Nice job, John, collecting all of this information and presenting it in a single place.
John follows his nice discussion of LB's default variables with a second article. This one provides a procedure for using Liberty BASIC to download files from the internet. If we write an application good enough to have a user base, we may want to provide our users with periodic updates downloadable from the Web. In the body of John's article, he provides a skinable, mini wav player for which a user can download a new skin. Nice work there, John!
John Richardson's procedure for dowloading a web file relies heavily on a information borrowed from [Alyce Watson's web site]. Alyce's first of two articles, Downloading a File to Disk, provides additional details about the URLDownloadToFileA function resident within the required dll, URLmon.dll. After explaining the function's arguments, Alyce provides a demo that downloads the main page of the Libery BASIC web site, [http://www.libertybasic.com]. To begin her article, Alyce says, "It is easy to download a file from the internet to your hard drive." Well, yeah Alyce, now that you've done the hard work of research and article-crafting for us!
Alyce's second article reviews Liberty BASIC's ability to change the fonts in windows and controls. For the most part, Gundel the Founder has made font designation easy: print #handle.control "font fontname" for some controls, and print #handle.control "!font fontname" for others. But the pesky GROUPBOX has exempted itself from this easy font control. Not to worry, fearless coders. Alyce not only discusses routine font control, but also provides an easy method for changing the font of a GROUPBOX via the Windows API! Read all about it here, and take a close look at her demo. Thanks again, Alyce!
Following Alyce's article, Gordon Sweet comes center stage again with his second contribution. In this one, Gordon discusses utilizing multiple windows in your applications. Gordon discloses that he recently upgraded to a larger monitor. With more screen real estate, Gordon found it advantageous to convert many of his own applications from single-window to multi-window. Gordon includes a nice demo to show how he did it. Thanks, Gordon!
What if you asked a landscape architect to develop a master plan for your property, and the architect responded with, "Well, first tell me how many pixels wide is your yard?" With that, you would probably start shopping for a new landscape architect. While the primary unit of screen length is the pixel, we normally measure our real world in inches, feet, yards and miles. Yet, much of our design work is done on computer systems. So, we have to have methods for converting "Real World" dimensions to screen dimensions. That's exactly what Tom Nally's Mapping Real World Coordinates to Screen Coordinates does. Nally discusses overlaying a coordinate system on the "Real World", imposing a discreet "viewport" on a portion of the Real World, and mapping to screen those objects that appear in the viewport. It comes with a pretty cool demo, too. Consider this a building block of a CAD system.
We conclude Newsletter 112 with a very challenging article by Ingemar Bjerle, Linear and Non-Linear Equation Systems. Ingemar provides a very compact and efficient routine, Gauss-Jordan, for solving simultaneous equations. In order to use Gauss-Jordan, your equation systems must be linear. If one or more of your equations are non-linear, Ingemar discusses additional routines to linearize the non-linear expressions using a method called a "Tayor series expansion". (A decent MS Powerpoint presentation on Taylor series expansion can be found [here], if you are connected to the 'net.) Once the equation has been linearized, then Gauss-Jordan can be called into play.
A nice bonus comes with the Guass-Jordan article, too! Ingemar provides three Liberty BASIC programs for this issue. One written specifically for his field of Chemical Engineering, gasiflib_parser2.bas, contains an equation parser, a feature that we expect to see in LB4!
Gauss-Jordan being Ingemar's second contribution of a scientific nature to the Liberty BASIC newsletter, I asked him to tell us a little bit about himself. Here is a brief description about Ingemar's current work and background in the first person.
After the restraints are lifted, please exit the cars on your right. Ladies, remember to pick up your purses. We are not responsible for any articles left in the cars. Feel free to stop by the gift shop on your way out.
Liberty BASIC Newsletter 112 is now secure. Nally out.
The Liberty BASIC Newsletter encourages all LB programmers to submit articles for publication. Everyone has something valuable to say, from beginners to veteran LBers. Consider sharing a code routine, with explanation. Perhaps you can review a favorite LB website, or program, or coding tool? Why not submit a list of questions that have been nagging at you? How about sharing your favorite algorithm?
The Publishing Team:
Alyce Watson: email@example.com
Brad Moore: firstname.lastname@example.org
Tom Nally: SteelWeaver52@aol.com
Carl Gundel: email@example.com
Bill Jennings: firstname.lastname@example.org