Re: [fpc-pascal] Eye Candy Contest
They may also want to take a look at the Virtual Magnifying Glass:http://sourceforge.net/project/screenshots.php?group_id=60638 Almost 250.000 downloads now =) on 3 platforms-- Felipe Monteiro de Carvalho ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Re: [fpc-pascal] Eye Candy Contest
On 11/1/06, Marc Weustink [EMAIL PROTECTED] wrote: Ehm how to get there from the main site (and shouldn't lazarus bethere as well) ?It has:http://wiki.lazarus.freepascal.org/Lazarus_Application_Gallery --Felipe Monteiro de Carvalho ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Re: [fpc-pascal] Eye Candy Contest
Felipe Monteiro de Carvalho schreef: On 11/1/06, *Marc Weustink* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: Ehm how to get there from the main site (and shouldn't lazarus be there as well) ? It has: Lazarus is not on the fpc gallery. Vincent ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Re: [fpc-pascal] Eye Candy Contest
On 02/11/06, Vincent Snijders [EMAIL PROTECTED] wrote: Lazarus is not on the fpc gallery. Vincent Not related to the Eye Candy Contest, but maybe we could add the fpGUI project to the FPC Gallery? If so, let me know what is needed. Regards, - Graeme - ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Re: [fpc-pascal] DateToStr locale
o.k. i've had a look at the libc source (locale dir). i understand the general gist of things, but it'd take ages to implement in pascal if i try and transliterate that. it's also not very easy to read (due to a generous use of defines). what work has been done on this for fpc? is there any (more readable) documentation on the locale binary files? posix docs? to get the time and date format info i'd have to do this: (1) get the locale that's being used (LANG environment variable). mine gives en_GB.utf8 (2) open the LC_TIME file that can be found under /usr/lib/locale/{locale from (1)}/ (3) extract the date and time format from this file sorry it's not more specific, but that's the main idea. it would obviously make sense to implement the whole lot of locale functions. i think it's quite fundamental. will fpc choose to mimic what libc does? it'd quite nice to have a single function that queries certain variables from certain categories (e.g. LC_MONETARY, LC_TIME, LC_NUMERIC). i'll see if i can do some more work on this. thanks henry On 01/11/06, Michael Van Canneyt [EMAIL PROTECTED] wrote: On Wed, 1 Nov 2006, Henry Vermaak wrote: hello all i've noticed that DateToStr gives correct results on win32 (regarding locale), but on linux and osx it always gives the date as dd-mm-. i read somewhere in the archives that there's a problem implementing this due to the need to link to libc or something (hand wavy). can anyone shed some light on this for me, or does anyone know about a work around? The locale info on Linux is stored in some files somewhere in /usr/lib/* The routines to access these files are in Libc. Since SysUtils should remain free from dependencies on the C library, we cannot use it to initialize the constants... I have somewhere a unit that links to C or uses the KDE info to initialize the localization constants in SysUtils. If you don't mind linking to C then I can send you this. If you want to make a Pascal version of the localization routines, then Please do :-) Michael. ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal
[fpc-pascal] Program needs probably the variants unit
Hello, I wrote accidentally the following line of pascal code: writeln(output, a + b); where a was a double, and b was a string. The program compiled, linked successfully. Why? Next, running it, I got the following: [code] Program needs probably the variants unit. Include the variants unit in your uses statements as one of the first units. Runtime error 221 at $08053F3A $08053F3A $BFFFEE98 [/code] Well. But I do not like programs that try to be more intelligent than operator. double + string expression is lexical error from my point of view, and always will be. I would prefer to detect them during compilation. What switches could enable that? -So is always on -S2 has no influence -Sd has no influence With regards, Jan Je/lowicki [EMAIL PROTECTED] - Department of Mathematics Katedra Matematyki University of Agriculture Akademia Rolnicza we Wroc/lawiu Wroc/law, POLAND - ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Re: [fpc-pascal] DateToStr locale
On Thu, 2 Nov 2006, Henry Vermaak wrote: o.k. i've had a look at the libc source (locale dir). i understand the general gist of things, but it'd take ages to implement in pascal if i try and transliterate that. it's also not very easy to read (due to a generous use of defines). what work has been done on this for fpc? is there any (more readable) documentation on the locale binary files? posix docs? to get the time and date format info i'd have to do this: (1) get the locale that's being used (LANG environment variable). mine gives en_GB.utf8 (2) open the LC_TIME file that can be found under /usr/lib/locale/{locale from (1)}/ (3) extract the date and time format from this file Yes, this is the idea. sorry it's not more specific, but that's the main idea. it would obviously make sense to implement the whole lot of locale functions. Indeed. I would expect you to open the correct file, and initialize all variables from that file. i think it's quite fundamental. will fpc choose to mimic what libc does? If you mean read the files and initialize the necessary variables, the answer is yes. it'd quite nice to have a single function that queries certain variables from certain categories (e.g. LC_MONETARY, LC_TIME, LC_NUMERIC). That can be done too, but since all constants are in 1 file, it makes more sense to process the file at once. Michael. ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Re: [fpc-pascal] DateToStr locale
o.k. i've had a look at the libc source (locale dir). i understand the general gist of things, but it'd take ages to implement in pascal if i try and transliterate that. it's also not very easy to read (due to a generous use of defines). what work has been done on this for fpc? is there any (more readable) documentation on the locale binary files? posix docs? to get the time and date format info i'd have to do this: (1) get the locale that's being used (LANG environment variable). mine gives en_GB.utf8 (2) open the LC_TIME file that can be found under /usr/lib/locale/{locale from (1)}/ Not portable. E.g. on BSD it is /usr/share/locale So between 1 and 2 there should be a step find locale dir. This because a solution is required to be Solaris, BSD and Mac OS X compatible. (3) extract the date and time format from this file sorry it's not more specific, but that's the main idea. it would obviously make sense to implement the whole lot of locale functions. i think it's quite fundamental. will fpc choose to mimic what libc does? it'd quite nice to have a single function that queries certain variables from certain categories (e.g. LC_MONETARY, LC_TIME, LC_NUMERIC). i'll see if i can do some more work on this. Another solution would be to have an additional unit that links to libc and gets the data. This way the limiting libc linking would only happen at the writers request, and not hamper all sysutils using programs. ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Re: [fpc-pascal] DateToStr locale
marco said: Not portable. E.g. on BSD it is /usr/share/locale So between 1 and 2 there should be a step find locale dir. This because a solution is required to be Solaris, BSD and Mac OS X compatible. true, there is a findlocale.c file under libc that deals with this. this is a necessary step. it'd quite nice to have a single function that queries certain variables from certain categories (e.g. LC_MONETARY, LC_TIME, LC_NUMERIC). michael said: That can be done too, but since all constants are in 1 file, it makes more sense to process the file at once. there is a separate file for each category, it seems. i'll try and investigate further and look for the posix docs. thanks for the comments. henry ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal
[fpc-pascal] Problem with multiple inheritance
Hello, I was trying to split the o-o wrappers around Qt procedural wrappers in 2 parts. One that depends on Lazarus and another that can be used with only Free Pascal. So I have some classes like this: TQtWidget = class(TObject) TQtFrame = class(TQtWidget) Both classes contain mixed code for accessing Qt functions and procedures specific for Lazarus, like Event loops, methods that receive lazarus classes, methods to receive event signals, etc. So I would now have, after splitting: For pure Qt: TQtWidget = class(TObject) TQtFrame = class(TQtWidget) And for laz parts: TLazQtWidget = class(TObject) TLazQtFrame = class(TLazQtWidget, TQtFrame) The problem is that on TLazQtFrame I would like to inherit all functions from a normal TQtFrame, but I would also like to inherit all functions from TLazQtWidget. How can I work around this? I mean, how can I redesign my idea to make it work with FP? Note that Qt requires that all methods to receive events, and signals be from objects (I cannot use a procedure to receive events). thanks, -- Felipe Monteiro de Carvalho ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal
[fpc-pascal] PROJECT_DERIVED_FILE_DIR
With fpc, in trying to compile an example brought in from CW, and using XCode 2.4.1 on a Dual 2.0 G5 10.4.8, I have started with a Carbon template. In the target rules for processing pascal source files, I see a custom script indicated to use output files $(PROJECT_DERIVED_FILE_DIR)/$(INPUT_FILE_BASE).s How do you look at the value that PROJECT_DERIVED_FILE_DIR is set to? And where would you change the setting? I cannot find it in any documentation. Is the custom script necessary? I am getting a compile error saying: powerpc-apple-darwin8-gcc-4.0.1: no input files while looking for .s file in the Build/projectname.build/DerivedSources directory. Is a .s always created from Pascal Sources during compiles? I see a program.s file in Build/projectname.build/DerivedSources/PPC/ directory but am not sure why it cannot be found or what to do about it. Any tips will be appreciated. Thx Ken ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Re: [fpc-pascal] PROJECT_DERIVED_FILE_DIR
On 02 Nov 2006, at 19:03, Ken G. Brown wrote: With fpc, in trying to compile an example brought in from CW, and using XCode 2.4.1 on a Dual 2.0 G5 10.4.8, I have started with a Carbon template. In the target rules for processing pascal source files, I see a custom script indicated to use output files $ (PROJECT_DERIVED_FILE_DIR)/$(INPUT_FILE_BASE).s How do you look at the value that PROJECT_DERIVED_FILE_DIR is set to? By looking at the build transcript. To see it, go to the Build Results (cmd-shift-B), and then click on the small icon looking like a couple of lines of text (next to a yellow warning triangle -- yes, the user interface of that pane is bad). And where would you change the setting? I cannot find it in any documentation. You can't change it, it's automatically set by Xcode. You can find out about it (and tons of others) by having a look at the build transcript mentioned above. Is the custom script necessary? Yes. I am getting a compile error saying: powerpc-apple-darwin8-gcc-4.0.1: no input files while looking for .s file in the Build/projectname.build/DerivedSources directory. Is a .s always created from Pascal Sources during compiles? Yes. I see a program.s file in Build/projectname.build/DerivedSources/ PPC/ directory but am not sure why it cannot be found or what to do about it. The compilation script should copy it to Build/projectname.build/ DerivedSources after compilation is finished, merging ppc and intel versions of the assembler code if necessary (because in the past Xcode did not allow specifying different output files for different architectures). This should be done by the make_conditional() function in the compilation script. You may also want to try Erling Johanssen's alternate Xcode project files, available from http://www.fabfilter.com/frederik/fpc-app-templates-20060921-ejo.zip They are written for Xcode 2.3 or later and therefore need far less workarounds for Xcode bugs and limitations (and hence are less prone to hard to find bugs). They also solve a few issues with the project files we distribute (the main one is that it puts the compilation script in a different target to avoid a race condition). Jonas ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal
[fpc-pascal] Progress Bar in different widget sets
Hi, GTK's progress bar has a feature where the progress bar moves left and right repeatedly, instead of the normal from Min to Max. What do you call that feature and what do you actually use it for? I know I have seen in used in Mozilla Thunderbird as well, but couldn't remember where. I just implemented a basic TProgressBar widget for fpGUI and wanted to know if that Gtk progress bar feature (running left and right repeatedly) is something people actually use in applications and worth the time implementing in fpGUI. Regards, - Graeme - -- There's no place like 127.0.0.1 ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Re: [fpc-pascal] Problem with multiple inheritance
Felipe Monteiro de Carvalho wrote: Hello, I was trying to split the o-o wrappers around Qt procedural wrappers in 2 parts. One that depends on Lazarus and another that can be used with only Free Pascal. So I have some classes like this: TQtWidget = class(TObject) TQtFrame = class(TQtWidget) Both classes contain mixed code for accessing Qt functions and procedures specific for Lazarus, like Event loops, methods that receive lazarus classes, methods to receive event signals, etc. So I would now have, after splitting: For pure Qt: TQtWidget = class(TObject) TQtFrame = class(TQtWidget) And for laz parts: TLazQtWidget = class(TObject) TLazQtFrame = class(TLazQtWidget, TQtFrame) The problem is that on TLazQtFrame I would like to inherit all functions from a normal TQtFrame, but I would also like to inherit all functions from TLazQtWidget. How can I work around this? I mean, how can I redesign my idea to make it work with FP? Note that Qt requires that all methods to receive events, and signals be from objects (I cannot use a procedure to receive events). Use the TQt class tree as a private for the TQtWS class tree. The Qt tree doesn't have to match 1:1 to the WS tree. (exactly this problem made me inplement the virtusl classes :) Marc ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Re: [fpc-pascal] Progress Bar in different widget sets
On Fri, 3 Nov 2006, Graeme Geldenhuys wrote: Hi, GTK's progress bar has a feature where the progress bar moves left and right repeatedly, instead of the normal from Min to Max. What do you call that feature and what do you actually use it for? Well, you can construct black talking cars with it, like the KIT2000 ;-) Saw that on TV once, long ago ;-) Michael. ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Re: [fpc-pascal] Progress Bar in different widget sets
Graeme Geldenhuys wrote: Hi, GTK's progress bar has a feature where the progress bar moves left and right repeatedly, instead of the normal from Min to Max. What do you call that feature and what do you actually use it for? I know I have seen in used in Mozilla Thunderbird as well, but couldn't remember where. See GNOME HIG: [http://developer.gnome.org/projects/gup/hig/2.0/controls-progress-bars.html], at the bottom: Indeterminate-progress indicator. An animated bar indicating only that an operation is ongoing, not how long it will take. Michalis ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Re: [fpc-pascal] Progress Bar in different widget sets
Graeme Geldenhuys wrote: GTK's progress bar has a feature where the progress bar moves left and right repeatedly, instead of the normal from Min to Max. What do you call that feature and what do you actually use it for? It's used when the Max isn't known. Micha ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal