Re: [Pharo-users] FileLocator problem?

2015-07-30 Thread Matthieu Lacaton
Windows 7 uses aliases for these directories. It is the way different languages or owners are handled. For example in French you can see your music directory as Ma Musique but the real name used in paths is actually Music. As Craig said, the default paths for these directories are :

Re: [Pharo-users] Announcments vs Events schism

2015-07-28 Thread Matthieu Lacaton
It seems to me that sometimes the difference is a bit blurry. I used to consider announcements like some kinds of user-generated events, but I may be wrong here :/ I'll use SDL as an example because this is the technology chosen for Pharo. In SDL the concept of announcement does not exist.

[Pharo-users] How to correctly boost performances with Nativeboost ?

2015-07-17 Thread Matthieu Lacaton
Hello everyone, I know, I come up with another question involving NativeBoost ... Sorry ! Anyway, I am currently trying to improve the performance of a Pharo application by trying to rewrite some parts in C and use them with NativeBoost. In the application, there is a need to compute a lot of

[Pharo-users] NativeBoost and OpenMP

2015-07-16 Thread Matthieu Lacaton
Hello, I haven't really seen anything related to this on the Internet and maybe some people will find it cool so I just wanted to report one thing I found out today : NativeBoost works great with OpenMP ! I wrote a C function twice, once with openMP and once without. I made 32 bits libraries

Re: [Pharo-users] NativeBoost and variadic functions

2015-07-16 Thread Matthieu Lacaton
at 11:16, Matthieu Lacaton matthieu.laca...@gmail.com wrote: Hello Igor, Thanks for your answer. I implemented something like that for the printf function: Basically, it generates a method with matching arguments and executes it. *printf:* stringFormat *args:* tab | argNumber

Re: [Pharo-users] NativeBoost and variadic functions

2015-07-15 Thread Matthieu Lacaton
it has some drawbacks. Moreover I am not even sure it will work everytime. But for now it seems to work ... 2015-07-13 19:24 GMT+02:00 Igor Stasenko siguc...@gmail.com: On 10 July 2015 at 10:18, Matthieu Lacaton matthieu.laca...@gmail.com wrote: Hello, Is it possible with NativeBoost

[Pharo-users] NativeBoost and variadic functions

2015-07-10 Thread Matthieu Lacaton
Hello, Is it possible with NativeBoost to create a binding for a variadic function ? I've seen the printf example in NBCPrinter but this implementation is kind of cheating since it always pass just a %s as format and one already formatted string to the C function. I've written a simple variadic

Re: [Pharo-users] I probably messed up with .changes...

2015-07-07 Thread Matthieu Lacaton
nicolaih...@web.de: 2015-07-06 9:55 GMT+02:00 Matthieu Lacaton matthieu.laca...@gmail.com: Hello, I would just like to report something that happened to me today. As I was working on a project, I tried inserting an instance variable to one of my classes. Starting from this moment

[Pharo-users] I probably messed up with .changes...

2015-07-06 Thread Matthieu Lacaton
Hello, I would just like to report something that happened to me today. As I was working on a project, I tried inserting an instance variable to one of my classes. Starting from this moment something became very weird. First, some subclasses were not listed as subclasses anymore, then I realised

Re: [Pharo-users] I probably messed up with .changes...

2015-07-06 Thread Matthieu Lacaton
10:36 GMT+02:00 Nicolai Hess nicolaih...@web.de: 2015-07-06 9:55 GMT+02:00 Matthieu Lacaton matthieu.laca...@gmail.com: Hello, I would just like to report something that happened to me today. As I was working on a project, I tried inserting an instance variable to one of my classes

Re: [Pharo-users] an elegant way to return a result

2015-07-03 Thread Matthieu Lacaton
Well, thanks for the documentation, the first article was quite interesting and I'm gonna get this book asap :) When you execute a block (far away from the place it was created), it acts as an exception, it stops the execution of currently executed methods and return to its home context (method

Re: [Pharo-users] an elegant way to return a result

2015-07-01 Thread Matthieu Lacaton
This whole conversation really makes me want to ask: How do you know if some code is bad, good or completely ugly ? I've not been programming for long but I've already heard sentences like this: Damn this piece of code is so bad ! so often that I am really wondering. What are the rules ?

Re: [Pharo-users] Setting GUI pointer's position

