filmov
tv
Learn Delphi Programming | Unit 9.2 | Styling and Reorganizing Your Delphi Code
Показать описание
-- Download some video lessons for FREE
-- Download some Delphi project files used in tutorials for FREE
-- Download some PDF lesson instructions for FREE
-- Participate in chats and discussions
-- Get Early access to new tutorials
-- No need to signup and no obligation
PS: SORT VIDEOS FROM EARLIEST TO LATEST TO START AT THE BEGINNING
----------------------------------------
Delphi Programming Tutorial - Unit 9.2 - Styling and Reorganizing Your Delphi Code for Improved Readability:
When working on large-scale Delphi projects, it is possible to distribute the workload between multiple programmers. It is also possible that members in a programming team need to work on the same code units.
It is therefore important for a programmer to write "clean" code, meaning code that is easily understood by the rest of the team. A few techniques are demonstrated in this tutorial to improve the readability of Delphi code:
1. Line continuation: When instructions are getting too long in the code editor (unit), they can be shortened by splitting the statement over multiple lines. However, it is important to know where a statement can be split to avoid errors.
2. Indentation: The readability of code can also be improved by indenting nested statements in such a way that the beginning and end of code blocks stand out prominently. Indentation can be done with the Tab key or the Space key.
3. Blank lines: Another way of improving the readability of code is to "batch" statements that are related together. For example, all statements that change properties of a specific object can be "batched", while all statements calling a specific method will be placed in the same "batch". Batches can then be separated by a blank line (like new paragraphs in an essay).
We implement all three these techniques in our code for the "Contact Information" project.
Happy learning!
PS. Please, help us to keep these Delphi tutorials FREE. Keep our sponsors happy and give this video a THUMBS UP. Also SHARE these Delphi tutorials with your friends and tell them to also SUBSCRIBE. Participate in discussions, ask questions and tell us about your experience in the COMMENTS section of a Delphi tutorial.
This tutorial (Delphi Programming Tutorial - Unit 9.2 - Styling and Reorganizing Your Delphi Code for Improved Readability) is best viewed in HD. To change your settings to HD:
1. Click on the gear-icon (Settings) at the bottom of the YouTube Video Player.
2. Select "720p HD" and wait a few moments for the setting to take effect.
You may also want to visit the following resources for more information:
Комментарии