Re: [Lazarus] Android Target GUI

2012-02-17 Thread michael . vancanneyt



On Fri, 17 Feb 2012, Marc Santhoff wrote:


Hi,

I'd like to know, how GUI building for Android is handled using Lazarus.

I have pretty much no idea of the Android SDK or things, but I
understand that this target involves compiling the code to Java byte
code. The details are not what I need at the moment, only a broad
overview how things work together and what role Lazarus plays in the GUI
part.


There are 2 approaches:

1. Do as Felipe does. He has described how it works.

2. Use the JVM backend. In that case, you make direct use of the Java
   classes and the android API. Your app willl look and behave like any
   other Android app. (I am not sure what Felipe's approach results in)

In the second case, Lazarus offers no help except that it's an excellent
Pascal editor/compiler. But the GUI designing part of Lazarus is then not
used. You must create the XML files manually.



How is the GUI specified, is it drawn like building a form or is it made
by drawing on a canvas in code?


Android uses XML files to specify the layout. This is the recommended way by
Google. You can build the GUI in code as well, but then you're pretty much in
uncharted territory.



Or does Lazarus/fpc only generate the event handlers an making a GUI is
a seperate task for a HTML designer or the like?


The android API does not know event handlers as Object Pascal does. 
It has some form of callback objects, which are pretty much the same thing, yet 
they work slightly different.


Basically, your class must expose a certain interface, and then it can be
assigned as the 'event handling object' to the GUI control.

It's probably easier to see it work in code than explain in words :-)

I just wrote an app in this way. It has about 160 lines of code (including
declaration) for a 2-form program that talks to a database to show some
stuff on screen.

Michael.

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


Re: [Lazarus] pppoe dialer

2012-02-17 Thread ik
On Wed, Feb 15, 2012 at 20:37, Osvaldo Filho  wrote:
> Hi, all!
>
> Can anyone help me with some information on how I can create a "dialer" for
> a PPPoE connection?
>

Are you looking for a direct dialler or a ui for a dialler ?
You can use the Linux pppoe-connect for example and create a ui that
execute it in the background and handle all of the configuration
files.

> Grateful.
>
> --
> ___
> Lazarus mailing list
> Lazarus@lists.lazarus.freepascal.org
> http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
>

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


Re: [Lazarus] [fpc-devel] Documentation contribution

2012-02-17 Thread Michael Schnell

On 02/16/2012 04:31 PM, Hans-Peter Diettrich wrote:

Remove crappy or questionable content, instead of only adding a note?
Not a good idea. even questionable/crappy content can be used as a 
starter for upcoming doc writers.


So, a comment (such as [?], but plain English and more specific is a lot 
better ) is much more helpful on the long run.


-Michael

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


Re: [Lazarus] installing chm help

2012-02-17 Thread Michael Schnell

On 02/17/2012 08:11 AM, Graeme Geldenhuys wrote:
 Thus, you can't have both CHM and INF help packages installed together. 
While I don't know if installing both help packages makes any sense at 
all (as the content of both is derived from the same sources and thus 
should be equivalent), it should be rather easy to implement a kind of 
switch in the IDE's menu to select the help package to be used, if 
multiple ones are installed. I suppose the IDE accesses the features of 
the help package/database via some "help package object", so switching 
would just be modifying one (or just a few)  pointers.


While it might not make much sense to install both (and in realtime be 
able to switch between) two offline help viewers, I feel it does make 
sense to switch between an online and an offline help viewer, if both 
packages are installed. (If the offline help viewer is not an 
appropriate package, IMHO, it should be converted to be one. I even 
think using DocView with online information provided by some 
"HTTP-INF-Server" might be very nice.)


-Michael

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


Re: [Lazarus] installing chm help

2012-02-17 Thread Michael Schnell

On 02/16/2012 04:48 PM, Sven Barth wrote:


Lazarus is doing this, because in theory (currently not possible*) you 
could have the following setup:


* for LCL help use the online documentation
* for RTL help use LHelp (CHM based)
* for FCL help use DocView (INF based)

All three help systems are registered to the IDE and for each you have 
added the corresponding files (e.g. rtl.chm and fcl.inf). Then the IDE 
will ask each help system whether it can provide help and in our 
example LHelp will answer with "Yes" for all identifiers that belong 
to rtl.chm.
Would it not be easier to implement and supposedly easier to use and 
more straight forward to just provide a switch in the IDE's menu (and/or 
to allow for multiple shortcuts such as alt-F1, shift-alt-F1 or 
whatever) to select a help package to be used.


-Michael

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


Re: [Lazarus] installing chm help

2012-02-17 Thread Michael Schnell

On 02/17/2012 09:44 AM, Michael Schnell wrote:

. (If the offline help viewer is not ...


Sorry: "online" ...

-Michael


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


Re: [Lazarus] installing chm help

2012-02-17 Thread Michael Schnell

On 02/16/2012 07:36 PM, Hans-Peter Diettrich wrote:

...presented an selection dialog with almost *every* F1 press?

That is why I vote for allowing the user to  pre-select the help package 
to be used in a menu and/or to use multiple shortcut keys to select the 
help package: easier to be implemented, much less ambiguity, quite easy 
to use, support for selecting between released (online) and current 
(offline) help.


-Michael

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


Re: [Lazarus] semaphore

2012-02-17 Thread Lukasz Sokol
On 16/02/2012 20:20, Sven Barth wrote:
> On 16.02.2012 18:08, Lukasz Sokol wrote:
>> On 16/02/2012 17:06, Lukasz Sokol wrote:
>>> On 16/02/2012 16:13, Sven Barth wrote:
>>> 
 
 Can you try to use "or" instead of "+"? Also you're trying to
 pass a C style octal number. Replace the leading zero by a "&"
 which is the
>>> 
>>> you mean '$' of course ;)
>> D'oh, sorry you mean '&' actually... :(
> 
> There is never a end to lerning. ;) From now on you'll know that FPC
> supports &[0-7]* for octal and %[0,1]* for binary numbers ^^
> 
> Regards, Sven
> 

I would have deleted my posting if gmane servers supported that ;)
L.


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


Re: [Lazarus] Feature Request: a new macro for a complete identifier name

2012-02-17 Thread Sven Barth

Am 17.02.2012 08:32, schrieb Graeme Geldenhuys:

Hi,

Based on the discussion about offline help viewers, and interesting
point was raised. In the case of DocView (which is setup via the
External Tools), I use the ${CurToken} macro to allow docview to do a
search - based on where the cursor is positioned.

Now somebody brought up a interesting commend. If the cursor was over
an identifier "Visible", to which class does that related. Docview
does display the search result in a easy manner, so it shouldn't be
too hard to use as-is, but it can be improved.

If I put the mouse cursor over "Visible", it will show me something like

property TButton.Visible

So can somebody that knows how, implement a new ${CurIdentifier} macro
which can be used in the External Tools entries. So when I press F1
while the cursor is on "Visible", it will actually pass
"TButton.Visible" or "TCombobox.Visible" etc to docview.

Lazarus IDE has all the information because the tooltips display all
than information, so for somebody that is in the know, they should
find it easy to implement such a new macro, by using similar code as
is used in the tooltips. I presume it uses CodeTools.

