Getting Started with the Lazarus IDE
()
About this ebook
Related to Getting Started with the Lazarus IDE
Related ebooks
Instant MinGW Starter Rating: 0 out of 5 stars0 ratingsExpert Delphi Rating: 5 out of 5 stars5/5Optimizing Visual Studio Code for Python Development: Developing More Efficient and Effective Programs in Python Rating: 0 out of 5 stars0 ratingsReSharper Essentials Rating: 4 out of 5 stars4/5Game Programming Using Qt: Beginner's Guide Rating: 0 out of 5 stars0 ratingsDelphi Cookbook - Second Edition Rating: 5 out of 5 stars5/5Arch Linux: Fast and Light! Rating: 3 out of 5 stars3/5Learn SQLite in 24 Hours Rating: 0 out of 5 stars0 ratingsPostgreSQL Server Programming Rating: 0 out of 5 stars0 ratingsPascal for Students (including Turbo Pascal) Rating: 3 out of 5 stars3/5Qt 5 Blueprints Rating: 4 out of 5 stars4/5GNU Octave Beginner's Guide Rating: 3 out of 5 stars3/5Vim: The Basics Rating: 1 out of 5 stars1/5Visual Studio Code Distilled: Evolved Code Editing for Windows, macOS, and Linux Rating: 3 out of 5 stars3/5Visual Studio 2015 Cookbook - Second Edition Rating: 0 out of 5 stars0 ratingsIvor Horton's Beginning Visual C++ 2013 Rating: 0 out of 5 stars0 ratingsC++ Application Development with Code::Blocks Rating: 0 out of 5 stars0 ratingsPyqt6 101: A Beginner’s Guide to PyQt6 Rating: 0 out of 5 stars0 ratingsIronPython in Action Rating: 0 out of 5 stars0 ratingsCentOS 7 Linux Server Cookbook - Second Edition Rating: 0 out of 5 stars0 ratingsSimultaneous multithreading A Complete Guide Rating: 0 out of 5 stars0 ratingsProgramming Concepts in Java Rating: 0 out of 5 stars0 ratingsCUDA Application Design and Development Rating: 0 out of 5 stars0 ratingsLua Game Development Cookbook Rating: 0 out of 5 stars0 ratingsPractical MATLAB Deep Learning: A Project-Based Approach Rating: 0 out of 5 stars0 ratingsCommon LISP: A Gentle Introduction to Symbolic Computation Rating: 4 out of 5 stars4/5SFML Blueprints Rating: 0 out of 5 stars0 ratingsFunctional Programming in C++ Rating: 0 out of 5 stars0 ratingsTcl/Tk: A Developer's Guide Rating: 5 out of 5 stars5/5
Programming For You
Python: Learn Python in 24 Hours Rating: 4 out of 5 stars4/5SQL QuickStart Guide: The Simplified Beginner's Guide to Managing, Analyzing, and Manipulating Data With SQL Rating: 4 out of 5 stars4/5HTML & CSS: Learn the Fundaments in 7 Days Rating: 4 out of 5 stars4/5SQL All-in-One For Dummies Rating: 3 out of 5 stars3/5Python: For Beginners A Crash Course Guide To Learn Python in 1 Week Rating: 4 out of 5 stars4/5Coding All-in-One For Dummies Rating: 4 out of 5 stars4/5Python Programming : How to Code Python Fast In Just 24 Hours With 7 Simple Steps Rating: 4 out of 5 stars4/5SQL: For Beginners: Your Guide To Easily Learn SQL Programming in 7 Days Rating: 5 out of 5 stars5/5Mastering Windows PowerShell Scripting Rating: 4 out of 5 stars4/5Learn to Code. Get a Job. The Ultimate Guide to Learning and Getting Hired as a Developer. Rating: 5 out of 5 stars5/5TensorFlow in 1 Day: Make your own Neural Network Rating: 4 out of 5 stars4/5Learn SQL in 24 Hours Rating: 5 out of 5 stars5/5Excel : The Ultimate Comprehensive Step-By-Step Guide to the Basics of Excel Programming: 1 Rating: 5 out of 5 stars5/5Grokking Algorithms: An illustrated guide for programmers and other curious people Rating: 4 out of 5 stars4/5C Programming for Beginners: Your Guide to Easily Learn C Programming In 7 Days Rating: 4 out of 5 stars4/5OneNote: The Ultimate Guide on How to Use Microsoft OneNote for Getting Things Done Rating: 1 out of 5 stars1/5Python QuickStart Guide: The Simplified Beginner's Guide to Python Programming Using Hands-On Projects and Real-World Applications Rating: 0 out of 5 stars0 ratingsThe Unofficial Guide to Open Broadcaster Software: OBS: The World's Most Popular Free Live-Streaming Application Rating: 0 out of 5 stars0 ratingsSecrets of the JavaScript Ninja Rating: 4 out of 5 stars4/5
Reviews for Getting Started with the Lazarus IDE
0 ratings0 reviews
Book preview
Getting Started with the Lazarus IDE - Roderick Person
Table of Contents
Getting Started with the Lazarus IDE
Credits
About the Author
About the Reviewer
www.PacktPub.com
Support files, eBooks, discount offers and more
Why Subscribe?
Free Access for Packt account holders
Preface
What this book covers
What you need for this book
Who this book is for
Conventions
Reader feedback
Customer support
Downloading the example code
Errata
Piracy
Questions
1. Installing and Configuring the Lazarus Development Environment
Why Lazarus?
Installing Lazarus in Linux
Downloading and installing the Lazarus Linux RPM package
Requirements
Downloading and installing the Lazarus Linux DEB package
Lazarus for Ubuntu
Installing under Windows
Installing under other OSes such as FreeBSD or Mac OS X
Installing Lazarus on Mac OS X
Installing under FreeBSD
Installing from source
Configuring the Lazarus development environment
Summary
2. Getting to Know the Lazarus IDE – a Quick Tour
The Object Inspector window
The Component Tree window
The Source Editor window
Main menu, quick icons, and the LCL Palette window
Project Options
The Run menu
The Tools menu
The LCL Palette
The Standard tab
The Additional tab
The Common Control tab
The Dialogs tab
The Data Controls tab
The SQLdb tab
Summary
3. Creating a Hello World Program
Hello World console application version
Modifying the code
Compiling and running
Hello World graphical user interface version
Adding components and modifying code
Compiling and running
Debugging
Expanding the Hello World application
Debugging commands
Other debugger features
Deploying
Summary
4. Converting Delphi
Differences between Lazarus and Delphi Components
Fonts
Dragging and docking
TEdit and TCustomEdit
TCustomTreeView and TTreeView
Messages and events
Unit differences
Conversion methods
Filenames and extension
Semantic and syntax differences
32-bit and 64-bit considerations
Resource files
Using the Convert Delphi Project Wizard
Converting a Delphi project manually
Summary
5. Creating a Lazarus Component
Creating a new component package
Adding properties
Adding events
Events with more parameters
Property editors
Component editors
Summary
6. The Lazarus Documentation Editor
Building the LazDE tool
Examining existing source documentation
Documenting your code
Using FPDoc
Summary
7. Rebuilding Lazarus with a GTK2 Interface
Rebuilding Lazarus interface on Windows
Summary
Index
Getting Started with the Lazarus IDE
Getting Started with the Lazarus IDE
Copyright © 2013 Packt Publishing
All rights reserved. No part of this book may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, without the prior written permission of the publisher, except in the case of brief quotations embedded in critical articles or reviews.
Every effort has been made in the preparation of this book to ensure the accuracy of the information presented. However, the information contained in this book is sold without warranty, either express or implied. Neither the author, nor Packt Publishing, and its dealers and distributors will be held liable for any damages caused or alleged to be caused directly or indirectly by this book.
Packt Publishing has endeavored to provide trademark information about all of the companies and products mentioned in this book by the appropriate use of capitals. However, Packt Publishing cannot guarantee the accuracy of this information.
First published: February 2013
Production Reference: 1180213
Published by Packt Publishing Ltd.
Livery Place
35 Livery Street
Birmingham B3 2PB, UK.
ISBN 978-1-78216-340-4
www.packtpub.com
Cover Image by Asher Wishkerman (<wishkerman@hotmail.com>)
Credits
Author
Roderick Person
Reviewer
Juha Manninen
Acquisition Editor
Rukhsana Khambatta
Commissioning Editor
Ameya Sawant
Technical Editors
Kaustubh S. Mayekar
Shruti Sugunan
Dominic Pereira
Copy Editor
Brandt D'Mello
Project Coordinator
Joel Goveya
Proofreader
Lauren Tobon
Indexer
Hemangini Bari
Production Coordinator
Pooja Chiplunkar
Cover Work
Pooja Chiplunkar
About the Author
Roderick Person has a varied background in the corporate IT field. For the last 14 years, he has been a programmer for one of the top-ranked health system in the United States. He is experienced with developing applications in Delphi, Free Pascal, Python, SQL, and other languages. He is also an advocate of leveraging open source application in a corporate environment.
I'd like to thank Barbara Kolski for her support and encouragement with this book, and my wife, Vicky Starr, and daughter, Milan Starr.
About the Reviewer
Juha Manninen is a software developer with more than 25 years of experience. Now, as a middle-aged man, he is studying in a university of applied sciences.
He has been a part of the Lazarus development team since 2009. However, as the team is made up of developers who volunteer their time to the project without compensation, Juha earns a living as a Delphi programmer.
Object Pascal is his favorite programming language, because it's a nice combination of native-compiled code and clear syntax.
www.PacktPub.com
Support files, eBooks, discount offers and more
You might want to visit www.PacktPub.com for support files and downloads related to your book.
Did you know that Packt offers eBook versions of every book published, with PDF and ePub files available? You can upgrade to the eBook version at www.PacktPub.com and as a print book customer, you are entitled to a discount on the eBook copy. Get in touch with us at
At www.PacktPub.com, you can also read a collection of free technical articles, sign up for a range of free newsletters and receive exclusive discounts and offers on Packt books and eBooks.
http://PacktLib.PacktPub.com
Do you need instant solutions to your IT questions? PacktLib is Packt's online digital book library. Here, you can access, read, and search across Packt's entire library of books.
Why Subscribe?
Fully searchable across every book published by Packt
Copy and paste, print, and bookmark content
On demand and accessible via web browser
Free Access for Packt account holders
If you have an account with Packt at www.PacktPub.com, you can use this to access PacktLib today and view nine entirely free books. Simply use your login credentials for immediate access.
Preface
Lazarus is an open-source integrated development environment for the Free Pascal compiler. Lazarus provides a code editor with syntax-highlighting, a visual form designer, and the Lazarus Component Library (LCL). Lazarus is very similar to Delphi, making it ideal for Delphi programmers to utilize. Because the LCL is highly compatible with Delphi's VCL, existing Delphi projects can be easily converted to Lazarus projects.
Lazarus is cross-platform and runs on many platforms, including Linux, BSD, and Mac OS X. Lazarus applications can be created on one platform and compiled on other supporting platforms, making it suitable for many programming tasks. Besides graphical user interface and console applications, Lazarus can also support web-based applications, Android, and iOS applications.
What this book covers
Chapter 1, Installing and Configuring the Lazarus Development Environment, explains the installation and configuration of the Lazarus environment on various platforms, such as Windows, Linux, and FreeBSD.
Chapter 2, Getting to Know the Lazarus IDE – a Quick Tour, is an overview of the basics of the Lazarus IDE, such as the code editor, object inspector, and the LCL palette.
Chapter 3, Creating a Hello World Program, provides an overview of the basics of creating a GUI and console application with Lazarus using the traditional Hello World program and expanding on it.
Chapter 4, Converting Delphi, covers converting an existing Delphi project to a Lazarus project using the Delphi conversion wizard, as well as manually converting the project.
Chapter 5, Creating a Lazarus Component, covers the creation of a custom component that