Re: [Lazarus] Online Package Manager

2017-04-12 Thread Lars via Lazarus

On 2016-10-04 07:11, Balázs Székely via Lazarus wrote:

Hi,

 I decided to implement the online package manager(opkman) or at least
give it a try. The first stable(alpha) version is ready and it works
like this: the packages are zipped and stored in a
webserver(repository) along with a json file. I chose zip to minimize
server load. The json file contains all the necessary info about the
packages. Once installed into the IDE, the opkman downloads, then
serialize the json file into a package list. The list is  displayed in
a tree. On request the packages can be downloaded or/and installed.
For now the repository is read-only, it contains only eight, well
known(I guess?) packages. The nature/type of the eight package is
irrelevant for now, since we are only testing the functionality of the
opkman. Few notes:

...


 Please test! Suggestions are welcome.



With online package managers there is the problem of centrally locating 
all packages at a single URL or repository, correct? So which url will 
be used? Sourceforge, freepascal.org...

And then you could have mirrors if the main url is down.

Whatever happened to the freepascal package download system at the 
command line? was that ever implemented? sorry I am not up to date on 
it..
One advantage of a central package system is that it encourages people 
to upload their packages, such as like torry.net. Whereas if each guy 
has his own website and then his website goes down or he quits 
programming, that package on his site gets lost and people must use 
archive.org or brute force techniques to find it online...


Github is in a way a central package system but not really as it is not 
a download tool for binary/releases as much as it's more of a source 
only package system.  Torry.net is really interesting and is the main 
reason I never used Visual C++ studio because visual C++ never had 
anything like torry, other than codeproject.  Torry never had a way to 
connect delphi directly to it, like a rubygems or the once discussed fpc 
package manager tool at the command line.. whatever happened to that 
idea?

--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Online Package Manager

2017-04-12 Thread Lars via Lazarus

On 2016-10-04 07:35, Graeme Geldenhuys via Lazarus wrote:

On 2016-10-04 13:11, Balázs Székely via Lazarus wrote:
 I decided to implement the online package manager(opkman) or at least 
give

it a try.


Not to deter from all your efforts, but I think there is already a
brilliant solution called "Delphinus". It is an open-source replacement
to the ridiculous one included with newer Delphi versions as standard.

All that would be required is to port that code to work with Lazarus 
IDE

(instead of Delphi IDE - or possible work with both IDE's).

So, what's the benefit of Delphinus:
  * there is _no_ central repository!
  * You can publish new project without notifying the Delphinus
author
  * It hooks into the Github API, so everything is automated.
  * You can have a console app or IDE add-on to install
packages.


Cool!

Is github okay with this idea though as they are really not a download 
system like sourceforge or google code...


They are more for source revision and not so much for final release 
downloads, although, this needs to be clarified as you can indeed just 
make a tag to release.. But as soon as you start distributing binaries 
on github, it sort of violates their policy. But, I suppose pacakages 
are not binaries like a final exe release of a program to be shipped.  
And lazarus/fpc is fairly uncommon and not very popular so github is 
likely not going to notice a bandwidth increase on their servers anyway. 
I think github is against becoming a download website to reduce their 
costs and focus on being a source revision system, not a distribution 
system like sourceforge.


--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Quick Video: A Web Application

2017-05-07 Thread Lars via Lazarus
Sorry, didn't watch the video yet, but, wasn't Morfik something similar? 
Or that was mostly offline apps?


Then there was also the intraweb for delphi, but AFAIR the Indy authors.
--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Quick Video: A Web Application

2017-05-07 Thread Lars via Lazarus

On 2017-04-19 10:21, Graeme Geldenhuys via Lazarus wrote:

On 2017-04-19 15:58, Michael Schnell via Lazarus wrote:
Lazarus would b able to seamlessly create such programs (even more up 
to
date, versatile and fast: using WebAssembly compiled from Pascal 
instead

of hand crafted Java Script).



I believe that is what Michael van Canneyt is working on.



I am also working on something like this for chromium embedded Offline 
Apps (with callbacks that can call native fpc code using html5/js 
widgets as the GUI), but, as I have many programs on the go, and many 
ideas, and not sure if it will be open source... I don't want to blow 
the whistle early. FastCGI would be a good mechanism for events, since 
it keeps a exe/elf open all the time rather than forking a new one for 
each event. But fastcgi doesn't run on that many servers.

--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Vulkan Library for FreePascal/Lazarus

2017-05-11 Thread Lars via Lazarus

On 2017-04-12 23:32, James.mcjohnson via Lazarus wrote:

This is both an announcement and request for help for an open source
FreePascal project which strives to provide:



You may want to also post this to the FPC mailing list rather than just 
the Lazarus list, as, vulkan can probably be used outside of the Lazarus 
IDE and just with plain fpc programs!


--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Vulkan Library for FreePascal/Lazarus

2017-05-11 Thread Lars via Lazarus

On 2017-04-13 11:34, Michalis Kamburelis via Lazarus wrote:


@James, would you mind removing the "Public Service Announcement" from
https://github.com/james-mcjohnson/VulkanLibraryForFreePascal/blob/master/LICENSE.md
? Don't get me wrong, I understand that you want to promote your faith
and I respect that. Having this in README files, and Pascal sources,
is absolutely OK. But I'm not a lawyer, and I'm unsure how it affects
the legal text of the license. Having just an "unmodified MIT license"
would feel safer for me.



Plus, it recommends using GoLang, not fpc, in the faith..

Be Baptized: "Go

Not fpc.

Just my opinion
--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


[Lazarus] CodeTools On Event insert? detect

2017-05-24 Thread Lars via Lazarus
I am looking for a way to detect when someone has added an event in the 
ide, for example button1click..


When someone double clicks a button in lazarus it generates code in the 
IDE for the event handler procedure..


I want to intercept/detect this, and add

  SomeCode();

between the begin/end of the event, i.e. on button 1 click.

Does codetools provide some way to do it?

It has a way to search the source code for a procedure and enter code, 
but how do you detect when an event is added to the source code?

--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


[Lazarus] Codetools OnBeforeCompile/After events

2017-05-25 Thread Lars via Lazarus

Does something like OnBeforeCompile/OnAfterCompile exist in codetools?

If not, would it be acceptable as a new code tool, or any criticisms if 
it is a bad idea? (I can work on a unit that does it, or would it be 
better to add it to one of the existing codetools units?)


AFAIR delphi had something like it, but its been a while since I worked 
with delphi ide tools.


--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Codetools OnBeforeCompile/After events

2017-05-25 Thread Lars via Lazarus

On 2017-05-26 01:24, Ondrej Pokorny via Lazarus wrote:

On 26.05.2017 8:21, Lars via Lazarus wrote:

Does something like OnBeforeCompile/OnAfterCompile exist in codetools?


Yes, they exists. "OnAfterCompile":

  LazarusIDE.AddHandlerOnProjectBuildingFinished(@MyEvent);
  LazarusIDE.AddHandlerOnLazarusBuildingFinished(@MyEvent);

Ondrej
--


Ahh, maybe I am looking at codetools when I should be looking at 
lazideintf.pp instead.

As that's where those are located..

For some reason I thought it would be part of code tools for writing 
plugins to the ide.

Thanks.
--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] CodeTools On Event insert? detect

2017-05-26 Thread Lars via Lazarus

On 2017-05-26 04:44, Mattias Gaertner via Lazarus wrote:

On Wed, 24 May 2017 13:43:10 -0500
Lars via Lazarus  wrote:


[...]
I want to intercept/detect this, and add

   SomeCode();

between the begin/end of the event, i.e. on button 1 click.

Does codetools provide some way to do it?


Donald Ziesig added templates to alter the inserted code snippets.
Please update svn, compile the IDE with
-dEnableCodeCompleteTemplates and restart it.

Read the header notes in
lazarus/components/codetools/codecompletiontemplater.pas

Default templates are defined in
components/codetools/codecompletiontemplates.xml

You can choose your own template file in Tools / Options /
Codetools / Code creation / Template file.



Thanks, I will try. Is it a special Define because it is a new untested 
feature waiting for approval?

If so I could be a tester
--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] CodeTools On Event insert? detect

2017-05-26 Thread Lars via Lazarus



[...]
I want to intercept [...] and add

   SomeCode();

between the begin/end of the event, i.e. on button 1 click.

Does codetools provide some way to do it?


Found this discussions about it too:

http://lists.lazarus.freepascal.org/pipermail/lazarus/2014-March/086457.html

http://free-pascal-lazarus.989080.n3.nabble.com/Lazarus-RFC-Code-tools-Feature-td4036425.html

That's interesting that Michael V. C. wanted logging at begin/end of 
code snippets in procedures, because that's exactly what powtils had to 
do but it looks kind of ugly at the source level to have IFDEF DEBUG at 
the end and begin of each procedure, but that's how I did it..


But, this requirement that I need has nothing to do with that, it's for 
something else.. but still interesting!

--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] CodeTools On Event insert? detect

2017-05-29 Thread Lars via Lazarus
Mattias, I'm still having issues figuring out exactly what Donald Z.'s 
code does and how to use it, but is there even a way to "hook" the ide 
event insertion currently? i.e. if you throw a Button on a form and 
double click it, I want to hook into that, and insert code immediately 
after the event has been inserted into the ide text edit window..


If this feature is currently not implemented I can work on a patch today 
that does it, however I don't want to work on a patch if this feature 
already exists and I just can't find it.


Something like: OnAfterEventInsert codetools/lazintf trigger

- User adds button 1 to form
- user double clicks button 1
- code is inserted inbetween begin/end automatically

I think the templates may help this but is there really a hook like this 
in code tools where you can hook into the events inserted into the IDE 
when a user double clicks a button/widget or double clicks the event in 
the object inspector?

--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


[Lazarus] Find/Replace inside IFDEF FPC else

2017-06-27 Thread Lars via Lazarus
When I use the find/replace dialogs, and search for text, it does not 
search inside the else section of {IFDEF FPC}. I assume this is a 
feature. However some times I want to replace text inside delphi code 
that is outside the IFDEF FPC and in the ELSE section?


Is there an option to set this behavior?
Thanks
--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Find/Replace inside IFDEF FPC else

2017-06-29 Thread Lars via Lazarus

On 2017-06-28 02:37, Michael Van Canneyt via Lazarus wrote:

On Wed, 28 Jun 2017, Mattias Gaertner via Lazarus wrote:


On Tue, 27 Jun 2017 22:46:55 -0500
Lars via Lazarus  wrote:

When I use the find/replace dialogs, and search for text, it does not 
search inside the else section of {IFDEF FPC}. I assume this is a 
feature. However some times I want to replace text inside delphi code 
that is outside the IFDEF FPC and in the ELSE section?


Find/Replace works on the text of the active source editor, it does 
not

parse for $IFDEFs.




Hrm, the issue does not show up any more today but acted that way the 
other day. I'll have to figure out when it is being caused... and file a 
bug report if necessary
I was searching and replacing for "0010" AFAIR, and it found all 
instances inside the IFDEF fpc but not in the else section. But now that 
I try it, it works today. Strange.


Glad you mention this, I was almost on the way to the reanimation 
department

of the nearest hospital...

Michael.


Please explain what the reanimation department is:
- the ability to revive a dead non animated person
- the department that takes slow moving people and animates them again 
at a good pace
- reincarnation (possible Dutch/English translation bug: animation = 
life)

- a reference to something else
--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


[Lazarus] Write array of byte data to TImage

2017-06-29 Thread Lars via Lazarus

Is there any way to write array of bytes to a TImage?

LoadFromStream doesn't appear to work, as it does not contain, AFAIK the 
bitmap header information that would be stored in a file...


i.e. is there any way to write raw array data to a bitmap or TImage.

Sorry, I haven't worked with images much... I assume the problem could 
be that load from stream must accept properly formed bitmap file, 
whereas I may be trying to just write the byte array itself that is not 
a properly formed bitmap/jpeg/png file with header information or image 
information.


RawImage.Data (PByte) is read only and cannot be written to AFAICT.
--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Which HTML render component better?

2017-07-07 Thread Lars via Lazarus

On 2017-07-06 08:05, Martok via Lazarus wrote:

Or use the CEF, but that bloats your application by about
35MB...



I think more...

maybe 35mb back in the cef 1 days?

But now it is larger with cef3
--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Congrats to the FPC/Lazarus projects - job well done!

2017-07-23 Thread Lars via Lazarus

On 2017-07-12 19:11, Graeme Geldenhuys via Lazarus wrote:

Hi Guys,

This is just to give everybody that works on FPC or Lazarus a pat on
the back. Seriously, you guys are doing an *excellent* job. Even
though I am sometimes a bit hard on you guys.