I don't believe it is needed to add (like in fpdoc) the package and
unit name to this identifier (eg: #lcl.buttons.TBitBtn.Visible), but
if the person that (maybe) implements this feature request thinks it
could be useful, then another separate macro should be added for that.





Maybe you should report this on the bug tracker?

Regards,
Sven

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


Re: [Lazarus] Android Target GUI

2012-02-17 Thread Sven Barth

Am 17.02.2012 08:24, schrieb Felipe Monteiro de Carvalho:

On Fri, Feb 17, 2012 at 5:59 AM, Marc Santhoff  wrote:

I have pretty much no idea of the Android SDK or things, but I
understand that this target involves compiling the code to Java byte
code.


Android can run native code too, it runs Linux shared objects. Lazarus
for Android compiles the project as a Linux shared object which is
exactly what many large and successful Android applications do and it
does not use the FPC compiler support for Java. I doubt that the Java
backend would ever support building all the necessary libraries which
the LCL uses or the LCL itself, for example due to the lack of
pointers. Also if that was the case then no 3rd party libraries would
work at all, like LNet. Basically I doubt that there can be any
significant sharing of code here. Also when I started the Java backend
didn't exist.


Though this doesn't invalidate most of your other reasons, but the JVM 
port DOES support pointers (more or less). See here: 
http://wiki.freepascal.org/FPC_JVM/Language#Partially_supported_language_features 



Regards,
Sven

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


Re: [Lazarus] installing chm help

2012-02-17 Thread Sven Barth

Am 17.02.2012 08:08, schrieb Graeme Geldenhuys:

On 16 February 2012 18:30, Sven Barth wrote:


If I remember correctly you are on a Windows system and you used the normal
Lazarus installer? Then you have the source, because the Windows installer
includes the source for the RTL and Packages directories of FPC inside
%lazarusdir%\fpc\%fpcversion%\ (otherwise most of the RTLs features like
CodeTools would not work as good as they do, also you would not have been
able to find e.g. "Integer" in the help).



So what you are saying is that if you don't have the source code for
FPC, them some of the help wouldn't work??? Now that is a design flaw!
  Having the source code of FPC was never a requirement for Lazarus -
but now it seems it is a must. A very odd design if you ask me. [good
news is, I have a solution I'll post in another thread]




Let me say it this way: If you don't have access to FPC's source than 
most of Lazarus features won't work (not only the help). That's why the 
source is bundled with the Windows installers and also why the IDE asks 
you to provide a source directory on first start with an empty 
configuration (this is new in trunk).


Regards,
Sven

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


Re: [Lazarus] installing chm help

2012-02-17 Thread Sven Barth

Am 17.02.2012 08:11, schrieb Graeme Geldenhuys:

On 16 February 2012 19:37, Michael Schnell  wrote:


* This is because of at least two reasons:
- the CHM package overrides all databases to itself
- DocView does not yet have an integration package


But as The CHM package overrides the database search function, a DocView (or
whatever) package would be able to do this, as well,

Sounds great.


No, it doesn't sound great. If I had to implement a INFHelpPackage
like what was done for CHM, that means the last one to be compiled
would "steal" / override all the databases for themselves. Thus, you
can't have both CHM and INF help packages installed together.




I think that the CHM package should be improved in that case. Currently 
there only exists the online help and the CHM help as help providers and 
the CHM one simply disables the online one. If a third help provider 
comes into play then IMHO this needs to change.


Regards,
Sven

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


Re: [Lazarus] installing chm help

2012-02-17 Thread Sven Barth

Am 17.02.2012 09:53, schrieb Michael Schnell:

On 02/16/2012 04:48 PM, Sven Barth wrote:


Lazarus is doing this, because in theory (currently not possible*) you
could have the following setup:

* for LCL help use the online documentation
* for RTL help use LHelp (CHM based)
* for FCL help use DocView (INF based)

All three help systems are registered to the IDE and for each you have
added the corresponding files (e.g. rtl.chm and fcl.inf). Then the IDE
will ask each help system whether it can provide help and in our
example LHelp will answer with "Yes" for all identifiers that belong
to rtl.chm.

Would it not be easier to implement and supposedly easier to use and
more straight forward to just provide a switch in the IDE's menu (and/or
to allow for multiple shortcuts such as alt-F1, shift-alt-F1 or
whatever) to select a help package to be used.


I don't know whether this would be easier/a better approach, I just 
wanted to highlight the possiblities of the current help system (if the 
CHM package wouldn't disable everything and if we'd have a INF based one...)


Regards,
Sven


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


Re: [Lazarus] semaphore

2012-02-17 Thread Antonio Fortuny

Hi again.

I've a problem with IDE (0.9.31 2011/12/05 Linux OpenSuse 12.1, FPC 
2.4.4, GTK-2:
when double-click on the event name of a TButton in the object inspector 
trying to generate the procedure event code, the unit "ipc" is open and 
the error "/usr/share/fpcsrc/rtl/unix/ipc.pp(119,9) Error: expected 
end., but seq found" is displayed in the errors window

Same behaviour when hitting Ctrl+Space to end the code for a variable

This is the code snippet from ipc.pp tagged by the IDE
105 {$if not defined(linux_ipc32) and not defined(FPC_USE_LIBC)}
TIPC_Perm = record
key   : TKey;
uid   : kernel_uid_t;
gid   : kernel_gid_t;
cuid  : kernel_uid_t;
cgid  : kernel_gid_t;
mode  : kernel_mode_t;
{$if sizeof(kernel_mode_t) < 4}
[114]__pad1: array[1..4-sizeof(mode_t)];
{$endif}
{$ifdef cpupowerpc}
seq   : cuint;
{$else}
[119]seq   : cushort;
{$endif}
__pad2: cushort;
__unused1 : culong;
__unused2 : culong;
  End;

Beside of this the IDE works well and compiled programs run as expected.
But this really annoying. :-$

Antonio.



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


[Lazarus] Lazarus trunk help options: CHM Help browser does not show up

2012-02-17 Thread Reinier Olislagers
Hi list,

Busy with my fpcup svn installer/updater.

1. I've managed to let fpcup generate lcl.chm documentation using
build_lcl_docs.lpr (going to get rtl.chm etc going later)
2. I also let it compile lhelp.exe.
3. fpcup also creates (if it doesn't exist) a helpoptions.xml file, with
basically these settings:
  

  

  

However, in Lazarus trunk/Tools/Options/Help Options, Viewers, I only
see HTML Browser, not CHM Help Browser.

Trying to eliminate errors: copying over helpoptions.xml from a working
(i.e. lhelp shows up when pressing F1 on a keyword) snapshot Lazarus
shows no difference.

Is there something more I need to do in order to get the setting and
lhelp to appear?

Now I've got you reading: a question on the help options screen itself:
what does FPC Doc HTML path stand for? HTML files generated by FPDoc?
FPC documentation in HTML format?
Perhaps a tooltip/hint on what that editbox means would indeed be handy,
as mentioned in the wiki...

Thanks,
Reinier

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


Re: [Lazarus] Android Target GUI

2012-02-17 Thread Felipe Monteiro de Carvalho
On Fri, Feb 17, 2012 at 9:11 AM,   wrote:
> Android uses XML files to specify the layout. This is the recommended way by
> Google. You can build the GUI in code as well, but then you're pretty much
> in uncharted territory.

It is pretty trivial to build the UI without XML. I never used the XML
part while programming for Android. For example (in pseudo-code):

procedure TMyActivity.OnCreate;
var
  layout: TAbsoluteLayout;
  params: TAbsoluteLayout_LayoutParams;
  tv: TTextView;
  et: TTextView;
  btn: TButton;
  ClickCount: Integer = 0;
begin
  // Prepares the UI of the program
  layout := TAbsoluteLayout.Create;

  tv := TTextView.Create;
  tv.setText('The first Pascal Android application =)');
  params := TAbsoluteLayout_LayoutParams.Create(320, 300, 0, 120);
  layout.addView(tv, params);
  params.Free;

  et := TEditText.Create;
  et.setText('edit me please');
  params := TAbsoluteLayout_LayoutParams.Create(320, 50, 0, 0);
  layout.addView(et, params);
  params.Free;

  btn := TButton.Create;
  btn.setText('Go!');
  btn.setOnClickListener(@buttonClickCallback);
  params := TAbsoluteLayout_LayoutParams.Create(320, 50, 0, 60);
  layout.addView(btn, params);
  params.Free;

  Activity.setContentView(layout);
end;

-- 
Felipe Monteiro de Carvalho

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


Re: [Lazarus] Lazarus trunk help options: CHM Help browser does not show up

2012-02-17 Thread Sven Barth

Am 17.02.2012 10:22, schrieb Reinier Olislagers:

Hi list,

Busy with my fpcup svn installer/updater.

1. I've managed to let fpcup generate lcl.chm documentation using
build_lcl_docs.lpr (going to get rtl.chm etc going later)
2. I also let it compile lhelp.exe.
3. fpcup also creates (if it doesn't exist) a helpoptions.xml file, with
basically these settings:
   
 
   
 
   

However, in Lazarus trunk/Tools/Options/Help Options, Viewers, I only
see HTML Browser, not CHM Help Browser.

Trying to eliminate errors: copying over helpoptions.xml from a working
(i.e. lhelp shows up when pressing F1 on a keyword) snapshot Lazarus
shows no difference.

Is there something more I need to do in order to get the setting and
lhelp to appear?

Now I've got you reading: a question on the help options screen itself:
what does FPC Doc HTML path stand for? HTML files generated by FPDoc?
FPC documentation in HTML format?
Perhaps a tooltip/hint on what that editbox means would indeed be handy,
as mentioned in the wiki...


Did you install the CHM help package in the IDE?

Regards,
Sven


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


Re: [Lazarus] Android Target GUI

2012-02-17 Thread Sven Barth

Am 17.02.2012 10:23, schrieb Felipe Monteiro de Carvalho:

On Fri, Feb 17, 2012 at 9:11 AM,  wrote:

Android uses XML files to specify the layout. This is the recommended way by
Google. You can build the GUI in code as well, but then you're pretty much
in uncharted territory.


It is pretty trivial to build the UI without XML. I never used the XML
part while programming for Android. For example (in pseudo-code):

procedure TMyActivity.OnCreate;
var
   layout: TAbsoluteLayout;
   params: TAbsoluteLayout_LayoutParams;
   tv: TTextView;
   et: TTextView;
   btn: TButton;
   ClickCount: Integer = 0;
begin
   // Prepares the UI of the program
   layout := TAbsoluteLayout.Create;

   tv := TTextView.Create;
   tv.setText('The first Pascal Android application =)');
   params := TAbsoluteLayout_LayoutParams.Create(320, 300, 0, 120);
   layout.addView(tv, params);
   params.Free;

   et := TEditText.Create;
   et.setText('edit me please');
   params := TAbsoluteLayout_LayoutParams.Create(320, 50, 0, 0);
   layout.addView(et, params);
   params.Free;

   btn := TButton.Create;
   btn.setText('Go!');
   btn.setOnClickListener(@buttonClickCallback);
   params := TAbsoluteLayout_LayoutParams.Create(320, 50, 0, 60);
   layout.addView(btn, params);
   params.Free;

   Activity.setContentView(layout);
end;



This part is rather easy, but it gets more interesting when using menus 
or the views for items in list views.


Also the XML layouts allows for a more clean seperation of layout and 
code ;)


Regards,
Sven

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


Re: [Lazarus] installing chm help

2012-02-17 Thread Mattias Gaertner
On Fri, 17 Feb 2012 09:08:34 +0200
Graeme Geldenhuys  wrote:

> On 16 February 2012 18:30, Sven Barth wrote:
> >
> > If I remember correctly you are on a Windows system and you used the normal
> > Lazarus installer? Then you have the source, because the Windows installer
> > includes the source for the RTL and Packages directories of FPC inside
> > %lazarusdir%\fpc\%fpcversion%\ (otherwise most of the RTLs features like
> > CodeTools would not work as good as they do, also you would not have been
> > able to find e.g. "Integer" in the help).
> 
> 
> So what you are saying is that if you don't have the source code for
> FPC, them some of the help wouldn't work??? Now that is a design flaw!
>  Having the source code of FPC was never a requirement for Lazarus -
> but now it seems it is a must. A very odd design if you ask me. [good
> news is, I have a solution I'll post in another thread]

The sources were always recommended because some features requires the
sources. For example creating events with the designer.
The IDE warns if the FPC sources are missing since many years.
Any Lazarus release installed the FPC sources too.

Mattias

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


Re: [Lazarus] installing chm help

2012-02-17 Thread Michael Schnell

On 02/16/2012 06:14 PM, Hans-Peter Diettrich wrote:


It's not the IDE, it's the Editor that has to determine the context.

??? The editor is part of the IDE
If it finds an identfier (Visible), it must invoke help for its 
declaration. If it finds a reserved word, it must invoke the language 
reference database instead. For help on a control in an dialog the 
designer of the dialog is responsible, by adding the proper "word" 
(search path) to the control's HelpKeyword or HelpContext.
Nope. with Button1.Visible we want help on TButton (or more specific: 
TButton.Visible (if exist) or (some parent of TButton.visible), but not 
on the Visible of some completely unrelated stuff that might exist 
somewhere else. The help package can (or at least could) know the parent 
hierarchy of TButton, but it can't know that in this source file in this 
user project the type of "Button1" is "TButton". Thus the IDE (at least) 
needs to provide "TButton" together with "Visible" in this example.
FPDoc already does an good job in linking to inherited classes or 
methods, so that a help viewer has all information for narrowing down 
the request to the closest existing help entry.
All this does not help in any way, if the help viewer is not provided 
with the type of "Button1" in this example. (The user might have decided 
to call the thingy Michael instead of Button1.)


-Michael

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


Re: [Lazarus] Feature Request: a new macro for a complete identifier name

2012-02-17 Thread Graeme Geldenhuys
On 17 February 2012 11:06, Sven Barth 
> Maybe you should report this on the bug tracker?


OK. Added as...

  http://bugs.freepascal.org/view.php?id=21308



-- 
Regards,
  - Graeme -


___
fpGUI - a cross-platform Free Pascal GUI toolkit
http://fpgui.sourceforge.net

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


Re: [Lazarus] Lazarus trunk help options: CHM Help browser does not show up

2012-02-17 Thread Reinier Olislagers
On 17-2-2012 10:24, Sven Barth wrote:
> Am 17.02.2012 10:22, schrieb Reinier Olislagers:
>> However, in Lazarus trunk/Tools/Options/Help Options, Viewers, I only
>> see HTML Browser, not CHM Help Browser.
>>
>> Trying to eliminate errors: copying over helpoptions.xml from a working
>> (i.e. lhelp shows up when pressing F1 on a keyword) snapshot Lazarus
>> shows no difference.
>>
>> Is there something more I need to do in order to get the setting and
>> lhelp to appear?
>>
>> Now I've got you reading: a question on the help options screen itself:
>> what does FPC Doc HTML path stand for? HTML files generated by FPDoc?
>> FPC documentation in HTML format?
>> Perhaps a tooltip/hint on what that editbox means would indeed be handy,
>> as mentioned in the wiki...
> 
> Did you install the CHM help package in the IDE?


Spot on, Sven, thanks.
Mmmm, chmhelp was marked for installation in my tests, but not
installed. Recompiled & it worked.

Probable reason: fpcup got modularized and I hadn't built Lazarus...

I'll retest from a more basic state.


Thanks again, Sven,
Reinier

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


Re: [Lazarus] Feature Request: a new macro for a complete identifier name

2012-02-17 Thread Michael Schnell

Nice try ;-) .

Of course extending the external tool interface is a rather decent 
alternative to using the "help package" interface.


Anyway I feel that the (maybe modified/extended) "help package" 
interface could provide even more appropriate functionality/usability.


-Michael

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


Re: [Lazarus] Lazarus trunk help options: CHM Help browser does not show up

2012-02-17 Thread Sven Barth

Am 17.02.2012 10:35, schrieb Reinier Olislagers:

On 17-2-2012 10:24, Sven Barth wrote:

Am 17.02.2012 10:22, schrieb Reinier Olislagers:

However, in Lazarus trunk/Tools/Options/Help Options, Viewers, I only
see HTML Browser, not CHM Help Browser.

Trying to eliminate errors: copying over helpoptions.xml from a working
(i.e. lhelp shows up when pressing F1 on a keyword) snapshot Lazarus
shows no difference.

Is there something more I need to do in order to get the setting and
lhelp to appear?

Now I've got you reading: a question on the help options screen itself:
what does FPC Doc HTML path stand for? HTML files generated by FPDoc?
FPC documentation in HTML format?
Perhaps a tooltip/hint on what that editbox means would indeed be handy,
as mentioned in the wiki...


Did you install the CHM help package in the IDE?



Spot on, Sven, thanks.
Mmmm, chmhelp was marked for installation in my tests, but not
installed. Recompiled&  it worked.

Probable reason: fpcup got modularized and I hadn't built Lazarus...

I'll retest from a more basic state.


You're welcome ^^

Regards,
Sven


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


Re: [Lazarus] Android Target GUI

2012-02-17 Thread michael . vancanneyt



On Fri, 17 Feb 2012, Sven Barth wrote:


Am 17.02.2012 10:23, schrieb Felipe Monteiro de Carvalho:

On Fri, Feb 17, 2012 at 9:11 AM,  wrote:
Android uses XML files to specify the layout. This is the recommended way 
by

Google. You can build the GUI in code as well, but then you're pretty much
in uncharted territory.


It is pretty trivial to build the UI without XML. I never used the XML
part while programming for Android. For example (in pseudo-code):


I know it is trivial (did it myself), but I just meant to say it is not the 
'recommended way', hence you're in 'uncharted territory' =-)


Michael.

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


Re: [Lazarus] Android Target GUI

2012-02-17 Thread Michael Schnell

On 02/17/2012 08:24 AM, Felipe Monteiro de Carvalho wrote:
 I doubt that the Java backend would ever support building all the 
necessary libraries ..


Is Dalvic not compatible with the Touring Machine ( 
http://en.wikipedia.org/wiki/Turing_machine ) ? :-P


-Michael


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


Re: [Lazarus] installing chm help

2012-02-17 Thread Graeme Geldenhuys
On 17 February 2012 11:13, Sven Barth  of Lazarus features won't work (not only the help). That's why the source is
> bundled with the Windows installers

First off, I don't run Windows. Also, in that case way isn't the FPC
source a mandatory install for other platforms?  ps: I use Linux.


> and also why the IDE asks you to provide
> a source directory on first start with an empty configuration (this is new
> in trunk).

It never told me features will then be broken! On setting up a new
development system in a hurry I often don't have the sources installed
'till much later (I just copy the binaries over). My desktop at home
is a case in point - my laptop packed up a few weeks back, and I still
haven't installed all the source code to everything I use. Yet I have
done lots of development work at home, by simply using the existing
binaries.


-- 
Regards,
  - Graeme -


___
fpGUI - a cross-platform Free Pascal GUI toolkit
http://fpgui.sourceforge.net

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


Re: [Lazarus] installing chm help

2012-02-17 Thread Graeme Geldenhuys
On 17 February 2012 11:29, Mattias Gaertner wrote:
> Any Lazarus release installed the FPC sources too.

Not under Linux it doesn't. I just checked. The APT repository has a
"recommended" flag for the fpc-source package, but it is not installed
by default.


If Lazarus IDE relies so heavily on the FPC sources, then such
dependencies should become a "requirement", not "recommended".


-- 
Regards,
  - Graeme -


___
fpGUI - a cross-platform Free Pascal GUI toolkit
http://fpgui.sourceforge.net

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


Re: [Lazarus] semaphore

2012-02-17 Thread Mattias Gaertner
On Fri, 17 Feb 2012 10:21:50 +0100
Antonio Fortuny  wrote:

> Hi again.
> 
> I've a problem with IDE (0.9.31 2011/12/05 Linux OpenSuse 12.1, FPC 
> 2.4.4, GTK-2:
> when double-click on the event name of a TButton in the object inspector 
> trying to generate the procedure event code, the unit "ipc" is open and 
> the error "/usr/share/fpcsrc/rtl/unix/ipc.pp(119,9) Error: expected 
> end., but seq found" is displayed in the errors window
> Same behaviour when hitting Ctrl+Space to end the code for a variable
> 
> This is the code snippet from ipc.pp tagged by the IDE
> 105 {$if not defined(linux_ipc32) and not defined(FPC_USE_LIBC)}
>  TIPC_Perm = record
>  key   : TKey;
>  uid   : kernel_uid_t;
>  gid   : kernel_gid_t;
>  cuid  : kernel_uid_t;
>  cgid  : kernel_gid_t;
>  mode  : kernel_mode_t;
>  {$if sizeof(kernel_mode_t) < 4}
> [114]__pad1: array[1..4-sizeof(mode_t)];
>  {$endif}
>  {$ifdef cpupowerpc}
>  seq   : cuint;
>  {$else}
> [119]seq   : cushort;
>  {$endif}
>  __pad2: cushort;
>  __unused1 : culong;
>  __unused2 : culong;
>End;
> 
> Beside of this the IDE works well and compiled programs run as expected.
> But this really annoying. :-$

Array without type?
It's always amazing to find out what fpc supports.

svn trunk can now parse it.

Mattias

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


Re: [Lazarus] Android Target GUI

2012-02-17 Thread Michael Schnell

On 02/17/2012 09:11 AM, michael.vancann...@wisa.be wrote:
Android uses XML files to specify the layout. This is the recommended 
way by

Google.
I suppose the Android SDK by Google provides a GUI designer that can be 
used here ...


-Michael

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


Re: [Lazarus] Android Target GUI

2012-02-17 Thread Michael Schnell

On 02/17/2012 10:27 AM, Sven Barth wrote:


Also the XML layouts allows for a more clean seperation of layout and 
code ;)


Which is desirable for appropriately schooled programmers but very 
uncommon in the "RAD-infected" Lazarus and Delphi community ;-) .


-Michael

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


Re: [Lazarus] Android Target GUI

2012-02-17 Thread Michael Van Canneyt



On Fri, 17 Feb 2012, Michael Schnell wrote:


On 02/17/2012 09:11 AM, michael.vancann...@wisa.be wrote:
Android uses XML files to specify the layout. This is the recommended way 
by

Google.
I suppose the Android SDK by Google provides a GUI designer that can be used 
here ...


Not really. You should use Eclipse is about the only recommendation (like 
that's going to happen).
There is an DroidDraw open source program which can produce the necessary XML 
files.

Michael.

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


Re: [Lazarus] installing chm help

2012-02-17 Thread Mattias Gaertner
On Fri, 17 Feb 2012 11:59:39 +0200
Graeme Geldenhuys  wrote:

> On 17 February 2012 11:29, Mattias Gaertner wrote:
> > Any Lazarus release installed the FPC sources too.
> 
> Not under Linux it doesn't. I just checked. The APT repository has a
> "recommended" flag for the fpc-source package, but it is not installed
> by default.
> 
> 
> If Lazarus IDE relies so heavily on the FPC sources, then such
> dependencies should become a "requirement", not "recommended".

Debian policy: Relying heavily is not enough for "required".
Some people do not use the designer.

The help works without sources. The help for sources does
not work without sources. It is planned to implement a search with
ignoring missing units.

Mattias

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


Re: [Lazarus] semaphore

2012-02-17 Thread Sven Barth

Am 17.02.2012 11:00, schrieb Mattias Gaertner:

On Fri, 17 Feb 2012 10:21:50 +0100
Antonio Fortuny  wrote:


Hi again.

I've a problem with IDE (0.9.31 2011/12/05 Linux OpenSuse 12.1, FPC
2.4.4, GTK-2:
when double-click on the event name of a TButton in the object inspector
trying to generate the procedure event code, the unit "ipc" is open and
the error "/usr/share/fpcsrc/rtl/unix/ipc.pp(119,9) Error: expected
end., but seq found" is displayed in the errors window
Same behaviour when hitting Ctrl+Space to end the code for a variable

This is the code snippet from ipc.pp tagged by the IDE
105 {$if not defined(linux_ipc32) and not defined(FPC_USE_LIBC)}
  TIPC_Perm = record
  key   : TKey;
  uid   : kernel_uid_t;
  gid   : kernel_gid_t;
  cuid  : kernel_uid_t;
  cgid  : kernel_gid_t;
  mode  : kernel_mode_t;
  {$if sizeof(kernel_mode_t)<  4}
[114]__pad1: array[1..4-sizeof(mode_t)];
  {$endif}
  {$ifdef cpupowerpc}
  seq   : cuint;
  {$else}
[119]seq   : cushort;
  {$endif}
  __pad2: cushort;
  __unused1 : culong;
  __unused2 : culong;
End;

Beside of this the IDE works well and compiled programs run as expected.
But this really annoying. :-$


Array without type?
It's always amazing to find out what fpc supports.

svn trunk can now parse it.


I somehow doubt this. It seems more like the condition there is never 
true and thus the omition was never noticed. At least according to the 
compiler's code there MUST be a "of" after an array. So it might have 
been better to investigate why "sizeof(kernel_mode_t) < 4" is evaluated 
to true by the IDE.


Regards,
Sven

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


Re: [Lazarus] Android Target GUI

2012-02-17 Thread Sven Barth

Am 17.02.2012 11:06, schrieb Michael Van Canneyt:



On Fri, 17 Feb 2012, Michael Schnell wrote:


On 02/17/2012 09:11 AM, michael.vancann...@wisa.be wrote:

Android uses XML files to specify the layout. This is the recommended
way by
Google.

I suppose the Android SDK by Google provides a GUI designer that can
be used here ...


Not really. You should use Eclipse is about the only recommendation
(like that's going to happen).
There is an DroidDraw open source program which can produce the
necessary XML files.


Maybe it's time to implement some non-LCL designer for that? :D

Regards,
Sven


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


Re: [Lazarus] Android Target GUI

2012-02-17 Thread Felipe Monteiro de Carvalho
On Fri, Feb 17, 2012 at 10:53 AM, Michael Schnell  wrote:
> Is Dalvic not compatible with the Touring Machine (
> http://en.wikipedia.org/wiki/Turing_machine ) ? :-P

lol! You should send a letter to Google explaining them how they were
mistaken when they launched their Native Development Kit =D

-- 
Felipe Monteiro de Carvalho

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


Re: [Lazarus] installing chm help

2012-02-17 Thread Hans-Peter Diettrich

Michael Schnell schrieb:

On 02/16/2012 06:14 PM, Hans-Peter Diettrich wrote:


It's not the IDE, it's the Editor that has to determine the context.

??? The editor is part of the IDE
If it finds an identfier (Visible), it must invoke help for its 
declaration. If it finds a reserved word, it must invoke the language 
reference database instead. For help on a control in an dialog the 
designer of the dialog is responsible, by adding the proper "word" 
(search path) to the control's HelpKeyword or HelpContext.



Nope.


Huh?

You understand "search path"?

DoDi


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


Re: [Lazarus] Android Target GUI

2012-02-17 Thread Graeme Geldenhuys
On 17 February 2012 12:05, Michael Schnell  wrote:
> On 02/17/2012 10:27 AM, Sven Barth wrote:
>>
>>
>> Also the XML layouts allows for a more clean seperation of layout and code
>> ;)
>>
> Which is desirable for appropriately schooled programmers but very uncommon
> in the "RAD-infected" Lazarus and Delphi community ;-) .


Actually, Delphi and Lazarus also use external files for the UI. But
instead of XML, they are some pascal object files (*.lfm & *.dfm).

Now if you were talking about fpGUI's UI Designer, then yes, there the
UI code is generated as source code. But, I still have clear
separation between UI and business code/objects. The form unit is what
I consider the UI, so the UI Designer is welcome to write code inside
that. My business objects, eg TLearner, TSchool etc are in separate
units, learner.pas and school.pas, respectively. The business objects
know nothing about the UI.  ;-)


-- 
Regards,
  - Graeme -


___
fpGUI - a cross-platform Free Pascal GUI toolkit
http://fpgui.sourceforge.net

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


Re: [Lazarus] semaphore

2012-02-17 Thread Mattias Gaertner
On Fri, 17 Feb 2012 11:15:28 +0100
Sven Barth  wrote:

> Am 17.02.2012 11:00, schrieb Mattias Gaertner:
> > On Fri, 17 Feb 2012 10:21:50 +0100
> > Antonio Fortuny  wrote:
> >
> >> Hi again.
> >>
> >> I've a problem with IDE (0.9.31 2011/12/05 Linux OpenSuse 12.1, FPC
> >> 2.4.4, GTK-2:
> >> when double-click on the event name of a TButton in the object inspector
> >> trying to generate the procedure event code, the unit "ipc" is open and
> >> the error "/usr/share/fpcsrc/rtl/unix/ipc.pp(119,9) Error: expected
> >> end., but seq found" is displayed in the errors window
> >> Same behaviour when hitting Ctrl+Space to end the code for a variable
> >>
> >> This is the code snippet from ipc.pp tagged by the IDE
> >> 105 {$if not defined(linux_ipc32) and not defined(FPC_USE_LIBC)}
> >>   TIPC_Perm = record
> >>   key   : TKey;
> >>   uid   : kernel_uid_t;
> >>   gid   : kernel_gid_t;
> >>   cuid  : kernel_uid_t;
> >>   cgid  : kernel_gid_t;
> >>   mode  : kernel_mode_t;
> >>   {$if sizeof(kernel_mode_t)<  4}
> >> [114]__pad1: array[1..4-sizeof(mode_t)];
> >>   {$endif}
> >>   {$ifdef cpupowerpc}
> >>   seq   : cuint;
> >>   {$else}
> >> [119]seq   : cushort;
> >>   {$endif}
> >>   __pad2: cushort;
> >>   __unused1 : culong;
> >>   __unused2 : culong;
> >> End;
> >>
> >> Beside of this the IDE works well and compiled programs run as expected.
> >> But this really annoying. :-$
> >
> > Array without type?
> > It's always amazing to find out what fpc supports.
> >
> > svn trunk can now parse it.
> 
> I somehow doubt this. It seems more like the condition there is never 
> true and thus the omition was never noticed. At least according to the 
> compiler's code there MUST be a "of" after an array. So it might have 
> been better to investigate why "sizeof(kernel_mode_t) < 4" is evaluated 
> to true by the IDE.

kernel_mode_t is defined in another unit.
The size_of requires parsing like a compiler, that means reading all
ppu files first and resolving every type on its way. And it requires
implementation details of the compiler.
I guess only the compiler can reliably resolve size_of.
Same for declared.

Maybe some heuristics and/or defines can be added to help codetools
parsing such $IFs.

Mattias

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


Re: [Lazarus] Android Target GUI

2012-02-17 Thread Graeme Geldenhuys
On 17 February 2012 12:16, Sven Barth 
> Maybe it's time to implement some non-LCL designer for that? :D

That is probably a smart idea. The Lazarus LCL Form Designer can
already save to XML too, it just can't read XML (as far as I know).


-- 
Regards,
  - Graeme -


___
fpGUI - a cross-platform Free Pascal GUI toolkit
http://fpgui.sourceforge.net

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


Re: [Lazarus] Feature Request: a new macro for a complete identifier name

2012-02-17 Thread Graeme Geldenhuys
On 17 February 2012 11:37, Michael Schnell  wrote:
>
> Of course extending the external tool interface is a rather decent
> alternative to using the "help package" interface.

The extended macros I suggested could also be used for LHelp - with
that I assume LHelp can take command line parameters. That way, all
"IDE searching for help" is offloaded to the help viewer - which in my
opinion seems the more logical route.


-- 
Regards,
  - Graeme -


___
fpGUI - a cross-platform Free Pascal GUI toolkit
http://fpgui.sourceforge.net

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


Re: [Lazarus] Android Target GUI

2012-02-17 Thread Sven Barth

Am 17.02.2012 11:38, schrieb Graeme Geldenhuys:

On 17 February 2012 12:05, Michael Schnell  wrote:

On 02/17/2012 10:27 AM, Sven Barth wrote:



Also the XML layouts allows for a more clean seperation of layout and code
;)


Which is desirable for appropriately schooled programmers but very uncommon
in the "RAD-infected" Lazarus and Delphi community ;-) .



Actually, Delphi and Lazarus also use external files for the UI. But
instead of XML, they are some pascal object files (*.lfm&  *.dfm).


The difference between Delphi/Lazarus and Android is that in the former 
there still exists a GUI class (descendant of TForm, TFrame, etc.) 
containing all available controls that needs to be instantiated. In case 
of Android you simply pass the ID of the layout to the containing 
"control" (the activity or e.g. the listview) and it instantiates all 
controls itself.


Regards,
Sven


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


Re: [Lazarus] semaphore

2012-02-17 Thread Hans-Peter Diettrich

Mattias Gaertner schrieb:


trying to generate the procedure event code, the unit "ipc" is open and
the error "/usr/share/fpcsrc/rtl/unix/ipc.pp(119,9) Error: expected
end., but seq found" is displayed in the errors window


This error message looks correct.



  {$if sizeof(kernel_mode_t)<  4}
[114]__pad1: array[1..4-sizeof(mode_t)];


This syntax either is illegal or should be added to the parser.



svn trunk can now parse it.
I somehow doubt this. It seems more like the condition there is never 
true and thus the omition was never noticed.


Right, it looks like a lurking bug to me.

Once the source code is fixed, what doesn't look complicated to me, and 
doesn't break anything, the problem has gone away. A dedicated "align" 
directive instead of the explicit alignment had been helpful, too.


The parser also may treat the "of " as optional. This also doesn't 
look hard to implement, and may be useful in other situations (while 
source code is edited).



At least according to the 
compiler's code there MUST be a "of" after an array. So it might have 
been better to investigate why "sizeof(kernel_mode_t) < 4" is evaluated 
to true by the IDE.


kernel_mode_t is defined in another unit.
The size_of requires parsing like a compiler, that means reading all
ppu files first and resolving every type on its way. And it requires
implementation details of the compiler.
I guess only the compiler can reliably resolve size_of.

+1

Conditional compilation either requires the *correct* settings, required 
to evaluate every condition, or silent handling of problems resulting 
from inproperly included/excluded parts.



Same for declared.

Maybe some heuristics and/or defines can be added to help codetools
parsing such $IFs.


This IMO would open up a can of worms. Adding the full compiler 
capabilites to general parsers, including e.g. machine and OS targets, 
is near impossible. The related compiler units are not usable outside 
the compiler, and every attempt to create parallel units will end up in 
a maintenance nightmare. Also much time will be spent, and memory will 
be occupied, when all used units have to be parsed before the currently 
active unit.


In the ToPas C-to-Pascal converter I had not only to parse all include 
files for an specific compiler, but also all effective compiler defines 
(built-in or configurable) had to be known. This made the proper 
configuration for a translation very complicated, and the tool unusable 
for people not very familiar with a specific compiler.


DoDi


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


Re: [Lazarus] Feature Request: a new macro for a complete identifier name

2012-02-17 Thread Marco van de Voort
In our previous episode, Graeme Geldenhuys said:
> > Of course extending the external tool interface is a rather decent
> > alternative to using the "help package" interface.
> 
> The extended macros I suggested could also be used for LHelp - with
> that I assume LHelp can take command line parameters. That way, all
> "IDE searching for help" is offloaded to the help viewer - which in my
> opinion seems the more logical route.

Personally I don't like this. It almost forces one to use lhelp, and I would
like to keep the option to use CHM via the native windows support.

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


Re: [Lazarus] Lazarus trunk help options: CHM Help browser does not show up

2012-02-17 Thread Reinier Olislagers
On 17-2-2012 10:35, Reinier Olislagers wrote:
> On 17-2-2012 10:24, Sven Barth wrote:
>> Am 17.02.2012 10:22, schrieb Reinier Olislagers:
>>> Now I've got you reading: a question on the help options screen itself:
>>> what does FPC Doc HTML path stand for? HTML files generated by FPDoc?
>>> FPC documentation in HTML format?
>>> Perhaps a tooltip/hint on what that editbox means would indeed be handy,
>>> as mentioned in the wiki...
>>
>> Did you install the CHM help package in the IDE?
> 
> 
> Spot on, Sven, thanks.
> Mmmm, chmhelp was marked for installation in my tests, but not
> installed. Recompiled & it worked.
> 
> Probable reason: fpcup got modularized and I hadn't built Lazarus...
> 
> I'll retest from a more basic state.
Yep, sorry, rerunning complete fpcup builds working IDE with CHM help
viewer and LCL.chm.

Now going to see if I can either persuade fpdoc to spit out rtl.chm and
fcl.chm, or download the latest release versions... et voila, working
offline help installed for free with your Lazarus SVN copy ;) (oh.. and
Graeme, with FPC source as well... SCNR...)

Thanks,
Reinier

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


[Lazarus] Editor File Manager in Windows menu

2012-02-17 Thread Juha Manninen
I implemented a new feature: an Editor File Manager.
It can be found as the first item in Windows menu.
It becomes very useful when you have lots of files open. Please check
out and give comments.

Juha

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


Re: [Lazarus] Editor File Manager in Windows menu

2012-02-17 Thread Martin

On 17/02/2012 12:59, Juha Manninen wrote:

I implemented a new feature: an Editor File Manager.
It can be found as the first item in Windows menu.
It becomes very useful when you have lots of files open. Please check
out and give comments.


Nice.

Sorting would be nice. By either file or full name. Often I know in 
which directory a file is, so if they were sorted


Maybe multiply  columns: folder / file / which window(s) / tab-index ...

Maybe allow to specify the sort order for the menu too.

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


Re: [Lazarus] Editor File Manager in Windows menu

2012-02-17 Thread Martin

On 17/02/2012 13:11, Martin wrote:

On 17/02/2012 12:59, Juha Manninen wrote:

I implemented a new feature: an Editor File Manager.
It can be found as the first item in Windows menu.
It becomes very useful when you have lots of files open. Please check
out and give comments.


Nice.

Sorting would be nice. By either file or full name. Often I know in 
which directory a file is, so if they were sorted


Maybe multiply  columns: folder / file / which window(s) / tab-index ...

Maybe allow to specify the sort order for the menu too.


Why is it modal?

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


Re: [Lazarus] Editor File Manager in Windows menu

2012-02-17 Thread Mattias Gaertner
On Fri, 17 Feb 2012 14:59:32 +0200
Juha Manninen  wrote:

> I implemented a new feature: an Editor File Manager.
> It can be found as the first item in Windows menu.
> It becomes very useful when you have lots of files open. Please check
> out and give comments.

Caption needs a resourcestring.

The file list needs scrollbars.

While loading IDEImages: Resource "laz_close" not found


Mattias

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


[Lazarus] FPDocManager now handles selectable FCL packages

2012-02-17 Thread Hans-Peter Diettrich
Only few FCL units are documented right now. This is not a special 
limitation for Lazarus applications, which do not normally use FCL 
units. But when e.g. the PParser unit is used in a project (like 
FPDocManager), a few notes on the essenial parts of selected units are 
appreciated. That's why the (now removed) docs/xml/fcl directory had 
been added for such inofficial descriptions. For now we assume that such 
a directory exists, and has been added to the FCL options in FPDocManager.


The FPDoc Editor can be used in the IDE, to add descriptions even to FCL 
units. But when somebody wants to supply such descriptions for addition 
to the official docs, some problems become noticeable.


Most FPDoc tools fail to work on units which deserve special compiler 
options, when the user cannot supply the required options. I.e. you may 
not be able to add descriptions in the FPDoc Editor, or MakeSkel or 
LazDE creates only an empty or invalid skeleton. In these (rare) cases 
you are most probably lost :-(


This was the reason for the addition of *selectable* FCL packages, for 
which the FPDocManager now can create documentation skeletons, and 
allows to update, syntax check, and to create the final documentation 
for the contained units.


Before you start documenting new FCL units, you should check the 
according package in the FCL packages list, and then try to Refresh the 
FCL docs. This may fail, e.g. for fcl-process, due to beformentioned 
missing compiler options. Then you'll have to uncheck that package 
again, and stop working on it for now[1].


Otherwise you'll get the skeletons for all units, pertaining to that 
package, *and* which had not been documented before by e.g. using the 
FPDoc Editor. As soon as a description file is found, the Refresh 
feature only will create *update* files, which have to be merged 
manually into the existing file. Or, even worse, MakeSkel may extinguish 
your previous work (untested). An automatic merge is on my ToDo list, 
but don't hold your breath. So you better create skeletons *before* 
adding any documentation to yet undocumented units.


Please note that your added descriptions do *not* become part of the 
entire FCL package, i.e. they are not listed in the FCL units pane. 
Nonetheless they are checked or added to the final docs by the 
FPDocManager, when no specific unit is selected.



The remainder is for keen users, which want to work around 
beforementioned problems.


[1] The FPDocManager creates both an INI file and an FPDoc project for 
all registered packages. In the case of the FCL package it also creates 
an additional fcl_prj_ext.xml project file, which contains all the added 
source and description files. This file is re-created for every 
operation on the FCL package, based on an scan of the FCL source and 
description directories. This way the input files are supplied for all 
added description files, no need to add them explicitly.


The project files can be edited manually and supplied to FPDoc or 
MakeSkel. This way a user can e.g. try to figure out the compiler 
options, required to process specific units properly.


So much for now.

DoDi


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


Re: [Lazarus] Feature Request: a new macro for a complete identifier name

2012-02-17 Thread Michael Schnell

On 02/17/2012 01:25 PM, Marco van de Voort wrote:
Personally I don't like this. It almost forces one to use lhelp, and I 
would like to keep the option to use CHM via the native windows support.


??? (AFAIU) The CHM help is installed as a package, while Graeme's 
suggestion targets the External Tool interface (which I in fact don't 
like, but if Graeme decides to go that way I'll be happy, too).


So this is completely unrelated.

-Michael

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


Re: [Lazarus] Android Target GUI

2012-02-17 Thread Reimar Grabowski
On Fri, 17 Feb 2012 11:06:18 +0100 (CET)
Michael Van Canneyt  wrote:

> 
> 
> On Fri, 17 Feb 2012, Michael Schnell wrote:

> > I suppose the Android SDK by Google provides a GUI designer that can be 
> > used 
> > here ...
> 
> Not really. You should use Eclipse is about the only recommendation (like 
> that's going to happen).
There is a GUI designer integrated in the Eclipse plugin (and IMHO quite a good 
one with preview functions for different phone or tablet resolutions and other 
goodies). Developing with Eclipse for Android is a pleasant experience with all 
the tools you need very well integrated into the IDE. Pascal development on the 
other hand is a little bit more cumbersome and not so pleasant at all, because 
of no integration to speak of. It is not really difficult in any way but the 
Java + Eclipse way makes for a lot smoother experience.
But I am one of those strange guys that always liked Eclipse and I don't really 
understand that Eclipse bashing. 

R.

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


Re: [Lazarus] Feature Request: a new macro for a complete identifier name

2012-02-17 Thread Graeme Geldenhuys
On 17 February 2012 15:35, Michael Schnell  wrote:
>
> ??? (AFAIU) The CHM help is installed as a package, while Graeme's
> suggestion targets the External Tool interface


Correct.


And if somebody doesn't like the LHelp IDE Integration for some or
other reason, they could even setup LHelp via the External Tools, like
I have done with DocView. But this is totally optional.

The best of both worlds as far as I can see.


-- 
Regards,
  - Graeme -


___
fpGUI - a cross-platform Free Pascal GUI toolkit
http://fpgui.sourceforge.net

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


Re: [Lazarus] Editor File Manager in Windows menu

2012-02-17 Thread Juha Manninen
2012/2/17, Martin :

I am happy you answered, Martin. I wanted to ask you about saving files.
If you look at the source, there is
  SrcEdit: TSourceEditor;
I can do
  SrcEdit.Activate;
which is very intuitive. I can also do:
  SrcEdit.SourceNotebook.CloseFile(SrcEdit.PageIndex);
which is ok, too. But I cannot do:
  SrcEdit.Save;
or anything similar.
So the question is how to save the files?


> Sorting would be nice. By either file or full name. Often I know in
> which directory a file is, so if they were sorted

Can be done.

> Maybe multiply  columns: folder / file / which window(s) / tab-index ...

It should use TListView then. It can be done but requires lots of changes.
The checkboxes must be dumped and selections used instead.
I don't have a FilterEdit control for TListView yet although it can be
implemented. The filter is a very nice thing to have with any GUI
container.
It means I will not implement columns very soon but maybe later, yes.


> Maybe allow to specify the sort order for the menu too.

Do you mean changing the editor tab order from the manager window? I
am planning to do it.
Maybe I have ask you again about how to do it best using the editor interface.

> Why is it modal?

Because a modeless window would require lots of synchronizing between
other parts of Lazarus. Editor windows can be opened, closed, renamed
and modified in many ways.
If there is a good notification API for it, please tell me.

The manager window is very useful even when it is modal.

I took a similar challenge when I changed the TabOrder dialog from
modal to modeless some time ago. It required lots of synchronization
with the form designer. The notification mechanism was already there
so it was not very hard after all.

Juha

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


Re: [Lazarus] FPDocManager now handles selectable FCL packages

2012-02-17 Thread Mattias Gaertner
On Fri, 17 Feb 2012 14:30:17 +0100
Hans-Peter Diettrich  wrote:

>[...]
> Most FPDoc tools fail to work on units which deserve special compiler 
> options, when the user cannot supply the required options. I.e. you may 
> not be able to add descriptions in the FPDoc Editor,

Please report FCL units that fail to parse in Lazarus.

Mattias

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


Re: [Lazarus] Lazarus trunk help options: CHM Help browser does not show up

2012-02-17 Thread Hans-Peter Diettrich

Reinier Olislagers schrieb:


Now going to see if I can either persuade fpdoc to spit out rtl.chm and
fcl.chm, or download the latest release versions... et voila, working
offline help installed for free with your Lazarus SVN copy ;) (oh.. and
Graeme, with FPC source as well... SCNR...)


If you want to create the RTL and FCL docs during installation, you can 
use according project files. These files are e.g. created by the 
FPDocManager. In the case of the FPC documentation some paths have to be 
fixed, so that the other builds can e.g. find the content files. Since 
the FPC descriptions do not change very often, you can distribute the 
project files together with your installer.


Since you have to download the docs sources in either case, you also can 
use the supplied MakeFile, of course.


Full offline documentation also should include the REF etc. files, which 
cannot be created like the LCL docs. So it might be easier to download 
the readily available help files, instead of creating these during the 
installation.


DoDi


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


Re: [Lazarus] installing chm help

2012-02-17 Thread Flávio Etrusco
On Fri, Feb 17, 2012 at 7:59 AM, Graeme Geldenhuys
 wrote:
> On 17 February 2012 11:29, Mattias Gaertner wrote:
>> Any Lazarus release installed the FPC sources too.
>
> Not under Linux it doesn't. I just checked. The APT repository has a
> "recommended" flag for the fpc-source package, but it is not installed
> by default.
>

Debian and Ubuntu (and probably every deb-based distro) install
"recommended" packages by default.

> (...)
> --
> Regards,
>   - Graeme -
>

Regards,
Flávio

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


Re: [Lazarus] Editor File Manager in Windows menu

2012-02-17 Thread Martin

On 17/02/2012 13:56, Juha Manninen wrote:

2012/2/17, Martin:

I am happy you answered, Martin. I wanted to ask you about saving files.
If you look at the source, there is
   SrcEdit: TSourceEditor;
I can do
   SrcEdit.Activate;
which is very intuitive. I can also do:
   SrcEdit.SourceNotebook.CloseFile(SrcEdit.PageIndex);
which is ok, too. But I cannot do:
   SrcEdit.Save;
or anything similar.
So the question is how to save the files?


SrcEditor is display, save etc, is done in main.pp.

You can always track back the UserCommandEvet (send by synedit to src edit for 
keypress, and src-edit to main)

procedure ProcessCommand(Sender: TObject;
   var Command: TSynEditorCommand; var AChar: TUTF8Char; Data: 
pointer);

procedure ProcessUserCommand(Sender: TObject;
   var Command: TSynEditorCommand; var AChar: TUTF8Char; Data: 
pointer);



at the end of the 2nd:

TSourceNotebook(FaOwner).ProcessParentCommand(self,Command,aChar,Data,

Handled);

It either goes to
IDECmd:=IDECommandList.FindIDECommand(Command);

Otherwise there is
Manager.OnProcessUserCommand(Self,Command,Handled);
which is set in main.pp
  SourceEditorManager.OnProcessUserCommand := @OnProcessIDECommand;


in

procedure TMainIDE.OnProcessIDECommand(Sender: TObject;
  Command: word;  var Handled: boolean);
  ecSave:
if (Sender is TDesigner) then begin
  GetDesignerUnit(TDesigner(Sender),ASrcEdit,AnUnitInfo);
  if (AnUnitInfo<>nil) and (AnUnitInfo.OpenEditorInfoCount > 0) then
DoSaveEditorFile(ASrcEdit, [sfCheckAmbiguousFiles]);
end else if (Sender is TObjectInspectorDlg) then begin
  GetObjectInspectorUnit(ASrcEdit,AnUnitInfo);
  if (AnUnitInfo<>nil) and (AnUnitInfo.OpenEditorInfoCount > 0) then
DoSaveEditorFile(ASrcEdit, [sfCheckAmbiguousFiles]);
end else if Sender is TSourceNotebook then
  mnuSaveClicked(Self);

-
so much for theory

easiest is (EditorComponent  is synedit)

SrcEdit.EditorComponent.CommandProcessor(ecSave, '', nil)

acts exactly like as if triggered by keys.




Sorting would be nice. By either file or full name. Often I know in
which directory a file is, so if they were sorted

Can be done.


Maybe multiply  columns: folder / file / which window(s) / tab-index ...

It should use TListView then. It can be done but requires lots of changes.
The checkboxes must be dumped and selections used instead.

Selection is easier anyway IMHO.

If I want a single file (saved or closed), then checkbox is rather annoying.



I don't have a FilterEdit control for TListView yet although it can be
implemented. The filter is a very nice thing to have with any GUI
container.
It means I will not implement columns very soon but maybe later, yes.



Maybe allow to specify the sort order for the menu too.

Do you mean changing the editor tab order from the manager window? I
am planning to do it.
I meant the order in the list (like click on column header (if there 
were any))



Maybe I have ask you again about how to do it best using the editor interface.


Why is it modal?

Because a modeless window would require lots of synchronizing between
other parts of Lazarus. Editor windows can be opened, closed, renamed
and modified in many ways.

SrcEditor has some events, but probably not enough

  TsemChangeReason = (
semWindowCreate,// Called after creation of a Window
semWindowDestroy,   // Called after removal of a Window
semWindowActivate,  // Window is now ActiveSourceWindow (does not 
vave to be focused)
semWindowFocused,   // The window became the active win of the 
application

semEditorCreate,
semEditorDestroy,
semEditorActivate,  // Editor is ActiveEditor
semEditorStatus // any status change of the editor (Caret, 
Selection, topline, ...)

  );

TSourceEditorManagerInterface (base class of SrcNotebook)
procedure RegisterChangeEvent(AReason: TsemChangeReason; AHandler: 
TNotifyEvent); virtual; abstract;
procedure UnRegisterChangeEvent(AReason: TsemChangeReason; 
AHandler: TNotifyEvent); virtual; abstract;



semEditorStatus  goes for EVERY keypress, so only fast handlers
  it has synedits modified flag, which equals saved/modified
  To avoid slow down, there should be a filtered wersion, for the 
desired flags only


- rename can probably be added


If there is a good notification API for it, please tell me.





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


Re: [Lazarus] Lazarus trunk help options: CHM Help browser does not show up

2012-02-17 Thread Reinier Olislagers
On 17-2-2012 15:16, Hans-Peter Diettrich wrote:
> Reinier Olislagers schrieb:
>> Now going to see if I can either persuade fpdoc to spit out rtl.chm and
>> fcl.chm, or download the latest release versions... et voila, working
>> offline help installed for free with your Lazarus SVN copy ;) (oh.. and
>> Graeme, with FPC source as well... SCNR...)

Thanks, DoDi,

> If you want to create the RTL and FCL docs during installation, you can
> use according project files. These files are e.g. created by the
> FPDocManager.
That's news...must have not been paying attention.
What are these project files called? Can I get them when installing FPC
only (i.e. without Lazarus)

> In the case of the FPC documentation some paths have to be
> fixed, so that the other builds can e.g. find the content files. Since
> the FPC descriptions do not change very often, you can distribute the
> project files together with your installer.
Mmm, ok, I guess that answers one of my previous questions.

> Since you have to download the docs sources in either case, you also can
> use the supplied MakeFile, of course.
... unless I'm overlooking something again, that requires latex to
export to chm files??
(eg make chm IIRC)
Chances of it being available on Windows, OSX, are not much higher than
on Linux. Requiring it just to build documentation seems... excessive.

> Full offline documentation also should include the REF etc. files, which
> cannot be created like the LCL docs. So it might be easier to download
> the readily available help files, instead of creating these during the
> installation.
 that's the solution I'm going for right now... ;)

Thanks,
Reinier

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


Re: [Lazarus] Lazarus trunk help options: CHM Help browser does not show up

2012-02-17 Thread Graeme Geldenhuys
On 17 February 2012 16:37, Reinier Olislagers  wrote:
>> Since you have to download the docs sources in either case, you also can
>> use the supplied MakeFile, of course.
> ... unless I'm overlooking something again, that requires latex to
> export to chm files??
> (eg make chm IIRC)
> Chances of it being available on Windows, OSX, are not much higher than
> on Linux. Requiring it just to build documentation seems... excessive.

The RTL and FCL documentation can be created without the LaTeX
requirement (if you don't target DVI or PDF), because they use the
fpdoc XML files as source. The Language Reference, Programmers
Reference etc are in *.tex Latex files, so they require a Latex setup
to build to any output.


-- 
Regards,
  - Graeme -


___
fpGUI - a cross-platform Free Pascal GUI toolkit
http://fpgui.sourceforge.net

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


Re: [Lazarus] Editor File Manager in Windows menu

2012-02-17 Thread Juha Manninen
2012/2/17, Mattias Gaertner :
> Caption needs a resourcestring.
> The file list needs scrollbars.
> While loading IDEImages: Resource "laz_close" not found

I fixed the caption and image. A vertical scrollbar is there automatically.
I didn't find a way to set a horizontal scrollbar in TChecklistBox.

Juha

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


Re: [Lazarus] Lazarus trunk help options: CHM Help browser does not show up

2012-02-17 Thread Reinier Olislagers
On 17-2-2012 15:45, Graeme Geldenhuys wrote:
> On 17 February 2012 16:37, Reinier Olislagers  wrote:
>>> Since you have to download the docs sources in either case, you also can
>>> use the supplied MakeFile, of course.
>> ... unless I'm overlooking something again, that requires latex to
>> export to chm files??
>> (eg make chm IIRC)
>> Chances of it being available on Windows, OSX, are not much higher than
>> on Linux. Requiring it just to build documentation seems... excessive.
> 
> The RTL and FCL documentation can be created without the LaTeX
> requirement (if you don't target DVI or PDF), because they use the
> fpdoc XML files as source. The Language Reference, Programmers
> Reference etc are in *.tex Latex files, so they require a Latex setup
> to build to any output.

Just to confirm: that would be by running
make chm
in the fpcdocs directory?
That throws up a lot of Latex warnings in my install...

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


Re: [Lazarus] TThread.WaitFor blocks the main event loop under Linux

2012-02-17 Thread Marco van de Voort
On Thu, Oct 21, 2010 at 04:53:35PM +0200, Michael Schnell wrote:
> C program use appropriate header files that provide inline functions for 
> atomic. Same are "flavor-architecture specific", providing different 
> algorithms (with some sub-archs supported by Kernel tricks) to allow for 
> atomicness. When compiling an so library it can use the appropriate 
> header file (e.g. to do Futex).

That is all handcrafted hackery. Sure, you can do that with FPC too, if you
can get used to configure like tricks and preprocessors.
 
> Seemingly, to take advantage from this we could use libc to use  Futex 
> ("pthread_mutex()").

pthread_mutex is used by tbasicevent for ages. If pthreads maps futexes
under normal mutex if available, it should all work out of the box. (and
afaik already since 2.4.0)

IOW, just use syncobjs.

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


Re: [Lazarus] Lazarus trunk help options: CHM Help browser does not show up

2012-02-17 Thread Marco van de Voort
On Fri, Feb 17, 2012 at 03:37:49PM +0100, Reinier Olislagers wrote:
> > If you want to create the RTL and FCL docs during installation, you can
> > use according project files. These files are e.g. created by the
> > FPDocManager.
> That's news...must have not been paying attention.
> What are these project files called? Can I get them when installing FPC
> only (i.e. without Lazarus)

In theory

make chm DOCS="rtl fcl" should do it, but it currently hits windows
commandline limits. (see below to get an idea) Dodi is right that the
bulk of the definition of filenames and paths should move out of the
makefile and into a project file. Michael is working on this, but still
WIP.

Prog/ref/user etc stuff require latex and tex4ht. But then it fails (under
windows) on some shell script in the makefile (easily worked around
using cygwin, but not for the unwashed masses). I don't think this will ever
be common round, since tex4ht is funky. 

In short: I would simply download the CHMs, and forget about auto-generation
for now. The sources are not always in a compilable state, and not branch
(trunk vs 2.6.x) and OS independent either


> > In the case of the FPC documentation some paths have to be
> > fixed, so that the other builds can e.g. find the content files. Since
> > the FPC descriptions do not change very often, you can distribute the
> > project files together with your installer.

(IMHO this should not be needed. A system that relies on random hardcoded
paths in a particular setup is flawed)

> > Since you have to download the docs sources in either case, you also can
> > use the supplied MakeFile, of course.
> ... unless I'm overlooking something again, that requires latex to
> export to chm files??
> (eg make chm IIRC)

And tex4ht

> Chances of it being available on Windows, OSX, are not much higher than
> on Linux. Requiring it just to build documentation seems... excessive.

I don't see why.
 
> > Full offline documentation also should include the REF etc. files, which
> > cannot be created like the LCL docs. So it might be easier to download
> > the readily available help files, instead of creating these during the
> > installation.
>  that's the solution I'm going for right now... ;)

The 2.6.0 CHMs are available from FPC ftp (dist//docs/doc-chm.zip). So 
that leaves only the lazarus
LCLs.

There are irregular snapshots on my homepage:

http://www.stack.nl/~marcov/doc-chm.zip

these do contain lcl stuff.

--


D:\repo\fpcdocs>make CHM DOCS="rtl fcl"
make html HTMLFMT=chm
make[1]: Entering directory `D:/repo/fpcdocs'
../fpc/utils/fpdoc/fpdoc  --warn-no-node --package=rtl --descr=rtl.xml
--content=rtl.xct --hide-protected --descr=system.xml --input="-dfpdocsystem
-- -dHASGETHEAP
STATUS -dSUPPORT_DOUBLE ../fpc/rtl/win32/system.pp -Fi../fpc/rtl/win32
-Fi../fpc/rtl/unix -Fi../fpc/rtl/inc -Fi../fpc/rtl/i386 -dCPU32 -dHASVARIANT
- -dFPC_HAS_TY
PE_EXTENDED -dHASWIDECHAR -Fi../fpc/rtl/win -Fi../fpc/rtl/win32
-Fi../fpc/rtl/unix -Fi../fpc/rtl/linux" --descr=objpas.xml
- --input="-dHASINTF ../fpc/rtl/objpas/
objpas.pp -Fi../fpc/rtl/win -Fi../fpc/rtl/win32 -Fi../fpc/rtl/unix
-Fi../fpc/rtl/linux" --descr=types.xml --input="../fpc/rtl/objpas/types.pp
- -Fi../fpc/rtl/win
-Fi../fpc/rtl/win32 -Fi../fpc/rtl/unix -Fi../fpc/rtl/linux"
- --descr=strutils.xml --input="../fpc/rtl/objpas/strutils.pp
- -- -Fi../fpc/rtl/win -Fi../fpc/rtl/win32 -
Fi../fpc/rtl/unix -Fi../fpc/rtl/linux" --descr=sysutils.xml
--input="../fpc/rtl/unix/sysutils.pp -Fi../fpc/rtl/objpas/sysutils
-- -Fi../fpc/rtl/inc -Fi../fpc/rtl/w
in -Fi../fpc/rtl/win32 -Fi../fpc/rtl/unix -Fi../fpc/rtl/linux"
--descr=strings.xml --input="../fpc/rtl/inc/strings.pp -Fi../fpc/rtl/i386
-- -Fi../fpc/rtl/inc -Fi..
/fpc/rtl/win -Fi../fpc/rtl/win32 -Fi../fpc/rtl/unix -Fi../fpc/rtl/linux"
/  --descr=mouse.xml --input="../fpc/rtl/unix/mouse.pp -Fi../fpc/rtl/inc
/  -- -Fi../fpc/rtl/win
 -Fi../fpc/rtl/win32 -Fi../fpc/rtl/unix -Fi../fpc/rtl/linux"
 - --descr=keyboard.xml --input="../fpc/rtl/unix/keyboard.pp
 - -- -Fi../fpc/rtl/inc -Fi../fpc/rtl/win -Fi..
/fpc/rtl/win32 -Fi../fpc/rtl/unix -Fi../fpc/rtl/linux" --descr=crt.xml
/  --input="../fpc/rtl/unix/crt.pp -Fi../fpc/rtl/inc -Fi../fpc/rtl/win
/  -- -Fi../fpc/rtl/win32 -
Fi../fpc/rtl/unix -Fi../fpc/rtl/linux" --descr=video.xml
--input="../fpc/rtl/unix/video.pp -Fi../fpc/rtl/inc -Fi../fpc/rtl/win
-- -Fi../fpc/rtl/win32 -Fi../fpc/rtl
/unix -Fi../fpc/rtl/linux" --descr=dos.xml --input="../fpc/rtl/unix/dos.pp
/  -Fi../fpc/rtl/inc -dcpui386 -Fi../fpc/rtl/win -Fi../fpc/rtl/win32
/  - -Fi../fpc/rtl/unix
-Fi../fpc/rtl/linux" --descr=sockets.xml --input="-dver1_0
-  ../fpc/rtl/unix/sockets.pp -Fi../fpc/rtl/inc -Fi../fpc/rtl/win32
- -Fi../fpc/rtl/win -Fi../fpc/rtl/win3
2 -Fi../fpc/rtl/unix -Fi../fpc/rtl/linux" --descr=objects.xml
--input="../fpc/rtl/inc/objects.pp -Fi../fpc/rtl/i386 -Fi../fpc/rtl/win32
-- -Fi../fpc/rtl/win -Fi../
fpc/rtl/win32 -Fi../fpc/rtl/unix -Fi../fpc/rtl/linux" --descr=heaptrc.xml
--input="../fp

Re: [Lazarus] Editor File Manager in Windows menu

2012-02-17 Thread Juha Manninen
  SrcEdit.EditorComponent.CommandProcessor(ecSave, '', nil)
did not really work, but this did:
  LazarusIDE.DoSaveEditorFile(SrcEdit, [])


> Selection is easier anyway IMHO.
> If I want a single file (saved or closed), then checkbox is rather annoying.

Now these 2 things are mixed. You can use a single selection to
activate and close a file (there is a popup menu).
But, you must use checkboxes for multiple file operations. I
understand it could be done with selections, too.
Maybe I must rethink it...

Martin, one more question if you don't mind: How to change editor tab
order? If you don't remember the answer by hart, I can study the code
later and find out myself.

Thanks for all the info. I will look at it later.

Juha


2012/2/17, Juha Manninen :
> 2012/2/17, Mattias Gaertner :
>> Caption needs a resourcestring.
>> The file list needs scrollbars.
>> While loading IDEImages: Resource "laz_close" not found
>
> I fixed the caption and image. A vertical scrollbar is there automatically.
> I didn't find a way to set a horizontal scrollbar in TChecklistBox.
>
> Juha
>

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


Re: [Lazarus] Editor File Manager in Windows menu

2012-02-17 Thread Martin

On 17/02/2012 16:37, Juha Manninen wrote:


Martin, one more question if you don't mind: How to change editor tab
order? If you don't remember the answer by hart, I can study the code
later and find out myself.


procedure TSourceNotebook.MoveEditor(OldPageIndex, NewPageIndex: integer);


If you allow sorting tabs, how do you display files, that are open in 
several windows?


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


Re: [Lazarus] Lazarus trunk help options: CHM Help browser does not show up

2012-02-17 Thread Graeme Geldenhuys
On 17 February 2012 17:22, Reinier Olislagers  wrote:
>
> Just to confirm: that would be by running
> make chm
> in the fpcdocs directory?
> That throws up a lot of Latex warnings in my install...


I'm at home now, and don't have a copy of the fpddocs repository. But
I do remember a README file in that repository, explaining how to
build RTL and FCL specific docs.

NOTE:
I don't know what platform you are using, but I do know that building
the docs under Windows, hits a command line parameter limit. Work is
being done to resolve this, but I don't know how far that work has
progressed.



-- 
Regards,
  - Graeme -


___
fpGUI - a cross-platform Free Pascal GUI toolkit
http://fpgui.sourceforge.net

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


[Lazarus] Lookup Field dont display values

2012-02-17 Thread Maxi
I have several lookup fields shown in DBGrids and values ​​do not appear
when I select them, but they appear in the list.
I can fix it?*


*Tengo varios campos lookup mostrados en dbgrids y no aparecen los valores,
cuando los selecciono, pero sí, aparecen en la lista.
Puedo solucionarlo?

-- 
El que pregunta aprende, y el que contesta aprende a responder.

No a la obsolecencia programada:
http://dimensionargentina.blogspot.com/2011/01/todo-esta-disenado-para-romperse.html

Linux User #495070
http://miexperiencialinux.blogspot.com/
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] I made a visualization of the Lazarus SVN repository

2012-02-17 Thread Juha Manninen
2012/2/16, Everton Vieira :
> Look who does the things around here are a bunch of heroes.
> We have to increase this number. Making easy and secure is the way.

Everton, start providing patches. It is easy and secure! :)


Bernd, how long you think the animation is kept in the Vimeo site?
It would be nice to have a similar animation from a longer period of
time, saved in place where it will stay for reasonably long, and
provide a link in Wiki pages.

There are amazing pieces of SW out there, like this "gource", which
most people don't know about. I didn't know about it before this
video.

Juha

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


Re: [Lazarus] I made a visualization of the Lazarus SVN repository

2012-02-17 Thread Everton Vieira

Em 17/02/2012, às 15:41, Juha Manninen escreveu:

> 2012/2/16, Everton Vieira :
>> Look who does the things around here are a bunch of heroes.
>> We have to increase this number. Making easy and secure is the way.
> 
> Everton, start providing patches. It is easy and secure! :)

Always that I can I will :) And you fly a lot brother! That`s so nice. Sure you 
have a very large view of it. Wish i had too.

Well, I had the idea that would be good to integrate in the IDE the process of 
bug report and patching. Today is too diffuse this work and many doesn't even 
know what it is. Make integrate in the IDE would make more concentrated and 
visible.

> 
> 
> Bernd, how long you think the animation is kept in the Vimeo site?
> It would be nice to have a similar animation from a longer period of
> time, saved in place where it will stay for reasonably long, and
> provide a link in Wiki pages.
> 
> There are amazing pieces of SW out there, like this "gource", which
> most people don't know about. I didn't know about it before this
> video.
> 
> Juha
> 
> --
> ___
> Lazarus mailing list
> Lazarus@lists.lazarus.freepascal.org
> http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


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


Re: [Lazarus] FPDocManager now handles selectable FCL packages

2012-02-17 Thread Hans-Peter Diettrich

Mattias Gaertner schrieb:

On Fri, 17 Feb 2012 14:30:17 +0100
Hans-Peter Diettrich  wrote:


[...]
Most FPDoc tools fail to work on units which deserve special compiler 
options, when the user cannot supply the required options. I.e. you may 
not be able to add descriptions in the FPDoc Editor,


Please report FCL units that fail to parse in Lazarus.


I didn't talk about Lazarus (IDE)?

But here is such a Lazarus unit:
  D:\repos\lazarusTrunk\components\jcf2\Parse\Tokens.pas
IMO this is a different issue, when the unit is not part of the project 
or of a loaded package.


DoDi


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


[Lazarus] Lazbuild search path

2012-02-17 Thread Leonardo M . Ramé
Hi, I'm trying to use Lazbuild from a cron job in a server to create
nightly builds. Our projects are developed on machines with different
paths for libraries, and I would like to know how to force Lazbuild to
ignore the search-path specified in the .lpi file, and use a new one.

How can I do that?

Thanks in advance,
-- 
Leonardo M. Ramé
http://leonardorame.blogspot.com

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


Re: [Lazarus] Looking for a general text editor

2012-02-17 Thread Bart
On 2/16/12, felipemonteiro.carva...@gmail.com
 wrote:
> Em 16/02/2012, às 20:41, Bart  escreveu:
>> Why not simply use my MruList unit
>> (http://home.tiscali.nl/~knmg0017/software/fpc_laz/mrulists.zip) as
>> well?

> If it is portable it should be fine

It should be, this is the uses clause:

uses
  SysUtils, Classes, Controls, Registry, IniFiles, FileUtil;

> just add to the project svn,

How?

> I killed all dependencies because a lot of
> people use non-standard stuff which don't work for example in Mac and bring
> all sords of problems to build and modify the program.

I tend to use only standard LCL stuff...

> For me the best would
> be giving you commit rights to the ccr if you don't have already and you
> commit directly what you see fit.

I'm unfamiliar with committing via svn (or any other tool like that).
Is there a wiki-entry about how to do that?
Do I need more then my svn client?

Bart

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


Re: [Lazarus] Lazbuild search path

2012-02-17 Thread Mattias Gaertner
On Fri, 17 Feb 2012 15:29:45 -0300
Leonardo M. Ramé  wrote:

> Hi, I'm trying to use Lazbuild from a cron job in a server to create
> nightly builds. Our projects are developed on machines with different
> paths for libraries, and I would like to know how to force Lazbuild to
> ignore the search-path specified in the .lpi file, and use a new one.
> 
> How can I do that?

Why does you lpi contain wrong search paths?

Make the search paths relative. 

Put the platform specific parts into packages.

Use macros.
http://wiki.lazarus.freepascal.org/IDE_Macros_in_paths_and_filenames

Use environment options and the macro env.

Otherwise:
Copy the lpi and change the search paths there.

Mattias

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


Re: [Lazarus] FPDocManager now handles selectable FCL packages

2012-02-17 Thread Mattias Gaertner
On Fri, 17 Feb 2012 19:09:54 +0100
Hans-Peter Diettrich  wrote:

> Mattias Gaertner schrieb:
> > On Fri, 17 Feb 2012 14:30:17 +0100
> > Hans-Peter Diettrich  wrote:
> > 
> >> [...]
> >> Most FPDoc tools fail to work on units which deserve special compiler 
> >> options, when the user cannot supply the required options. I.e. you may 
> >> not be able to add descriptions in the FPDoc Editor,
> > 
> > Please report FCL units that fail to parse in Lazarus.
> 
> I didn't talk about Lazarus (IDE)?

Ok, sorry. I thought you talked about the "FPDoc Editor" of the IDE.
 

Mattias

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


Re: [Lazarus] Lazarus trunk help options: CHM Help browser does not show up

2012-02-17 Thread Reinier Olislagers
On 17-2-2012 17:18, Marco van de Voort wrote:
> On Fri, Feb 17, 2012 at 03:37:49PM +0100, Reinier Olislagers wrote:
>>> If you want to create the RTL and FCL docs during installation, you can
>>> use according project files. These files are e.g. created by the
>>> FPDocManager.
>> That's news...must have not been paying attention.
>> What are these project files called? Can I get them when installing FPC
>> only (i.e. without Lazarus)
> 
> In theory
> 
> make chm DOCS="rtl fcl" should do it, but it currently hits windows
> commandline limits. (see below to get an idea) Dodi is right that the
> bulk of the definition of filenames and paths should move out of the
> makefile and into a project file. Michael is working on this, but still
> WIP.
> 
> Prog/ref/user etc stuff require latex and tex4ht. But then it fails (under
> windows) on some shell script in the makefile (easily worked around
> using cygwin, but not for the unwashed masses). I don't think this will ever
> be common round, since tex4ht is funky. 
> 
> In short: I would simply download the CHMs, and forget about auto-generation
> for now. The sources are not always in a compilable state, and not branch
> (trunk vs 2.6.x) and OS independent either

Thanks. That's the direction I'm pursuing right now.

>>> In the case of the FPC documentation some paths have to be
>>> fixed, so that the other builds can e.g. find the content files. Since
>>> the FPC descriptions do not change very often, you can distribute the
>>> project files together with your installer.
> (IMHO this should not be needed. A system that relies on random hardcoded
> paths in a particular setup is flawed)

Agreed, but will let other people fight it out ;)

>>> Since you have to download the docs sources in either case, you also can
>>> use the supplied MakeFile, of course.
>> ... unless I'm overlooking something again, that requires latex to
>> export to chm files??
>> (eg make chm IIRC)
> 
> And tex4ht
ACK.

> 
>> Chances of it being available on Windows, OSX, are not much higher than
>> on Linux. Requiring it just to build documentation seems... excessive.
> 
> I don't see why.

I mentioned that because the Lazarus people seemed to manage with their
lcl_build_docs (IIRC), which uses fpdoc to generate CHM files from XML
source - either by using my Tex installation on Windows, or not
requireing latex.

>>> Full offline documentation also should include the REF etc. files, which
>>> cannot be created like the LCL docs. So it might be easier to download
>>> the readily available help files, instead of creating these during the
>>> installation.
>>  that's the solution I'm going for right now... ;)
> 
> The 2.6.0 CHMs are available from FPC ftp (dist//docs/doc-chm.zip). 
> So that leaves only the lazarus
> LCLs.
Thans, got that.
LCL docs I can generate (see above).


> There are irregular snapshots on my homepage:
> 
> http://www.stack.nl/~marcov/doc-chm.zip
> 
> these do contain lcl stuff.
En nog een keer bedankt, Marco,

regards,
Reinier

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


Re: [Lazarus] Lazarus trunk help options: CHM Help browser does not show up

2012-02-17 Thread Reinier Olislagers
On 17-2-2012 18:11, Graeme Geldenhuys wrote:
> On 17 February 2012 17:22, Reinier Olislagers  wrote:
>>
>> Just to confirm: that would be by running
>> make chm
>> in the fpcdocs directory?
>> That throws up a lot of Latex warnings in my install...
> I'm at home now, and don't have a copy of the fpddocs repository. But
> I do remember a README file in that repository, explaining how to
> build RTL and FCL specific docs.

Dis nie 'n probleem nie, Graeme... Ek dink mens het Latex nodig maar dit
maak nie rerig saak nie (sien onder)
No problem, Graeme... I though you need Latex, but it doesn't really
matter (see below)

> NOTE:
> I don't know what platform you are using, but I do know that building
> the docs under Windows, hits a command line parameter limit. Work is
> being done to resolve this, but I don't know how far that work has
> progressed.

Trying to get fpcup running on Windows, OSx, Linux... perhaps FreeBSD
too, if things work out correctly & Marco v.d. Voort can test it ;)

Other people confirmed the limit in Windows; I'll go with downloading
FPC documentation for now,

dankie,
Reinier



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


Re: [Lazarus] Looking for a general text editor

2012-02-17 Thread Darius Blaszyk

On Feb 17, 2012, at 7:30 PM, Bart wrote:

> On 2/16/12, felipemonteiro.carva...@gmail.com
>  wrote:
>> Em 16/02/2012, às 20:41, Bart  escreveu:
>>> Why not simply use my MruList unit
>>> (http://home.tiscali.nl/~knmg0017/software/fpc_laz/mrulists.zip) as
>>> well?
> 
>> If it is portable it should be fine
> 
> It should be, this is the uses clause:
> 
> uses
>  SysUtils, Classes, Controls, Registry, IniFiles, FileUtil;
It won't be. Registry is windows only. Why not implement something yourself 
based on an XML file? Should be trivial. Here's some inspiration: 
http://www.angusj.com/delphi/mruunit.html


>> just add to the project svn,
> 
> How?
> 
>> I killed all dependencies because a lot of
>> people use non-standard stuff which don't work for example in Mac and bring
>> all sords of problems to build and modify the program.
> 
> I tend to use only standard LCL stuff...
> 
>> For me the best would
>> be giving you commit rights to the ccr if you don't have already and you
>> commit directly what you see fit.
> 
> I'm unfamiliar with committing via svn (or any other tool like that).
> Is there a wiki-entry about how to do that?
> Do I need more then my svn client?
Just search the wiki;

http://wiki.lazarus.freepascal.org/Using_the_Lazarus-ccr_SVN_repository
http://wiki.lazarus.freepascal.org/Lazarus_git-svn
http://wiki.lazarus.freepascal.org/Creating_A_Patch

If you're on windows, chances are you're using tortoisesvn. Just read the 
documentation of that app. There are plenty of quick guides online. And of 
course, if you have specific questions either ask on IRC or on the ML.

Regards, Darius
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus trunk help options: CHM Help browser does not show up

2012-02-17 Thread Hans-Peter Diettrich

Marco van de Voort schrieb:

On Fri, Feb 17, 2012 at 03:37:49PM +0100, Reinier Olislagers wrote:

If you want to create the RTL and FCL docs during installation, you can
use according project files. These files are e.g. created by the
FPDocManager.

That's news...must have not been paying attention.
What are these project files called? Can I get them when installing FPC
only (i.e. without Lazarus)


In theory

make chm DOCS="rtl fcl" should do it, but it currently hits windows
commandline limits. (see below to get an idea)


Where is the DOCS option (and more) documented?


Dodi is right that the
bulk of the definition of filenames and paths should move out of the
makefile and into a project file. Michael is working on this, but still
WIP.


The problem was not the length of the commandline. The AVs are/were due 
to duplicate include paths or defines, created from the MakeFile. This 
should have been fixed in FPDoc already.




In the case of the FPC documentation some paths have to be
fixed, so that the other builds can e.g. find the content files. Since
the FPC descriptions do not change very often, you can distribute the
project files together with your installer.


(IMHO this should not be needed. A system that relies on random hardcoded
paths in a particular setup is flawed)


References to the content files of required packages require 
installation-specific pathes. The installer should know, however, in 
which directories the files reside, and can create the commandlines 
accordingly.


Another problem is the OStarget, which is somewhat hard-coded in the 
MakeFile, and then mixed with the current platform in the MakeFile. 
FPDoc adds further defines to the input specs, to increase the confusion 
and chance for errors. The input specifiers in a project include the 
settings derived on the machine on which the project was created, which 
will mix up with the settings added by FPDoc at runtime. One such 
problem has already been fixed in the MakeFile.


And one more problem are inconsistent directory separators. At least I 
had to fix several paths already, before passing them to fpdoc or makeskel.



--


D:\repo\fpcdocs>make CHM DOCS="rtl fcl"
make html HTMLFMT=chm
make[1]: Entering directory `D:/repo/fpcdocs'

[...]
This looks like an apostrophe (single quoted) added to the path?
More such single quotes, used instead of double quotes in the MakeFile, 
cause error messages on Windows, like reported here:

'..' is not recognized as an internal or external command,
operable program or batch file.
make[1]: *** [rtl.chk] Error 1
make[1]: Leaving directory `D:/repo/fpcdocs'
make: *** [CHM] Error 2


These bugs should have been fixed in the MakeFile already.

More errors can follow (on make rtl.chk), when the CSS file is not 
found, and when "touch" is not found as a command. Both errors are not 
fatal, except that the CSS file is not used, but should be avoided, somehow.


DoDi


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


Re: [Lazarus] Lazarus trunk help options: CHM Help browser does not show up

2012-02-17 Thread Hans-Peter Diettrich

Reinier Olislagers schrieb:

On 17-2-2012 15:16, Hans-Peter Diettrich wrote:

Reinier Olislagers schrieb:

Now going to see if I can either persuade fpdoc to spit out rtl.chm and
fcl.chm, or download the latest release versions... et voila, working
offline help installed for free with your Lazarus SVN copy ;) (oh.. and
Graeme, with FPC source as well... SCNR...)


Thanks, DoDi,


If you want to create the RTL and FCL docs during installation, you can
use according project files. These files are e.g. created by the
FPDocManager.

That's news...must have not been paying attention.


Yes, it's a feature of FPC trunk only.


What are these project files called? Can I get them when installing FPC
only (i.e. without Lazarus)


These are XML files. You can create such projects yourself, by adding
  fpdoc ... --write-project=MyPrj.xml
to an fpdoc commandline.


In the case of the FPC documentation some paths have to be
fixed, so that the other builds can e.g. find the content files. Since
the FPC descriptions do not change very often, you can distribute the
project files together with your installer.

Mmm, ok, I guess that answers one of my previous questions.


Since you have to download the docs sources in either case, you also can
use the supplied MakeFile, of course.

... unless I'm overlooking something again, that requires latex to
export to chm files??
(eg make chm IIRC)


No. LaTeX may be required for the basic FPC docs, whose sources are 
LaTeX(?), but not for the helpfiles for units (RTL, FCL, LCL), built 
from XML docs.



Chances of it being available on Windows, OSX, are not much higher than
on Linux. Requiring it just to build documentation seems... excessive.


Full offline documentation also should include the REF etc. files, which
cannot be created like the LCL docs. So it might be easier to download
the readily available help files, instead of creating these during the
installation.

 that's the solution I'm going for right now... ;)


Sometimes it requires a few steps in other directions, until we find the 
simplest solution ;-)


DoDi


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


Re: [Lazarus] FPDocManager now handles selectable FCL packages

2012-02-17 Thread Mattias Gaertner
On Fri, 17 Feb 2012 19:09:54 +0100
Hans-Peter Diettrich  wrote:

> Mattias Gaertner schrieb:
> > On Fri, 17 Feb 2012 14:30:17 +0100
> > Hans-Peter Diettrich  wrote:
> > 
> >> [...]
> >> Most FPDoc tools fail to work on units which deserve special compiler 
> >> options, when the user cannot supply the required options. I.e. you may 
> >> not be able to add descriptions in the FPDoc Editor,
> > 
> > Please report FCL units that fail to parse in Lazarus.
> 
> I didn't talk about Lazarus (IDE)?
> 
> But here is such a Lazarus unit:
>D:\repos\lazarusTrunk\components\jcf2\Parse\Tokens.pas

I found a project jcf.lpi which uses this unit. 
I fixed compilation.
No parser error.

What project/package have you used?

> IMO this is a different issue, when the unit is not part of the project 
> or of a loaded package.

What do you expect?

Mattias

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


Re: [Lazarus] Looking for a general text editor

2012-02-17 Thread Graeme Geldenhuys
On 17 February 2012 21:15, Darius Blaszyk  wrote:
> Why not implement something yourself based on an XML file?
> Should be trivial. Here's some inspiration:
>http://www.angusj.com/delphi/mruunit.html

Or simply use a INI file - which seems to be used already in that app.

PS:
Doesn't LCL come with a MRU component? I thought I saw it once on my
component palette. Just looked again, and can't find it now though.


>>> just add to the project svn,
>>
>> How?

Or read the SVN documentation. It is called the SVN Red Book, and it
is well written, with lots of examples.

  http://svnbook.red-bean.com/

Another more versatile option is to use git-svn. That means you work
with a SVN repository but managed by Git. Git has lots of benefits
over SVN (local commits, local branch, local history, better merging
support etc), and with git-svn you can use git, but collaborate with
other users in a SVN repository. Well worth a look.

  http://wiki.lazarus.freepascal.org/Lazarus_git-svn

-- 
Regards,
  - Graeme -


___
fpGUI - a cross-platform Free Pascal GUI toolkit
http://fpgui.sourceforge.net

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


Re: [Lazarus] Lazbuild search path

2012-02-17 Thread Leonardo M . Ramé
On 2012-02-17 19:57:47 +0100, Mattias Gaertner wrote:
> On Fri, 17 Feb 2012 15:29:45 -0300
> Leonardo M. Ramé  wrote:
> 
> > Hi, I'm trying to use Lazbuild from a cron job in a server to create
> > nightly builds. Our projects are developed on machines with different
> > paths for libraries, and I would like to know how to force Lazbuild to
> > ignore the search-path specified in the .lpi file, and use a new one.
> > 
> > How can I do that?
> 
> Why does you lpi contain wrong search paths?
> 
> Make the search paths relative. 
> 
> Put the platform specific parts into packages.
> 
> Use macros.
> http://wiki.lazarus.freepascal.org/IDE_Macros_in_paths_and_filenames
> 
> Use environment options and the macro env.
> 
> Otherwise:
> Copy the lpi and change the search paths there.
> 

Thanks Mattias, the lpi contains correct search path for the develpment
PC, but the library directories are organized differently on the build machine.

Is there a way to pass a Macro as an Lazbuild parameter?.

-- 
Leonardo M. Ramé
http://leonardorame.blogspot.com

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


Re: [Lazarus] Lazarus trunk help options: CHM Help browser does not show up

2012-02-17 Thread Marco van de Voort
On Fri, Feb 17, 2012 at 08:05:48PM +0100, Reinier Olislagers wrote:
> >> Chances of it being available on Windows, OSX, are not much higher than
> >> on Linux. Requiring it just to build documentation seems... excessive.
> > 
> > I don't see why.
> 
> I mentioned that because the Lazarus people seemed to manage with their
> lcl_build_docs (IIRC), which uses fpdoc to generate CHM files from XML
> source - either by using my Tex installation on Windows, or not
> requireing latex.

fpdoc is a FPC package, and the RTL and FCL doc sets of FPC work with it
too.

However, those are all documentation of sources. 

The latex manuals however are not XML. Editing latex is much more
confortable, and allows high quality PDF using a lot of the latex features,
not in the least the macro system.

The extra requirements are certainly a pain, but changing this would just
create a bigger pain.

Moreover, documentation building is not exactly that the average user does
regularly (seeing that there are less than 10 patches for it per quarter),
so it doesn't make sense to optimize it.

I do think it should at least be possible to do this on Windows. From a
philosophical perspective, FPC should not force a certain platform on people
wanting to be developers.

My first latex-on-windows attempt was in '98, so be sure that I have been
waiting quite some time :)

latex is already doable.  fpdoc based docs already work, but not via the
make system. (IIRC calling fpdoc via createprocessex does work, since the 
API limit is much higher than the shell limit). 

The commandline problems can be avoided via the project system, and on a
slightly longer term, maybe fpmake will allow to kill off the horrible
makefile of fpdocs.

But even then,
tex4ht on Windows is still an unknown factor. But for now, one thing at a
time :-)


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


Re: [Lazarus] Lazbuild search path

2012-02-17 Thread Mattias Gaertner
On Fri, 17 Feb 2012 17:28:13 -0300
Leonardo M. Ramé  wrote:

> On 2012-02-17 19:57:47 +0100, Mattias Gaertner wrote:
> > On Fri, 17 Feb 2012 15:29:45 -0300
> > Leonardo M. Ramé  wrote:
> > 
> > > Hi, I'm trying to use Lazbuild from a cron job in a server to create
> > > nightly builds. Our projects are developed on machines with different
> > > paths for libraries, and I would like to know how to force Lazbuild to
> > > ignore the search-path specified in the .lpi file, and use a new one.
> > > 
> > > How can I do that?
> > 
> > Why does you lpi contain wrong search paths?
> > 
> > Make the search paths relative. 
> > 
> > Put the platform specific parts into packages.
> > 
> > Use macros.
> > http://wiki.lazarus.freepascal.org/IDE_Macros_in_paths_and_filenames
> > 
> > Use environment options and the macro env.
> > 
> > Otherwise:
> > Copy the lpi and change the search paths there.
> > 
> 
> Thanks Mattias, the lpi contains correct search path for the develpment
> PC, but the library directories are organized differently on the build 
> machine.

Normally you organize libraries in lazarus packages. It's not hard. Just
create a package, add the files and add the package to the project.

Then you can simply do

lazbuild /path/to/package.lpk /path/to/project.lpi

I hardly set search paths anymore. The IDE does that for me.

 
> Is there a way to pass a Macro as an Lazbuild parameter?.

Add to the project compiler options search path ;$ENV(MYPATH).

Then you can do in bash:
MYPATH=/your/path lazbuild some.lpi


Mattias

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


Re: [Lazarus] Lazarus trunk help options: CHM Help browser does not show up

2012-02-17 Thread Marco van de Voort
On Fri, Feb 17, 2012 at 08:05:51PM +0100, Hans-Peter Diettrich wrote:
> > In theory
> > 
> > make chm DOCS="rtl fcl" should do it, but it currently hits windows
> > commandline limits. (see below to get an idea)
> 
> Where is the DOCS option (and more) documented?

Should it be? 

If you think it should, please annotate such things in the wiki.  :-)
 
> > Dodi is right that the
> > bulk of the definition of filenames and paths should move out of the
> > makefile and into a project file. Michael is working on this, but still
> > WIP.
> 
> The problem was not the length of the commandline.

> The AVs are/were due to duplicate include paths or defines, created from
> the MakeFile.  This should have been fixed in FPDoc already.

I haven't said anything about AVs. See the makefile I posted.

Afaik I once tried to run the commandline constructed on linux on Windows 
via tprocess. That worked fine. Probably because it avoids shell and
make limitations.

> > (IMHO this should not be needed. A system that relies on random hardcoded
> > paths in a particular setup is flawed)
> 
> References to the content files of required packages require 
> installation-specific pathes. 

Then they shouldn't be in the project system, but passed on the commandline,
or a seperate settings file.

Having to edit project files before using them, just switches one voodoo
solution by the other.

> The installer should know, however, in 
> which directories the files reside, and can create the commandlines 
> accordingly.

Which installer? Primarily docs are run by release engineers from svn. 
This use should be central.
 
> Another problem is the OStarget, which is somewhat hard-coded in the 
> MakeFile, and then mixed with the current platform in the MakeFile.

That is a totally different problem. A quality solution for that is very
costly, and IMHO that time can be spent on better things. 

> FPDoc adds further defines to the input specs, to increase the confusion 
> and chance for errors. The input specifiers in a project include the 
> settings derived on the machine on which the project was created, which 
> will mix up with the settings added by FPDoc at runtime. One such 
> problem has already been fixed in the MakeFile.

I've no idea what so ever you are talking about.
 
> And one more problem are inconsistent directory separators. At least I 
> had to fix several paths already, before passing them to fpdoc or makeskel.

That is general crossplatform and make problems. One of the reasons for me
that make has to go long term.

New versions of half of the win32 tools we use aren't available, and the
newest are from 2005.

> > --
> > 
> > 
> > D:\repo\fpcdocs>make CHM DOCS="rtl fcl"
> > make html HTMLFMT=chm
> > make[1]: Entering directory `D:/repo/fpcdocs'
> [...]
> This looks like an apostrophe (single quoted) added to the path?

> cause error messages on Windows, like reported here:
> > '..' is not recognized as an internal or external command,
> > operable program or batch file.
> > make[1]: *** [rtl.chk] Error 1
> > make[1]: Leaving directory `D:/repo/fpcdocs'
> > make: *** [CHM] Error 2
> 
> These bugs should have been fixed in the MakeFile already.

Newest checkout. Up to date snapshot.



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


Re: [Lazarus] Looking for a general text editor

2012-02-17 Thread Sven Barth

On 17.02.2012 20:15, Darius Blaszyk wrote:


On Feb 17, 2012, at 7:30 PM, Bart wrote:


On 2/16/12, felipemonteiro.carva...@gmail.com
  wrote:

Em 16/02/2012, às 20:41, Bart  escreveu:

Why not simply use my MruList unit
(http://home.tiscali.nl/~knmg0017/software/fpc_laz/mrulists.zip) as
well?



If it is portable it should be fine


It should be, this is the uses clause:

uses
  SysUtils, Classes, Controls, Registry, IniFiles, FileUtil;

It won't be. Registry is windows only. Why not implement something yourself 
based on an XML file? Should be trivial. Here's some inspiration: 
http://www.angusj.com/delphi/mruunit.html


You are wrong. The Registry unit of FPC is implemented in a Cross 
Plattform way. On non-Windows plattforms it uses a XML file to store the 
values. As long as you don't need security related stuff (access 
control, etc) or need to access Registry keys of the OS or other 
applications this should be sufficient.


Regards,
Sven


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


Re: [Lazarus] Lazbuild search path

2012-02-17 Thread Leonardo M . Ramé
On 2012-02-17 21:39:59 +0100, Mattias Gaertner wrote:
> On Fri, 17 Feb 2012 17:28:13 -0300
> Leonardo M. Ramé  wrote:
> 
> > On 2012-02-17 19:57:47 +0100, Mattias Gaertner wrote:
> > > On Fri, 17 Feb 2012 15:29:45 -0300
> > > Leonardo M. Ramé  wrote:
> > > 
> > > > Hi, I'm trying to use Lazbuild from a cron job in a server to create
> > > > nightly builds. Our projects are developed on machines with different
> > > > paths for libraries, and I would like to know how to force Lazbuild to
> > > > ignore the search-path specified in the .lpi file, and use a new one.
> > > > 
> > > > How can I do that?
> > > 
> > > Why does you lpi contain wrong search paths?
> > > 
> > > Make the search paths relative. 
> > > 
> > > Put the platform specific parts into packages.
> > > 
> > > Use macros.
> > > http://wiki.lazarus.freepascal.org/IDE_Macros_in_paths_and_filenames
> > > 
> > > Use environment options and the macro env.
> > > 
> > > Otherwise:
> > > Copy the lpi and change the search paths there.
> > > 
> > 
> > Thanks Mattias, the lpi contains correct search path for the develpment
> > PC, but the library directories are organized differently on the build 
> > machine.
> 
> Normally you organize libraries in lazarus packages. It's not hard. Just
> create a package, add the files and add the package to the project.
> 
> Then you can simply do
> 
> lazbuild /path/to/package.lpk /path/to/project.lpi
> 
> I hardly set search paths anymore. The IDE does that for me.

Ah!, I didn't thought about that. Looks good.

For example, I use Synapse library. I could create an .lpk package only
in my build system then I can compile my programs as you mentioned.

> 
>  
> > Is there a way to pass a Macro as an Lazbuild parameter?.
> 
> Add to the project compiler options search path ;$ENV(MYPATH).
> 
> Then you can do in bash:
> MYPATH=/your/path lazbuild some.lpi

-- 
Leonardo M. Ramé
http://leonardorame.blogspot.com

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


Re: [Lazarus] Lazarus trunk help options: CHM Help browser does not show up

2012-02-17 Thread Sven Barth

On 17.02.2012 21:44, Marco van de Voort wrote:

Dodi is right that the
bulk of the definition of filenames and paths should move out of the
makefile and into a project file. Michael is working on this, but still
WIP.


The problem was not the length of the commandline.



The AVs are/were due to duplicate include paths or defines, created from
the MakeFile.  This should have been fixed in FPDoc already.


I haven't said anything about AVs. See the makefile I posted.

Afaik I once tried to run the commandline constructed on linux on Windows
via tprocess. That worked fine. Probably because it avoids shell and
make limitations.


Jupp... the limit for CreateProcess is 32768 characters.

Regards,
Sven

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


Re: [Lazarus] I made a visualization of the Lazarus SVN repository

2012-02-17 Thread Juha Manninen
2012/2/17, Everton Vieira :
> Em 17/02/2012, às 15:41, Juha Manninen escreveu:
>> Everton, start providing patches. It is easy and secure! :)
>
> Always that I can I will :) And you fly a lot brother! That`s so nice. Sure
> you have a very large view of it. Wish i had too.

I don't really have so big view. The existing code must be studied
always when creating new code. A good IDE with its code browsing and
other features is important then, it works as an extension of the
brains.


> Well, I had the idea that would be good to integrate in the IDE the process
> of bug report and patching. Today is too diffuse this work and many doesn't
> even know what it is. Make integrate in the IDE would make more concentrated
> and visible.

Do you have problems now creating bug reports and patches? What kind
of problems?
I don't know how, and why, should patching be integrated in IDE. A
patch is easy to make with "svn diff" for example. The difficult part
is actually creating high quality code for a big project of over 1 000
000 LOC. There is no simple trick to make that easy.

Integrating bug reporting into IDE would have benefits if the IDE can
trap an exception and include details of it in the report, together
with info about the environment, and send it (semi-)automatically
somewhere.
Until that is implemented, the current issue tracker works very well IMO.

Juha

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


[Lazarus] TMSSQLConnection - sqlDB component for accessing MS SQL Server

2012-02-17 Thread Marcos Douglas
Hi,

As you can see here http://bugs.freepascal.org/view.php?id=17303 the
developer known to LacaK developed a new connector for MSSQLServer,
descendant of TSQLConnection class, and sent the beta code in 2010-08-30.

Some developers discussed the new code here:
http://lazarus.freepascal.org/index.php/topic,15135.msg80922.html#msg80922

I'm already using this connector in production without problems.

To FPC core team:
Could you take a look in that component and think about included this code
in SVN to new developers use too, please?

Thanks,
Marcos Douglas
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] TMSSQLConnection - sqlDB component for accessing MS SQL Server

2012-02-17 Thread William Oliveira Ferreira
sounds good, will be a nice tool! It works on linux natively or need some
external lib?

William de Oliveira Ferreira
Bacharel em Sistemas de Informação


2012/2/17 Marcos Douglas 

> Hi,
>
> As you can see here http://bugs.freepascal.org/view.php?id=17303 the
> developer known to LacaK developed a new connector for MSSQLServer,
> descendant of TSQLConnection class, and sent the beta code in 2010-08-30.
>
> Some developers discussed the new code here:
> http://lazarus.freepascal.org/index.php/topic,15135.msg80922.html#msg80922
>
> I'm already using this connector in production without problems.
>
> To FPC core team:
> Could you take a look in that component and think about included this code
> in SVN to new developers use too, please?
>
> Thanks,
> Marcos Douglas
>
> --
> ___
> Lazarus mailing list
> Lazarus@lists.lazarus.freepascal.org
> http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
>
>
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] TMSSQLConnection - sqlDB component for accessing MS SQL Server

2012-02-17 Thread Marcos Douglas
2012/2/17 William Oliveira Ferreira 
>
> sounds good, will be a nice tool! It works on linux natively or need some 
> external lib?

Work on Windows and Linux.

Marcos Douglas

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


[Lazarus] Thanks for the help!

2012-02-17 Thread Reinier Olislagers
Amidst the discussion of the failings/possible improvement of help
systems, I'd like to thank everybody involved in getting Lazarus and FPC
help to the state it is now.

Using the ExternHelp and ChmHelpPkg packages in Lazarus, I get
context-sensitive help for FPC/Lazarus keywords, and I even get MSDN
help for some Windows specific keywords!

Thanks a lot,
Reinier

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


Re: [Lazarus] Lazarus trunk help options: CHM Help browser does not show up

2012-02-17 Thread Reinier Olislagers
On 17-2-2012 21:36, Marco van de Voort wrote:
> On Fri, Feb 17, 2012 at 08:05:48PM +0100, Reinier Olislagers wrote:
 Chances of it being available on Windows, OSX, are not much higher than
 on Linux. Requiring it just to build documentation seems... excessive.
>>>
>>> I don't see why.
>>
>> I mentioned that because the Lazarus people seemed to manage with their
>> lcl_build_docs (IIRC), which uses fpdoc to generate CHM files from XML
>> source - either by using my Tex installation on Windows, or not
>> requireing latex.
> 
> fpdoc is a FPC package, and the RTL and FCL doc sets of FPC work with it
> too.
I understand.

> However, those are all documentation of sources. 
> 
> The latex manuals however are not XML. Editing latex is much more
> confortable, and allows high quality PDF using a lot of the latex features,
> not in the least the macro system.
I know and see the point in using latex for that. (Especially since we
have such nice reference documentation, with a maintainer of the
toolchain and all... )

Sorry, I should have written my previous post a bit better, indicating I
knew the reason for using latex as such.

> The extra requirements are certainly a pain, but changing this would just
> create a bigger pain.
> 
> Moreover, documentation building is not exactly that the average user does
> regularly (seeing that there are less than 10 patches for it per quarter),
> so it doesn't make sense to optimize it.
Agreed.

> I do think it should at least be possible to do this on Windows. From a
> philosophical perspective, FPC should not force a certain platform on people
> wanting to be developers.

;)

> My first latex-on-windows attempt was in '98, so be sure that I have been
> waiting quite some time :)
Installed miktex, but not a latex guru at all, so when the make bombs, I
have no idea where the error originated... my install, the makefiles on
Windows...

> latex is already doable.  fpdoc based docs already work, but not via the
> make system. (IIRC calling fpdoc via createprocessex does work, since the 
> API limit is much higher than the shell limit). 
> 
> The commandline problems can be avoided via the project system, and on a
> slightly longer term, maybe fpmake will allow to kill off the horrible
> makefile of fpdocs.
The project system being fppkg? Or fpdocmanager?

> But even then,
> tex4ht on Windows is still an unknown factor. But for now, one thing at a
> time :-)
Totally agreed.

Thanks,
Reinier

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


Re: [Lazarus] TMSSQLConnection - sqlDB component for accessing MS SQL Server

2012-02-17 Thread Reinier Olislagers
On 18-2-2012 2:13, William Oliveira Ferreira wrote:
> sounds good, will be a nice tool! It works on linux natively or need
> some external lib?
> 
> William de Oliveira Ferreira
> Bacharel em Sistemas de Informação

It uses freetds; IIRC, the forum post contains (a link to) a recent
binary for Windows.
On Linux, your package manager should probably have it ;)

By the way, thanks to FreeTDS, TMSSQL can also talk to Sybase ASE servers.

Regards,
Reinier

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


Re: [Lazarus] Lazarus trunk help options: CHM Help browser does not show up

2012-02-17 Thread Reinier Olislagers
On 18-2-2012 6:46, Reinier Olislagers wrote:
> On 17-2-2012 21:36, Marco van de Voort wrote:
>> The commandline problems can be avoided via the project system, and on a
>> slightly longer term, maybe fpmake will allow to kill off the horrible
>> makefile of fpdocs.
> The project system being fppkg? Or fpdocmanager?
Sorry, please disregard; DoDi's post indicated it is some new feature in
trunk...

Thanks,
Reinier

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


[Lazarus] Lazarus usable with FPC trunk?

2012-02-17 Thread Reinier Olislagers
Hi list,

Recently I've seen some indication Lazarus is being used with FPC trunk.

Because of the major Unicode changes in 2.7, I think Marco advised to
use Lazarus with FPC 2.6.

I'm still using fixes_2.6 for both my "unstable" development system, and
a backup development system.

Would it make sense to move over to trunk?

Thanks,
Reinier

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


Re: [Lazarus] FPDocManager now handles selectable FCL packages

2012-02-17 Thread Hans-Peter Diettrich

Mattias Gaertner schrieb:

On Fri, 17 Feb 2012 19:09:54 +0100
Hans-Peter Diettrich  wrote:


Mattias Gaertner schrieb:

On Fri, 17 Feb 2012 14:30:17 +0100
Hans-Peter Diettrich  wrote:


[...]
Most FPDoc tools fail to work on units which deserve special compiler 
options, when the user cannot supply the required options. I.e. you may 
not be able to add descriptions in the FPDoc Editor,

Please report FCL units that fail to parse in Lazarus.

I didn't talk about Lazarus (IDE)?


Clarification: When working on/with the FPDocManager, or with the 
documentation commandline tools (fpdoc, makeskel...), the fpdoc units 
can report errors when processing units. This is one scenario.
When I open these reported units in the IDE, these are not normally part 
of the current project, so this is another scenario.



The file fcl-process/src/pipesipc.pp is broken on many platforms. It 
only contains:

  {$define ipcunit}
  {$i simpleipc.inc}
but neither dummy/simpleipc.inc nor win/simpleipc.inc care about 
ipcunit, so that the module lacks unit, interface, implementation 
clauses and an "end.". This is invalid syntax. When included by 
simpleipc.pp, the module syntax for "unit simpleipc;" is okay, 
beforementioned parts reside in simpleipc.pp.


Even if pipesipc.pp were a program, a "begin ... end." part is missing, 
and it's known that fpdoc doesn't accept program modules.


These are definitely bugs in the fcl-process sources, should I file an 
bug report?




But here is such a Lazarus unit:
   D:\repos\lazarusTrunk\components\jcf2\Parse\Tokens.pas


I found a project jcf.lpi which uses this unit. 
I fixed compilation.

No parser error.


I just can't test your update, due to SVN server problems. In the last 
version the CodeExplorer didn't show any entries for this unit.



What project/package have you used?


No special package. I only opened the unit in the IDE, from the global 
search results for "parser".



IMO this is a different issue, when the unit is not part of the project 
or of a loaded package.


What do you expect?


I don't expect that the IDE (code tools...) can handle units out of 
their containing package, when these require special compiler options 
(include paths...). FPDoc Editor alerts the user on an attempt to 
document an unit, which is not part of the current project or of a 
(loaded) package.


Please note that the Lazarus FCL package only contains an subset of the 
FPC FCL units, including simpleipc.pp, but not pipesipc.pp. Can I assume 
that all FCL units, which require special compiler options, should 
become part of the Lazarus FCL package? In this case the various 
simpleipc.inc files have to be fixed, before pipesipc.pp can be added to 
this package. But even then I don't understand how the required include 
path for simpleipc.pp is found by Lazarus.


DoDi


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


Re: [Lazarus] Lazarus trunk help options: CHM Help browser does not show up

2012-02-17 Thread Hans-Peter Diettrich

Marco van de Voort schrieb:

On Fri, Feb 17, 2012 at 08:05:51PM +0100, Hans-Peter Diettrich wrote:

In theory

make chm DOCS="rtl fcl" should do it, but it currently hits windows
commandline limits. (see below to get an idea)

Where is the DOCS option (and more) documented?


Should it be?


Tell me a reason why it does *not* deserve documentation.


If you think it should, please annotate such things in the wiki.  :-)


What do you expect me to annotate? That I'm missing a documentation of 
the options, which the user can add on a "make" commandline?




(IMHO this should not be needed. A system that relies on random hardcoded
paths in a particular setup is flawed)
References to the content files of required packages require 
installation-specific pathes. 


Then they shouldn't be in the project system, but passed on the commandline,
or a seperate settings file.


They become part of the project created using --write-project. This is 
not noticeable in the RTL and FCL projects, where all files reside in 
the same directory. When e.g. the LCL refers to the RTL and FCL, the 
content files (--import) reside in different directories, so that at 
least macros or environment options have to be used to evaluate the 
pathes on a user machine.



Having to edit project files before using them, just switches one voodoo
solution by the other.

+1


The installer should know, however, in 
which directories the files reside, and can create the commandlines 
accordingly.


Which installer? Primarily docs are run by release engineers from svn. 
This use should be central.


This part was in response to the generation of local documentation by 
the new installer (FPCup) of Reinier.



Another problem is the OStarget, which is somewhat hard-coded in the 
MakeFile, and then mixed with the current platform in the MakeFile.


That is a totally different problem. A quality solution for that is very
costly, and IMHO that time can be spent on better things. 

FPDoc adds further defines to the input specs, to increase the confusion 
and chance for errors. The input specifiers in a project include the 
settings derived on the machine on which the project was created, which 
will mix up with the settings added by FPDoc at runtime. One such 
problem has already been fixed in the MakeFile.


I've no idea what so ever you are talking about.


See this snippet from your posted make:

>>
make[1]: Entering directory `D:/repo/fpcdocs'
../fpc/utils/fpdoc/fpdoc  --warn-no-node --package=rtl --descr=rtl.xml
--content=rtl.xct --hide-protected --descr=system.xml --input="-dfpdocsystem
-- -dHASGETHEAP
STATUS -dSUPPORT_DOUBLE ../fpc/rtl/win32/system.pp -Fi../fpc/rtl/win32
-Fi../fpc/rtl/unix -Fi../fpc/rtl/inc -Fi../fpc/rtl/i386 -dCPU32 -dHASVARIANT
- -dFPC_HAS_TY
PE_EXTENDED -dHASWIDECHAR -Fi../fpc/rtl/win -Fi../fpc/rtl/win32
-Fi../fpc/rtl/unix -Fi../fpc/rtl/linux" --descr=objpas.xml
<<

I'd suspect that "-Fi../fpc/rtl/win32" together with 
"-Fi../fpc/rtl/unix" can result in problems. At least the results depend 
on the search order for the include files.


An older MakeFile even added pathes twice, and this has been fixed.


And one more problem are inconsistent directory separators. At least I 
had to fix several paths already, before passing them to fpdoc or makeskel.


That is general crossplatform and make problems. One of the reasons for me
that make has to go long term.


This is not only a make problem, it also turned out that FPDoc, 
build_lcl_docs, and maybe even RTL functions, have problems with mixed 
directory separators. Problems can arise when a script uses the current 
platform separators, and these are different from the separators stored 
in an fpdoc project file.


DoDi


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


  1   2   >