Pharo-users
By thread
pharo-users@lists.pharo.org
By month
Messages by month
- ----- 2026 -----
- July
- June
- May
- April
- March
- February
- January
- ----- 2025 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2024 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2019 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2018 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2017 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2016 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2015 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2014 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2013 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2012 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2011 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2010 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
March 2017
- 90 participants
- 580 messages
Re: [Pharo-users] [ANN] Image saver with time tag
by stepharong
agreed I would like to use iso by default
2017-03-18-....
On Sat, 18 Mar 2017 12:11:35 +0100, Ben Coman <btc(a)openinworld.com> wrote:
> Nice feature. I'd actually consider "Save As..." defaulting to the time
> tag. Any objections?
> How often do people use "Save As..." and for what purpose besides
> safety-backup?
>
> cheers -ben
>
> On Mon, Oct 31, 2016 at 12:36 AM, phil(a)highoctane.be
> <phil(a)highoctane.be> wrote:
>> I like to save images with a time tag and got tired of typing in the
>> save window.
>>
>> So, there is HOImageSaver.
>>
>> https://github.com/Pharophile/HOImageSaver
>>
>> It works with Pharo 5.
>>
>> Load as follows:
>>
>> Metacello new
>> githubUser: 'pharophile' project: 'HOSImageSaver' commitish:
>> 'master' path: 'packages';
>> baseline: 'HOImageSaver';
>> onWarningLog;
>> load
>>
>>>> Phil
>
--
Using Opera's mail client: http://www.opera.com/mail/
March 18, 2017
Re: [Pharo-users] [ANN] Release of the Spec book
by stepharong
> Thanks! These books are really valuable asset!
>
> Regarding the hardcopy, I hope in the future you could make it a bit
> more expensive for a more solid construction with staple or spiral.
damien did a new version of the template but we should
- try it
- probably convert the books
- create a new cover
- test it :)
so we will do it but it is a lot of work.
I would like to have most of the pharo using the same version of sba and
pillar.
Stef
March 18, 2017
Re: [Pharo-users] [ANN] Image saver with time tag
by Ben Coman
Nice feature. I'd actually consider "Save As..." defaulting to the time
tag.
Any objections?
How often do people use "Save As..." and for what purpose besides
safety-backup?
cheers -ben
On Mon, Oct 31, 2016 at 12:36 AM, phil(a)highoctane.be <phil(a)highoctane.be>
wrote:
> I like to save images with a time tag and got tired of typing in the save
> window.
>
> So, there is HOImageSaver.
>
> https://github.com/Pharophile/HOImageSaver
>
> It works with Pharo 5.
>
> Load as follows:
>
> Metacello new
> githubUser: 'pharophile'
> project: 'HOSImageSaver'
> commitish: 'master'
> path: 'packages';
> baseline: 'HOImageSaver';
> onWarningLog;
> load
>
> Phil
>
March 18, 2017
Re: [Pharo-users] [ANN] Release of the Spec book
by Hilaire
Thanks! These books are really valuable asset!
Regarding the hardcopy, I hope in the future you could make it a bit
more expensive for a more solid construction with staple or spiral.
Hilaire
Le 17/03/2017 à 09:32, Johan Fabry a écrit :
> Stéphane and I are happy to announce the 1.0 release of the book on Spec, the UI framework for Pharo!!
--
Dr. Geo
http://drgeo.eu
March 18, 2017
Re: [Pharo-users] Specifying library dependencies in UFFI
by stepharong
Tx phil for these cool words.
We are pushing and we need inputs too because from time to time I have the
impression that we
are focusing a bit too much on our own system but this is natural :)
Stef
On Fri, 17 Mar 2017 07:17:38 +0100, phil(a)highoctane.be
<phil(a)highoctane.be> wrote:
> It is true that you can kill an image or two doing this.
>
> A reason why I added this little thing
> https://github.com/Pharophile/HOImageSaver and use it quite often.
>
> I also got a debug and assert VM to build for Windows, so I have the
> full symbols table available.
>
> Running Pharo and, say CodeBlocks IDE side by side, and connecting GDB
> in CodeBlocks through attach to process using the Pharo PID works pretty
> well to figure out what is going on.
>
> I am also using Snagit a lot to capture screenshots with values etc for
> future reference.
>
> Using a remote Pharo image from another image that will stay untouched
> may be a better way to go in the future but will not really work if one
> has a breakpoint triggered in the remote one >anyway,..
>
> But I found the process of wrapping a library pretty much painless
> compared to the sea of wrapping code one gets from Swig for example.
>
> Once we will have wrapped a couple external libraries with UFFI I expect
> some patterns to emerge and our ability to wrap things to be enhanced
> drastically, to the point that we will see >incredible growth in terms
> of capabilities.
>
> We will then really up our game on how to load code from a central repo,
> a la npmjs, or mavencentral, or gems, or pip. Because it sucks big time
> in a couple of occasions.
>
> With any tech, there is always this hype cycle with the disullusionment
> after the "peak of excitement" and that is needed to reach the
> productivity.
> I would urge all Pharo users to keep pushing and not let go of the
> vision, because there is really nothing like Pharo around.
>
> I just got remembered of how good it was yesterday: a given job stopped
> processing its input because the underlying format of the file changed
> under its feet. It was a matter of 30 minutes >between diagnostic and
> fix, and I was able to deliver the output for a critical meeting by the
> client. There is zero way I would have been able to inspect, diagnose,
> and fix that fast with something >else.
> Using Pharo makes someone a kind of maverick but the vista is quite good.
>
> Phil
>
>
> On Thu, Mar 16, 2017 at 3:48 PM, Dimitris Chloupis
> <kilon.alios(a)gmail.com> wrote:
>> My point was that anything you do in Pharo will lower performance quite
>> a bit, but it wont be noticable anyway unless its in a big loop or
>> something.
>> Second that Pharo cannot debug such issues which is a huge deal when
>> you work with OS stuff and OS calls.
>> You are far better doing this outside UFFI and straight inside a C IDE
>> because you will have an army of tools that will make your life a ton
>> easier.
>> Hence why I talked about performance, C coding and Pharo crashes.
>> In my case I had to write and test the code in C to port it to UFFI
>> because it was impossible to resolve the bugs from inside Pharo. Also
>> crashing Pharo all the time got really annoying and I >>managed to
>> corrupt a couple of images too in the process.
>> Of course debugging C code from a C IDE is quite similar to how you
>> work with Pharo.
>> I also got an experience with loading libraries because I worked with
>> Shared memory mapped files which is the technology OS uses to load
>> DLLs. Its really low level stuff that come directly >>from OS kernel.
>> It was a ton of fun.
>> Also C is easier because obviously there is a ton of docs and all you
>> have to do is copy paste. In case of UFFI you have to first figure out
>> the C code and then how to convert it to UFFI so its >>double the
>> effort for little gain. Its much better thing to just wrap C code and
>> minimize the usage of UFFI.
>> The benefits of Pharo are lost anyway as soon as you drop so low level.
>> On Thu, Mar 16, 2017 at 3:05 PM <raffaello.giulietti(a)lifeware.ch> wrote:
>>> Indeed, experimenting using some combination of AddDllDirectory(),
>>> SetDllDirectory() and LoadLibraryEx() was in my plan for next week.
>>>
>>> Thanks
>>>
>>>
>>>
>>> On 16/03/17 11:59, Mark Bestley wrote:
>>>> Yes the calling process can alter where these indirect DLLs are loaded
>>>> from and so should be able to be done in UFFI and directly from
>>>> Smalltalk
>>>>
>>>> The OS will load the DLL specified then it runs DllMain and doing that
>>>> causes the OS to load any DLLs that it calls
>>>>
>>>> MSDN https://msdn.microsoft.com/en-us/library/7d83bc18.aspx says
>>>>
>>>> With both implicit and explicit linking, Windows first searches for
>>>> "known DLLs", such as Kernel32.dll and User32.dll. Windows then
>>>> searches
>>>> for the DLLs in the following sequence:
>>>> The directory where the executable module for the current process is
>>>> located.
>>>> The current directory.
>>>> The Windows system directory. The GetSystemDirectory function
>>>> retrieves
>>>> the path of this directory.
>>>> The Windows directory. The GetWindowsDirectory function retrieves the
>>>> path of this directory.
>>>> The directories listed in the PATH environment variable.
>>>>
>>>>
>>>> This can be changed using the call LoadLibraryEx instead of
>>>> LoadLibrary
>>>> Flags can be set to change the directories used
>>>>
>>>> https://msdn.microsoft.com/en-us/library/windows/desktop/ms684179(v=vs.85).…
>>>>
>>>>
>>>>
>>>> Also see AddDllDirectory
>>>> https://msdn.microsoft.com/en-us/library/windows/desktop/hh310513(v=vs.85).…
>>>>
>>>>
>>>> Mark
>>>>
>>>> On 15/03/2017 17:22, Raffaello Giulietti wrote:
>>>>> Hi Dimitris,
>>>>>
>>>>> I don't get your point about proper C coding, C performance or Pharo
>>>>> crashes. It is not the focus of this thread.
>>>>>
>>>>> How dependencies between libraries are resolved at load-time is
>>>>> dictated
>>>>> by the OS. If the OS offers a working mechanism to specify folders
>>>>> that
>>>>> the OS uses to search for libraries at load-time, well, I think that
>>>>> Pharo, hence the UFFI, should offer it as well and in a more
>>>>> fashionable
>>>>> format.
>>>>> UFFI is quite elegant in many respects but I wouldn't call it a
>>>>> minimalist design (zero hand holding, if I understand you correctly).
>>>>> But I'm happy the extra elegance is there because it makes life more
>>>>> comfortable.
>>>>>
>>>>> Again, I still have to experiment with SetDllDirectory() in the case
>>>>> of
>>>>> Windows, so I'm not in a position to say something authoritative yet.
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> On 2017-03-15 17:41, Dimitris Chloupis wrote:
>>>>>> Please note the moment you use a FFI of any language you step to a C
>>>>>> territory. VMs tend not to touch the code because the code is
>>>>>> already
>>>>>> in machine code format.
>>>>>>
>>>>>> There is zero reason for UFFI to worry about the dependencies of a
>>>>>> library loaded, this must happen at the library level that UFFI does
>>>>>> not focus on.
>>>>>>
>>>>>> What you describe here is standard practice because the vast
>>>>>> majority
>>>>>> of libraries depend on other libraries. In the end UFFI or any FFI
>>>>>> in
>>>>>> any language is not there to replace proper C coding but rather to
>>>>>> allow you to utilize C libraries. You cannot hope to achieve
>>>>>> performance comparable to C if you try to use a language that is
>>>>>> not C
>>>>>> to do standard things like dependency management.
>>>>>>
>>>>>> If the library fail to load it wont be because of UFFI it will be
>>>>>> because the library is buggy at handling its dependencies. That
>>>>>> means
>>>>>> that the library will be buggy even if you use it from C directly.
>>>>>>
>>>>>> Even you do not know what you doing at C level, you going to crash
>>>>>> Pharo countless times anyway and the least of your worries will be
>>>>>> handling dependencies which far more obvious than some other nasty C
>>>>>> bugs.
>>>>>>
>>>>>> I think its a great idea that UFFI does zero hand holding. This way
>>>>>> it
>>>>>> gives the clear message that if you do not understand C then you
>>>>>> should not be using the UFFI in the first place.
>>>>>>
>>>>>> On Wed, Mar 15, 2017 at 4:51 PM Esteban Lorenzano
>>>>>> <estebanlm(a)gmail.com
>>>>>> <mailto:estebanlm@gmail.com>> wrote:
>>>>>>
>>>>>>
>>>>>> > On 15 Mar 2017, at 15:44, Raffaello Giulietti
>>>>>> <raffaello.giulietti(a)lifeware.ch
>>>>>> <mailto:raffaello.giulietti@lifeware.ch>>
>>>>>> wrote:
>>>>>> >
>>>>>> > On 2017-03-15 15:20, Esteban Lorenzano wrote:
>>>>>> >>
>>>>>> >>> On 15 Mar 2017, at 15:08, Raffaello Giulietti
>>>>>> <raffaello.giulietti(a)lifeware.ch
>>>>>> <mailto:raffaello.giulietti@lifeware.ch>>
>>>>>> wrote:
>>>>>> >>>
>>>>>> >>> Hi Esteban,
>>>>>> >>>
>>>>>> >>> I understand this is the current status of the UFFI, so I
>>>>>> can
>>>>>> certainly use the workarounds discussed below.
>>>>>> >>>
>>>>>> >>> But I hope UFFI will soon offer a more "declarative" way to
>>>>>> specify the search folders, kind of LD_LIBRARY_PATH mechanism
>>>>>> but
>>>>>> in the UFFI.
>>>>>> >>
>>>>>> >> that will NOT solve the problem of dependencies of libraries
>>>>>> indirectly references.
>>>>>> >> There is no way to do that (indirect reference solving) on an
>>>>>> executing program that I know.
>>>>>> >> So is not âcurrent status of UFFIâ: it will never provide
>>>>>> that.
>>>>>> >>
>>>>>> >
>>>>>> > Do you mean that SetDllDirectory() has no influence when
>>>>>> invoked
>>>>>> between Pharo's start and the LoadLibrary() call done by the
>>>>>> UFFI?
>>>>>>
>>>>>> I really have no idea. You can try to add it to your app.
>>>>>>
>>>>>> Esteban
>>>>>>
>>>>>> >
>>>>>> >
>>>>>> >
>>>>>> >
>>>>>> >> All that, unless someone come and says: "look, Esteban is
>>>>>> like
>>>>>> thisâ.
>>>>>> >>
>>>>>> >> I spent last three weeks (not full time of course) trying to
>>>>>> do
>>>>>> exactly that for our current linux vm, to force libgit2 to use
>>>>>> the
>>>>>> version of libssh2 we want (and not the version on system)⦠and
>>>>>> I
>>>>>> failed. I solved some cases, but not all. So at the end I opted
>>>>>> to
>>>>>> change zeroconf to define LD_LIBRARY_PATH before calling pharo.
>>>>>> Only way I found I can force the lookup paths.
>>>>>> >>
>>>>>> >> cheers,
>>>>>> >> Esteban
>>>>>> >>
>>>>>> >>>
>>>>>> >>>
>>>>>> >>>
>>>>>> >>> Greetings
>>>>>> >>> Raffaello
>>>>>> >>>
>>>>>> >>>
>>>>>> >>>
>>>>>> >>>
>>>>>> >>> On 2017-03-15 14:52, Esteban Lorenzano wrote:
>>>>>> >>>> Hi,
>>>>>> >>>>
>>>>>> >>>> UFFI cannot do what you want.
>>>>>> >>>> If I understand well, you have:
>>>>>> >>>>
>>>>>> >>>> Pharo -> libA.dll -> libB.dll
>>>>>> >>>>
>>>>>> >>>> Pharo does a LoadLibrary(libA.dll), but has no control on
>>>>>> how
>>>>>> libA calls libB⦠and is not possible for us to influence it more
>>>>>> than the predefined platform ways.
>>>>>> >>>>
>>>>>> >>>> One posible workaround (just possible, no idea if it will
>>>>>> work) is to perform a load of libB before is required by libB.
>>>>>> Then hopefully the loader will understand is same library and
>>>>>> will
>>>>>> answer same handler (but not sure, because if it discriminates
>>>>>> by
>>>>>> path⦠then youâre in the same position). Anyway, if you want to
>>>>>> try it, it would be something like this:
>>>>>> >>>>
>>>>>> >>>> DynamicLoader loadLibrary: 'path/to/libB.dllâ.
>>>>>> >>>> DynamicLoader loadLibrary: 'path/to/libA.dllâ.
>>>>>> >>>>
>>>>>> >>>> then you can try to execute functions of libAâ¦
>>>>>> >>>>
>>>>>> >>>> cheers,
>>>>>> >>>> Esteban
>>>>>> >>>>
>>>>>> >>>>
>>>>>> >>>>> On 15 Mar 2017, at 14:32, Raffaello Giulietti
>>>>>> <raffaello.giulietti(a)lifeware.ch
>>>>>> <mailto:raffaello.giulietti@lifeware.ch>>
>>>>>> wrote:
>>>>>> >>>>>
>>>>>> >>>>> On 2017-03-15 13:51, Ben Coman wrote:
>>>>>> >>>>>>
>>>>>> >>>>>>
>>>>>> >>>>>> On Wed, Mar 15, 2017 at 4:42 PM, Raffaello Giulietti
>>>>>> >>>>>>
>>>>>> <raffaello.giulietti(a)lifeware.ch
>>>>>> <mailto:raffaello.giulietti@lifeware.ch>
>>>>>> >>>>>>
>>>>>> <mailto:raffaello.giulietti@lifeware.ch
>>>>>> <mailto:raffaello.giulietti@lifeware.ch>>>
>>>>>> wrote:
>>>>>> >>>>>>
>>>>>> >>>>>> Hi Ben,
>>>>>> >>>>>>
>>>>>> >>>>>> my understanding is that SetDllDirectory only affects
>>>>>> the
>>>>>> search
>>>>>> >>>>>> path of libraries that are loaded at *run-time* with
>>>>>> LoadLibrary.
>>>>>> >>>>>>
>>>>>> >>>>>> What I'm asking for is a mechanism that works at
>>>>>> *load-time*, when a
>>>>>> >>>>>> library I'm accessing directly depends on another one
>>>>>> which I'm not
>>>>>> >>>>>> targeting directly.
>>>>>> >>>>>>
>>>>>> >>>>>>
>>>>>> >>>>>> I don't quite follow. I'm not intimate with Windows
>>>>>> dynamic loading, so
>>>>>> >>>>>> these questions are an opportunity for me to learn...
>>>>>> >>>>>>
>>>>>> >>>>>> You can't mean when Pharo loads, because it wouldn't know
>>>>>> of OTHER.DLL ?
>>>>>> >>>>>>
>>>>>> >>>>>> Do you mean that LoadLibrary is not called explicitly by
>>>>>> YOUR.DLL before
>>>>>> >>>>>> its uses the function from OTHER.DLL?
>>>>>> >>>>>>
>>>>>> >>>>>
>>>>>> >>>>> During the build of YOUR.DLL, you can specify that it
>>>>>> should
>>>>>> depend on OTHER.LIB (kind of binary which lists function headers
>>>>>> and static data declarations for OTHER.DLL). Linking resolution
>>>>>> is
>>>>>> then done at load-time of YOUR.DLL, not by invoking
>>>>>> LoadLibrary("OTHER.DLL").
>>>>>> >>>>>
>>>>>> >>>>> When YOUR.DLL is loaded by UFFI at run-time (here by means
>>>>>> of LoadLibrary(), I guess), Windows (not the UFFI) also attempts
>>>>>> to load OTHER.DLL because of the linking information gathered
>>>>>> during the build. Notice that the linking information does *not*
>>>>>> include a specific path for OTHER.DLL.
>>>>>> >>>>>
>>>>>> >>>>> (You don't have to mention standard *.LIBs like
>>>>>> Kernel32.lib
>>>>>> because they are included by default. But of course, Windows
>>>>>> knows
>>>>>> where to find the corresponding .dll.)
>>>>>> >>>>>
>>>>>> >>>>> OTHER.DLL is searched using the strategy described in the
>>>>>> MSDN page you mention. My expectation is/was that UFFI has/had
>>>>>> an
>>>>>> API for specifying the search paths where to find OTHER.DLL in a
>>>>>> platform-independent way. In other words, I would expect the
>>>>>> UFFI
>>>>>> to do the call of SetDllDirectory() or whatever is needed on
>>>>>> Windows for me or to use other mechanisms on other platforms.
>>>>>> >>>>>
>>>>>> >>>>>
>>>>>> >>>>>
>>>>>> >>>>>> Do you mean you link OTHER.DLL to YOUR.DLL at compile
>>>>>> time?
>>>>>> >>>>>> But still, YOUR.DLL it not loaded until called via Pharo
>>>>>> FFI, so neither
>>>>>> >>>>>> is OTHER.DLL,
>>>>>> >>>>>> and Dynamic-Link Library Search Order [1] says... "If a
>>>>>> DLL
>>>>>> with the
>>>>>> >>>>>> same module name
>>>>>> >>>>>> is already loaded in memory, the system uses the loaded
>>>>>> DLL, no matter
>>>>>> >>>>>> which directory it is in.
>>>>>> >>>>>> The system does not search for the DLL."
>>>>>> >>>>>>
>>>>>> >>>>>> So maybe before calling any of YOUR.DLL,
>>>>>> >>>>>> do a SetDllDirectory followed by a LoadLibrary(OTHER.DLL)
>>>>>> >>>>>> and later when you call into YOUR.DLL,
>>>>>> >>>>>> OTHER.DLL is already loaded.
>>>>>> >>>>>>
>>>>>> >>>>>
>>>>>> >>>>> Yes, this might work but is rather contrived.
>>>>>> >>>>>
>>>>>> >>>>>
>>>>>> >>>>>
>>>>>> >>>>>> Otherwise it would seems(?) your options are either
>>>>>> Manifests
>>>>>> >>>>>> or Dynamic-Link Library Redirection, both done outside of
>>>>>> Pharo.
>>>>>> >>>>>>
>>>>>> >>>>>
>>>>>> >>>>> What if neither YOUR.DLL nor OTHER.DLL are under my
>>>>>> control?
>>>>>> The only thing I know is where the .dll and the corresponding
>>>>>> .lib
>>>>>> + .h are.
>>>>>> >>>>>
>>>>>> >>>>>
>>>>>> >>>>>
>>>>>> >>>>> Thanks for your interest
>>>>>> >>>>> Raffaello
>>>>>> >>>>>
>>>>>> >>>>>
>>>>>> >>>>>
>>>>>> >>>>>
>>>>>> >>>>>> But I'll try whether SetDllDirectory also affects
>>>>>> load-time searches.
>>>>>> >>>>>>
>>>>>> >>>>>> Anyway, I hope future versions of the UFFI to offer
>>>>>> setting the
>>>>>> >>>>>> search paths more easily.
>>>>>> >>>>>>
>>>>>> >>>>>>
>>>>>> >>>>>>
>>>>>> >>>>>> Greetings
>>>>>> >>>>>> Raffaello
>>>>>> >>>>>>
>>>>>> >>>>>
>>>>>> >>>>>
>>>>>> >>>>
>>>>>> >>>>
>>>>>> >>>
>>>>>> >>>
>>>>>> >>
>>>>>> >>
>>>>>> >
>>>>>> >
>>>>>>
>>>>>>
>>>>>
>>>>
>>>>
>>>
>>>
>
--
Using Opera's mail client: http://www.opera.com/mail/
March 17, 2017
Re: [Pharo-users] Magritte extension
by stepharong
Hi asbath
can you attach your code?
So that we can load it in a magritified image?
Stef
On Fri, 17 Mar 2017 07:54:37 +0100, Asbath Sama biyalou via Pharo-users
<pharo-users(a)lists.pharo.org> wrote:
> Hello.
>
> I am using Magritte to generate reports for a pharo class. I want to
> customize generated components in order to have a better design.
>
> My class is Match
>
> Object subclass: #Match
> instanceVariableNames: 'date_match hour_match status actions stadium
> comments teams goals1 goals2 competition'
> classVariableNames: ''
> category: MyProject-Entity'
>
>
> Descriptions for some variables.
>
> Stadium is also a Class.
>
> Match>>descriptionStadium
> <magritteDescription>
> ^ MASingleOptionDescription new
> label: 'Stadium';
> priority: 305;
> accessor: #stadium;
> options: Team allStadiumsName;
> componentClass: TBSMagritteSelectListComponent;
> beRequired;
> yourself
>
>
> Match>>descriptionTeams
> <magritteDescription>
> ^ MAMultipleOptionDescription new
> label: 'Teams';
> priority: 805;
> accessor: #teams;
> options: Team allTeamsName;
> componentClass: MAMultiselectListComponent;
> yourself
>
>
> The generated component in the form is not very pretty. I want to have
> multiple checkbox.
>
>
> Match>>descriptionStatus
> <magritteDescription>
> ^ MASingleOptionDescription new
> label: 'Status';
> priority: 505;
> accessor: #status;
> options: #('Pas en cours' 'En Cours' 'Mi-temps' 'Terminé');
> componentClass: TBSMagritteSelectListComponent;
> yourself
>
>
> For the report I use the class SEMatchReport
>
> TBSMagritteReport subclass: #SEMatchReport
> instanceVariableNames: 'report'
> classVariableNames: ''
> category: 'MyProject-Components'
>
>
> SEMatchReport class>>from
> | report matchs commandColumn |
> matchs := Match selectAll.
> report:= self rows: matchs description: (self
> filteredDescriptionsFrom: matchs anyOne).
> commandColumn := MACommandColumn new.
> (SEMatchReport new session isSimpleAdmin)
> ifTrue: [
> report addColumn: (commandColumn
> addCommandOn: report selector: #editMatch: text: 'Modifier';
> yourself;
> addCommandOn: report selector: #addAction: text: 'Ajouter
> une action'; yourself ) ]
> ifFalse: [
> report addColumn: (commandColumn
> addCommandOn: report selector: #editMatch: text: 'Modifier';
> yourself;
> addCommandOn: report selector: #deleteMatch: text:
> 'Supprimer'; yourself;
> addCommandOn: report selector: #addAction: text: 'Ajouter
> une action'; yourself ) ].
> ^ report
>
> I want to put some bootstrapp icons near commandColumn actions. like
> pencil or delete on 'Supprimer'.
>
>
> SEMatchReport class>>filteredDescriptionsFrom: aMatch
> ^ aMatch magritteDescription select: [ :each | #(date_match
> hour_match stadium goals1 goals2 teams)
> includes: each accessor selector ]
>
> I notice that on the generated report on column stadium we have
> aStadium. We don't have the value (the name). I don't know how to
> mention it in the filtered descriptions.
>
> Change the color of lines in the report, etc. All that things.
>
> Sorry for the bad english.
>
> Thanks.
>
> Asbath
>
>
--
Using Opera's mail client: http://www.opera.com/mail/
March 17, 2017
Re: [Pharo-users] doesNotUnderstand: infinit loop
by Denis Kudriashov
Fix is inbox. But I am not sure how good it is. It fixed known cases but
can broke something else. So maybe it is not for Pharo6.
2017-03-17 12:10 GMT+01:00 Esteban A. Maringolo <emaringolo(a)gmail.com>:
> 2017-03-17 6:46 GMT-03:00 Denis Kudriashov <dionisiydk(a)gmail.com>:
> >
> > 2017-03-16 18:07 GMT+01:00 Esteban A. Maringolo <emaringolo(a)gmail.com>:
> >>
> >> I got used to save the image before debugging a single test and/or
> recover
> >> lost changes. But this is certainly hard if you want to do TDD :)
> >>
> >> Is this related with the debugger UI (GT) or with the underlying
> >> frameworks?
> >
> >
> > No. Problem is in Context methods: #stepToHome: and
> > #runUntilErrorOrReturnFrom:. They called from DebugSession #stepThrough:
> and
> > #stepOver:
>
> I don't know the internals of the debugger, nor the Context execution,
> but this sometimes happens when running the test, without an open
> debugger.
>
> I will try to find a case and report it to the latest issue you created.
>
> Thanks for your support.
>
>
> Esteban A. Maringolo
>
>
March 17, 2017
Re: [Pharo-users] Recreating Live Coding experience in C++ and Python [ was: Re: Specifying library dependencies in UFFI]
by Dimitris Chloupis
Python is my No2 does not have to be yours, obviously. I prefer it because
of its minimalistic ideology and huge third party library ecosystem that
makes it dead easy to code in. But in the end I use it because that's what
Blender uses for scripting.
Of course Pharo remains my No1 ;)
I hate web development for the usual reasons hence I try to stay as far
away from it as possible. Pearl syntax looks too ugly to me.
I also use C++ because that's what Unreal uses. My post was not an
advertisement for those two languages , just to mention that live coding is
possible. I actually hate C++. But it's a necessary evil in my case.
On the subject of C macros , there is scons which is a Python library and I
suspect there are a ton more out there. Blender which is more than one
million lines of C code used it but I think now the rely more on CMake.You
could probably build one in Pharo too easily for personal usage. I do not
rely on C macros or scons because Unreal has its own build system which
handles many common issues with the compiler for me.
There is a ton of technology for any kind of problem, just a google away.
On Fri, 17 Mar 2017 at 12:37, Dima Makhnin <dimamakhnin(a)gmail.com> wrote:
> Why all the hype about python? why not more flexible languages like
> JavaScript ES6, or Perl5 that are capable of preserving string to object
> literal isomorphism out of the box?
>
> Of course Dynamic Languages are fine for this, that's essentially what
> Objective C is; C + FakeTalk.
>
> I dream of a future where we can throw out the silly C processor macros
> and replace them with a real script engine; eg write c in a php file and
> have it generate code at preprocessor time, and if you need help at
> runtime, load the php runtime, and interact with it.
>
> This can be done in any language, For SmallTalk it's something like
> objective c but objective c is halfway there, it didn't replace c
> preprocessor with inline smalltalk.
>
> But yeah, hopefully we see more elegant compiletime-runtime interop in the
> future.
>
> On Mar 17, 2017 6:21 AM, "Dimitris Chloupis" <kilon.alios(a)gmail.com>
> wrote:
>
>
> With any tech, there is always this hype cycle with the disullusionment
> after the "peak of excitement" and that is needed to reach the
> productivity.
>
> I would urge all Pharo users to keep pushing and not let go of the vision,
> because there is really nothing like Pharo around.
>
>
> The one things I love about Pharo is Live Coding. The ability to change
> the code while it executes without all this recompile-restart nonsense.
>
> I also was under the assumption you were when it came to live coding that
> none is doing better than Smalltalk and Lisp. So just for fun I went on to
> experiment how easy it would be to re implement live coding in C++ and
> Python. I was not expecting much if anything.
>
> With Python it was super easy, I only need a main loop, wrap the loop
> inside an exception that in case of an error would catch the error , not
> stop the execution but rather using the import tools that come with Python
> will import the module. Worked like a charm.
>
> I use this to develop a blender addon.
>
> But the really shock was how easy it was to do this with C++. I thought
> that memory leaks would make live coding with C++ impossible , I was dead
> wrong. Apparently OS exceptions can capture even crashes, they wont allow
> the executable to crash. Instead of python modules I use DLLs on windows ,
> .dylibs on MacOS and .so on Ubuntu. Executable is a tiny loop reloading the
> dlls and providing to them a pointer to a very large array that contains
> the entire memory of the app, DLLs handle the memory to share it between
> objects etc.
>
> https://github.com/kilon/LiveCPP
>
> Next step is integrating iPython and also python debugger and testing unit
> testing with live coding.
>
> So yes definetly learn Pharo because it has many hidden gems , if you are
> newcomer. But if you miss Pharo , like me, when you code in other language,
> despair not, its very easy to recreate at least live coding.
>
>
March 17, 2017
Re: [Pharo-users] Magritte extension
by Esteban A. Maringolo
2017-03-17 8:23 GMT-03:00 Mariano Martinez Peck <marianopeck(a)gmail.com>:
> Hi,
>
> Before a longer answer, what is TBSMagritteReport ? Is it yours or is it
> some magritte extension for Bootstrap?
It is a Twitter Boostrap styled (with TBS classes) Magritte Report.
Regards,
Esteban A. Maringolo
March 17, 2017
Re: Magritte extension
by Asbath Sama biyalou
On 17/03/2017 12:23, Mariano Martinez Peck wrote:
> Hi,
>
> Before a longer answer, what is TBSMagritteReport ? Is it yours or is
> it some magritte extension for Bootstrap?
It is a magritte extension for Bootstrap. Or which one are you using?
>
> Thanks,
>
> On Fri, Mar 17, 2017 at 3:54 AM, Asbath Sama biyalou
> <asamabiyalou(a)yahoo.com <mailto:asamabiyalou@yahoo.com>> wrote:
>
> Hello.
>
> I am using Magritte to generate reports for a pharo class. I want to
> customize generated components in order to have a better design.
>
> My class is Match
>
> Object subclass: #Match
> instanceVariableNames: 'date_match hour_match status actions
> stadium
> comments teams goals1 goals2 competition'
> classVariableNames: ''
> category: MyProject-Entity'
>
>
> Descriptions for some variables.
>
> Stadium is also a Class.
>
> Match>>descriptionStadium
> <magritteDescription>
> ^ MASingleOptionDescription new
> label: 'Stadium';
> priority: 305;
> accessor: #stadium;
> options: Team allStadiumsName;
> componentClass: TBSMagritteSelectListComponent;
> beRequired;
> yourself
>
>
> Match>>descriptionTeams
> <magritteDescription>
> ^ MAMultipleOptionDescription new
> label: 'Teams';
> priority: 805;
> accessor: #teams;
> options: Team allTeamsName;
> componentClass: MAMultiselectListComponent;
> yourself
>
>
> The generated component in the form is not very pretty. I want to have
> multiple checkbox.
>
>
> Match>>descriptionStatus
> <magritteDescription>
> ^ MASingleOptionDescription new
> label: 'Status';
> priority: 505;
> accessor: #status;
> options: #('Pas en cours' 'En Cours' 'Mi-temps' 'Terminé');
> componentClass: TBSMagritteSelectListComponent;
> yourself
>
>
> For the report I use the class SEMatchReport
>
> TBSMagritteReport subclass: #SEMatchReport
> instanceVariableNames: 'report'
> classVariableNames: ''
> category: 'MyProject-Components'
>
>
> SEMatchReport class>>from
> | report matchs commandColumn |
> matchs := Match selectAll.
> report:= self rows: matchs description: (self
> filteredDescriptionsFrom: matchs anyOne).
>
> commandColumn := MACommandColumn new.
>
> (SEMatchReport new session isSimpleAdmin)
> ifTrue: [
> report addColumn: (commandColumn
> addCommandOn: report selector: #editMatch: text:
> 'Modifier';
> yourself;
> addCommandOn: report selector: #addAction: text: 'Ajouter
> une action'; yourself ) ]
> ifFalse: [
> report addColumn: (commandColumn
> addCommandOn: report selector: #editMatch: text:
> 'Modifier';
> yourself;
> addCommandOn: report selector: #deleteMatch: text:
> 'Supprimer'; yourself;
> addCommandOn: report selector: #addAction: text: 'Ajouter
> une action'; yourself ) ].
>
> ^ report
>
> I want to put some bootstrapp icons near commandColumn actions. like
> pencil or delete on 'Supprimer'.
>
>
> SEMatchReport class>>filteredDescriptionsFrom: aMatch
> ^ aMatch magritteDescription select: [ :each | #(date_match
> hour_match stadium goals1 goals2 teams)
> includes: each accessor selector ]
>
> I notice that on the generated report on column stadium we have
> aStadium. We don't have the value (the name). I don't know how to
> mention it in the filtered descriptions.
>
> Change the color of lines in the report, etc. All that things.
>
> Sorry for the bad english.
>
> Thanks.
>
> Asbath
>
>
>
>
> --
> Mariano
> http://marianopeck.wordpress.com
Asbath
March 17, 2017