2015-06-29 Thread Matthieu Lacaton
Hello, I asked the same thing some time ago and here are the answers I got : http://forum.world.st/Moving-the-HandMorph-td4826025.html Maybe it will give you ideas. As I said at the end, I did not find how to move the active hand but you can create another one and move this one. I don't know

Re: [Pharo-users] Setting GUI pointer's position

2015-06-29 Thread Matthieu Lacaton
hand and make it take the place of the existing hand and move it (so the effect would be like moving the hand) On Mon, Jun 29, 2015 at 11:33 AM, Matthieu Lacaton matthieu.laca...@gmail.com wrote: Hello, I asked the same thing some time ago and here are the answers I got : http

[Pharo-users] Athens and radial gradient

2015-06-18 Thread Matthieu Lacaton
Hello, I wanted to use Athens API to define a radial gradient and I saw that the class RadialGradientPaint only had one radius as instance variable and it seemed to me it was passed as the end radius while the start radius was set to 0. Does it mean that if I want to define a start radius

Re: [Pharo-users] NativeBoost nested structures

2015-06-16 Thread Matthieu Lacaton
Are you bound to exactly this structure? If you can define the structure, you can use a nested structure that uses pointers instead of values: NBTestNestedStructure2 fieldsDesc ^ #( NBTestStructure1byte* oneByte; int otherField ) Now you can create and

[Pharo-users] NativeBoost nested structures

2015-06-15 Thread Matthieu Lacaton
Hello everyone, I have a nested struct, let's say struct1 which contains struct2 which contains an int field named field. When I try to update the field from struct 1 directly I can't. What I mean is if I do : struct1 struct2 field: 4 for instance, the value in field is not updated. Even if I

Re: [Pharo-users] NativeBoost pointer and +

2015-06-09 Thread Matthieu Lacaton
, Matthieu 2015-06-08 19:56 GMT+02:00 Henrik Johansen henrik.s.johan...@veloxit.no: On 08 Jun 2015, at 4:41 , Matthieu Lacaton matthieu.laca...@gmail.com wrote: Hello everyone, I have a small question about NativeBoost : How does the + operator when applied to a pointer translates

Re: [Pharo-users] NativeBoost pointer and +

2015-06-09 Thread Matthieu Lacaton
as allocating/deallocating memory for buffers you using. On 8 June 2015 at 16:41, Matthieu Lacaton matthieu.laca...@gmail.com wrote: Hello everyone, I have a small question about NativeBoost : How does the + operator when applied to a pointer translates into NativeBoost code ? To give a bit

[Pharo-users] NativeBoost pointer and +

2015-06-08 Thread Matthieu Lacaton
Hello everyone, I have a small question about NativeBoost : How does the + operator when applied to a pointer translates into NativeBoost code ? To give a bit of context, what I want to do is to reallocate some non-contiguous bytes in memory to a buffer. Basically, I have an array of integers in

[Pharo-users] Slice for a non Pharo package ?

2015-05-30 Thread Matthieu Lacaton
Hello, I reported a bug on Athens here : https://pharo.fogbugz.com/f/cases/15640/ I also created a slice to solve it by following the Pharo fogbugz video tutorial. But then I realized that Athens is not present in Pharo/main so it would not make sense to commit the slice into the Pharo Inbox.

Re: [Pharo-users] PharoCommonTools methods

2015-05-25 Thread Matthieu Lacaton
Oh yes thx Nicolai, I did not look in the #doesNotUnderstand method. What is the main purpose of doing this instead of actually implementing a method ? 2015-05-25 19:20 GMT+02:00 Nicolai Hess nicolaih...@web.de: 2015-05-25 18:27 GMT+02:00 Matthieu Lacaton matthieu.laca...@gmail.com: Hello

Re: [Pharo-users] Moving the HandMorph

2015-05-13 Thread Matthieu Lacaton
Hello again, Just for the record, the EventRecorder source code allowed me to solve my problem. It is apparently not possible to move the main HandMorph but you can create a new secondary one and move it wherever you want ! Thanks again, Matthieu 2015-05-12 17:59 GMT+02:00 Matthieu Lacaton

Re: [Pharo-users] MouseWheel events

2015-05-12 Thread Matthieu Lacaton
Le 11/5/15 02:34, Sean P. DeNigris a écrit : Matthieu Lacaton wrote Let's say for example thant I want to create a rectangle on the screen and be able to move it up and down by pressing CTRL + up / down arrow and be able to rotate it with the mouse wheel. Does this mean that on Linux I just

