Recent

Author Topic: Blogs  (Read 13573 times)

tverweij

  • Guest
Blogs
« on: April 17, 2018, 09:28:50 am »
I am relative new to Lazarus and FPC - I come from the Microsoft .Net world.

As I am struggling through all available (lacking) information, I am wondering why there is so little information on Lazarus and FPC.
Yes, there are the Wiki pages. But almost all are out of date - looks like hey are not maintained by anyone.
And there is a developer blog (http://lazarus-dev.blogspot.com/) - last post from 2015 and a total of 47 posts in 8 years.
On code project - one of the biggest code repositories, Free Pascal is non existent, and Delphi is almost non existent.
And when I search using google, the only thing I find is the outdated wiki.

A project will be as successful as its documentation:
- we need to share up to date knowledge
- we need example projects to learn how to use specific technologies
- we need to share the internals of the compiler
- we need to spread the word of these great projects (lazarus and FPC)

Good documentation and samples will attract new developers and it will increase the tiobe index for the language (as this is done by the count of pages that relate to a language, not it's user base or count of projects done in it).

Can we make a place available within the lazarus / free pascal sites where anyone can blog? With a specific blog area for the developers of laz and FPC?
Can we make a place available for sample projects?
Can we get links on the official website to the FPC and Lazarus blogs maintained by users?

It would help a lot for beginners and for starters with new areas of the development system.






howardpc

  • Hero Member
  • *****
  • Posts: 4144
Re: Blogs
« Reply #1 on: April 17, 2018, 09:49:55 am »
Quote
- we need example projects to learn how to use specific technologies
In the IDE use Tools->Example Projects...
or with a file browser explore ../lazarus/examples/... for yourself

Quote
- we need to share the internals of the compiler
The compiler is open source. Its internals are available to all.

Raf20076

  • Full Member
  • ***
  • Posts: 173
    • https://github.com/Raf20076
Re: Blogs
« Reply #2 on: April 17, 2018, 09:53:51 am »
You can find some examples in here http://lazplanet.blogspot.com/
http://lazplanet.blogspot.com/2017/12/supercharge-your-beginner-friends-with.html (free ebook for beginners)
http://hnue.edu.vn/Portals/0/TeachingSubject/hoanglm/27736a95-2ee0-47c4-be13-d810aa36cd76ObjectPascalBasis.pdf (free ebook)
Also when you installed Lazarus IDE on your computer, you can find examples and components here

C:\lazarus\examples (you can open projects examples)
C:\lazarus\components (you can istall extra components)
C:\lazarus\docs\chm (you can read some documentation)


Download Lazarus Code and Component Repository from here
https://sourceforge.net/p/lazarus-ccr/svn/HEAD/tree/ click on the upper right side button Download Snapshot
then uzip it and you can install extra components from there, plus you have examples.
« Last Edit: April 17, 2018, 10:01:45 am by Raf20076 »

tverweij

  • Guest
Re: Blogs
« Reply #3 on: April 17, 2018, 10:10:02 am »
The examples in Lazarus.
Might be handy, but most projects have no description and because it is not on the web, I can not use Google to find what I need.
This is what I mean - the searching for what you need is too time consuming - if you can find it at all.
And a sample project is nice. But a web page where the sample is explained is better; that way you can learn from it instead of having to examine the code to find out how it works.

Te same for the docs, in Chm and in Pdf - not searchable, not linkable (for Pdf).

Anyone here ever looked at MSDN? Because that is what I mean.

Raf20076

  • Full Member
  • ***
  • Posts: 173
    • https://github.com/Raf20076

tverweij

  • Guest
Re: Blogs
« Reply #5 on: April 17, 2018, 10:25:22 am »
By example:
Reference for unit 'Pipes' (complete copy of the page):

Quote
Unit implementing pipe streams.

uses

  System,

  sysutils,

  Classes;
Overview

The Pipes unit implements streams that are wrappers around the OS's pipe functionality. It creates a pair of streams, and what is written to one stream can be read from another.

Ok, and what do I use it for, examples of usage, possible exceptions, multi-platform information, limitations?

Edit: links to the classes, procedures and functions give some more information, but it is still very limited.
« Last Edit: April 17, 2018, 10:29:45 am by tverweij »

tverweij

  • Guest
Re: Blogs
« Reply #6 on: April 17, 2018, 10:48:14 am »
To give an example, I was looking for the workings of the dynamic arrays.
To find out houw it worked, I needed to go like everywhere to get bits of information - combined (including the help of some old Borland documentation) I finally found enough information to make a decision.

What I needed:
1. How is a dynamic array stored in memory
2. How is a SetLength of a dynamic array handled
3. How do I handle heap fragmentation when free memory is enough, but no free block is large enough.

Where I found it:
1. Old Borland documentation (sorry, I am not going to dive into the compiler code to find out) - only have to hope that the FPC implementation is the same as it is not mentioned in the prog.pdf.
2. Don't know anymore - but on the Freepascal docs (internet) it is not mentioned that SetLength is ALWAYS returning a NEW dynamic array, even when you are thrinking the array it is copied.
3. Found it in the prog.pdf of FPC

This meant 3 days of reading and searching for all bits and pieces.

But it looks like its my problem - looking at the current answers.
Maybe I am to lazy to use open source .... (I am not using it because it is free; I tried Delphi and found that Lazarus is a better editor than the Delphi one, and I always - still - paid Microsoft, so costs are no problem).
I need to earn my income with programming - so three days of searching means three days no income.


mse

  • Sr. Member
  • ****
  • Posts: 286
Re: Blogs
« Reply #7 on: April 17, 2018, 10:57:24 am »
To give an example, I was looking for the workings of the dynamic arrays.
The documentation of the Free Pascal compiler, language, and RTL is here:
https://www.freepascal.org/docs.var
You will find it from the Free Pascal main-page under 'Documentation':
https://www.freepascal.org/
Dynamic arrays are documented here:
https://www.freepascal.org/docs-html/current/ref/refsu14.html#x38-510003.3.1
Quote
The SetLength call will make sure the reference count of the returned array is 1, that is, if 2 dynamic array variables were pointing to the same memory they will no longer do so after the setlength call:
Quote
I need to earn my income with programming - so three days of searching means three days no income.
What are your plans on how to give some of the income you earn by open source tools back to the maker of the tools or the community?
« Last Edit: April 17, 2018, 11:08:00 am by mse »

hrayon

  • Full Member
  • ***
  • Posts: 118
Re: Blogs
« Reply #8 on: April 17, 2018, 04:23:11 pm »
Hello Tverweij!
You're right, things here are not very practical.
I follow Lazarus for a few years (I do not make money from it yet), there are some quirks here ...
There is no solid organization that maintains Lazarus and FPC, though these tools are fantastic.
I imagine that the main maintainers of the project are not supported by the Lazarus / FPC pair, but rather by what they should have developed with Lazarus / FPC. I also imagine that there is not an exclusive dedication by the project maintainers.
The fact that I imagine this or that is also due to this inconsistency of communication, this fault between maintainers and users.
The project maintainers are excellent programmers, but for the rest I do not know.
Sometimes someone comes up with suggestions for improvements around these tools, such as the website, the wiki, the forum, the logo ... and some forks appear because of the problems that also related to what you reported.
I sometimes think that the near-inexistence of a solid organization behind Lazarus is due to the similarity to Delphi, and even if everyone believes they are independent tools, the current owner of Delphi may not legally believe, and this would bring legal insecurity to anyone behind Lazarus.
It's a personal vision, I might be wrong.

tverweij

  • Guest
Re: Blogs
« Reply #9 on: April 23, 2018, 12:04:18 pm »
Let me state it in another way, as I am clearly misunderstood.

There is indeed much information; the FPC online documentation (also installed as PDF and chm), the FPC/Lazarus Wiki and the example projects.

But the problem is they are not linked.
If I press F1 in Lazarus, I get the FPC documentation. This  is generated documentation without example code and without links to the wiki.
If I search in the wiki, I get every page 3 or 4 times - in different languages, making the list too long to make sense.

When I am looking for a package in the online package I get (by example): APE, when I open it, I get Package Info: Category: Science, no home page and no further info. What does it do /  what is it used for?
Same in the Install/Uninstall packages: no information on the packages whatsoever. Also no links to the wiki pages.

And the example projects; more than 70% does not have any description. So what is the intend of the example?

The problem is not that there is not enough information, but that it is not structured and not linked to each other.





Handoko

  • Hero Member
  • *****
  • Posts: 5131
  • My goal: build my own game engine using Lazarus
Re: Blogs
« Reply #10 on: April 23, 2018, 12:54:57 pm »
Welcome back tverweij.

We are currently lack of volunteers to improve the documentation. I heard some users said they want to help to make the documentation better. The idea is good but not much efforts have been done because it is not an easy task. It requires good knowledge on both Pascal language and the software (Lazarus IDE and FPC).

As a volunteer-supported project, Lazarus is awesome. In some areas it may be not good as the commercial one. But it's really improved a lot compare to first time I tried it 10 years ago.

One thing I like about Lazarus/FPC is the community, people here are nice. If you have question about the software or Pascal programming, lots of experienced users will help you.
« Last Edit: April 23, 2018, 05:35:58 pm by Handoko »

Trenatos

  • Hero Member
  • *****
  • Posts: 535
    • MarcusFernstrom.com
Re: Blogs
« Reply #11 on: April 23, 2018, 03:28:08 pm »
I'm with you tverweij, the language and tools are good, but the documentation is horrible.

You're not the first to point out the issues with the Wiki, examples, website, etc.

The biggest issue is that it's all volunteer driven, there is no company owning it and putting paid man-hours into the core project/website/docs/wiki.

tverweij

  • Guest
Re: Blogs
« Reply #12 on: April 23, 2018, 04:40:45 pm »
Than a simple question: How can I help?
I can spend several hours a week on it.

mse

  • Sr. Member
  • ****
  • Posts: 286
Re: Blogs
« Reply #13 on: April 23, 2018, 05:00:59 pm »
AFAIK the concrete problem was that you needed information about the working of Free Pascal dynamic arrays but you did not find the link 'Documentation' on https://www.freepascal.org/
correct?
Or was the problem that you did not find https://www.freepascal.org/
?
The question is how the situation can be improved. How did you try to get information? You write:
Quote
Where I found it:
1. Old Borland documentation (sorry, I am not going to dive into the compiler code to find out) - only have to hope that the FPC implementation is the same as it is not mentioned in the prog.pdf.
2. Don't know anymore - but on the Freepascal docs (internet) it is not mentioned that SetLength is ALWAYS returning a NEW dynamic array, even when you are thrinking the array it is copied.
3. Found it in the prog.pdf of FPC
Why did you not first check the documentation link on Free Pascal website? What must be done that it is more known to the FPC users?



Handoko

  • Hero Member
  • *****
  • Posts: 5131
  • My goal: build my own game engine using Lazarus
Re: Blogs
« Reply #14 on: April 23, 2018, 05:31:20 pm »
Than a simple question: How can I help?
I can spend several hours a week on it.

All kinds of help are welcome.

We all agree the documentation and tutorials need to be improved. They are not properly organized and some of them contain outdated information. If you have idea to make it better, then do it.

If you found bugs, you can report it to the bugtracker forum. If you're not sure it is a bug or not, you can post it to the forum and hear what the others say. Here is the bugtracker forum:
https://bugs.freepascal.org

I saw you're an experienced programmer. Maybe you can help in implementing new features or bug fixing. I ever tried to pick and solve some random bugs in the bugtracker forum, but I'm just not skilled enough to do so.

As far as I know this forum is for general questions and helping newbies. If you're interested in developing Lazarus/FPC you should join the developer mailing lists:
https://www.freepascal.org/maillist.var

And here I found some links that maybe useful for you:
http://wiki.freepascal.org/How_to_become_Lazarus_developer_%28committer%29
http://wiki.freepascal.org/User_Changes_Trunk
https://www.freepascal.org/future.var
« Last Edit: April 23, 2018, 05:38:45 pm by Handoko »

 

TinyPortal © 2005-2018