Having moved back to Delphi (I'm using XE at the moment) for a
contracting job, I got to the realization how bad Delphi has become.
Compared to Lazarus IDE, Delphi IDE is a joke!!


Except that firemonkey has wa more complete of a component palette 
set for macOS cocoa...





[rant on]

My issues with Delphi IDE in the last two weeks:


[...]

 - Delphi IDE is so SLOW to start up, and I'm running a beefy Intel i7
   with 32GB RAM.



Agree, Delphi is very slow to load, and use, even on a modern 64 bit 
laptop


Wirth's law applies, if you know it... As computers get faster, software 
gets more bloated and computers cannot keep up with the software bloat.

--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Video: Terrain Demo

2017-07-23 Thread Lars via Lazarus

On 2017-07-14 01:18, Anthony Walter via Lazarus wrote:

I've been working on actually finishing Bare Game version 2. This
evening I created another example program and thought some of you
might want to view it.

It's a procedural terrain generation example. You can view a small
screen capture of it at this page:

https://www.getlazarus.org/videos/bareterrain
--


Which graphics tools does it use as a basis?

directx/opengl/other?
--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Congrats to the FPC/Lazarus projects - job well done!

2017-07-25 Thread Lars via Lazarus

On 2017-07-24 09:42, Graeme Geldenhuys via Lazarus wrote:

On 2017-07-24 03:39, Lars via Lazarus wrote:
Wirth's law applies, if you know it... As computers get faster, 
software
gets more bloated and computers cannot keep up with the software 
bloat.


Indeed, and it doesn't only seem to apply to Windows software. Linux
and FreeBSD software are affected too. Just last week I tried
FreeBSD's "native GUI desktop environment" called Lumina, which
includes a file manager application. By pure chance I ran htop and
noticed the Lumina file manager uses 500MB RAM.


Is it because of QT 5 ?
It says on the internets that Lumina uses QT 5

Or, in Lazarus terms: To keep on topic ;-)  do lazarus QT apps act much 
more slow or use up much more memory.


I'm always interested in the actual culprit of the issue - it could even 
be a memory leak that just needs fixing!

--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


[Lazarus] Display multiple images

2017-07-26 Thread Lars via Lazarus
Is there any component to display multiple images, and, maybe scroll 
through them, left to right, or up and down?


These methods might be the way:
1. do it manually with code. Put TImages in a tscrollbox, display them 
one by one
2. ListView? but size might be too small, just thumbnails, unless it is 
configurable

3. Some third party component that I don't know about
4. TImageList, connected somehow (TListView already mentioned)
--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Display multiple images

2017-07-27 Thread Lars via Lazarus

On 2017-07-27 03:22, Alexey via Lazarus wrote:

Old from me, 2008 year, Delphi only
http://atviewer.sourceforge.net/atimagemap.htm

Alex


That looks really neat !

Were there reasons you decided to not port to lazarus (too difficult)..

As I could start a project attempting to convert it to Lazarus
--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] The new kid is growing up fast

2017-08-20 Thread Lars via Lazarus

On 2017-08-15 06:19, Graeme Geldenhuys via Lazarus wrote:

Hi guys,

Just wanted to show you guys something. The new kid on the block is
growing up very fast CrossVCL.

   https://www.youtube.com/watch?v=_lr_BQlXvkk

I believe the programmer is the ex-FMX (FireMonkey) developer that was
let go by Embarcadero, and he is hitting back with a vengeance. The
CrossVCL project has grown from nothing to something in an extremely
short time. Coming from a toolkit designer myself, that is very
impressive to see.


Regards,
  Graeme


Is there some technical info page "how it works"?

Does it require WINE or anything obscure, which makes installing apps 
difficult for the end user?


It says Win API, so as soon as I heard that I thought "WINE" but I have 
no idea :-)

--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] The new kid is growing up fast

2017-08-20 Thread Lars via Lazarus

On 2017-08-15 14:16, Graeme Geldenhuys via Lazarus wrote:

On 2017-08-15 12:35, Michael Schnell via Lazarus wrote:

How to compare it against Lazarus ?


No idea - I've only been watching the CrossVCL videos as milestones
get reached. I've never tried CrossVCL personally, and don't use
Delphi personally either (since 2006).



Didn't you pull delphi out recently for some work you said?

Anyway, I'd like to know more technical details of how CrossVCL actually 
works... compared to how lazarus works.


Lazarus compiles native apps for each platform, whereas CrossVCL?  May 
make the same mistakes as Kylix? Or not.


If anyone wants, this could be changed to Fpc-Other post, sorry if it's 
not on topic for Lazarus discussions. It could be related in that the 
architecture behind crossvcl could be studied for research and ideas 
could be used between it, but..

--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Why is there no announcement of Lazarus event

2017-09-14 Thread Lars via Lazarus

On 2017-09-08 07:03, Marc Weustink via Lazarus wrote:

Which event are you referring to?

Marc



The resurrection, second, or third coming of the hero Lazarus?

Not fully familiar with the Bible character... but if Lazarus is here, I 
will need to see him.




Just wondering? Or is it still coming?


Regards,
  Graeme

--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus

--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus

--
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Launching External Tool Cmd.exe in Windows

2016-09-26 Thread Lars via Lazarus
On Sat, September 24, 2016 11:06 pm, Cyrax via Lazarus wrote:
>> Any idea what workarounds people used before? Surely someone used
>> cmd.exe before as an external tool in an older version.  I tend to not
>> use the latest version from source control. But I can, if I have to!
>>
>
> In Tools->Configure External tools...->Add dialog, input these:
>
>
> Title : Command Prompt
> Program Filename : $Env(COMSPEC)
> Parameters : '/c "start "Command Prompt" "%COMSPEC%""'
>
>

Genius! Any idea how to launch a console app using this trick?


i.e. I develop a console app in lazarus (the $TargetFile()) and want to
launch it but leave it open. Cmd /k was what I thought.

 other option would be to make a ms dos batch file, that launches a
command window, and run it. Or like the other poster said, create a
launcher program
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Run Parameters Dialog

2016-09-26 Thread Lars via Lazarus
On Fri, September 23, 2016 12:19 am, Mattias Gaertner wrote:
> On Thu, 22 Sep 2016 18:46:49 -0600
> "Lars"  wrote:
>
>
>> Hi in the Run Parameters dialog, it appears as though $macros such as
>> $TargetFile() or the current project directory, etc., don't get
>> expanded
>
> Please create a bug report.
>
>

Not sure if it was intended as design.

The designer of Lazarus didn't necessarily need this feature...

I will create one but it could be as designed
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Run Parameters Dialog

2016-09-28 Thread Lars via Lazarus
On Mon, September 26, 2016 11:55 pm, Juha Manninen via Lazarus wrote:
> On Tue, Sep 27, 2016 at 8:07 AM, Lars via Lazarus
>  wrote:
>
>> The designer of Lazarus didn't necessarily need this feature...
>>
>
> Mattias is the designer of Lazarus. :)
>


I thought there were more than one designer and it went through several
phases of different people coming and going, hence the name Lazarus which
was revived from the dead, and instead of just one Jesus like person being
revived it was multiple people which makes it Lazaruses rather than
Lazarus
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Run Parameters Dialog

2016-09-28 Thread Lars via Lazarus
On Wed, September 28, 2016 2:19 pm, Lars wrote:
> On Mon, September 26, 2016 11:55 pm, Juha Manninen via Lazarus wrote:
>
>> On Tue, Sep 27, 2016 at 8:07 AM, Lars via Lazarus
>>  wrote:
>>
>>
>>> The designer of Lazarus didn't necessarily need this feature...
>>>
>>>
>>
>> Mattias is the designer of Lazarus. :)
>>
>>

:-) Quote:

"So, three individuals (Cliff Baeseman, Shane Miller, and Michael A. Hess)
began Lazarus in February 1999. Each of these three had tried to get
involved with the Megido project before it dissolved. They started their
own project, Lazarus, out of frustration with their earlier Megido
experience.

The next member of the team was Marc Weustink. He got involved with the
project in August 1999. Marc was looking for a Linux Delphi (at that time
Borland had not developed Kylix). He was also interested in Linux in
general, and joined the Lazarus project for that reason. At the time Marc
joined, Lazarus was not much more than an empty toolbar and some hardcoded
GTK menu items. The editor was still being discussed. Marc is still a core
contributor, with the debugger interface as his pet subproject.

A year after Marc joined Mattias Gaertner got involved (September 2000).
With Mattias as a member of the team the project made a significant move
forward. Mattias ported synedit, and coded large parts of the codetools
and the designer. With these new additions Lazarus began to look more like
it does today. Three years later, Mattias added the package system and has
continued to add further IDE features and enhancements. "

Quote from:
http://wiki.freepascal.org/History


-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Teaching Pascal at College

2016-10-17 Thread Lars via Lazarus
> On 14/10/16 08:30, Michael Schnell via Lazarus wrote:
>
>
> Of course there are decent drawbacks regarding relying too much on RAD
> and about not really understanding the fundamentals behind it. But in the
> end the addressees are non-computer engineers.

The big issue with teaching using a RAD tool, is welding the program logic
into the onclick events, instead of decoupling the logic in separate
procedures that can be reused elsewhere.  RAD tools are superior at
prototyping... I can't believe how awesome they are at that. They are
inferior, however, when it comes to bad habits being brought on.  With
this warning, RAD tools can still be very useful for writing solid
programs, as long as one knows this warning ahead of time.

When I first learned delphi I made the mistake of putting code in the
onClick events and similar, and then when you expand your app later you
realize all that code is welded in place and cannot be reused outside of
the events.

Of course decoupling the logic from the GUI leads to more layers of code.

How I got rid of my bad habits when I first learned delphi: I started
writing console apps with no object oriented programming, no events, and
learned that not everything is a click event in computer programming.