[Pharo-users] Moving the HandMorph

2015-05-12 Thread Matthieu Lacaton
Hello everybody, Is there a way to move the position of the cursor (the HandMorph) by passing commands to it ? I tried things like ActiveHand position: or ActiveHand moveToEvent: but nothing worked for me. Thanks, Matthieu

Re: [Pharo-users] Moving the HandMorph

2015-05-12 Thread Matthieu Lacaton
Okay. That was 2 years ago so I was wondering if something had changed since then but apparently not. Thanks a lot, Matthieu 2015-05-12 17:51 GMT+02:00 Nicolai Hess nicolaih...@web.de: 2015-05-12 17:40 GMT+02:00 Matthieu Lacaton matthieu.laca...@gmail.com: Hello everybody

Re: [Pharo-users] Moving the HandMorph

2015-05-12 Thread Matthieu Lacaton
Or maybe have a look at HandMorphForReplay in http://forum.world.st/ANN-EventRecorderMorph-Port-to-3-0-td4736258.html Oh I didn't know about that, I'll definitely have a look at it, it seems cool ! Thanks, Matthieu 2015-05-12 17:57 GMT+02:00 Matthieu Lacaton matthieu.laca...@gmail.com

Re: [Pharo-users] MouseWheel events

2015-05-10 Thread Matthieu Lacaton
a lot ! 2015-05-11 2:34 GMT+02:00 Sean P. DeNigris s...@clipperadams.com: Matthieu Lacaton wrote Let's say for example thant I want to create a rectangle on the screen and be able to move it up and down by pressing CTRL + up / down arrow and be able to rotate it with the mouse wheel. Does

Re: [Pharo-users] MouseWheel events

2015-05-10 Thread Matthieu Lacaton
that on Linux I just can't ? And does this mean that if I create an application able to react to mouse wheel, I need to code it differently for Windows and for Linux ? Matthieu 2015-05-06 23:55 GMT+02:00 Sean P. DeNigris s...@clipperadams.com: Matthieu Lacaton wrote Shouldn't I get a MouseWheel event

Re: [Pharo-users] SDL plugin ?

2015-05-06 Thread Matthieu Lacaton
/2015 21:48, Matthieu Lacaton wrote: Hello, I am currently playing with OSWindow and I am wondering what the SDL plugin is in the OSSDL2Driver ? When I downloaded the latest linux VM + image I got a library called libSDL2DisplayPlugin but how can I get this plugin for windows ? Is it possible

[Pharo-users] SDL plugin ?

2015-05-06 Thread Matthieu Lacaton
Hello, I am currently playing with OSWindow and I am wondering what the SDL plugin is in the OSSDL2Driver ? When I downloaded the latest linux VM + image I got a library called libSDL2DisplayPlugin but how can I get this plugin for windows ? Is it possible to get the source code too ? Thanks,

[Pharo-users] Some Athens modifications ?

2015-05-06 Thread Matthieu Lacaton
Hello everybody, I was playing arround with Athens lately and I think I encountered a few small bugs along the way (I may be wrong though) : 1) In *LinearGradientPaint class from:* aStartPoint *to:* aStopPoint There is a call to the method *initializeFrom: aStartPoint to: aStopPoint* but this

[Pharo-users] MouseWheel events

2015-05-06 Thread Matthieu Lacaton
Hello everyone, I have a question about MouseWheel events in Pharo. On Linux, when I use the wheel of my mouse the event I get in return is an instance of MouseWheelEvent : * [(606@633) mouseWheel Character arrowDown CTRL 33261828 nil] * When I press CTRL + ArrowUp or CTRL + ArrowDown on my

Re: [Pharo-users] SDL2 and fork

2015-04-20 Thread Matthieu Lacaton
: Hi Matthieu, This is important: Binding SDL with Pharo will help Roassal to get better. Please, let us know how it goes Alexandre On Apr 9, 2015, at 12:54 PM, Matthieu Lacaton matthieu.laca...@gmail.com wrote: Hello everyone, I tried to use the SDL2 binding to Pharo to create

[Pharo-users] SDL2 and fork

2015-04-09 Thread Matthieu Lacaton
Hello everyone, I tried to use the SDL2 binding to Pharo to create a very basic 2D application (just some sprites and events) and it worked great. The issue I have is that when I start my application, as long as I have an active SDL window, I can't use my Pharo image anymore (it freezes). To