Re: [fpc-pascal] generics class hierarchy

2010-12-17 Thread Sven Barth

Am 17.12.2010 03:30, schrieb David Emerson:

err... my mistake. the error message was referring to a different problem, which
I was blind to in my hurry. Sorry for all the messages. I'll shut up now. :)



Would you please state your FPC version the next time? (If you have 
stated I, but I haven't seen it: I'm sorry) Some problems might be fixed 
in the development version while they aren't in the latest release.


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


Re: [fpc-pascal] Re: FPC programs in Android without JNI

2010-12-17 Thread Andrew Haines
On 12/16/10 12:23, Felipe Monteiro de Carvalho wrote:
> Hello,
> 
> It might be interesting to know that I managed to build a bridge which
> exports the Java API and the Android API to Free Pascal. Check this
> hello world code and screenshot:
> 
> http://wiki.lazarus.freepascal.org/Android_Interface/Android_Programming#Using_the_Android_API_from_Pascal
> 
> The full code is here:
> 
> http://p-tools.svn.sourceforge.net/viewvc/p-tools/PascalNotes4Android/
> 
> bye,

The Android 2.3 ndk now has support for a NativeActivity and there is a
sample of OpenGL ES native program.



General notes:

* Adds support for native activities, which allows you to
implement the Android application lifecycle in native code.
* Adds native support for the following:
  o Input subsystem (such as the keyboard and touch screen)
  o Access to sensor data (accelerometer, compass,
gyroscope, etc).
  o Event loop APIs to wait for things such as input and
sensor events.
  o Window and surface subsystem
  o Audio APIs based on the OpenSL ES standard that support
playback and recording as well as control over platform audio effects
  o Access to assets packaged in an .apk file.


___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Re: FPC programs in Android without JNI

2010-12-17 Thread Felipe Monteiro de Carvalho
I a

On Dec 17, 2010 8:47 PM, "Andrew Haines"  wrote:

On 12/16/10 12:23, Felipe Monteiro de Carvalho wrote:
> Hello,
>
> It might be interesting to know ...
The Android 2.3 ndk now has support for a NativeActivity and there is a
sample of OpenGL ES native program.



General notes:

   * Adds support for native activities, which allows you to
implement the Android application lifecycle in native code.
   * Adds native support for the following:
 o Input subsystem (such as the keyboard and touch screen)
 o Access to sensor data (accelerometer, compass,
gyroscope, etc).
 o Event loop APIs to wait for things such as input and
sensor events.
 o Window and surface subsystem
 o Audio APIs based on the OpenSL ES standard that support
playback and recording as well as control over platform audio effects
 o Access to assets packaged in an .apk file.


___
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

Re: [fpc-pascal] Re: FPC programs in Android without JNI

2010-12-17 Thread Andrew Haines
On 12/17/10 15:46, Felipe Monteiro de Carvalho wrote:
> I a
> 

??
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] Re: FPC programs in Android without JNI

2010-12-17 Thread Robert Wolfe

On 12/17/2010 4:25 PM, Andrew Haines wrote:

On 12/17/10 15:46, Felipe Monteiro de Carvalho wrote:

I a


??
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal



Looks like someone may have hit the send button too soon :D

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] Having trouble defining an initialized constant correctly

2010-12-17 Thread Cox, Stuart TRAN:EX
Please excuse me if I've posted this request to the wrong list.  I
really did spend some time in trying to find a FPC list for simple
coding questions.  Sorry.

I have a set of record types defined and want to create an initialized
constant and an array constant with values.  Occasionally I find that I
just cannot get the structure of the constants written properly and the
compiler whines at me until I throw my hands in the air.  I'd really
appreciate it if someone could show me what I'm not able to see for
myself.

{The types are:}
Type

  TFloat = Double;

  TPoint2D   = record 
 x, 
 y:TFloat; 
  end;

  TSegment2D  = array [1..2] of TPoint2D;

  TSlabel = string[5];

  TSegLabID = record
slabel :TSlabel;
segmentNo : integer;
  end;

  TSrecord = record
sSegLabID : TSegLabID;
segment :   TSegment2D;
  end;

  TLSegment = record
Srecord : TSrecord;
trueLP : TPoint2D;
  end;

  TexistingLines5 = array[0..4] of TLSegment;

{Then the hard part:}

Const
  { one wee little one }

  LSegmentNull : TLSegment = (Srecord:(sSegLabID:(sLabel:'';
  segmentNo:maxlongint)
  );
  segment:((x:maxlongint;y:maxlongint),
   (x:maxlongint;y:maxlongint)));
  trueLP:(x:maxlongint;y:maxlongint));

  { an array of five of the little blighters }

  CexistingLines : TexistingLines5= (
 
(Srecord:(sSegLabID:(sLabel:'0';segmentNo:0));segment:((x:0.5;y:0.5),(x:
3.5;y:1.7));trueLP:(x:0.5;y:0.5)),
 
(Srecord:(sSegLabID:(sLabel:'1';segmentNo:1));segment:((x:1.0;y:4.0),(x:
5.8;y:2.8));trueLP:(x:1.0;y:4.0)),
 
(Srecord:(sSegLabID:(sLabel:'2';segmentNo:2));segment:((x:1.5;y:3.0),(x:
6.2;y:2.4));trueLP:(x:1.5;y:3.0)),
 
(Srecord:(sSegLabID:(sLabel:'3';segmentNo:3));segment:((x:2.3;y:4.3),(x:
6.8;y:4.7));trueLP:(x:2.3;y:4.3)),
 
(Srecord:(sSegLabID:(sLabel:'4';segmentNo:4));segment:((x:2.5;y:0.3),(x:
6.8;y:4.7));trueLP:(x:2.5;y:0.3))
);

Can anyone save me from my misery?

Stu Cox
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal