Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2002-12

datasource - dataset

7 messages · 3 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Unknown author
to Jesus Reyes: Hi, I'm reporting this here but I don't know if I should do that in some other place,…
Jesus Reyes wrote
Hi, I'm reporting this here but I don't know if I should do that in some other place, it's a fcl related issue in datasource.inc (FIXES_1_0_0) on line 489: If FStateFlastState then it should be (I think): Fstate=FLastState then ...

Fixed.

Show quoted text 7 lines
In dataset.inc after TDataset.GetField ... Apparently lazarus has problems with nested comments (Shift+Ctrl+Up/Down not further investigated) or can be changed the outer comments from { } to (* .. *). TField.Displaywidth property currently is implemented as: ... Read FDisplayWidth .... but it should be .... Read GetDisplayWidth ...

There is no GetDisplayWidth function. What should it do according to you ? Something like:
Function TField.GetDisplayWidth : Longint;

begin
  If FDisplayWidth0 then
    Result:=FDisplayWidth
  else
    Result:=DataSize
end;

Or what ?

Michael.

Reply by email

Jesus Reyes

Hi, I'm reporting this here but I don't know if I should do that in some other place, it's a fcl related issue in datasource.inc (FIXES_1_0_0) on line 489: If FStateFlastState then it should be (I think): Fstate=FLastState then ...

In dataset.inc after TDataset.GetField ... Apparently lazarus has problems with nested comments (Shift+Ctrl+Up/Down not further investigated) or can be changed the outer comments from { } to (* .. *).

TField.Displaywidth property currently is implemented as: ... Read FDisplayWidth .... but it should be .... Read GetDisplayWidth ...

Thanks.

Jesus Reyes A.

_________________________________________________________ Do You Yahoo!?
La mejor conexi�n a internet y 25MB extra a tu correo por $100 al mes. http://net.yahoo.com.mx

Reply by email

Mattias Gaertner
to Jesus Reyes
In dataset.inc after TDataset.GetField ... Apparently lazarus has problems with nested comments (Shift+Ctrl+Up/Down not further investigated) or can be changed the outer comments from { } to (* .. *).

The CodeTools now has nested comments as default for all directories with the #NestedComment defined (FPC sources and lazarus sources) and for files with the .pp extension.
The $mode directive now also set the nested comments for mode FPC and ObjFPC.

I have not changed the highlighter. I put it on my todo list, but it has no big priority for me. If anyone needs it, you know where you can find the sources ;)

Mattias

Reply by email

Jesus Reyes
to Mattias Gaertner
Show quoted text 15 lines
> be changed the outer comments from { } to (* .. *). The CodeTools now has nested comments as default for all directories with the #NestedComment defined (FPC sources and lazarus sources) and for files with the .pp extension. The $mode directive now also set the nested comments for mode FPC and ObjFPC. I have not changed the highlighter. I put it on my todo list, but it has no big priority for me.

neither for me. :)

Thanks

_________________________________________________________ Do You Yahoo!?
La mejor conexi�n a internet y 25MB extra a tu correo por $100 al mes. http://net.yahoo.com.mx

Reply by email

Jesus Reyes
to Unknown author: Fixed. There is no GetDisplayWidth function. What should it do according to you ?…
Show quoted text 13 lines
There is no GetDisplayWidth function. What should it do according to you ? Something like: Function TField.GetDisplayWidth : Longint; begin If FDisplayWidth0 then Result:=FDisplayWidth else Result:=DataSize end; Or what ?

Yes, or maybe:

....
else

      Result:=GetDefaultWidth;

which is currently implemented in TField. Some other derivatives could override it or just let the default that TField set, being still free of setting
DisplayWidth directly.

By the way, something like:

      property Size; default 20;

declared in TStringField really set Size:=20 when
one creates a instance of TStringField? or it has
another purpose? I'm affraid the reference manual does not mention it

_________________________________________________________ Do You Yahoo!?
La mejor conexi�n a internet y 25MB extra a tu correo por $100 al mes. http://net.yahoo.com.mx

Reply by email

Mattias Gaertner
to Jesus Reyes: Hi, I'm reporting this here but I don't know if I should do that in some other place,…
Show quoted text 8 lines
Hi, I'm reporting this here but I don't know if I should do that in some other place, it's a fcl related issue in datasource.inc (FIXES_1_0_0) on line 489: If FStateFlastState then it should be (I think): Fstate=FLastState then ... In dataset.inc after TDataset.GetField ... Apparently lazarus has problems with nested comments (Shift+Ctrl+Up/Down not further investigated) or can be changed the outer comments from { } to (* .. *).

Nested comments are a problem in general. Delphi does not support them and so the synedit highlighter which is used by the lazarus IDE does not support them. The codetools and fpc can handle them, but they are not activated in all modes. So for fpc code you have to turn it on as default, but for Delphi code you have to turn it off as default. Because lazarus should work with Delphi and FPC code, and nested comments are used very seldom, I have turned them off.
I will add a directory flag, so that nested comments are turned on for the FPC source files.
But the synedit highlighter will need much more work.

Mattias

Show quoted text 16 lines
TField.Displaywidth property currently is implemented as: ... Read FDisplayWidth .... but it should be .... Read GetDisplayWidth ... Thanks. Jesus Reyes A. _________________________________________________________ Do You Yahoo!? La mejor conexi�n a internet y 25MB extra a tu correo por $100 al mes. http://net.yahoo.com.mx _________________________________________________________________ To unsubscribe: mail with "unsubscribe" as the Subject archives at http://www.lazarus.freepascal.org/mailarchives

Reply by email

Unknown author
to Jesus Reyes: Yes, or maybe: .... else Result:=GetDefaultWidth; which is currently implemented in…
Show quoted text 31 lines
> There is no GetDisplayWidth function. What should it > do according to you ? > Something like: > Function TField.GetDisplayWidth : Longint; > > begin > If FDisplayWidth0 then > Result:=FDisplayWidth > else > Result:=DataSize > end; > > Or what ? Yes, or maybe: .... else Result:=GetDefaultWidth; which is currently implemented in TField. Some other derivatives could override it or just let the default that TField set, being still free of setting DisplayWidth directly. By the way, something like: property Size; default 20; declared in TStringField really set Size:=20 when one creates a instance of TStringField?

No.

or it has another purpose? I'm affraid the reference manual does not mention it

The 'default' is a hint for the streaming property: it means that if the value equals the default value, the streaming system should not stream the value of that property. It saves time and space

But you must still set the default value in the constructor or some other place.

Michael.

Reply by email