People late in the game (learned programming when GUI's were available)
and have no experience with console mode apps will earn some bad habits
because of the GUI oriented programming. Those with experience in other
areas of programming such as old Dos programs, web programs (basically
like a dos or unix console program) will learn different ways of
organizing code without everything being tied to a GUI event driven code.

I suppose even doing a plain Win32 API app with no delphi code (pure win
api) would help someone learn how to organize code from a second opinion
view, without being forced to use the event driven system you were given
by the RAD tool.

Of course, also learning other programming languages helps (although, IMO
learning too many brain dead languages and hip cool ones will not help, as
much as others claim... Basic programmers from the 80's or 70's still
think in GOTO's and line numbers)
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


[Lazarus] Help System with Chromium Embedded component

2016-10-21 Thread Lars via Lazarus
Hi, I have been experimenting with chromium embedded and the power is
endless.  It's like being able to write CGI programs but on the desktop
with no server needing to be installed.

I was thinking documentation for software could benefit from having a
chromium embedded (or firefox embedded) system.

The issue with static plain html documents is that they aren't really
powerful like a full fledged .CHM system or .hlp system. But even chm and
.hlp files are primitive, they are just basic, and 1990's technology.

With chromium embedded it seems you can literally do anything you want:
combine lazarus widgets with a web server like program, but without
requiring a web server. I.e. you can output to the web browser just like a
cgi program can, but no server side needed, it's all done on the client.

To me this seems like the perfect help system tool as you'll get something
far more powerful than a PDF file... you can highlight text using lazarus
code and callback back to the browser, whereas PDF files are not so
programmable and controllable with code. I don't even know if pdf is
scriptable.

The biggest issue with help documents is they are usually either static
PDF files that are not in any way searchable like an online documentation
on a web server or they are static html files without any power added
to them, or they are chm files which are simple but not so powerful.

It seems there is almost a mismatch where people want a PDF file but also
want to use google for help. This leads to the help files not really being
integrated into the app and people just end up using google to find help
on their program. The way I see it is if there was a chromium embedded or
firefox embedded help system you wouldn't need google as much, as you
would have the documents on your client like in the old days with Delphi 5
and 6 when you just pressed F1 and it took you to the page. F1 local
client help just like delphi could in fact be automated with chromium
embedded the same way delphi had it with the old documentation system from
the 1990's... but with chromium embedded, you get rich html help
documents, not old html document style from 1990's..

As much as I love CHM/HLP file systems from Ms Winblows it seems that one
could even develop a more powerful one with chromium embedded and
callbacks back and forth to the component

Now I haven't much looked into the current Lazarus help system or what
people use for help systems in popular lazarus apps, but I'm posting this
to the mailing list as an idea for anyone who wants to make a rich help
system with a rich integrated help system.

The issue with opening an html file in a browser for help, is that the
person has to leave their application and then alt tab back to it, whereas
a chromium embedded help system could be put right into the software
itself not a separate browser application.  And the issue with chm files
as I see it, is they are a simple format from the 1990's with limitations
(As much as I respect simple formats from long ago.. some help systems
need to be richer)

PDF files are indeed very rich documents but they lack programmability.
For example F1 online (or rather offline local client) help like in Delphi
5 seems not possible, even though delphi 5 help is 1990's technology and
pdf files are modern.

There seems to be a mismatch here where you have fragmented help systems
on modern software, and people end up basically abandoning help systems
and instead just go on google and search. Maybe the old delphi 5 style F1
help system could be brought back, but with a modern flare: chromium html
pages, with javascript possible too if absolutely necessary, to make them
richer. But the cool thing about chromium embedded is you can avoid
javascript by using fpc/lazarus code as callbacks instead of relying just
on clunky javascript.. i.e. you can mix modern pascal code in with HTML to
render, search, display, etc.

So I'm not talking about just a help system for lazarus (the current one
may be just fine) but a help system architecture for all software apps
released in the future! Apps developed with lazarus, not just lazarus
itself.. and apps developed with delphi and other tools.


-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Teaching Pascal at College

2016-10-21 Thread Lars via Lazarus
On Tue, October 18, 2016 2:11 am, Michael Schnell via Lazarus wrote:
>
>> The big issue with teaching using a RAD tool, is welding the program
>> logic into the onclick events, instead of decoupling the logic in
>> separate procedures that can be reused elsewhere.

> As you point out in the text this is as well a pro (easy fast solving of
> small unitary tasks) as a con (bad reusability, bad code when doing big
> projects)



>
> Of course it's great to dedicate a (later) lesson to un-RAD-ing your
> code in order to be prepared for bigger tasks.
>
> -Michael
>

Agree, although one could even just start out teaching console mode
programs before RAD, which I think is what many universities do... I
remember seeing that they were still using turbo pascal in some courses in
Canada at universities here.

The issue with console mode programs is students see utterly no use for
them. I remember when I was using dos as a little kid, I was introduced to
basic, and I saw no use of it. GUI apps are of much more use to people as
they are flashy and rich with widgets, whereas console mode programs seem
utterly boring.

I guess that's the difference between unix users and Windows users.. Unix
users back in the old days saw console mode programs as huge thrills and a
great experience. When I saw Dos programs when I was a kid I thought they
were pathetic and useless, and it deterred me from programming.

If I knew about delphi as a child I probably would have been more
interested in programming.  I remember trying visual basic and disliking
the language keywords. I liked the visual basic tool since you could
easily create widgets on forms, but I disliked the language itself. Visual
basic also forms the exact same (if not worse) bad habits of welding code
into click events and doing sloppy quick coding.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


[Lazarus] Chromium embedded on freebsd or firefox embedded

2016-10-21 Thread Lars via Lazarus
What is the actual status of chromium embedded and firefox embedded on
bsd? Does it only work on Windows and Linux?

Seems there is not so much info about CEF in general on freebsd other than
this info:
https://lists.freebsd.org/pipermail/freebsd-chromium/2014-January/001113.html

I so much love the bsd license and want to move my desktop and some of my
development over to BSD, but it just seems like bsd is constantly playing
catch up to what linux and windows already had years ago. That's my
biggest fear about all bsd's.

Since I will be doing work with chromium embedded on multiple projects it
will be interesting to know what the status of it is on bsd for lazarus?
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Teaching Pascal at College

2016-10-21 Thread Lars via Lazarus
On Mon, October 17, 2016 7:32 pm, Mehmet Erol Sanliturk wrote:
> One obvious point is that an "event" driven programming knowledge is a
> must to become a competent programmer . The problem is how this can be
> learned . Without knowing how to program an algorithm when a related event
> is occurred , will bring any one to nothing means ( not to a success ) .
>

An interesting question is what is an event and isn't in some way or
another all programming based on events that occur?

The concept of callbacks is very similar to events. you make a callback
when something happens, just like an event. This can be done even in old
turbopascal programs or console mode programs..

I'm not so sure event driven programming is a must to become a competent
programmer, I would have to think about that. Events could (may) force a
programmer to think about programs in a certain way... when there are
alternatives? or are events the only alternative just in another form
(callbacks, or calling procedures). It begs the question about whether
events are just procedures being called, which is the same as any
programming methodology since all programs "call procedures".

Is a compiler event driven? A competent programmer could write a compiler,
or a parser. Are they necessary to have event driven architectures?

i.e. is the fpc compiler event driven, even if not officially event driven
someone ended up reinventing events in it? From what I understand Michael
V. C.'s documentation tool is event driven which differs from the fpc
compiler.  However I beg the question:  is all programming event driven in
some way since events are just "calls to procedures". Of course that is
simplifying it, but "what is an event?" would be a good computing science
article to write. If I had any time..
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Teaching Pascal at College

2016-10-21 Thread Lars via Lazarus
On Mon, October 17, 2016 2:52 am, Michael Schnell via Lazarus wrote:
> On 14.10.2016 16:10, Jürgen Hestermann via Lazarus wrote:
>
>>
>> In most cases they never get to the step "find out how it works".
>> If it works, nobody wants to invest time anymore to look under the hood.
>>  So they always operate on the surface and repeat the same
>> subobtimal programming over and over again because they don't know how to
>> do it better.
>>
> That is absolutely correct.
>
>
> But the point where the "knowing how it works" is just a matter of
> deliberate choice (or the professor, the student or the situation you get
> in and need to crawl deeper into the complexity of the matter.-
>
>
> - do I need know how/why the GUI builder creates the code that makes a
> Button visible on a Form and  my Event handler be called when a button
> is pressed ?  (I.e. do I need to be able to write the code myself without
> the help of the GUI builder ?)
>

Sometimes knowing the internals and details can be a disadvantage because
instead of thinking about the abstract program you are thinking about cpu
cycles, bit popping, bit twiddling, low level API calls.

Sometimes it's nice to live in La La land of an abstract layer over top so
you can focus on the program construct, instead of low level
implementation details.  I for one, do not like doing pure Win Api calls,
even though that can be so much fun for an intellectual exercise. The
first time I really realized this was when I downloaded the Sysinternals
tools (procmon, taskmon, regmon) now which no longer exist as sysinternals
tools and were purchased by microsoft. I was absolutely fascinated that
Mark R. and friend, wrote those tools in pure winapi... I was beautiful
code.

But I was also disappointed that they would waste their time on such low
level code when a lot of it could have been easily abstracted with a tool
like Delphi, with just some winapi calls directly, and most of the stuff
automated with gui widgets already in a vcl.  They didn't use c++ and did
it in pure c, AFAIR.  It was beautiful code, but then I asked my self..
why? why would you waste your time doing pure api calls? Just as
intellectual exercize?

Sometimes it's nice to live in a fairy land (abstract) over top of all the
low level details.

Also, Edsgar Dijkstra was also very much against knowing too many details
about the CPU or computer hardware, as he though computing was math, not
engineering of computers.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Teaching Pascal at College

2016-10-21 Thread Lars via Lazarus
On Mon, October 17, 2016 3:07 am, Graeme Geldenhuys via Lazarus wrote:
> On 2016-10-17 09:52, Michael Schnell via Lazarus wrote:
>
>> - do I need know how/why the GUI builder creates the code that makes a
>> Button visible on a Form and  my Event handler be called when a button
>> is pressed ?
>
> Yes
>
>
> (I.e. do I need to be able to write the code myself
>
>> without the help of the GUI builder ?)
>
> Yes
>
>
>
>> - do I need to know how the startup code works that make the Form
>> visible on the screen ?
>
> Yes
>
>
>> - do I need to know how the Event-Queue and the checksynchronize()
>> system works ?
>
> If you are using queues and Synchronise, then Yes.
>
>
>
>> - do I need to know what system, calls the pascal program performs ?
>>
>
> No
>
>
>
> The rest of your questions were just flame bait so don't deserve an
> answer.
>
>
> If you don't know any of the above, how do you expect to do any
> debugging? Yes, debugging is a major part of being a programmer.


I can chime in on this flame here. Although debugging is a major part of a
lot of programmers life, it SHOULD NOT be.  We should be developing
applications knowing the entire source code of the application in our
minds, without just knowing little tiny bits of the system and "Winging
it".

Today's bloatware applications are so large no one can understand them
which is what attracts me to systems like Oberon by Nik. Wirth, and
OpenBSD, and other small systems that are simple enough you can understand
them in a month of reading about them (the basics).

Also Plan9 from bell labs... and small programming languages, like oberon,
are very interesting because they go against today's trends of bloatware
like Firefox (as much as I love firefox) and Lisp, or Emacs.

The idea that programmers spend much of their efforts debugging, is a bug,
not a feature. Debugging itself, is a bug in a programmers life, that
should be fixed. I love a small program that I rarely debug that's been
running on a server for years without being touched. I dislike so much
apps that need "maintenance".
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Teaching Pascal at College

2016-10-21 Thread Lars via Lazarus
On Mon, October 17, 2016 3:48 am, Michael Schnell via Lazarus wrote:
> On 17.10.2016 11:07, Graeme Geldenhuys via Lazarus wrote:
>
>
>> YES ...YES...NO...
>>
>
> IMHO a personal POV that is not very helpful in a totally general
> discussion (please keep in mind that the intention of the OP to consider
> Pascal instead of C was to keep the students from running away too soon.
>

oberon/golang instead of C are some other options.  The issue with
standard pascal in place of C was that once you figured out the
limitations of the 255 length string and other standard pascal gotchyas,
you not only ran away from C, you also ran away from Pascal.

Apple tried to solve this by extending pascal, which defeated the purpose
of a standard pascal. It was no longer standard. This all written about by
Brian K in "what pascal is not my fav..."

And the story is not so much different today, we have several instances of
pascal floating about: delphi, fpc... and it gets worse: each release of
delphi, breaks the last version so you end up polluting your code with
IFDEF's and version checks, taking away from the actual program and
causign the programmer to be concerned about completely irrelevant details
that have nothing to do with high level abstract programming

Oberon was supposed to solve this by making a standard version of pascal
that was modern, but not calling it pascal since pascal had a bad
reputation. But oberon, sadly, has several versions of itself... active
oberon, object oberon, oberon 1 2 3 4 5... embedded oberon (oberon 7?) so
this "shit" is not much different than C++, excuse my french! As much as I
love all these programming languages we have to stop FORKING everything
and replacing it with a new incompatible version next year.

The time I waste converting old delphi 5 code to work in delphi berlin, or
converting turbopascal units that are really useful over to modern delphi,
is time wasted. I would rather have one language that remained the same
for 20 years and then changed only after 20 years. This seems to be
something that GOLang wants to do, stop making so many incompatible
changes.. We'll see.  Sometimes I just write code in Delphi 5 style and
don't use any other features, to make it portable everywhere.. since any
modern pascal compiler will compile delphi 5 code. The discipline of
sticking to one standards compliant code is difficult. That's what Plain C
is all about I guess, but then you end up wasting your life coding your
own memory allocations.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Teaching Pascal at College

2016-10-21 Thread Lars via Lazarus
On Tue, October 18, 2016 4:42 am, Mehmet Erol Sanliturk via Lazarus wrote:
> One unfortunate situation is that there is not much Pascal software for
> Petri Nets processing , except the following ( which its license is very
> ambiguous means not usable )

Hopefully in these situations, you can find a C dll and then just write a
wrapper, in Pascal, to link the the DLL code.

Any petri related DLL's that you could bind to?

Just because the petri code is written in another language, doesn't mean
you can then use fpc to link to it and write layers around it?

I have no idea of dll's available for petri.. sorry, just offering this
idea. In fact 99 percent of programming today is using other people's code
that is stored away in dll's. The entire operating system is a bunch of
dll's and likely your typical lazarus application only uses 1-10 percent
pascal code and 90 percent DLL code in C.


>
>
> Petri Nets are a vast subject now . There are some Petri Nets processing
> software but their licenses being copy left are not friendly for
> commercial environment .
>

Ahh, the age old license war which I've been a part of and why I prefer
MIT/bsd code...

>
> Actually , it is not compulsory to use Pascal , but Pascal will supply
> the Pascal programming language learners a very good example ,

Again you could also use a combination here: c dll's linked in. If that
works.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Teaching Pascal at College

2016-10-21 Thread Lars via Lazarus
On Tue, October 18, 2016 4:53 am, Mehmet Erol Sanliturk via Lazarus wrote:
> My application was like the following ( as a very simple example ) :
>
>
> Pose a problem "Display your name ."
> After this is done :
>
>
> "Display your name 10 times ."
>
>
> The students were not able to write their programs . Then , solution was
> "You should use a loop ."


How do you know some clever student wouldn't end up using recursion
without any loop involved?

And that leads to a question, should recursion even be used in teaching or
are loops easier to reason about?

I find recursion, although intellectually interesting, kind of difficult
to map in the mind, and I'm skeptical of all the functional languages
using recursion, almost abusively.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Teaching Pascal at College

2016-10-21 Thread Lars via Lazarus
On Fri, October 14, 2016 6:11 am, wkitty42--- via Lazarus wrote:
> On 10/14/2016 07:04 AM, Graeme Geldenhuys via Lazarus wrote:
>
>> On 2016-10-14 12:01, Graeme Geldenhuys via Lazarus wrote:
>>
>>> and maybe incite them every now and again
>>
>> Oops, that meant to read: "...and maybe entice them..."
>>
>
> incite works, too :)
>

I recall Michael V. C. saying you could revoke a person's programming
language... give them an "incitation"

https://s-media-cache-ak0.pinimg.com/564x/20/41/bb/2041bb01aa8b11cb5c715cebd520d12a.jpg
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Teaching Pascal at College

2016-10-21 Thread Lars via Lazarus

>  Both points are important,
> being popular is also important, network effect is important. More users
> means more libraries, more beta testers, more information, more tools. So,
> better frameworks.


Popular isn't always good. Look at perl's Cpan, or heck even java.
Basically if you have a bunch of monkeys typing on typewriters it does not
necessarily mean you are going to get a good book written by monkeys even
if there are 1,000,000 working on it in the same room.

Ruby Gems same thing.  All this popular stuff doesn't necessarily mean
high quality code.

Take something utterly unpopular like Oberon, and you see super high
quality code. Or OpenBSD that virtually no one uses yet it is rock solid
code compared to some of the other garbage out there.

Of course I don't want to reiterate what Paul Graham has said, he wrote an
article about "popular" and it's issues.

>
> Don't underestimate the "popular factor".
>

Certainly. But popular is also analogous to monkeys on typewriters pumping
out quantity, but not quality.

Don't mean to call Ruby or Perl or Java programmers monkeys, but some of
the stuff I've seen come out of that end appears to be of such.

Cpan, for example, is a repository for all perl code. And very popular it
was during the internet days when Perl was the duct tape of the internet.
The fact that they called it "duct tape" should be the first clue...
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Teaching Pascal at College

2016-10-21 Thread Lars via Lazarus

>> Il 13/10/2016 16:48, Reimar Grabowski via Lazarus ha scritto:
>>
>>
>>> If you want modern, teach them Java and let the programs run on their
>>> phones or keep doing console programs and do the GUI in JS (aka web
>>> applications). ^^


Wait, wasn't java killed, the day someone thought up the idea of compiling
other languages to the JVM... LOL. What's the need for java if you can
take any language of your choice, and compile it to JVM.

The great thing about Java is that supposedly it's a small language.. but
hell the libraries make it super complicated.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Teaching Pascal at College

2016-10-21 Thread Lars via Lazarus
On Tue, October 18, 2016 7:23 am, Jürgen Hestermann via Lazarus wrote:
> Am 2016-10-18 um 12:53 schrieb Mehmet Erol Sanliturk via Lazarus:
>
>> Order of teaching is not so critical : As you say , write a GUI program
>> for events : Say : "Now it is necessary to define what will be done for
>> the events ? ... Its way is the following : Write your program parts in
>> that way ..."
>
> IMO the order is extremly important!
> If you start with the fundamental informations
> (how does the processor work in general,
> how are variables stored (stack/heap/etc.), what does the processor do in
> loops, etc.) then this information is remembered very well because
> everybody can imagine what goes on in general. You can *predict* what will
> (should) happen in your program.
>


Hmmm.. I'm not so sure learning about the internals of the CPU is so good.
IMO that is computer science, whereas programming is computing science.

I was interested in how computers physically worked, before I became a
programmer. One of the worst things a programmer can do is think in CPU
cycles because it's a low level detail that has nothing to do with the
program as a mathematical construct.

For example in mathematics when you write equations on paper do you ever
think about how the electronic calculator works, to process these numbers,
when you punch the math into your calculator? The last thing a mathematics
student knows about, is the internal architechture of the Casio calculator
he is using, because he's more focused on the maths... which IMO is good.
To now know anything, and be completely ignorant, of the casio calculator
and how it processes your equations and additions and subtractions, is a
very good thing.

On the other hand, someone interested in physics, and computer science
(not computing science) will benefit greatly from learning how the cpu
works, memory, etc.  Every time they said they were offering "computer
science" courses, as a child I always wondered... is that how the
capacitors, resistors, and cpu chips work? I never once could possibly
grasp how programming a computer had anything to do with the computer
itself. As programming can be done on paper and never touch a computer,
and still be a a program that is understandable even if it doesn't run on
any physical system.

I've been very skeptical of any programmer who immediately converts his
program to assembly instructions. I can see how it is useful for
debugging, and creating a compiler on hardware, but it completely ruins
the abstract program concept. It's equivalent of someone writing a
beautiful mathematics paper, and then converting it to his casio
calculator instruction set. A mathematician would never do such a thing as
he couldn't care less about the internals of his casio calculator. So I
don't understand why so many programmers are obsessed with low level
details. I guess I just find abstract la la land a better place to be in,
where there is even a potential for a program to be proven correct and
never debugged.


>
> If you just start with clicking you do not know *why* it works
> (if it works) nor do you know *why* it does not work (if it does not do
> so). They would always need someone at hand with exprience to tell them
> how to continue. This can be very frustrating for studends.
>
> Therefore I would always present at least a rough overview about
> procedural programming before starting with objects and events. In the
> end, the latter is still processed in a procedural manner which every
> programmer should know.
>
>
>> My application was like the following ( as a very simple example ) :
>> Pose a problem "Display your name ."
>> After this is done :
>> "Display your name 10 times ."
>> The students were not able to write their programs . Then , solution was
>>  "You should use a loop ."
>> "A loop is defined in the following ways : ... "
>> Such an approach is used frequently in Mathematics text books :
>> Subject text .
>> Problems ..
>> Last problems were "Unsolvable" with the above text .
>> Solution :
>> "Read the next chapter ..."
>> Such approaches are "the Art of Teaching" ...
>>
>
> IMO this "approach" has a severe drawback:
> The students do not get an overall picture of what
> *can* be done and *how* it can be done.
> If they do not know about loops how should they
> know that they exist? They would need to read *everything* that is
> available and hope to find something helpful. That is very frustrating and
> can lead to suboptimal solutions because they get tired of reading yet
> another chapter and instead use something else (like copying the code in
> the editor 10 times).
>
> --
> ___
> Lazarus mailing list
> Lazarus@lists.lazarus-ide.org
> http://lists.lazarus-ide.org/listinfo/lazarus
>
>

-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Teaching Pascal at College

2016-10-21 Thread Lars via Lazarus
On Tue, October 18, 2016 9:16 am, Jürgen Hestermann via Lazarus wrote:
> Am 2016-10-18 um 16:47 schrieb Michael Schnell via Lazarus:
>
>> If you start with complex stuff that does not yield immediate success
>> (i.e. a working program that does something that might be useful) The
>> students will loose interest and run away, unless they are nerds like
>> ourselves.
>
> Yes, therefore start with simple procedural (console)
> programs that let them have immediate success with all the elementary
> things that a program consists of (variables/types, loops, commands,
> etc.). If that is understood you can switch to GUI applications.
>
>
> If you do it the other way round you only delay the date
> of frustration but you do not avoid it.
>


There are two sides to this story, I'm afraid. I'm a fan of the console
program teaching method myself but the issue is: console mode programs are
irrelevant and useless.  Today, MS DOS doesn't exist any more. Even when
ms dos existed, console mode programs were boring, and only complete geeks
would be interested in creating console mode programs. We're talking about
people who have no social lives who create text mode games here...

If I was introduced to ComponentPascal (oberon) or delphi as a person
learning programming, where there were actual widgets you could create, it
just might convince me that programming is of some use. Console mode
programs are utterly useless to a newcomer. Wow you created a console mode
program that prints and asks questions... Joy Joy!  I think that's why I
never got interested in Basic, for ms dos... It was on my machine but I
just couldn't see how it was of any use. Now on the other hand if Delphi
was on a windows 3.1 machine I may have even been interested, as you could
just see a person being drawn into wiz bang widgetsets.. that do something
useful, unlike a boring console mode program.

Saying that, I still am a fan of console mode program teaching as it
teaches you about variables, setting values, incrementing, etc.

Today, programmers learn to program in PHP because HTML is the widgetset.
Often a first programming language a person learns is PHP these days, IMO.
And that's sad, as it creates bad habits galore. All because HTML today is
literally "the widget set" being used for programming.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Teaching Pascal at College

2016-10-21 Thread Lars via Lazarus
On Fri, October 14, 2016 4:42 am, Mehmet Erol Sanliturk via Lazarus wrote:
> On Fri, Oct 14, 2016 at 1:18 AM, Michael Schnell via Lazarus <
> lazarus@lists.lazarus-ide.org> wrote:
>
>> On 13.10.2016 10:20, Graeme Geldenhuys via Lazarus wrote:
>>
>>
>>> +1
>>> That would be the best solution. GUI programming is based on
>>> fundamentals than need to be understood first.
>>>
>>
>> -1 !!
>>
>>
>> The OP explained that his main purpose is to introduce more fun in the
>> education.  That can be done by plunging into programming directly with
>> GUI
>> development.
>>
>> This is why RAD had been invented.
>>
>>
>> Of course there are decent drawbacks regarding relying too much on RAD
>> and about not really understanding the fundamentals behind it.
>>
>> But in the end the addressees are non-computer engineers.
>>
>>
>> -Michael
>> --
>> ___
>>
>>
>
>
> As an engineer , they need to write programs for doing computations not
> available in ready-made packages . Therefore , they need to a sufficient
> knowledge to write programs . This can be achieved in a good balance of
> learning programming itself and GUI application .
>
>


The word engineer is so overloaded, that I hate it, with my guts.

What is an engineer? A guy "who makes stuff".. which pretty much describes
every single profession.

Do software engineers have to buy an APPEGA subscription? are they
registered as professional engineers and have to have a degree to prove
it?

I think the word engineer should be kept for the oil and gas industry,
IMO, where buffoons engineer solutions to rape oil out of the ground.

I prefer the term programmer...

I made the mistake of thinking of myself as a software engineer at one
time, but I'm wondering... since engineering requires a membership with an
organization like APEGA, are software engineers misusing the engineer
term?

Now, if you mean "engineer" as in someone who really does hold an APEGA
subscription and is using programming languages to control oil and gas
industry PLC's (logic controllers) then I can understand using engineer as
a title.

Honestly, I just hate the word engineer... as to me an engineer is a
vague, meaningless term.  It essentially means "guy who makes solutions to
problems" or "Guy who makes things"... But since engineers have to have an
APEGA subscription to be a valid engineer, why are programmers using the
term? It's leaked into the industry and profession, which was a big
mistake imo. I just prefer the term programmer. Not hacker. Not engineer.
I'm a programmer.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] How to use strings properly with fixes_1_6 and FPC 3.0.0?

2016-10-21 Thread Lars via Lazarus
On Fri, October 21, 2016 1:03 am, Gabor Boros via Lazarus wrote:
> Hi All,
>
>
> In the past I used Length, Pos, Delete, for i:=1 to Length(s) do s[i]...
> and realized yesterday these practices are wrong. But I do not know what
> the right practice.

Indeed this is a serious problem these days, unicode.. which is almost a
virus. In GoLang they use something called "Runes" to try and solve the
problem.  Off topic but I wonder if Lazarus/fpc uses something anything
similar to golang's rune's approach or looked into it.

IMO unicode reaches something like Godel's incompleteness problem. You can
never actually prove that a unicode program will work properly nor prove
that it won't have bugs, because unicode creates infinite gotchyas and
unicode is always evolving to have more characters that you didn't know
about before.

It makes code inelegant compared to plain english 255 systems like in the
1970's.

There is an interesting article/video about it on Sucksless, and even this
guy scares me when he talks about unicode even though he is trying to fix
the problems:
"UTF-8 everywhere? Writing Unicode compliant software that sucks less,
Laslo Hunhold"

But it of course is not specific to Lazarus. Sorry for slightly off topic.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Chromium embedded on freebsd or firefox embedded

2016-10-21 Thread Lars via Lazarus
On Fri, October 21, 2016 3:07 am, Graeme Geldenhuys via Lazarus wrote:

>
> I don't know about Chromium Embedded, but I did dab with Firefox
> Embedded 4 years ago, and from what I remember it was working fine. I
> never used in in a large-scale application though. I didn't like the large
> dependency I had to include with every application.
>

Ahh, the dependency issue is definitely an issue since the dll's and files
included are massive. Okay for large apps, but for small apps it increases
the download size significantly.

When you dabbed with firefox embedded, was it a lazarus component? Or did
you make calls directly to an API without using a component?

Appreciate Michael V. C.'s article on the topic, in a PDF. Some of the old
links are dead though, referencing the newbielabs website.

-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Teaching Pascal at College

2016-10-21 Thread Lars via Lazarus
On Fri, October 21, 2016 2:11 am, Martin Schreiber via Lazarus wrote:
> On Friday 21 October 2016 09:51:38 Lars via Lazarus wrote:
>
>>
>> I'm not so sure event driven programming is a must to become a
>> competent programmer, I would have to think about that.
>
> "Event driven" probably means that there is an event queue with a central
>  toolkit-main-eventloop which dispatches the events instead a program
> specific flow control.
>

What about a pure win32 API app written in C.  Do you essentially reinvent
your own event system using callbacks with program flow control? Or the
win32 api has an event system in its api itself?  Been a while since I did
some win32 api programming..
I'm just wondering if pretty much every system out there has some kind of
rolled your own event system of some kind.  The other common item that
pops up everywhere is some kind of messaging system to notify objects,
which I guess is what Smalltalk takes credit for.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Chromium embedded on freebsd or firefox embedded

2016-10-21 Thread Lars via Lazarus
On Fri, October 21, 2016 6:04 am, José Mejuto via Lazarus wrote:
>
> Embeded Firefox is not possible anymore via XulRunner as embedded
> support has been dropped by Mozilla.

Really? I heard about them changing the architecture to a new embedded
architecture and no longer supporting an old architecture in the new code
base, but not dropping support entirely for the entire embedded system?

Or lazarus is simply not yet supporting the new architecture they came up
with?


> Firefox embedded does not work properly in Lazarus since Firefox 9 +/-
> and it is not possible to make it work unless forking Firefox xulrunner.

Isn't there a new xulrunner architecutre they created to replace it..
that's what I remember reading. I will find a link to the page and report
back here soon if I find it.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Chromium embedded on freebsd or firefox embedded

2016-10-21 Thread Lars via Lazarus
On Fri, October 21, 2016 8:19 pm, Lars wrote:
>> Firefox embedded does not work properly in Lazarus since Firefox 9 +/-
>> and it is not possible to make it work unless forking Firefox xulrunner.
>>
>
> Isn't there a new xulrunner architecutre they created to replace it..
> that's what I remember reading. I will find a link to the page and report
> back here soon if I find it.
>

As promised, links:

https://github.com/zotero/translation-server/issues/24

Someone says that there is now something called a Firefox SDK or Gecko SDK
instead of xulrunner...

I wonder if it replaces it or is more complicated/difficult to use and not
intended so much for embedding?
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Help System with Chromium Embedded component

2016-10-23 Thread Lars via Lazarus
Now that I think about my post about using chromium embedded for a help
engine, the issue I see is that it's a large dependency .. so for small
applications that are say 1MB large, and you want to supply a help system
with it... all of a sudden the 1mb exe has to be shipped with a gazillion
other files that wouldn't be needed with a more simple format.

Still, I think I will try to release a help system for powtils using
chromium embedded, as an offline experiment with CGI (no web server
needed). However this will take time, and I almost feel like I posted that
chromium idea drunk, even though I was not drinking.

On Sat, October 22, 2016 5:24 pm, Graeme Geldenhuys via Lazarus wrote:
> On 2016-10-22 22:36, Mattias Gaertner via Lazarus wrote:
>
>> Is this a problem of the CHM producer or the CHM viewer?
>>
>
> Both. The LaTeX-to-HTML conversion is definitely not great. Michael
> would agree on this one. Then taking that already bad HTML and converting
> in to CHM, makes the end result even worse. That doesn't do any justices
> for Michael's hard work in writing the documentation and having it
> beautifully presented (like the official PDF versions).

-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Chromium embedded on freebsd or firefox embedded

2016-10-23 Thread Lars via Lazarus
On Sat, October 22, 2016 4:59 am, José Mejuto via Lazarus wrote:
> Hello,
>
>
> Yes XulRunner is being replaced by GeckoSDK, but the main difference is
> that XulRunner had an stable API (frozen) and some semi-stable APIs, so
> most base functions for embed are stable. This is now longer available in
> GeckoSDK where nothing is frozen, API can change from release to
> release and the only way to embed it is writing a C code that generates a
> plain C interface that must link against a moving target.
>

I see! You certainly are very knowledgeable about the subject and have
done a lot of research on it. Now it makes sense to me more.

This api that continually changes, reminds me of MySQL. I wrote web
programs only to find out they broke, when mysql changed their API, and
then freepascal had to release a newer file that linked to the DLL. It's a
nightmare when api continually changes.

I can see them (firefox) changing the architecture to support multiprocess
though.


> I'll try later to find the relevant links I had found in the past about
> this topic, found after spending a lot of hours trying to make morend
> XulRunners work embedded in Lazarus.
>

Your knowledge on the subject is significant! Thanks.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Chromium embedded on freebsd or firefox embedded

2016-10-23 Thread Lars via Lazarus
On Sat, October 22, 2016 7:25 am, José Mejuto via Lazarus wrote:
>
> The link that explains almost anything:
>
>
> https://dutherenverseauborddelatable.wordpress.com/2016/03/07/the-gecko-m
> onoculture/
>
> And the link that shows the embedding problem:
>
>
> http://chrislord.net/index.php/2016/03/08/state-of-embedding-in-gecko/
>

Those are some interesting reads. It confirms my gut instinct to choose
chromium embedded (CEF) for development, instead of mozilla embedded, as
chromium embedded seems more designed for embedding at this stage than the
more immature firefox code.

I wonder how often chromium embedded breaks their api, or changes the V8
engine so that old stuff no longer works.

One thing I'd really like is a single DLL to ship with an application
instead of mounds and mounds of files that these embedded solutions
require. However I guess that's not going to happen.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Run FPC on Raspberry Pi3 in command line mode

2016-10-30 Thread Lars via Lazarus
On Fri, October 28, 2016 11:23 pm, Ken Kashmarek via Lazarus wrote:
> I have been runing FPC v3 on Windows 7 from a command line window.  The
> Windows 7 version of the IDE sucks.
>

By IDE do you mean lazarus, or the freepascal IDE which is different (like
turbopascal).

There is an FPC mailing list too if you just end up using FPC as a
command line program, fpc mailing list is definitely where the questions
sho

> I found everything for starting the IDE but not for
> starting the compiler directly (I will be using my own editor for source
> files).

To use FPC there is no need to install lazarus, you can just install fpc
and run fpc from the command line. Lazarus is geared toward delphi style
development, whereas FPC compiler from freepascal.org is more like a gnu c
compiler at the command line, or, if you prefer, more like turbo pascal if
you prefer to use a bright blue  (keeps you up at night) console mode ide.
There is no requirement to use the console mode ide, nore is there any
requirement to use Lazarus delphi like IDE.

freeepascal.org has downloads and a separate mailing list just for fpc.
THis is the lazarus delphi like IDE mailing list
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Chromium embedded on freebsd or firefox embedded

2016-10-30 Thread Lars via Lazarus
On Mon, October 24, 2016 5:33 am, José Mejuto via Lazarus wrote:

> Hello,
>
>
> Yes, currently Chromium seems to be better, but anyway it will need a
> lot of work starting from the CEF as if my brain serves me CEF API is C++
> so you will find the same problem as Qt interface, a very big DLL/so to
> convert C++ to plain C functions that will need a quite good maintain.
>

http://wiki.freepascal.org/fpCEF3

I was under the impression someone had already done a lot of the work
already porting all the C++ code...

Just wondered if it was usable on BD or mostly focused on Windows and
linux... also macosx interests me.

>> I wonder how often chromium embedded breaks their api, or changes the
>> V8
>> engine so that old stuff no longer works.
>
> As far as I know it is quite stable now.
>
>

Just found out that some things in CEF1 are no longer working in CEF3:
example: they removed the Listener functions which were really useful, now
you have to use javascript listener code instead. So they have broken some
stuff from CEF1 to CEF3 but probably not nearly as broken as firefox
embedded! This is because firefox never started out as a multi process
browser, whereas chromium had a head start on multi process.

>> One thing I'd really like is a single DLL to ship with an application
>> instead of mounds and mounds of files that these embedded solutions
>> require. However I guess that's not going to happen.
>
> No for sure, that will not happen :) unless you use some dirty tricks.
> In the past I was able to "inject" 3 or 4 DLLs in my EXE and use them,
> but only in 32 bits Windows and I was unable to port the code to the 64
> bits windows loader (it basically performs the same actions Windows do
> when load a DLL from disk, but the function loads it from a resource and
> adjust the call pointers and other things as Windows will do it).
>
> Of course that method will not with all DLLs.

Interesting, I've heard of similar delphi tricks before of embedding exe's
or dll's inside exe's in order to ship a single binary .. In fact this
brings back nostalgia of reading about it 10-14 years ago.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Online Package Manager

2016-10-30 Thread Lars via Lazarus
On Fri, October 28, 2016 12:20 am, Balázs Székely via Lazarus wrote:
> Hi,
>
>
> We have made considerable progress with the online package manager. Next
> week the central repository will be populated with 30+ packages. Here is a
>  short video(please watch it in 700p).
>
> https://youtu.be/y_hT8u2u5bU
>
>
> Suggestions are welcome.
>
>

Now all that is needed is something like Torry.net which indexes and
offers search for all the components.  This is something that has kept me
using delphi/lazarus instead of Visual C++, as visual C++ has absolutely
nothing for websites offering components... I have no clue where msvc
users get their components from, they seem to roll their own or use
codeproject.com

The current lazarus code repository on sourceforge and spread about
throughout the wiki is good, but a website like torry.net that centrally
indexes the stuff would be great. In fact I was interested in working on
such a project at one time but paid projects were more of a priority so I
put it on the back burner.

Also, interesting that Torry still has no real lazarus section AFAIK...
it's almost as if torry doesn't much care about fpc/lazarus. There were
rumors that they were going to add it at some point; not sure whatever
happened.

-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Help System with Chromium Embedded component

2016-11-07 Thread Lars via Lazarus
On Sun, November 6, 2016 4:35 am, vfclists . via Lazarus wrote:
> On 24 October 2016 at 00:34, Lars via Lazarus
> 
>> wrote:
>>
>
>> Now that I think about my post about using chromium embedded for a help
>>  engine, the issue I see is that it's a large dependency .. so for
>> small applications that are say 1MB large, and you want to supply a help
>> system with it... all of a sudden the 1mb exe has to be shipped with a
>> gazillion other files that wouldn't be needed with a more simple format.
>>
>>
>> Still, I think I will try to release a help system for powtils using
>> chromium embedded, as an offline experiment with CGI (no web server
>> needed). However this will take time, and I almost feel like I posted
>> that chromium idea drunk, even though I was not drinking.
>>
>> On Sat, October 22, 2016 5:24 pm, Graeme Geldenhuys via Lazarus wrote:
>>
>>> On 2016-10-22 22:36, Mattias Gaertner via Lazarus wrote:
>>>
>>>
>>>> Is this a problem of the CHM producer or the CHM viewer?
>>>>
>>>>
>>>
>>> Both. The LaTeX-to-HTML conversion is definitely not great. Michael
>>> would agree on this one. Then taking that already bad HTML and
>>> converting in to CHM, makes the end result even worse. That doesn't do
>>> any justices for Michael's hard work in writing the documentation and
>>> having it beautifully presented (like the official PDF versions).
>> 
>> --
>> ___
>> Lazarus mailing list
>> Lazarus@lists.lazarus-ide.org
>> http://lists.lazarus-ide.org/listinfo/lazarus
>>
>>
>
>
> I think using CEF is fine as there don't seem to be any other realistic
> options. That is the situation as it is. Something which is likely to get
> more support is "more better" than a perfect but little used and little
> known system. A Lazarus installation currently takes over 1 Gb, so what
> difference does another 300Mb make to it when it is something as critical
>  as help?

I was speaking of a help system for any application, not just lazarus
alone... i.e. you build a 2mb exe and ship it to your customer (not
lazarus.exe but another exe built with lazarus)...

So now your elf/exe has to include a huge dependency... Chromium is not
just one dll. It would be ideal if it was only one dll, like mysqlite.

So if you build a 2-6mb app, now you have to ship yet more files
increasing the size further.

Maybe not a huge issue with todays high speed internet connections, but it
still is another dependency.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Help System with Chromium Embedded component

2016-11-07 Thread Lars via Lazarus
On Sun, November 6, 2016 4:35 am, vfclists . via Lazarus wrote:
> Something which is likely to get
> more support is "more better" than a perfect but little used and little
> known system.

One issue is firefox has a track record of not supporting embedded browser
for very long without abandoning it, or changing the api to make it
incompatible with old code... so who says this isn't also going to happen
with chromium (CEF) at some point... Hopefully chromium will not go down
the same path as firefox embedded. I do know, that CEF1 has some features
that are incompatible with CEF3 so they've already broken some things...
hopefully cef3 stays stable api for a long time and there is no cef4 that
comes out which breaks old cef3 code.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] ctrl-c code completion

2016-11-07 Thread Lars via Lazarus
On Sun, November 6, 2016 10:05 am, Michael Van Canneyt via Lazarus wrote:
>
> press ctrl-c to do command-completion

If ctrl - c is for copying, how does this not interfere?

i.e. ctrl c is for copy and paste, so... how is ctrl-c used for command
completion without interfering with clipboard?
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Help System with Chromium Embedded component

2016-11-07 Thread Lars via Lazarus
On Sun, November 6, 2016 1:18 pm, Graeme Geldenhuys via Lazarus wrote:
> If anybody things installing 300MB just to get some lousy help for a
> small 1MB application is acceptable,

Maybe CEF needs a lite version.  I am guessing that chromium embedded
pulls in a lot of unused code that is not needed for most cef embededded
browser apps.

Would be nice if there was a CEF (chromium embedded) lite which was only,
maybe 10MB. Obviously, I'd prefer a 100KB option over even a 10MB
option

300MB seems awfully like bloatware to me..  is it really 300MB to ship the
latest CEF 3? I haven't checked.  Even if it was 110MB that's still too
large.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Help System with Chromium Embedded component

2016-11-07 Thread Lars via Lazarus
On Mon, November 7, 2016 12:25 pm, vfclists . via Lazarus wrote:
> I mean the latest thing now is
> WebAssembly which shows how ridiculous the whole business has become.


Web assembly, if designed properly, might actually get rid of some
problems. Javascript is a large mammoth, or ugly beast. Web assembly may
allow one to for example compile freepascal code directly to byte code
that runs in the browser, instead of people using ugly obfuscated bloated
javascript "hacks".

It's sort of like a JVM bytecode, but for the web browser. Or a .net
bytecode. I don't fully know what web assembly intends to be, as it's not
completed yet fully, but, it may actually get rid of some of the
javascript bloated crap out there.

Lots of people may in fact ignore webassembly and continue to use
javascript. God forbid.

> It
> is not a fault on Lars end that he sees CEF as the best way to provide
> help. It is just the way things are.

Not necessarily the best, because of the large dependency..

If CEF (chromium embedded) offered a lite version that was only 2MB to
ship with an exe, or 500KB then it may in fact be a good solution for
help..

-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Help System with Chromium Embedded component

2016-11-08 Thread Lars via Lazarus
On Tue, November 8, 2016 3:49 am, Michael Schnell via Lazarus wrote:
> On 08.11.2016 11:42, Michael Van Canneyt via Lazarus wrote:
>
>>
>> I seriously doubt that. It's just something that will exist next to
>> javascript but in essence will perform the same tasks as javascript.
> ==OFF TOPIC== (so ignore if there is not a very short answer)
>
>
> Any plans  for a webassembly support with FPC ?
>
>

There is an old thread about it here:

http://forum.lazarus.freepascal.org/index.php/topic,28836.0.html

Many skeptics, but many think it is an interesting idea even though
skeptical.

And what happened to microsoft silverlight? did anyone care?
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Help System with Chromium Embedded component

2016-11-08 Thread Lars via Lazarus
On Tue, November 8, 2016 3:19 am, Graeme Geldenhuys via Lazarus wrote:
> On 2016-11-08 02:51, Lars via Lazarus wrote:
>
>> It's sort of like a JVM bytecode, but for the web browser.
>>
>
> That makes you wonder, why not simply go back to Java Applets.



One issue, back in the day, was that you could only use Java programming
language, right? At that time no one had thought of multi language jvm
targetting with different originating languages...  all java applets were
java programming language coded, afaik...

I could be wrong.

Another issue with java applets is you had to make sure they were
installed correctly, whereas javascript need not install. With webassembly
I don't think there is a java system you have to install on the machine.
Java applets required first downloading the JVM from Sun, right?


It's been so long since I've seen a java craplet (that's the locker room
talk name for it) that I cannot remember.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Help System with Chromium Embedded component

2016-11-08 Thread Lars via Lazarus
On Tue, November 8, 2016 9:36 am, Werner Pamler via Lazarus wrote:
> Am 08.11.2016 um 15:56 schrieb Martok via Lazarus:
>
>> Hi,
>>
>>
>> I may have missed this point in the discussion, but would it not make
>> more sense to get a native HTML component (either from IPro or the THTML
>> port) to the point where it can provide everything needed?
...
> +1

Well the reason chromium is in my line of sight, is because other people
do the work to maintain the browser for you.  Creating your own web
browser component is massive amounts of work, whereas chromium is coded by
other people.  True you have to write wrappers around it, but you also end
up with a standard component where there are already plenty of c++
examples to learn from, and you are supported by a massive team over at
chromium. Whereas writing your own browser component requires constantly
playing "catch up", implementing every feature needed which chromium had 5
years ago.


So does IPro or THtml have any large following and existing codebase to
work with? I would have to learn about these as I have not used them.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Help System with Chromium Embedded component

2016-11-08 Thread Lars via Lazarus
On Tue, November 8, 2016 3:13 am, Graeme Geldenhuys via Lazarus wrote:
> My point is, for a help system you really don't need the latest and
> greatest HTML5 features. It's simply not needed. What you do want in well
> formatted text, images and some basic rich text styles. Good help is more
> about the contents and the speed of getting to that contents, that about
> the presentation.  But some people are more obsessed about presentation
> with rubbish or near zero content.
>

Agreed, but when you need documentation to look as professional as a PDF
file, HTML 5 could be useful.  I find the documentation, for example, for
Total Commander, to just be a little bit too Windows 3.1 looking. It's may
be good documentation filled with lots of good text, but it feels like
something from Windows 95 or windows 3.1.  For professional software apps
a windows 3.1 look may be just a bit too off putting.  In the case of
total commander, the folks who use total commander are they types of nerds
that don't care. But for modern professional capitalism sold apps, I think
help documents have to look more modern.  As much as I hate modern, just
for the sake of being modern. Like some kind of fashion show.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Help System with Chromium Embedded component

2016-11-08 Thread Lars via Lazarus
On Tue, November 8, 2016 3:42 am, Michael Van Canneyt via Lazarus wrote:
> I seriously doubt that. It's just something that will exist next to
> javascript but in essence will perform the same tasks as javascript. You
> can create relatively clean and structured javascript if you want. It just
> requires discipline as the language doesn't enforce it.

I start off by writing some javascript and I think, hey this isn't so bad.
But eventually after about 10 paragraphs of code it starts to get ugly, no
matter what I try. That's why there is a book written called "Javascript,
the good parts" because it has become such a large mammoth that they
needed to write a book about a subset of java that may (or may not) be the
good parts. Whether those are the good parts or not, is still up for
debate, because I haven't read the book. If I had time..


>
> The problem is IMHO not so much the language, but what you do with it.
>
>

Okay but take brainf*ck language as an example. In this case the language
is in fact a serious problem.  Or take C++.  The language just encourages
you to do nasty things when you need/want to. In order to write sensible
looking C++ code you should... just use a subset of C++, such as C, and
avoid most C++ features. But then you call in some library and they are
using that feature, so, you have to use it too... the issue with
javascript is you pull in a lot of libraries that make use of the features
so you have to end up using them indirectly too.

Again, I guess I should read the book "Javascript the good parts" if I
have time.

>
> Well, there is interest in a WebAssembly backend for FPC.
> Someone is looking at it.
> Just as we are working on a transpiler from Pascal to Javascript.
>


That's good news, and I have no idea how you guys keep up with all this
crap that comes out every year. The work required to port fpc to all these
systems, whether virtual machines, or real machines, is enormous.

What ever happened to LLVM ? much interest? Yet another port to a virtual
machine.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] WebAssembly

2016-11-10 Thread Lars via Lazarus
On Wed, November 9, 2016 2:38 am, Michael Schnell via Lazarus wrote:
> IMHO Silverlight is dying because Java is the winner over C#, due to
> Android systems outselling any other OS architecture.
>
>
> Hence WebASM - that seems to be based on Java - might be successful in
> pushing the idea of allowing for precompiled byte code embedded in HTML.
>

If you mean based on java as in it compiles to a virtual machine like
thing, actually this was more of a pascal thing, and oberon thing, than
Java - java stole the idea from the UCSD-Pascal system, ancient. I wrote
about this long ago...  And, I could be wrong but I think java also stole
from Oberon. i.e. when people credit Java for the idea of JVM, what they
really should be crediting is UCSD Pascal, and then Oberon which succeeded
it... Oberon is 1990's and maybe late 80's technology, UCSD pascal is
ancient. But I'm nit picking.

> Regarding fpc/Lazarus, it obviously would be a huge benefit if on top of
> fpc's WebAdmin support, the LCL would provide decent support for an
> appropriate WidgetType that allows to simply cross-compile a "usual"
> Lazarus project to be runnable in a browser.
>

I'm partial to Marco V.'s post on the lazarus forum I linked.. I think
maybe porting lazarus to web assembly might just result in all sorts of
kludges. Maybe best to start from scratch. But as I said I'm partial: not
fully decided.


-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] WebAssembly

2016-11-10 Thread Lars via Lazarus
On Wed, November 9, 2016 4:02 am, Michael Schnell via Lazarus wrote:
> On 09.11.2016 11:53, Mattias Gaertner via Lazarus wrote:
>
>>
>> WebAsm <> WebAssembly.
>>
>>
>> WebAsm is "A processor for text-based documents (most notably, HTML)".
>>
>>
>> WebAssembly is a subset of JavaScript with some additions, optimized
>> for compiling languages like C/C++/Java to JavaSript. Some browser
>> vendors said they are working on it.
> Thanks for clarification.
>
>

I thought the idea of web assembly was not to compile to javascript, but
to compile to byte code..

We already have tons of tools that compile to javascript, so what would be
the difference between those tools and web assembly..

i.e. I thought ( could be mistaken ) that web assembly put little chunks
of assembly like code in your HTML. Almost like assembly language but
higher level.

Does it really compile just to plain javascript? I thought the idea was to
actually create a new assembly like instruction language and not use
javascript language
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Help System with Chromium Embedded component

2016-11-10 Thread Lars via Lazarus
On Wed, November 9, 2016 3:07 am, Graeme Geldenhuys via Lazarus wrote:
> On 2016-11-09 04:43, Lars via Lazarus wrote:
>
>
>> One issue, back in the day, was that you could only use Java
>> programming language, right?
>
> Hence the name "Java Applet"  ;-)
>
>

But, could one compile fpc code to javaapplet jvm bytecode? Why no one
thought of this idea?  And when I say fpc, I mean literally any language
not just fpc.  We already have tools that convert languages to jvm
runnable code, so why not java applets programmed in other languages?


-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Help System with Chromium Embedded component

2016-11-10 Thread Lars via Lazarus
On Wed, November 9, 2016 3:10 am, Graeme Geldenhuys via Lazarus wrote:
> On 2016-11-09 05:13, Lars via Lazarus wrote:
>
>> I find the documentation, for example, for
>> Total Commander, to just be a little bit too Windows 3.1 looking.
>>
>
> I'll bet you a 6-pack of beer that the documentation was written by the
> developer himself. That would explain the lack of typography. :)
>
>

But it's not just say Ghislers writing style or formatting, but the
general look of the old help systems from windows 95 era.  i.e. any
chm/hlp system appears to be win 3.1 looking, or if not win 3.1, then win
95 looking.

As much as I really appreciate simple text documentation with minimal html
bloat, I'm thinking more of the professional $250 software app or $99
software app that needs to ship a documentation system that will make
people feel satisfied for their dollar.  An old win 3.1/win95 style
hlp/chm system just seems a bit too cheap.

But, I'm nit picking.  I do appreciate simple documentation without eye
candy crap.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Help System with Chromium Embedded component

2016-11-10 Thread Lars via Lazarus
On Wed, November 9, 2016 7:57 am, Marco van de Voort via Lazarus wrote:
> The frequent updates that often break interfaces are also an headache.
>

This is what happened to firefox: xul runner's current state is
broken/unknown/scary. I hope the same doesn't happen to chromium.
Cef1 has some incompatibilities with cef3 but at least not as bad as the
firefox embedded xulrunner state of affairs.

> If I would replace lhelp and chm, I wouldn't go that way, but some way
> with a local webserver (for searching and the like), and just use whatever
> is installed.
>

A local web server as in running on port 80?

The issue I see here is what if someone has apache installed already?

The advantage of no web server at all is you have no conflicts with port
80 already running an apache instance.

But maybe I misinterpreted what you are saying.

-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Help System with Chromium Embedded component

2016-11-10 Thread Lars via Lazarus
>>> The best reason to have some local (whatever how limited) widget is
>>> for IDE popups of helptext instead of an external browser.

External browser requires alt-tabbing away from the ide which is a pain. A
external browser cannot be communicated with once you open the html file.
with a local widget, you can communicate with that widget. With an
external browser, once you've loaded the page there is no way to
communicate. An an external browser doesn't offer a search system if it's
a static html file served off line.  So then you end up with people just
using google and online help and stack exchange, instead of reading
documentation.

My idea with chromium embedded is to write the documentation for an online
web server, but then easily port it to offline documentation served with
chromium embedded. No local web server needs to be installed on port 80
conflicting with any other servers on the users computer. Html anchors can
be used to scroll to certain parts of the documentation. Or if anchors are
not enough, there is always javascript.

But, my idea of using chromium embedded is sort of a dream ruined. Because
of the large 100+MB dependency it pulls in, as pointed out by others (i.e.
Graeme said 300MB, maybe that was exaggeration).

A local ngnix server or similar could serve documentation (or even nYume
or Aservia) however this requires that a port 80 be tied up, or another
port alternative to port 80 which may be blocked by firewall. That I would
want to avoid, as it's just another hassle.

It's amazing someone hasn't thought of a web server that works off line,
that uses no ports, and just runs as some kind of plain Exe not using any
http port... Not sure if this is an absurd idea (actually, that's kind of
what chromium embedded is).
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] WebAssembly

2016-11-11 Thread Lars via Lazarus
On Fri, November 11, 2016 2:23 am, Michael Schnell via Lazarus wrote:
> On 11.11.2016 01:33, Lars via Lazarus wrote:
>
>> Maybe best to start from scratch.
>>
> Regarding the Lazarus paradigm "write once, compile and run everywhere",
> IMHO not a good idea.

The issue is you are working in a sandbox. Lazarus is designed to take
control of the computer using all the dangerous things without any
sandbox, such as being able to delete and write to pretty much any file
you want that has the correct permissions in place. A sandbox is much more
specialized to develop for, because you may only be able to access certain
directory with limited files

So you could modify lazarus to work with this sandbox restriction, but,
might be easier to design from scratch. ...

I understand the desire to just take existing LCL app and port it to the
web browser, but that's a pipe dream, because browsers will be in
sandboxes that just don't work like client applications on Ms Windows,
BSD/Linux.

Another option is just to use a separate widget set and see how that
works, such as fpGUI widget. But I guess that means you can't as easily
take an existing app and port it.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Help System with Chromium Embedded component

2016-11-11 Thread Lars via Lazarus
On Fri, November 11, 2016 3:54 am, Graeme Geldenhuys via Lazarus wrote:
> On 2016-11-11 00:53, Lars via Lazarus wrote:
>
>> I do appreciate simple documentation without eye
>> candy crap.
>
> :)  Just take a look at Apple's OSX built-in help (not the online
> content). It is minimalist and mostly text - with a hint of good
> typography. It works! Microsoft Windows 7 does very similar to Apple -
> simple and elegant.

I've always liked the website delphibasics .co .uk (or whatever the
address is).

Would the current help systems be even capable of looking like that?  Must
be just a few div boxes.  Really simple, interesting color shades. No
fancy garbage, just simple boxes of text.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Help System with Chromium Embedded component

2016-11-11 Thread Lars via Lazarus
On Fri, November 11, 2016 4:03 am, Graeme Geldenhuys via Lazarus wrote:
> On 2016-11-11 01:11, Lars via Lazarus wrote:
>
>> port alternative to port 80 which may be blocked by firewall. That I
>> would want to avoid, as it's just another hassle.
>
> You can always use any other port >1024 for that.

No issues with default firewalls?  Last thing I want, is a customer having
to futz around with router firewall, windows firewall, etc.


> But for help, firing up Chrome of Firefox is just too damn slow, and
> eats way to much memory. Also you will have to implement your own search
> (which will be slow over HTML files), table of contents and index pages.

But isn't that what iota full text search is for, to preindex all the
search stuff so no time is spent grepping through html files

The issue with Iota I found was that it was written in an old fpc style
where some things are not proper code, but compiled at that state of fpc
development.  iota, if you don't know, is a full text search indexing
library for fpc.  Discussed briefly on the fpc mailing lists eons ago.

> Then what about other useful features like bookmarking a help topic,
> inline annotations (user defined notes added to a help topic at runtime).
>

User defined notes, were not available in chm files were they? I thought
chm/hlp file were just dumb, fixed help files with no bells an whistles.
i.e. total commander style help.

With a chrome embedded browser object, you can use the DOM to manipulate
the document. That's basically how chrome plugins work in the browser
where you can modify the html page and add widgets to someone else's site,
on your client side. If you wanted to add notes to html help you could use
the DOM to do it and store those extra notes in a database, or something. 
I'd be interested in how many people do this: add notes to their help,
inline.  We know that people add notes at the end of the documentation,
like the php manual where people add comments to the bottom of the page. I
didn't realize there were help systems were you could inline some notes?


> As for communications with a external [dedicated] help viewer. fpGUI's
> Docview does that via IPC, Microsoft's WinHelp I think could do it too,
> OS/2 VIEW help viewer did lots of 2-way communications with applications.
>
>

Which is an interesting question: why hasn't firefox allowed IPC from
external apps. Could be a security vulnerability. Maybe just one of those
interesting features that could be, should be, would be, but no one has
thought of implementing.  If firefox had IPC you could navigate to an
anchor from an external exe.

Also an interesting question is why hasn't adobe got something like this
so that adobe files could be used as help files: scroll to a certain part
of the pdf file programmatically using IPC, or maybe using an adobe
embedded object.  I find pdf files just a little too slow, though, and not
as responsive, due to them being like a resource intensive graphic. So I
suppose pdf files ruin the zippy feeling of a fast help system.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Help System with Chromium Embedded component

2016-11-11 Thread Lars via Lazarus
On Fri, November 11, 2016 4:37 am, wkitty42--- via Lazarus wrote:
> what's wrong with something like LHelp and using IPC to tell it where to
> load the next help from that the user has asked for??
>

I'll have to experiment with LHelp, thanks

> from these cheap seats i have way over here, it seems like you are over
> engineering this...
>

Anyone who pulls in a 150MB-300MB chromium embedded plugin is likely over
engineering (not to mention bloatware).

I'm critical of my own original post. Would be much better if there was a
chromium lite version that you could embed which was only 2MB or 1MB.

One plan I had was to simply port an existing html documentation system
that runs on a cgi program on a server, over to offline help, with minimal
effort. Chromium embedded seemed the way to go because you can literally
trick chromium embedded into being a cgi like device, on the client side,
without any web server.

Whether LHelp can do that, is something I'd have to research.

I have some existing projects where the help system is already in place,
on a server, and I don't much feel like writing two sets of help systems
one that works offline and one that works online, I'd rather just have one
system that works online and offline. So I figured CEF3 or CEF1 would be a
way to make already existing online documentation, work offline too.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Help System with Chromium Embedded component

2016-11-11 Thread Lars via Lazarus
On Fri, November 11, 2016 4:23 pm, Graeme Geldenhuys via Lazarus wrote:
> On 2016-11-11 22:46, Lars via Lazarus wrote:
>
>> Would the current help systems be even capable of looking like that?
>> Must
>> be just a few div boxes.  Really simple, interesting color shades. No
>> fancy garbage, just simple boxes of text.
>
> I don't know how much CSS the HTML component in LHelp supports. But if
> you look at the source of that website, they actually use HTML tables


Holy batman, they are using tables? Wow.. I was sure it was a Div box
based website but they are using classic tables. Interesting.

> By using colour like that, you are also limiting your audience - eg:
> what about colour blind people?

Would be interesting if there was a firefox/chrome plugin that converted a
website to be all black and white to help people, or maybe grayscale.  But
good point.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


[Lazarus] LHelp or help systems that also work on..

2016-11-18 Thread Lars via Lazarus
Hi,

Since I use both Lazarus and Delphi and never just use one or the other,
is there any help system that works in both delphi and Lazarus? i.e.
anyone port LHelp to delphi so delphi apps can have a similar help system?
Or any other help systems that are portable between Laz and Delphi?

I haven't studied much, but my guess is LHelp was specifically built for
Lazarus and never considered Delphi, due to the name "L Help" which stands
for maybe lazarus help.  Assumptions here...


-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] LHelp or help systems that also work on..

2016-11-19 Thread Lars via Lazarus
On Fri, November 18, 2016 5:08 am, Andrew Haines via Lazarus wrote:
> lhelp uses IPC to communicate so it wouldn't be too bad to write a Delphi
> unit to control it. Compiling lhelp though is a fpc only job.
>
> https://github.com/graemeg/lazarus/blob/upstream/components/chmhelp/packa
> ges/help/lhelpcontrol.pas
>


Thanks for the tip. So I see many people are using SimpleIPC. Has anyone
come across any problems. When I tried it when it very first came out
almost days or weeks after the first release of it, I noticed some
duplicate messages being passed. Not sure if it was my problem or the IPC
unit problem. Seemed like a really neat tool, SimpleIPC.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] LHelp or help systems that also work on..

2016-11-19 Thread Lars via Lazarus
On Sat, November 19, 2016 3:24 pm, Lars wrote:
> On Fri, November 18, 2016 5:08 am, Andrew Haines via Lazarus wrote:
>
>> lhelp uses IPC to communicate so it wouldn't be too bad to write a
>> Delphi
>> unit to control it.

p.s. in addition to my last message, wouldn't SimpleIPC need to be ported
to delphi then..  or at least some of it's mechanism.

Would be neat if simpleipc was available in delphi so fpc programs could
communicate to delphi programs.  If only simpleipc was standardized and
available in all languages ;-)
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


[Lazarus] stale pipe workarounds

2016-11-19 Thread Lars via Lazarus
Hi while researching help systems I came across the code which uses IPC to
communicate and see that people are adding stale pipe work arounds.

So this can't be resolved in the ipc code itself and must be in the
application?  Just wondering why these work arounds are needed and when
they occur. The stale pipe code work around is at

https://github.com/graemeg/lazarus/blob/upstream/components/chmhelp/packages/help/lhelpcontrol.pas

So does anyone who uses IPC have to be aware of this and add the work
around to all ipc code in all applications?  Or it only happens in certain
cases? It just makes me scared that there is this hack/fix needed.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] LHelp or help systems that also work on..

2016-11-19 Thread Lars via Lazarus
On Fri, November 18, 2016 6:16 am, Graeme Geldenhuys via Lazarus wrote:
> On 2016-11-18 11:36, Lars via Lazarus wrote:
>
>> Since I use both Lazarus and Delphi and never just use one or the
>> other, is there any help system that works in both delphi and Lazarus?
>
> Yes, Docview and INF help can be used in both cases.

Docview is an fpGui based project?

If so that would be interesting and maybe my ticket into finally looking
at some fpGui code
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Lazarus and MySQL 5.7

2016-11-22 Thread Lars via Lazarus
On Mon, November 21, 2016 2:33 am, Graeme Geldenhuys via Lazarus wrote:
> On 2016-11-21 00:30, Giuliano Colla via Lazarus wrote:
>
>> Lazarus 1.6 includes the package SQLDBLaz which provides support for
>> MySQL from
>> versions 4.0 to 5.6.
>
> Yes, and that "Lazarus Packages" is simply a IDE wrapper around the
> components included by FPC's fcl-db code. You don't need Lazarus to use any
> components or classes introduced by FPC.
>
>
>> Looking into the sources, version 5.7 is already there, but the package
>> doesn't support it
>
> It is pretty straight forward to create a new "registered component"
> line in the Lazarus packages [SqlDBLaz], which in turn will register a
> icon/component in Lazarus's component palette.
>
> Too many developers don't seem to understand the underlying workings of
> components or classes. If they don't see it in the component palette they
> don't know how to use it. It is just sad how "RAD development" has dumbed
> down so many developers.
>

But this is one issue with components is once you create your own rolled
component, it becomes a non standard component available in only your IDE
and no one elses...

Every time I think about inheriting a component and creating my own, I
stop myself and try to just use the built in component palette ones
wherever possible As sort of a "I know the standard components will
always be there" but my own rolled components may not.. if I do a fresh
install of an IDE on another system, etc. Then it requires using non
standard components.

But as for mysql, obviously once someone ports the component it will
become standard and be shipped with the ide. I'm speaking of other cases.
Like say inheriting a button and creating my own... then I'm using a non
standard component and it makes me scared.

Just what I've found anyway, that the biggest scariest thing about
creating your own components, is they are now non standard not shipped
with the IDE.

I first realized this when I needed a button that had new behavior in
Delphi.. so I created my own. Then I realized that any time I install the
IDE on a system, I now have the headache of having to install a non
standard component in order to use it.

As powerful as creating your own components is, it also comes with some
drawbacks.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


[Lazarus] macOS Sierra save as dialog hangs

2016-11-30 Thread Lars via Lazarus
Hi, Not sure if this has anything specifically to do with Sierra version
of MacOS but that's the only Mac I have to test on..

When I run the latest Lazarus from source forge download section, on Mac
Sierra OS version, The IDE loads up and works fine except for when I try
to save the project.

If I click any of the drop down menu items in the save project as dialog
it hangs, with the spinning multicolor cursor and will not stop unless I
force the application to quit.

In addition, clicking the save button hangs in that dialog if I don't
click any of the drop down items.

Anyone on Mac had this issue?

I ran a disk first aid to make sure my hard drive is not the cause.

Then as an experiment I opened a new project (after forcing lazarus to
quit then restarting it) and added a save dialog widget to the form. I
launched the application without saving it and executed the save dialog.
This one does not hang, i.e. in project1. However the lazarus app itself,
hangs when save dialog accessed..

Wondering if this is a Sierra issue specifically. Not positive it is
because I've seen other Sierra users on the internet able to use lazarus.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] macOS Sierra save as dialog hangs

2016-11-30 Thread Lars via Lazarus
On Wed, November 30, 2016 2:31 am, C Western via Lazarus wrote:
> May be http://bugs.freepascal.org/view.php?id=29911
> which is supposed to be resolved in the trunk version.
>
> See also http://bugs.freepascal.org/view.php?id=30533
>
>
> Colin
>

Thanks. Just applied the patch to my local copy, instead of downloading
entire source tree.

Fixes the issue.. on my computer.

Wow - fast reply, fast fix! Thanks (power of open source).

As for my new Mac Laptop though, not too impressed with the zippiness it
does not have compared to all my windows laptops ever owned. This thing is
slow! Oh well.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] SQLite & DB Aware Components

2016-12-05 Thread Lars via Lazarus
On Fri, December 2, 2016 9:18 am, Martin Collins via Lazarus wrote:
> The weird thing is that when creating my fields the visual database
> managers did not have the option of VARCHAR only TEXT (plus INTEGER, BLOB,
> REAL & NUMERIC), but I just found I can create a VARCHAR field by
> executing your SQL statement above! Further reading on sqlite seems to
> suggest that VARCHAR isn't really stored that way as SQLite just treats it
> as unlimited TEXT?
>

SQL lite, is not a database, it is a sloppy untyped dumb text storage
system, that is called a database even though it really is not...

It's perfect for when you need something a little more advanced than plain
text files, but in no way, is it an sql or relational database, even
though it accepts SQL language to access it..

Basically, it's one little step better than using plain text files... and
it is easier to ship than mysql embedded or other tools that require more
complex setups. Actually I haven't looked at mysql embedded recently, to
see what they are up to  And as we all know mysql has a reputation of
not being a proper relational database either!

But despite sqlite being a poorly typed, weakly typed, basically dumb
database which isn't even a database... It is still a useful tool, and one
step better than Xml files, or plain text storage in plain files.

Whenever choosing sqlite, I always tell myself: remember, SQL is NOT a
relational database even though it claims to be one, so be prepared to use
it carefully, as a dumb text storage system just like plain text files.
With this warning in mind it is a very useful tool.

Fabian Pascal has something to say about it, if anyone claims it's
relational.. or typed...  The typing system in it is a joke, it basically
ignores types. As do plain text files when you save stuff to them.. You
can reinvent your own typing system though by doing careful checks.  When
using sqlite it's almost like a static/strong type programmer choosing to
use a weakly typed programming language with dynamic types: it feels odd
and strange that there is not this sterility involved with proper checks
in place. But that's exactly kind of what like using plain text files is
like... you have to store plain text and do checks at run time for
issues... So sql lite is basically, a plain text organization system. It
is, I repeat, NOT a relational nor an sql database... And Fabian Pascal
can say it much better than I can with his attack on it.

Still, a useful tool: just be warned.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] DoomRL based of FPC now open sourced

2016-12-07 Thread Lars via Lazarus
There was also the original doom source code released in C, which was
converted 100 percent to Delphi, and then I modified it to work with
FPC... had some bugs, that were worked out.

Not sure what the difference between actual original Doom and DoomRL is

There is also Quake for delphi, and quake for fpc which I also worked on
and it had some bugs, which AFAIk may have been worked out by someone

On Wed, December 7, 2016 6:18 pm, Kostas Michalopoulos via Lazarus wrote:
> And cue all the people in Reddit yet again reminiscing about their Turbo
> Pascal days. And those are the best comments :-P.
>
>
> Yesterday i wrote a rendering test for light clustering with forward
> rendering (https://www.youtube.com/watch?v=MefoEXK1gUw). It has been a
> while since i wrote something more advanced than early 2000s stuff in
> terms of graphics and when it comes to Lazarus, it has been a while since
> i worked on non-tool stuff (although, the math stuff in the demo was from
> my tool package :-P).
>
> I don't see FPC and Lazarus as lacking anything in terms of features or
> performance for use in high end games. Well, except perhaps runtime
> support for consoles, but that isn't unsolvable (and has already been done
> with another low key compiled language - AFAIK Remedy used D for some
> parts of their latest game and had to port the language's runtime to
> consoles).
>
> And well, not everyone is interested in consoles anyway :-P.
>
>
>
> On Thu, Dec 8, 2016 at 2:36 AM, Graeme Geldenhuys via Lazarus <
> lazarus@lists.lazarus-ide.org> wrote:
>
>> On 2016-12-07 17:44, Anthony Walter via Lazarus wrote:
>>
>>> DoomRL was written using Free Pascal.
>>>
>>
>> That's just awesome!  Thanks for sharing.
>>
>>
>> Regards,
>> Graeme
>>
>>
>> --
>> ___
>> Lazarus mailing list
>> Lazarus@lists.lazarus-ide.org
>> http://lists.lazarus-ide.org/listinfo/lazarus
>>
>>
> --
> ___
> Lazarus mailing list
> Lazarus@lists.lazarus-ide.org
> http://lists.lazarus-ide.org/listinfo/lazarus
>
>

-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] FPC on Rpi3 executable module sizes

2016-12-07 Thread Lars via Lazarus
On Sat, December 3, 2016 8:58 am, Ken Kashmarek via Lazarus wrote:
> I have solved the problem with modules sizes when compiled under Lazarus
> FPC
> 3.0.0 on RPi3.
>
>
> First, I am able to perform scripted compile and link operations (ie, not
>  done via the IDE).


Another option is to write your script, and launch it with a tools menu
item in the ide. Not integrated compiling, but at least you can compile it
from a menu item in the ide.

Tools -> Configure External Tools

Then at least you don't have to run to the command line window manually,
you just click a menu item button or use a keyboard shortcut

-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] DoomRL based of FPC now open sourced

2016-12-13 Thread Lars via Lazarus
On Wed, December 7, 2016 9:55 pm, Anthony Walter via Lazarus wrote:
> Lars,
>
>
> DoomRL has nothing to do with Doom, other than borrowing the
> theme/setting. It's a rogue-like game or RPG in a Doom setting.
> --

True, just thought I would mention, incase anyone had forgotten about
these projects years ago.. Someone ended up forking/copying some of my
work and other peoples work into GitHub projects:

https://github.com/mariuz/quake2fpc

http://www.pascalgamedevelopment.com/showthread.php?4090-DoomToFreepascal-2-1-4

-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


[Lazarus] macOS developer files and bindings to be created

2016-12-25 Thread Lars via Lazarus
Hi, I noticed some of the macos lazarus implementations are incomplete
(for example AVFoundation doesn't seem to exist anywhere) so the question
is if I want to create an avfoundation library, where do I start?

First I would try to find macos header files/include files, and where are
they on my system? (Mac Newbie here!) Would I have to download XCode and
they come with it? Or have to find them elsewhere from apple web site?

And are there automatic conversion tools or it is all done manually,
typing in objectivec1 mode into freepascal and creating pascal bindings
all by hand..?
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Why is SAX so slow?

2016-12-25 Thread Lars via Lazarus
On Sun, December 25, 2016 4:47 am, Werner Pamler via Lazarus wrote:
> Motivated by a user comment on excessive memory consumption of
> fpspreadsheet


Sorry to not answer your question, but, fpspreadsheet looks very
intereresting and first time I really looked..  So it is a spreadsheet
without using any MS COM or activex to utilize ms excel?  A native
spreadsheet for lazarus?  Cool! Something I'll probably need some time.
Any crashes or major issues, other than slowness being reported in this
thread now?

-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] In search of a component for holding a table of strings

2017-01-06 Thread Lars via Lazarus
On Fri, January 6, 2017 5:40 am, Bart via Lazarus wrote:
> Mind you FF is able to copy the table in plaintext format using Tabs
> as a separator, which would be easy, but IE (which is the only browser
> available to me on the system) cannot do so.
>
> Obviously my boss does not care, he does not have to use this program,
> only the doctors (12 of them) have. And needless to say that the ICT
> department has forbidden me to use this program, because "it is not a
> commercial progra, and therefore there is no offical support for it, and
> unsupported programs cannot be installed on our system". (Note: the ICT
> guys all use Chrome as their browser, because "IE sucks") Fortunately my
> program is standalone (try that with VB or VC), so I just put it somewhere
> on a share, and so far they have not noticed.
>

If you get into some tricky web browser issues you can also visit the DOM
with internet explorer embedded browser control.. (or firefox embedded or
chromium embedded). Then you can copy whatever html table you want into
whatever format you want... just visit the table via the dom, or visit any
of the html web page components and deal with it.

But if fast html parser does the job... it's simpler.


-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] In search of a component for holding a table of strings

2017-01-07 Thread Lars via Lazarus
On Fri, January 6, 2017 10:35 am, Bart via Lazarus wrote:
> On 1/6/17, Michael Schnell via Lazarus 
> wrote:
>
>
>> Instead of a two dimensional array of strings you could have use a
>> single dimensional array of StringLists (a less symmetrical way, of
>> course).
>
> That was my frist try (see:
> http://svn.code.sf.net/p/flyingsheep/code/trunk/FarmedTools/tableemulator.
> pp), but then you run into troubles when a string contains a LineEnding...
>

Isn't there a way to change LineEnding to something like a dummy that
never gets read...

Or maybe I am confusing Delimiter for CSV values

Should line ending be modifiable to anything someone wants?
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Semicolon checking

2017-01-15 Thread Lars via Lazarus
On Sun, January 15, 2017 3:30 pm, Vojtěch Čihák via Lazarus wrote:
> Hello, has Lazarus (CodeTools) or FPC some checking for empty commands? I
> accidentally did this stupid mistake:  
> if ... then begin
>
>   end else;
>   begin
>     ...
>     exit;
>   end;
>  

Yikes! I think you just discovered a bug in the pascal language itself
that was not thought of... as when using a text editor it's easy to leave
a semi colon laying around by accident some times.

I wonder if Oberon solves this issue, or semi-colon-less languages have
any advantage.  If you remove the begin from a language (Wirth did in his
later languages) you get rid of some issues.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Changes to fpWeb...

2017-01-16 Thread Lars via Lazarus
On Mon, January 16, 2017 12:19 pm, Daniel Gaspary via Lazarus wrote:
> On Mon, Jan 16, 2017 at 8:12 AM, Michael Schnell via Lazarus
>  wrote:
>
>> Does fpweb / weblaz already support status messages from the server to
>> the client (or will it some day) to allow for "Rich Web Applications") ?
>>
>
> I don't work very often with web, but I'm curious...
>
>
> Can you give examples of these messages? And who (nginx, apache..?)
> and how they are implemented?
>
> Thanks.


Indeed, does he mean javascript pop up messages, but initiated by the
server? when is the message displayed and why would it be displayed?  an
ajax on the current web page loaded, but initiated by the server?

-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Teaching Pascal at College

2017-01-16 Thread Lars via Lazarus

> On Sunday 15 January 2017 15:30:44 Martin Vahi via Lazarus wrote:
>
>>
>> I haven't used Lazarus yet, I need to learn it,
>> but during the development of my own JavaScript GUI library I have came
>> to a conclusion that GUI-s are inherently something that require "dynamic
>> programming" or the code gets really bloated.
>>

GUI's require wrappers.

Delphi 5 as an example, is a wrapper around the win32api

All successful programming projects are just good wrappers. (everything is
a wrapper)

If you program GUI's yourself from scratch, you waste thousands (if not
millions) of lines of code instead of having a tool that already wrapped
it and abstracted it for you and put it in a reusable library (again a
wrapper)

-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Teaching Pascal at College

2017-01-16 Thread Lars via Lazarus
On Mon, January 16, 2017 3:19 am, Michael Schnell via Lazarus wrote:
> On 15.01.2017 15:30, Martin Vahi via Lazarus wrote:
>
>> have came to a conclusion that GUI-s are inherently something that
>> require "dynamic programming" or the code gets really bloated.
>>
>>
> The nice thing about Lazarus "RAD" paradigm is that this is completely
> hidden (in the library) from application programmer. So (s)he only needs to
> write the code that is obviously useful for the task at hand.

Except when you find a bug in the lcl, and have to dig in to it..

In theory one could never look into the lcl or underlying api's

in practice, sometimes there is an issue to be resolved... like when I
fired up the macOS laptop and found that moving the mouse crashed the app,
and Dmitry helped me figure out why ;-)  Had too look into the macOS
related lcl code
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Changes to fpWeb...

2017-01-16 Thread Lars via Lazarus
On Mon, January 16, 2017 1:59 pm, Leonardo M. Ramé via Lazarus wrote:
>> Indeed, does he mean javascript pop up messages, but initiated by the
>> server? when is the message displayed and why would it be displayed?  an
>>  ajax on the current web page loaded, but initiated by the server?
>
> I think he is talking about WebSockets. The only framework I'm aware of
> implementing it is m0rm0t.

What is the exact name of it... couldn't find it:

https://www.google.com/search?q=m0rm0t+web+sockets

maybe a spelling mistake or slightly different name?
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Teaching Pascal at College

2017-01-17 Thread Lars via Lazarus
On Tue, January 17, 2017 2:22 am, Graeme Geldenhuys via Lazarus wrote:
> On 2017-01-16 20:18, Lars via Lazarus wrote:
>
>> GUI's require wrappers.
>>
>
> No they don't.
>

Sane GUI programming requires wrappers...

Insane programmers will program a GUI without a wrapper...
;-)


>
>> Delphi 5 as an example, is a wrapper around the win32api
>>
>
> Yes, Delphi's VCL is a wrapper around the common Win32 widgets. LCL is a
> wrapper around Win32, Qt, Cocoa, Carbon and even fpGUI. But not all GUI
> toolkits are designed like than.
>
> For example, fpGUI is not a wrapper around any existing widgets on any
> platform. fpGUI implements its own widgets (gui controls) from scratch and
> talks directly to the underlying libraries (XLib & GDI) to notify the
> system about the top-level window and receiving OS events.

fpGUI is, in every way possible, a wrapper.

It wrapps low level x11/win32 calls into a usable frameworks called fpGUI

Object orientation is often a wrapper around system calls, fpGUI is object
oriented and makes low level calls so someone can use fpGUI as a wrapper
around these obnoxious insane low level calls that no one wants to use
directly.
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Running an app on boot

2017-01-25 Thread Lars via Lazarus
On Wed, January 25, 2017 6:26 am, Paul Breneman via Lazarus wrote:
>
> Or switch to a Raspberry Pi and use https://Ultibo.org ?  Maybe Ultibo
> can be ported later to Beaglebone?
>

Beaglebone is more "open" hardware than pi but I guess that's another
topic. The price of pi certainly is attractive compared to beagle bone
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Saving namespace files on WinXP

2017-01-29 Thread Lars via Lazarus
> On 1/27/17, Marcos Douglas B. Santos via Lazarus
>  wrote:
>
>
> If you try to save a file that has a "namespace" like
> "foo.bar.unit1.pas" the IDE won't put the file extension.
>
>
> Is this a known bug?
>

But why save an fpc unit with dots in it, does this file syntax even get
accepted as a unit?

Delphi has this:
https://sergworks.wordpress.com/2011/08/09/dotted-unit-names-in-delphi/

So it would conflict/confuse with that feature?

Can you even compile an fpc unit that has dots in it? Did fpc ever
implement the delphi dotted namespace system?  (sorry, I tend to avoid new
features and stick with the old, so I have no clue)
-- 
___
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus


  1   2   >