Re: [fpc-pascal] Database Metadata proposal

2014-06-03 Thread Daniel Gaspary
On Tue, Jun 3, 2014 at 2:46 AM, LacaK  wrote:
> TSQLConnection.GetTableNames(List: TStrings; SchemaName : String; Options :
> TSchemaOptions);
>
> Which IMO fits better in existing frame.

Using this method, to take all tables, from all schemas, the user
would need to run multiples queries, one for each schema.
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal


[fpc-pascal] Disabling the MIN, MAX, Close icon of EXE in free pascal

2014-06-03 Thread mokashe.ram
Hi Everyone,

 could anyone help me on disabling the MIN,MAX,Close icon of EXE in free
pascal.

Thanks,
sudarshan



--
View this message in context: 
http://free-pascal-general.1045716.n5.nabble.com/Disabling-the-MIN-MAX-Close-icon-of-EXE-in-free-pascal-tp5719494.html
Sent from the Free Pascal - General mailing list archive at Nabble.com.
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] (no subject)

2014-06-03 Thread Dimitrios Chr. Ioannidis

Hi,

Στις 3/6/2014 1:20 μμ, ο/η Reinier Olislagers έγραψε:

On 03/06/2014 12:17, Dimitrios Chr. Ioannidis wrote:

   FYI, in a wst soap client talking to a .net web service i find out,
that for SOAP calls, if the CONTENT-TYPE http header ( i'm using
fpc-http-protocol ) doesn't have the 'text/xml' plus the 'charset=UTF-8'
like this 'text/xml; charset=UTF-8', the server chocks. So, i changed
the const sSOAP_CONTENT_TYPE in base_soap_formatter.pas to
sSOAP_CONTENT_TYPE = 'text/xml; charset=UTF-8', and all is working fine.

I don't know if this is a bug or not.

No idea, but Isn't there a specific wst mailing list/group mentioned on
the WST wiki page? Maybe it's a better idea to post there.


i already done that. I posted here also because i wanted to share it 
with users who doesn't keep track that list while using the wst framework.



BTW: if the content is indeed UTF8, IIRC, it's not a bug to explicitly
specify charset=UTF-8; a similar fix was needed for exporting XML files
to Microsoft .Net dataset XML format IIRC.


AFAIU, in the SOAP HTTP Binding the character encoding in the 
Content-Type header is optional.


Regards,

--
Dimitrios Chr. Ioannidis



smime.p7s
Description: Κρυπτογραφημένη υπογραφή S/MIME
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

[fpc-pascal] (no subject)

2014-06-03 Thread Reinier Olislagers
On 03/06/2014 12:17, Dimitrios Chr. Ioannidis wrote:
>   FYI, in a wst soap client talking to a .net web service i find out,
> that for SOAP calls, if the CONTENT-TYPE http header ( i'm using
> fpc-http-protocol ) doesn't have the 'text/xml' plus the 'charset=UTF-8'
> like this 'text/xml; charset=UTF-8', the server chocks. So, i changed
> the const sSOAP_CONTENT_TYPE in base_soap_formatter.pas to
> sSOAP_CONTENT_TYPE = 'text/xml; charset=UTF-8', and all is working fine.
> 
> I don't know if this is a bug or not.

No idea, but Isn't there a specific wst mailing list/group mentioned on
the WST wiki page? Maybe it's a better idea to post there.

BTW: if the content is indeed UTF8, IIRC, it's not a bug to explicitly
specify charset=UTF-8; a similar fix was needed for exporting XML files
to Microsoft .Net dataset XML format IIRC.
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal


[fpc-pascal] WST SOAP HTTP CONTENT TYPE

2014-06-03 Thread Dimitrios Chr. Ioannidis

Hi,

  FYI, in a wst soap client talking to a .net web service i find out, 
that for SOAP calls, if the CONTENT-TYPE http header ( i'm using 
fpc-http-protocol ) doesn't have the 'text/xml' plus the 'charset=UTF-8' 
like this 'text/xml; charset=UTF-8', the server chocks. So, i changed 
the const sSOAP_CONTENT_TYPE in base_soap_formatter.pas to 
sSOAP_CONTENT_TYPE = 'text/xml; charset=UTF-8', and all is working fine.


I don't know if this is a bug or not.

--
Dimitrios Chr. Ioannidis



smime.p7s
Description: Κρυπτογραφημένη υπογραφή S/MIME
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] Typinfo incompatibilities between FPC and Delphi

2014-06-03 Thread Sven Barth
Am 03.06.2014 10:26 schrieb "Graeme Geldenhuys" <
mailingli...@geldenhuys.co.uk>:
>
> On 2014-05-31 10:57, Vincent Snijders wrote:
> > I think it is possible to write code without $ifdef (valid for Delphi
> > and FPC) if you use the typeinfo unit to extract the information.
> > http://www.freepascal.org/docs-html/rtl/typinfo/
>
> Almost, but not quite. Good news is, it is not nearly as bad as Sven
> makes it out to be.
>

If one uses a helper function like you did then it's indeed not as bad, but
if one doesn't...

> function tiGetTypeInfo(PropInfo: PPropInfo): PTypeInfo;
> begin
> {$IFDEF FPC}
>   Result := PropInfo^.PropType;
> {$ELSE}
>   Result := PropInfo^.PropType^;
> {$ENDIF}
> end;

Out of curiosity: is this helper declared as "inline"? Would get rid of the
call completely in both Delphi and FPC...

>
> I've also introduced an enhanced GetPropInfo() with a signature as
follows:
>
> function tiGetPropInfo(AClass: TClass; PropPath: string; PInstance:
> Pointer): PPropInfo;

Might also profit from a declaration as "inline" :)

Yours,
Sven
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] Typinfo incompatibilities between FPC and Delphi

2014-06-03 Thread Graeme Geldenhuys
On 2014-05-31 10:57, Vincent Snijders wrote:
> I think it is possible to write code without $ifdef (valid for Delphi
> and FPC) if you use the typeinfo unit to extract the information.
> http://www.freepascal.org/docs-html/rtl/typinfo/

Almost, but not quite. Good news is, it is not nearly as bad as Sven
makes it out to be.

The tiOPF project uses RTTI extensively. I have written a lot of that
code, and with the following helper function, I could eliminate a lot of
IFDEF's between FPC and Delphi RTTI behaviour.


function tiGetTypeInfo(PropInfo: PPropInfo): PTypeInfo;
begin
{$IFDEF FPC}
  Result := PropInfo^.PropType;
{$ELSE}
  Result := PropInfo^.PropType^;
{$ENDIF}
end;

I've also introduced an enhanced GetPropInfo() with a signature as follows:

function tiGetPropInfo(AClass: TClass; PropPath: string; PInstance:
Pointer): PPropInfo;


To see the complete code, take a look at the Core/tiRTTI.pas unit in the
tiOPF's 'tiopf2' branch.

That unit is also fully unit tested. Tests and usage examples can be
found in the following unit:

  UnitTests/Tests/tiRTTI_TST.pas


Regards,
  - Graeme -

-- 
fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal
http://fpgui.sourceforge.net/
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal