[fpc-pascal] Use OpenDocument (.odt) files as templates

2017-12-01 Thread Luiz Americo Pereira Camara
Does someone knows a component to use OpenDocument (.odt) files as templates to generate a .odt output file given some data? Something like https://github.com/opensagres/xdocreport but for pascal. A c library exported as a dll could work also Luiz ___

Re: [fpc-pascal] JavaScript versions of pascal RTL functions (FormatFloat, DateToStr etc)

2017-10-16 Thread Luiz Americo Pereira Camara
2017-10-15 8:25 GMT-02:00 Michael Van Canneyt : > > > Hello, > > If you want the latest preview and demos to play with: > > https://www.freepascal.org/~michael/pas2js-demo-0.8.28.zip Thanks, but i'm getting 404 error Luiz ___ fpc-pascal maillist - f

Re: [fpc-pascal] JavaScript versions of pascal RTL functions (FormatFloat, DateToStr etc)

2017-10-13 Thread Luiz Americo Pereira Camara
Em 13 de out de 2017 19:23, "Michael Van Canneyt" escreveu: On Fri, 13 Oct 2017, Luiz Americo Pereira Camara wrote > > > Do you know any implementation of such functions, with similar signatures, > in JavaScript? > In december, you will be able to use pascal for your

[fpc-pascal] JavaScript versions of pascal RTL functions (FormatFloat, DateToStr etc)

2017-10-13 Thread Luiz Americo Pereira Camara
Hi, I'm developing an app were the client is written in Javascript + HTML and the backend in pascal (fpc) I'd like to use my pascal knowledge of RTL functions, mostly utils (FormatFloat, DateToStr etc) in the client app Do you know any implementation of such functions, with similar signatures, i

Re: [fpc-pascal] class property accessor static

2017-02-08 Thread Luiz Americo Pereira Camara
2017-02-07 23:17 GMT-03:00 Paul Ishenin : > 07.02.2017 18:10, Mattias Gaertner wrote: > >> The getter/setter of a class-property must be "static" (Delphi >> compatible). >> If I understand "static" correctly, then "static" simply omits passing >> the class as parameter. So a static class procedure

Re: [fpc-pascal] PascalScript broken by FPC 3.0 ?

2017-01-15 Thread Luiz Americo Pereira Camara
2017-01-14 21:44 GMT-03:00 Kapibara Pas : > Hi there, > > > What has happened? Is it possible to get it to work again without going > back to Lazarus 1.4 and fpc 2.6.4? > A bug report with a sample project showing the crash would be helpful Luiz ___ fp

Re: [fpc-pascal] How to split file of whitespace separated numbers?

2016-12-31 Thread Luiz Americo Pereira Camara
2016-12-31 8:18 GMT-03:00 Bo Berglund : > On Sat, 31 Dec 2016 11:27:53 +0100, greim > > The Readln approach followed by splitting in a stringlist is enough of > an improvement that I can use it. > > Did you look at StrUtils.ExtractSubStr ? Should be faster than TStrings; PosWord := 1; Word := Ex

Re: [fpc-pascal] How to split file of whitespace separated numbers?

2016-12-24 Thread Luiz Americo Pereira Camara
2016-12-23 15:27 GMT-03:00 Marco van de Voort : > In our previous episode, Graeme Geldenhuys said: > > For many other things, plain code could be faster, but often a lot more > > effort and time consuming to implement. Where as you could have written > > a regex expression in under 10 seconds and

Re: [fpc-pascal] How to split file of whitespace separated numbers?

2016-12-24 Thread Luiz Americo Pereira Camara
Em 23 de dez de 2016 05:15, "Bo Berglund" escreveu: Is there a quick way to split a string of whitespace separated values into the separate members? Unir strutils Wordcount + extractword Or Extractsubstr in loop http://www.freepascal.org/docs-html/rtl/strutils/extractsubstr.html Luiz I

Re: [fpc-pascal] Install gdb on MacOSX to debug fpc applications

2016-12-10 Thread Luiz Americo Pereira Camara
2016-12-10 7:34 GMT-03:00 C Western : > I think you have to compile gdb yourself - see posts on the gdb mailing > lists: > > https://sourceware.org/ml/gdb/2016-11/msg00011.html > > https://sourceware.org/ml/gdb/2016-11/msg4.html > > When I last looked, macports had not been updated. I think th

[fpc-pascal] Install gdb on MacOSX to debug fpc applications

2016-12-09 Thread Luiz Americo Pereira Camara
I'm following the article below to install fpc in MascOSX (Sierra): http://www.freepascal.org/~michael/articles/lazonmac/lazonmac.pdf I managed to install gdb from macports. The article points that to gdb work properly is necessary to edit com.apple.taskgated.plist file But in recent versions o

Re: [fpc-pascal] TMS Aurelius Free today

2016-11-10 Thread Luiz Americo Pereira Camara
2016-11-10 12:27 GMT-03:00 Dennis : > From Facebook, I just found this ORM became FREE today. > > http://www.tmssoftware.com/site/aureliusfree.asp > > I don't know whether it is better than mormot but might just download > first. > No source code: Aurelius Free Edition is only available for Delp

Re: [fpc-pascal] Could someone explain me which the correct triggering of the BeforeDestruction method?

2016-09-04 Thread Luiz Americo Pereira Camara
Seems that Delphi considers that the object is already created at the time AfterConstruction is called, so it understands that when it gets into AfterConstruction is sucessfully created. Semantically makes sense. The counter proof is see if AfterConstruction is called when a exception occurs in co

Re: [fpc-pascal] OData and Office365 REST API support

2016-07-11 Thread Luiz Americo Pereira Camara
2016-07-11 16:23 GMT-03:00 Graeme Geldenhuys : > On 2016-07-11 19:32, Michael Van Canneyt wrote: > > Maybe switching to git alone may make a checkout less painful > > I have no doubts. ;-) > > Regarding the checkout it would be slower than the svn checkout since git retrieves all the revision his

[fpc-pascal] Best way / tool to create resource files (*.res) for fpc projects

2016-05-26 Thread Luiz Americo Pereira Camara
For Lazarus projects, the IDE comes with an integrated resource editor that uses fcl-res to create the resource file In my case, i want to create a standalone resource to be used in a package so can't use Lazarus IDE editor Is there any tool that uses fcl-res to manipulate resource files? (GLazRe

Re: [fpc-pascal] TMaskUtils.ValidateInput function: how is it supposed to behave?

2016-04-18 Thread Luiz Americo Pereira Camara
2016-04-18 13:47 GMT-03:00 Bart : [..] > The internal processing of the (edit)mask is the same as TMaskEdit. > If that is broken somehow, it is also broken in TMaskEdit. > > The only functions that may need adjustments are > > * function FormatMaskText(const EditMask: string; const AValue: string

Re: [fpc-pascal] try..finally vs interfaces performance

2016-04-14 Thread Luiz Americo Pereira Camara
2016-04-14 10:58 GMT-03:00 Graeme Geldenhuys : > On 2016-04-14 14:15, Marcos Douglas wrote: > > because you gain more than just automatic memory release. > > It is also worth noting that not all Interface usage means “automatic > memory release”. If you use COM-style Interfaces, then yes you get

Re: [fpc-pascal] Sqldb - How to pass an array of values as a param to be used with SQL IN operator?

2016-04-10 Thread Luiz Americo Pereira Camara
2016-04-10 16:29 GMT-03:00 Tony Caduto : > What about using a stored procedure to do it ? You could pass the list > for the in as a string and handle it in the stored procedure. Of course > that's no help if using sqlite or other that does not support stored > procedures. > I'm working with mul

Re: [fpc-pascal] Sqldb - How to pass an array of values as a param to be used with SQL IN operator?

2016-04-10 Thread Luiz Americo Pereira Camara
2016-04-10 15:39 GMT-03:00 Stephen Chrzanowski : > Due to the nature of the bind mechanism, you won't be able to do it this > way. The only way you'll be able to do that is with your program doing > string substitution instead of doing the bind. Since you're dealing with > integers only, you'll

Re: [fpc-pascal] Sqldb - How to pass an array of values as a param to be used with SQL IN operator?

2016-04-10 Thread Luiz Americo Pereira Camara
2016-04-10 11:01 GMT-03:00 Tony Caduto : > Did you try putting quotes around the param ID in the sql query? > in(":myparam") > I am guessing it's the commas that are the problem. > Its the other way around the problem is the quotes See the attached app. When using Select * from Test where Id in

[fpc-pascal] Sqldb - How to pass an array of values as a param to be used with SQL IN operator?

2016-04-10 Thread Luiz Americo Pereira Camara
I switched most of my SQL queries to use Params instead of formatting directly the SQL. But until now i havent figured a way to pass an array of values (mostly integers) to be used with IN operators. Example: SQL: Select * from Customer where Id in (:idlist) I need to query customers with Ids

Re: [fpc-pascal] Create dynamic SQL according to available params

2016-04-07 Thread Luiz Americo Pereira Camara
Thanks for all the responses The Marcos' one is particular interesting since goes in a direction a did not think earlier Luiz 2016-04-07 12:06 GMT-03:00 Graeme Geldenhuys : > On 2016-04-07 13:47, Michael Thompson wrote: > > This moves it up that list... > > I can give you many more reason to m

Re: [fpc-pascal] Create dynamic SQL according to available params

2016-04-07 Thread Luiz Americo Pereira Camara
2016-04-07 9:03 GMT-03:00 Michael Van Canneyt : > > > On Thu, 7 Apr 2016, Luiz Americo Pereira Camara wrote: > > >> Is there any code that given a SQL Template would generate the second >> filter when paramy is available and keep blank when not available? >> >

[fpc-pascal] Create dynamic SQL according to available params

2016-04-07 Thread Luiz Americo Pereira Camara
I enconter the following pattern frequently (simplified): SQL: Select * From Customers Where FieldX = 1 Later i need a similar query that uses a different filter like Select * From Customers Where FieldX = 1 and FieldY = :paramy Is there any code that given a SQL Template would generate the sec

Re: [fpc-pascal] Recovering info from a backtrace with an external debug file

2016-02-11 Thread Luiz Americo Pereira Camara
2016-02-11 0:12 GMT-03:00 Martin : > > Lazarus has "Leaks and Traces" in the view menu. Paste the trace, and then > use the Button "Resolve" to load the exe with symbols. That should do. > > It uses a copy of the code found in infodwrf and "whatever the name of the > unit reading stabs". Both of t

Re: [fpc-pascal] Recovering info from a backtrace with an external debug file

2016-02-11 Thread Luiz Americo Pereira Camara
2016-02-11 0:06 GMT-03:00 Luiz Americo Pereira Camara < luizameri...@gmail.com>: > > > 2016-02-10 23:59 GMT-03:00 : > >> On 02/10/2016 09:47 PM, Luiz Americo Pereira Camara wrote: >> >>> >>> How to get the line number, method names of the

Re: [fpc-pascal] Recovering info from a backtrace with an external debug file

2016-02-10 Thread Luiz Americo Pereira Camara
2016-02-10 23:59 GMT-03:00 : > On 02/10/2016 09:47 PM, Luiz Americo Pereira Camara wrote: > >> >> How to get the line number, method names of the backtrace using the >> external >> debug file? >> > > my first eWAG gut response is to distribute the DBG fil

[fpc-pascal] Recovering info from a backtrace with an external debug file

2016-02-10 Thread Luiz Americo Pereira Camara
Hi, I compiled a program with -Xg (generating an external debug info file *.dbg) And deployed the executable without the debug info When an exception occurs i get a backtrace with only addresses How to get the line number, method names of the backtrace using the external debug file? Thanks in

Re: [fpc-pascal] How to compile Lazarus program using only FPC?

2015-09-25 Thread Luiz Americo Pereira Camara
Em 24/09/2015 18:02, "Mattias Gaertner" escreveu: > > On Thu, 24 Sep 2015 16:21:31 +0100 > Graeme Geldenhuys wrote: > > > On 2015-09-24 16:14, Michael Van Canneyt wrote: > > Is lazbuild a pure console application? > > Yes. > > > If so, no problem, but my guess > > is that it still uses the LCL so

Re: [fpc-pascal] Persistent list to store objects

2015-08-17 Thread Luiz Americo Pereira Camara
TCollection with fpjsonrtti unit See examples in packages/fcl-json folder Luiz Em 17/08/2015 14:06, "luciano de souza" escreveu: > Hello all, > > There are several classes which manages lists. TCollection, > TObjectlist, TFPGObjectlist... Does someone know if one of then can be > saved as a fil

Re: [fpc-pascal] record helpers & how they effect records

2015-06-08 Thread luiz americo pereira camara
I'd like to extend the question to class helpers, i.e., declaring and using the helper is equivalent to declaring and using a function that takes the class instance as a parameter? Luiz Em 08/06/2015 17:52, "David Emerson" escreveu: > using a simple record, e.g. > > some_record_type = record >

Re: [fpc-pascal] Google Code closing down

2015-03-14 Thread luiz americo pereira camara
2015-03-14 17:16 GMT-03:00 Graeme Geldenhuys : > On 2015-03-14 19:44, vfclists . wrote: > > Google Code now has an Export to Github version on the repository pages. > > I've just noticed that too. That should make saving valuable open source > projects much easier (way less effort). > > I've anyb

Re: [fpc-pascal] AWS Lib - Object Pascal library for the Amazon Web Services

2014-12-29 Thread luiz americo pereira camara
Good work. Currently i dont use AWS but if i need in future i will give a try. As a tip, i suggest to add GUID to interface declarations this will allow to query them. In Lazarus put the cursor after interface keyword and press Ctrl+Shift+G Luiz Em 27/12/2014 22:42, "Marcos Douglas" escreveu:

Re: [fpc-pascal] Brook Framework and Template Engines

2014-12-13 Thread luiz americo pereira camara
2014-12-12 10:14 GMT-03:00 silvioprog : > > On Fri, Nov 14, 2014 at 11:18 AM, Fabrício Srdic > wrote: > >> Hello, >> >> What's the current status of the Brook Server Pages project? >> >> What's the recommended template engine to use with Brook Framework? >> >> Best regards >> > Hello, > > Just wai

Re: [fpc-pascal] Mapping Cairo pixmap to FPC Bitmap and back

2014-09-21 Thread luiz americo pereira camara
https://code.google.com/p/luipack/source/browse/trunk/cairo/lcl/cairolcl.pas#152 https://code.google.com/p/luipack/source/browse/trunk/cairo/lcl/include/win32/cairolcl.inc#4 Direct bitmap data access (possible also with LCL.TBitmap in some cases) https://code.google.com/p/luipack/source/browse/t

Re: [fpc-pascal] Fast HTML Parser

2014-08-08 Thread luiz americo pereira camara
2014-08-08 8:28 GMT-03:00 Marco van de Voort : > In our previous episode, luiz americo pereira camara said: > > You can try http://www.benibela.de/sources_en.html#internettools > > That seems more something like sax_html fromt the fcl-xml package. > It's not a simple par

Re: [fpc-pascal] Fast HTML Parser

2014-08-07 Thread luiz americo pereira camara
You can try http://www.benibela.de/sources_en.html#internettools Luiz 2014-08-07 10:20 GMT-03:00 Marco van de Voort : > In our previous episode, Marcos Douglas said: > > > It has (or at least had) a very simple to use HTML parser that was very > > > fast. If you don't come write with the above

Re: [fpc-pascal] How to use generics and meta class?

2014-02-27 Thread luiz americo pereira camara
2014-02-27 18:43 GMT-03:00 Joao Morais : > Correct. The feature I was talking about is something like: > > generic TMyGeneric > > And TMyType is a class. In this case the compiler knows I am talking about > a generic for a class type and a "generic as Java" becomes possible. Seems that you are

Re: [fpc-pascal] Placing binary data (resources) in object files?

2013-06-04 Thread luiz americo pereira camara
2013/6/4 Anthony Walter : > I came with a nice solution to all this and thought I'd share... > > I wrote a tool named makeres. Is it open source? Luiz ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listin

Re: [fpc-pascal] Difference between fpc 2.6.2 rc1 and fpc 2.6.2 final

2013-04-11 Thread luiz americo pereira camara
2013/4/11 Jonas Maebe : > > On 11 Apr 2013, at 13:18, luiz americo pereira camara wrote: > Are there any difference between those two versions? > > > Yes, all commits later than r22844 in > svn log http://svn.freepascal.org/svn/fpc/tags/release_2_6_2

[fpc-pascal] Difference between fpc 2.6.2 rc1 and fpc 2.6.2 final

2013-04-11 Thread luiz americo pereira camara
Somehow i missed the final release of 2.6.2 So i'm still using fpc 2.6.2rc1 Are there any difference between those two versions? Luiz ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] File Association and opening with already running app

2013-04-05 Thread luiz americo pereira camara
2013/4/5 Graeme Geldenhuys : > On 2013-04-04 16:34, Dennis wrote: >> In windows, you can create Mutex. That's how I ensure no other instance >> of the same program is running. > > > Yes I know that bit, and that is what I did for my old VB6 and Delphi 5 > projects. The question here was not only ab

Re: [fpc-pascal] FPJSON and float values.

2013-02-28 Thread luiz americo pereira camara
2013/2/28 Michael Van Canneyt : > > > On Thu, 28 Feb 2013, silvioprog wrote: > >> Hello, >> Please see: >> >> http://bugs.freepascal.org/view.php?id=23970 > > > Fixed. Seems that you committed by accident code to make AsJSON output more compact. This may lead to compatibility problems. Luiz ___

Re: [fpc-pascal] Strings - suggestions

2012-12-22 Thread luiz americo pereira camara
Em 22/12/2012 09:55, "Michael Van Canneyt" escreveu: > > > > Because of the requirement for backwards compatibility with FPC itself, we'll make 2 RTLs: one backwards compatible, one with the new unicode string. > It will be possible to compile a utf8 rtl? There will be a RtlString ? Luiz > > _

Re: [fpc-pascal] Requirement of {$M+} to add RTTI info

2012-12-12 Thread luiz americo pereira camara
2012/12/12 Sven Barth : > Am 12.12.2012 01:15 schrieb "luiz americo pereira camara" > : > > >> >> Some time ago, i was getting an error while trying to use RTTI >> functions in a class descending directly of TObject >> >> Later i discovered th

[fpc-pascal] Requirement of {$M+} to add RTTI info

2012-12-11 Thread luiz americo pereira camara
Some time ago, i was getting an error while trying to use RTTI functions in a class descending directly of TObject Later i discovered that i needed to descend from TPersistent due to $M+ directive (http://www.freepascal.org/docs-html/prog/progsu44.html), so i did. Now, i decided to go back and de

Re: [fpc-pascal] Editing XMP data in images

2012-10-01 Thread luiz americo pereira camara
2012/10/1 Mattias Gaertner > Hi, > > I need to edit XMP data in images (at least tif, jpg). > > Maybe someone has already done it and can give me a hint? > This? https://delphihaven.wordpress.com/ccr-exif/ Luiz ___ fpc-pascal maillist - fpc-pascal@

[fpc-pascal] Help translate .SAVENV x86-64 assembly directive

2012-10-01 Thread luiz americo pereira camara
Hi, I'm translating porting a Delphi component that uses x86-64 assembly. So far, most of the asm code compiles and works fine. The only thing that i could not translate is the .SAVENV directive. See http://blogs.embarcadero.com/abauer/2011/10/10/38940 and http://docwiki.embarcadero.com/RADStudi

Re: [fpc-pascal] Dynamic messaging in Delphi

2012-07-24 Thread Luiz Americo Pereira Camara
interface ['myintf'] procedure DoThis (value: integer); end; if delegate.GetInterface('myintf', intfDelegate) then intfDelegate.DoThis Luiz Thanks. On Jul 24, 2012, at 4:26 PM, Luiz Americo Pereira Camara wrote: if delegate.GetInterface(IM

Re: [fpc-pascal] Dynamic messaging in Delphi

2012-07-24 Thread Luiz Americo Pereira Camara
Em 24/7/2012 11:13, Ryan Joseph escreveu: I was asking on the Mac Pascal list if Delphi had any ways to invoke methods on objects which the class was unknown at compile time (like a class that invokes a user defined delegate commonly used in Cocoa Mac programming and I assume Delphi not knowin

fpc-pascal@lists.freepascal.org

2012-07-22 Thread Luiz Americo Pereira Camara
Em 22/7/2012 21:46, leledumbo escreveu: Basically I just have to add this: http://wiki.nginx.org/HttpFastcgiModule#fastcgi_split_path_info location / { fastcgi_split_path_info ^((?U).+www.tkd1depok.org)(/?.+)$; fastcgi_param PATH_INFO $fastcgi_path_info; fastcg

fpc-pascal@lists.freepascal.org

2012-07-22 Thread Luiz Americo Pereira Camara
Em 22/7/2012 18:49, leledumbo escreveu: It's indeed nginx fastcgi configuration issue, I've managed to make it work somehow by reading its documentation. Thanks :) Can you post your config here so we can also learn how to configure nginx? Luiz _

Re: RE : [fpc-pascal] JSON and UTF8

2012-07-11 Thread Luiz Americo Pereira Camara
Em 10/7/2012 23:19, waldo kitty escreveu: On 7/10/2012 07:00, Luiz Americo Pereira Camara wrote: With the old behavior, in an system with a system code page <> UTF8, if i try to show the parsed value of "\u4E01" in e.g. a LCL app will get garbage. I would expect to work

Re: RE : [fpc-pascal] JSON and UTF8

2012-07-10 Thread Luiz Americo Pereira Camara
Em 10/7/2012 04:59, Michael Van Canneyt escreveu: On Tue, 10 Jul 2012, Ludo Brands wrote: Following up on bug 22310 http://bugs.freepascal.org/view.php?id=22310 I enabled the use of UTF8 in the FPC JSON support. The constructors of the JSON parser/scanner now accept an extra argument UseUTF

Re: RE : [fpc-pascal] JSON and UTF8

2012-07-10 Thread Luiz Americo Pereira Camara
Em 10/7/2012 04:32, Ludo Brands escreveu: Following up on bug 22310 http://bugs.freepascal.org/view.php?id=22310 I enabled the use of UTF8 in the FPC JSON support. The constructors of the JSON parser/scanner now accept an extra argument UseUTF8 which tells them to convert JSON strings to UTF8,

Re: [fpc-pascal] Re: UTF8 JSON library: was: [Lazarus] UTF-8 XML

2012-06-24 Thread Luiz Americo Pereira Camara
Em 24/6/2012 12:22, Reinier Olislagers escreveu: On 24-6-2012 17:05, Luiz Americo Pereira Camara wrote: Hi, Thanks for your work. I plan to look at OAuth library soon No problems, if you have questions, please feel free to ask. I will About fpjson and UTF8, can you post an example

Re: [fpc-pascal] UTF8 JSON library: was: [Lazarus] UTF-8 XML

2012-06-24 Thread Luiz Americo Pereira Camara
Em 24/6/2012 07:58, Reinier Olislagers escreveu: Related: With the help of Ludo Brands - as usual ;) - I've converted the FPC fpjson library to return UTF8 data. I use it for my twitter/Oauthv1 library/program; you can find it incorporated there at https://bitbucket.org/reiniero/fpctwit/src Se

Re: RE : [fpc-pascal] Re: Variant vs Pointer

2012-03-03 Thread Luiz Americo Pereira Camara
On 3/3/2012 10:08, Marcos Douglas wrote: Think in my class like a Business Object. The struct is very similar with TParams it has many TParam. The data, in a TParam, is save in a Variant type. I need something like: u := TmyBO.Create; // the name does matter u.Attr['name'].Value := 'Marcos'; //

Re: [fpc-pascal] Class reference doubt

2011-11-25 Thread Luiz Americo Pereira Camara
On 25/11/2011 07:50, Dimitri Smits wrote: so you have: type TMyObject=class(TObject) ... constructor Create; end; Yes TMyClass = class of TMyObject; //<-- important I guess Not important or necessary. I was using TClass from RTL = class of TObject ... procedure pr

Re: [fpc-pascal] Class reference doubt

2011-11-24 Thread Luiz Americo Pereira Camara
On 24/11/2011 19:34, Jonas Maebe wrote: In that case, you did not hit the same problem as the original poster (your "I also hit this problem recently" is what triggered my response). His problem was that if you call a non-virtual constructor on a class reference variable, that the constructor i

Re: [fpc-pascal] Class reference doubt

2011-11-24 Thread Luiz Americo Pereira Camara
On 24/11/2011 05:47, Graeme Geldenhuys wrote: On 2011-11-24 03:58, Luiz Americo Pereira Camara wrote: possible to get the expected behavior without forcing programmer to create a virtual constructor by using the new RTTI What has the "new RTTI" got to do with anything? Sim

Re: [fpc-pascal] Class reference doubt

2011-11-24 Thread Luiz Americo Pereira Camara
On 24/11/2011 08:02, Jonas Maebe wrote: On 24 Nov 2011, at 02:58, Luiz Americo Pereira Camara wrote: On 23/11/2011 18:48, Jesus Reyes wrote: in the following example The output is: cls class is TFoo TObj.create where I would expect: cls class is TFoo TObj.create TFoo.create I also hit

Re: [fpc-pascal] Class reference doubt

2011-11-23 Thread Luiz Americo Pereira Camara
On 23/11/2011 18:48, Jesus Reyes wrote: in the following example The output is: cls class is TFoo TObj.create where I would expect: cls class is TFoo TObj.create TFoo.create I also hit this problem recently Found that this is one limitation of fpc. Under newer delphi it's possible to get the

Re: [fpc-pascal] Re: Delphi's anonymous functions in Free Pascal

2011-11-07 Thread Luiz Americo Pereira Camara
On 7/11/2011 07:28, Martin Schreiber wrote: > One reason is to make it easy for FPC users to reuse existing Delphi > code that is out there without having to rewrite it in an "FPC- > compatible way". > Is there a big demand? Examples? I speak only for myself. This is a component that i'd

Re: [fpc-pascal] Free Pascal 2.6.0rc1 released

2011-11-05 Thread Luiz Americo Pereira Camara
On 5/11/2011 20:27, Marco van de Voort wrote: Downloads are available at the FTP server at: ftp://freepascal.stack.nl/pub/fpc/beta/2.6.0-rc1/ Cant download 550 /pub/fpc/beta/2.6.0-rc1/: Permission denied. Luiz ___ fpc-pascal maillist - fpc-pasca

Re: [fpc-pascal] fpWeb REST support (asking about features)

2011-06-07 Thread Luiz Americo Pereira Camara
On 7/6/2011 04:22, ik wrote: Hello, One of the thing that I find really missing in fpWeb is the ability to have support for REST. That is, to place different callbacks to GET, POST, UPDATE, DELETE, HEAD and PUT. Let's say that I create a support for the following PATH_INFO: I started som

Re: [fpc-pascal] Minimal Sylpheed plugin in FreePascal

2011-05-17 Thread Luiz Americo Pereira Camara
On 17/5/2011 17:03, Anton Shepelev wrote: Jonas Maebe: One likely potential cause is the fact that released FPC versions enable all floating point exceptions. Since libc does not do that, many C programs and frameworks contain invalid floating point operations. Is masking such exception

Re: [fpc-pascal] FPImage and GetDataLineStart

2011-04-21 Thread Luiz Americo Pereira Camara
On 21/4/2011 06:41, Marco van de Voort wrote: In our previous episode, Sven Barth said: Am 20.04.2011 22:20, schrieb Leonardo M. Ram?: Hi, I need to write a function that replaces TLazIntfImage by using fpImage, and I can't find an alternative to GetDataLineStart. How can I replace it?. Maybe

Re: [fpc-pascal] Classes and class methods

2011-02-10 Thread Luiz Americo Pereira Camara
On 9/2/2011 07:58, Mark Morgan Lloyd wrote: Is it possible to put a class (not an instance) in a variable or array element, and to use this to call a class method? I'm defining a hierarchy of classes and it would be convenient if it were possible to register the fact that a class had a particu

Re: [fpc-pascal] JSON Parser to tree view

2010-10-21 Thread Luiz Americo Pereira Camara
ik escreveu: Hello, I wish to use the JSON parser to create some sort of TreeView of my JSON (it's more then 500 lines of data). Before I'll write such code, do you know of any existed code that does such thing, or at least most of the work ? http://code.google.com/p/luipack/source/browse/t

Re: [fpc-pascal] IntList

2010-10-19 Thread Luiz Americo Pereira Camara
Juha Manninen (gmail) escreveu: Hi In Lazarus project jcf2 component has an IntList class which is poorly implemented. It depends on integer and pointer being the same size. I will later suggest to replace it. I have a better IntList. See: http://github.com/JuhaManninen/Pascal/blob/master/I

Re: [fpc-pascal] Nesting

2010-09-14 Thread Luiz Americo Pereira Camara
Juha Manninen (gmail) escreveu: A new Lazarus review : http://delphimax.wordpress.com/2010/09/13/freepascal-and-lazarus-success-or- failure/ has this comment about Lazarus source: --- Abundant use of the Exit() command instead of nesting code in If/then/else. It has been proven (last time in De

Re: [fpc-pascal] How to download fpc242 rc1 (to test a possible bug)

2010-09-13 Thread Luiz Americo Pereira Camara
Marco van de Voort escreveu: In our previous episode, Luiz Americo Pereira Camara said: And it did compile with 2.4.0? Yes. Also with 251 Hmm, I think I know what that is. A wrong merge that should have been reverted. http://bugs.freepascal.org/view.php?id=16121 I'll s

Re: [fpc-pascal] How to download fpc242 rc1 (to test a possible bug)

2010-09-12 Thread Luiz Americo Pereira Camara
Marco van de Voort escreveu: In our previous episode, Luiz Americo Pereira Camara said: I noticed that there's a folder for fpc242 rc1 in ftp://ftp.freepascal.org/pub/fpc/beta/ Trying to access gives an error 550 The reason to get the 242 version is to test an bug reported by a use

[fpc-pascal] How to download fpc242 rc1 (to test a possible bug)

2010-09-12 Thread Luiz Americo Pereira Camara
Hi, I noticed that there's a folder for fpc242 rc1 in ftp://ftp.freepascal.org/pub/fpc/beta/ Trying to access gives an error 550 The reason to get the 242 version is to test an bug reported by a user of the fpc243 snapshot provided at http://www.hu.freepascal.org/lazarus/ Basically it woul

[fpc-pascal] A check before setting a property (or the cost of a call instruction)

2010-07-22 Thread Luiz Americo Pereira Camara
Hi, In Lazarus i just committed the following code: if Alignment <> FDataLink.Field.Alignment then Alignment := FDataLink.Field.Alignment; but i could do also: Alignment := FDataLink.Field.Alignment; The setter property of Alignment already checks if the passed value is equal: p

Re: [fpc-pascal] How to set a CORBA interface property (tkInterfaceRaw) through RTTI

2010-07-21 Thread Luiz Americo Pereira Camara
Luiz Americo Pereira Camara escreveu: Hi, I've managed to set a COM interface property (tkInterface) through RTTI using SetInterfaceProp. But i could not find a way to set a CORBA interface property (tkInterfaceRaw) since SetInterfaceProp expects IUnknown. In the attached example, w

[fpc-pascal] How to set a CORBA interface property (tkInterfaceRaw) through RTTI

2010-07-20 Thread Luiz Americo Pereira Camara
Hi, I've managed to set a COM interface property (tkInterface) through RTTI using SetInterfaceProp. But i could not find a way to set a CORBA interface property (tkInterfaceRaw) since SetInterfaceProp expects IUnknown. In the attached example, when i try to use SetInterfaceProp i get the m

Re: [fpc-pascal] fpweb tutorial

2010-07-13 Thread Luiz Americo Pereira Camara
Felipe Monteiro de Carvalho escreveu: Hello, Does anyone know where I can find documentation or a tutorial about fpweb? http://blog.silvioprog.com.br/2010/06/criando-um-aplicativo-cgi-com_27.html It's in portuguese Luiz Also, is the version included in FPC 2.4.0 very old and I should rea

Re: [fpc-pascal] methods of an object to create others objects

2010-07-06 Thread Luiz Americo Pereira Camara
Marcos Douglas escreveu: Better: obj1 := nil; obj2 := nil; Try obj1 := TMyObject.Create; obj2 := TMyObject.Create; obj1.DoSomething1; obj2.DoSomething2; finally obj1.Free; obj2.Free; end; The objectcs are protected. But is boring... :) Everybody codify like that, afraid if resource

Re: [fpc-pascal] FastCGI and FpWeb

2010-07-03 Thread Luiz Americo Pereira Camara
Michael Van Canneyt escreveu: On Sat, 3 Jul 2010, Luiz Americo Pereira Camara wrote: I've created some CGI applications with fpWeb with success. I tried to create a FastCGI application (a simple hello world) but when a request is done the program start, Application.Initializ

[fpc-pascal] FastCGI and FpWeb

2010-07-03 Thread Luiz Americo Pereira Camara
I've created some CGI applications with fpWeb with success. I tried to create a FastCGI application (a simple hello world) but when a request is done the program start, Application.Initialize and Application.Run is called. TCustomWebApplication.HandleRequest (I've monitored OnGetModule) is not

Re: [fpc-pascal] Mozilla XPCOM

2010-06-08 Thread Luiz Americo Pereira Camara
Marcos Douglas escreveu: On Tue, Jun 8, 2010 at 12:55 PM, Luiz Americo Pereira Camara wrote: Marcos Douglas escreveu: Hi Luiz, On Mon, Jun 7, 2010 at 10:35 PM, Luiz Americo Pereira Camara wrote: Take a look at http://lazarusroad.blogspot.com/2008/11/effect-of-using

Re: [fpc-pascal] Mozilla XPCOM

2010-06-08 Thread Luiz Americo Pereira Camara
Marcos Douglas escreveu: Hi Luiz, On Mon, Jun 7, 2010 at 10:35 PM, Luiz Americo Pereira Camara wrote: Take a look at http://lazarusroad.blogspot.com/2008/11/effect-of-using-constant-parameter-for.html Then, this continue true how I said in other mail: On Mon, Jun 7, 2010 at 11:59

Re: [fpc-pascal] Mozilla XPCOM

2010-06-07 Thread Luiz Americo Pereira Camara
Marcos Douglas escreveu: Well... just to I will know. A long time ago (Delphi 4) I learned: Always use 'const' for 'strings' because this is faster. Strings will be passed by reference. This remains true? eg: var str: string; procedure Foo1(const s: string); procedure Foo2(s: string); Ta

Re: [fpc-pascal] VirtualTreeview Mac (Carbon)

2010-06-01 Thread Luiz Americo Pereira Camara
CA Gorski escreveu: And if so, what is to do? Remove the dependencies on lclextensions from your port? Yes Ok, I will try... Meantime I tried to compile lclextensions against gtk2 What messages do you get when compile lclextensions for carbon? I ask that so i can add the missing functi

Re: [fpc-pascal] VirtualTreeview Mac (Carbon)

2010-06-01 Thread Luiz Americo Pereira Camara
CA Gorski escreveu: Lazarus/LCL has added most of the needed functions, but it's not released yet. I am using the daily snapshot anyway. Are they in there? Yes And if so, what is to do? Remove the dependencies on lclextensions from your port? Yes Luiz

Re: [fpc-pascal] VirtualTreeview Mac (Carbon)

2010-05-31 Thread Luiz Americo Pereira Camara
CA Gorski escreveu: or should one change the later (VT) to use FCL/LCL functions so that it does not rely on Windows functions anymore? Later Why later and not immediately? It's a lot of work. It's easier to maintain sync with Delphi version Lazarus/LCL has added most of the needed funct

Re: [fpc-pascal] VirtualTreeview Mac (Carbon)

2010-05-31 Thread Luiz Americo Pereira Camara
CA Gorski escreveu: Has anybody tried to compile the new VT port which requires lclextensions (Luipack) on Mac OS with target widget Carbon? It's a know issue. See http://forum.lazarus.freepascal.org/index.php/topic,8601.0.html I don't have a mac, so i need patches. I did and wasn't succes

Re: [fpc-pascal] XML Iteration

2010-05-04 Thread Luiz Americo Pereira Camara
Lee Jenkins escreveu: Frank Church wrote: I am having some problems with XPath. EvaluateXPathExpression raises exceptions with some search strings and I am not sure if it is my limited knowledge of XPath, or a buggy XPath implementation. The attached demo uses the example from http://www.w

Re: [fpc-pascal] FPC + 64bit Windows => anybody?

2010-05-04 Thread Luiz Americo Pereira Camara
Lukas Gradl escreveu: Thanks. BTW: are you using the latest DCPCrypt? Recently I applied a lot of 64-bit fixes for DCPCrypt - extensively tested under 64-bit Linux. Once I get a 64-bit Windows FPC going, I'll test on that platform too. Latest DCPCrypt is in Lazarus-CCR git repository at SourceF

Re: [fpc-pascal] XML Iteration

2010-04-28 Thread Luiz Americo Pereira Camara
Lee Jenkins escreveu: Luiz Americo Pereira Camara wrote: Frank Church escreveu: I am glad to see someone with an interest in FPCs XML. Do you have some experience with XPath usage in PFC/Lazarus? Luiz, In Unit1.pas: XPathResult := EvaluateXPathExpression('//Desc

Re: [fpc-pascal] How to convert ISO format string in FreePascal

2010-04-27 Thread Luiz Americo Pereira Camara
Frank Church escreveu: I want to convert a time stamp in -mm-dd hh:mm:ss format to a TDatetime in FPC but can't find but haven't found a way yet. A very simple function i use: function XMLDateTime2DateTime(const XMLDateTime: String): TDateTime; var DateOnly: String; TPos: Integer; begin

Re: [fpc-pascal] XML Iteration

2010-04-27 Thread Luiz Americo Pereira Camara
Frank Church escreveu: Thanks for the link. What is WST? My searches turn up something related to eclipse. Web Services Toolkit: http://wiki.lazarus.freepascal.org/Web_Service_Toolkit Luiz ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.o

Re: [fpc-pascal] XML Iteration

2010-04-27 Thread Luiz Americo Pereira Camara
Frank Church escreveu: I am glad to see someone with an interest in FPCs XML. Do you have some experience with XPath usage in PFC/Lazarus? In this program: http://www.silvioprog.com.br/downloads/Cliente_SOAP_SAH.zip?attredirects=0&d=1 you can find a simple usage of XPath + WST Luiz

[fpc-pascal] Apple forbids fpc applications on iPhone

2010-04-09 Thread Luiz Americo Pereira Camara
According to http://daringfireball.net/2010/04/iphone_agreement_bans_flash_compiler , in the new SDK programs compiled with fpc are not allowed anymore. A quote "Applications must be originally written in Objective-C, C, C++" Luiz ___ fpc-pascal mail

Re: [fpc-pascal] CLX is returning to Delphi 2011

2010-04-07 Thread Luiz Americo Pereira Camara
Marco van de Voort escreveu: In our previous episode, dmitry boyarintsev said: Does Embarcadero offer 2 different way of cross-platform development. Delphi Prism (XDelphi?) with its Mono .Net based development and Does Prism explicitely target Mono, or is it merely possible to DIY?

Re: [fpc-pascal] sql server embedded: sqlite the only solution?

2009-12-22 Thread Luiz Americo Pereira Camara
Michael Van Canneyt escreveu: On Tue, 22 Dec 2009, JoshyFun wrote: SQLite is faster than Firebird, but take care that SQLite does not enforce foreign keys, so data integrity must be handled by the programmer "manually". About the "sqlite is faster": This depends highly on the kind of quer

Re: [fpc-pascal] sql server embedded: sqlite the only solution?

2009-12-22 Thread Luiz Americo Pereira Camara
JoshyFun escreveu: Hello FPC-Pascal, Tuesday, December 22, 2009, 12:55:07 AM, you wrote: ZD> I think you talk about Firebird embedded version 1.0, SQlite3 best than it ZD> I have Point of Sale application use Firebird 2.1 in desktop PC and ZD> Sqlite3 in Wince, the same project with same SQL st

[fpc-pascal] Generate RTF file with UTF-8 encoded data

2009-12-09 Thread Luiz Americo Pereira Camara
I need to create a RTF file from UTF-8 encoded strings. Does someone has an example on how to save UTF-8 strings in a RTF file? Luiz ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal

  1   2   >