[lazarus] Update

Shane Miller SMiller1 at stvgb.org
Wed Oct 27 07:49:21 EDT 1999


I would prefer that we add a LINUX.PP file to the LCL and create new functions with these ssame names.  That way we don't have to change ANY code except the USES clause.  In the USES we would just have to add linux.pp and the winapi calls would be there.

Shane


>>> Curtis White <osiriz at teleport.com> 10/26/99 11:36PM >>>

On 26-Oct-99 Marc Weustink wrote:
> 
> Now the question how to implement. I think thewre are a few options:
> 1)
> Don't support direct API calls. Use their class counterparts. IE, dont use
> ExtTextOut(Canvas.Handle, ...) but use Canvas.ExtTextOut(...). This bereaks
> a lot of compatibility.
> 
> 2)
> Use a platform dependent windows.pp like the classes unit. However there
> aleady exists a rtl windows.pp (and linux.pp)
> 
> 3)
> Since linux.pp and windows.pp are rtl files, create ONE LCLwindows.pp. This
> file contains (win)API related implementations for every platform (if it is
> possible) or just a call to its InterfaceObject(since it's global)
> counterpart (all platform specific stuff in one place). Like
> LCLwindows.ExtTextOut calls InterfaceObject.ExtTextOut.
> 
> Question is, what way to go. I think I prefer last one. It's only adding a
> reference to LCLwindows if needed. Any thoughts ?
> 

I agree with you. I like the last option. But the problem we will need to
overcome is the compatibility with Delphi. Almost every Delphi unit in
existance contains:

uses Windows ...

So all of those would need to be changed depending on which environment you are
compiling in. If compiling in Windows, then everything is fine. But then the
code will need to be changed to compile in Linux. Also, when compiling in
Windows, how would we handle functions that are the same in both LCLwindows and
Windows?


Curtis

_________________________________________________________________
     To unsubscribe: mail lazarus-request at miraclec.com with
                "unsubscribe" as the Subject
    archives at http://www.miraclec.com/list_archives/lazarus






More information about the Lazarus mailing list