Rich Text (RTF)

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

Rich Text (RTF)

Thomas A Petersen




Josh, et. al,

Check out the Open Office Importer from SqueakMap.  There is some basic RTF
parsing there.

Good hunting,
tap


Reply | Threaded
Open this post in threaded view
|

Access to primitiveTable from a plugIn

Alejandro F. Reimondo
Hi All,
I am trying to update my implementation of sqAPIs
 to VM 3.7.
I implemented the external interface as a plugIn,
 but I have not found the way to access the Interpreter
 primitive table from a plugIn.
How must a plugIN add/replace numbered primitives
 in the interpreter's table?
thanks in advance,
Ale.

Reply | Threaded
Open this post in threaded view
|

Re: Access to primitiveTable from a plugIn

Andreas.Raab
Alejandro F. Reimondo wrote:
> How must a plugIN add/replace numbered primitives
> in the interpreter's table?

Not at all, e.g., there is no access to the primitive table by plugins.
What do you need that access for?

Cheers,
   - Andreas

Reply | Threaded
Open this post in threaded view
|

Re: Access to primitiveTable from a plugIn

Alejandro F. Reimondo
Hi Andreas,

> What do you need that access for?
I need to add/reserve 3 primitive numbers and want
 to be setup by the plugin when loaded.

Doing that way porting sqAPIs from VM 1.3 to 3.7
(as an internal plugin) can be realized without risk of
 adding bugs to the implementation.

thanks in advance,
Ale.
p.d.: I think I can´t use named primitives because the
 implementation uses the first literal of the method
 to store information, as also do sqAPIs.

----- Original Message -----
From: "Andreas Raab" <[hidden email]>
To: "The general-purpose Squeak developers list"
<[hidden email]>
Sent: Monday, April 17, 2006 3:44 PM
Subject: Re: Access to primitiveTable from a plugIn


> Alejandro F. Reimondo wrote:
> > How must a plugIN add/replace numbered primitives
> > in the interpreter's table?
>
> Not at all, e.g., there is no access to the primitive table by plugins.
> What do you need that access for?
>
> Cheers,
>    - Andreas
>


Reply | Threaded
Open this post in threaded view
|

Re: Access to primitiveTable from a plugIn

Andreas.Raab
Hi -

I don't think it's a good idea to expose the primitive table to plugins
(either internal or external) in a standardized way. After all, getting
away from numbered primitives is exactly why we introduced named
primitives and plugins to begin with.

Since it seems to me that the tradeoff in this discussion is to either
change the VM to make it work with the plugin or to change the plugin to
make it work with the VM I'd strongly opt for the latter, e.g., update
the plugin by the proper means to work with the latest VMs.

If that's too much time for you to invest, you can build custom VMs
simply by doing something like

        extern void* primitiveTable[].

in your code, which requires the plugin to be internal but will work
short term.

Cheers,
   - Andreas

Alejandro F. Reimondo wrote:

> Hi Andreas,
>
>> What do you need that access for?
> I need to add/reserve 3 primitive numbers and want
>  to be setup by the plugin when loaded.
>
> Doing that way porting sqAPIs from VM 1.3 to 3.7
> (as an internal plugin) can be realized without risk of
>  adding bugs to the implementation.
>
> thanks in advance,
> Ale.
> p.d.: I think I can´t use named primitives because the
>  implementation uses the first literal of the method
>  to store information, as also do sqAPIs.
>
> ----- Original Message -----
> From: "Andreas Raab" <[hidden email]>
> To: "The general-purpose Squeak developers list"
> <[hidden email]>
> Sent: Monday, April 17, 2006 3:44 PM
> Subject: Re: Access to primitiveTable from a plugIn
>
>
>> Alejandro F. Reimondo wrote:
>>> How must a plugIN add/replace numbered primitives
>>> in the interpreter's table?
>> Not at all, e.g., there is no access to the primitive table by plugins.
>> What do you need that access for?
>>
>> Cheers,
>>    - Andreas
>>
>
>
>


Reply | Threaded
Open this post in threaded view
|

Re: Access to primitiveTable from a plugIn

Alejandro F. Reimondo
Andreas,
Thank you for your answer.
I also thought that the way is hacking the VM, but didn't
 want to miss something to learn about plugins...
I need to port sqAPIs to 3.7 vm
 because we are trying to have access to APIs for
 squeak under pocketPC (FFI requires assembler
 code as I know, and is not compatible to any other smalltalk)
 to be used in computer vision projects (like the projects
 presented in http://www.aleReimondo.com.ar/OpenCV
 including realtime face detection, image processing,
 object detection and tracking, implemented using
 visual smalltalk).
It is a little step in our plan, and this is the reason to make
 it as easy as possible.
thank you again for the help,
Ale.


----- Original Message -----
From: "Andreas Raab" <[hidden email]>
To: "The general-purpose Squeak developers list"
<[hidden email]>
Sent: Monday, April 17, 2006 4:55 PM
Subject: Re: Access to primitiveTable from a plugIn


> Hi -
>
> I don't think it's a good idea to expose the primitive table to plugins
> (either internal or external) in a standardized way. After all, getting
> away from numbered primitives is exactly why we introduced named
> primitives and plugins to begin with.
>
> Since it seems to me that the tradeoff in this discussion is to either
> change the VM to make it work with the plugin or to change the plugin to
> make it work with the VM I'd strongly opt for the latter, e.g., update
> the plugin by the proper means to work with the latest VMs.
>
> If that's too much time for you to invest, you can build custom VMs
> simply by doing something like
>
> extern void* primitiveTable[].
>
> in your code, which requires the plugin to be internal but will work
> short term.
>
> Cheers,
>    - Andreas
>
> Alejandro F. Reimondo wrote:
> > Hi Andreas,
> >
> >> What do you need that access for?
> > I need to add/reserve 3 primitive numbers and want
> >  to be setup by the plugin when loaded.
> >
> > Doing that way porting sqAPIs from VM 1.3 to 3.7
> > (as an internal plugin) can be realized without risk of
> >  adding bugs to the implementation.
> >
> > thanks in advance,
> > Ale.
> > p.d.: I think I can´t use named primitives because the
> >  implementation uses the first literal of the method
> >  to store information, as also do sqAPIs.
> >
> > ----- Original Message -----
> > From: "Andreas Raab" <[hidden email]>
> > To: "The general-purpose Squeak developers list"
> > <[hidden email]>
> > Sent: Monday, April 17, 2006 3:44 PM
> > Subject: Re: Access to primitiveTable from a plugIn
> >
> >
> >> Alejandro F. Reimondo wrote:
> >>> How must a plugIN add/replace numbered primitives
> >>> in the interpreter's table?
> >> Not at all, e.g., there is no access to the primitive table by plugins.
> >> What do you need that access for?
> >>
> >> Cheers,
> >>    - Andreas
> >>
> >
> >
> >
>
>