Re: [Pharo-users] Roassal 2 disable browser and vis. animations

2016-08-27 Thread Peter Uhnak
On Sat, Aug 27, 2016 at 12:04:00PM +0200, Robert Kuszinger wrote: > > Anyway, on windows it crashed many times (On WIndows I downloaded this: > http://moosetechnology.org/res/download/moose_suite_6_0-win.zip) The VM is not particularly stable even on linux when it comes to FreeType and Cairo. Co

Re: [Pharo-users] [Moose-dev] [ann] pillar support in gtinspector

2016-08-30 Thread Peter Uhnak
On Tue, Aug 30, 2016 at 07:50:10AM +0200, Offray Vladimir Luna Cárdenas wrote: > Hi, > > > On 29/08/16 21:47, Yuriy Tymchuk wrote: > > [...] > > > > > > > It pains me that we are editing Pillar in outside tools, and now we > > > should no longer have to do that. Of course, this is not the most

Re: [Pharo-users] Spec Label is Black on Dark theme

2016-08-30 Thread Peter Uhnak
On Tue, Aug 30, 2016 at 10:16:03PM +0200, Nicolai Hess wrote: > 2016-08-30 20:01 GMT+02:00 Brad Selfridge : > > > How does one change Spec labels so that they don't show as black on Dark > > Theme but do show as black on standard Pharo theme? > > > > > > > Looks like ListModel should overwrite #d

Re: [Pharo-users] BitArray and BooleanArray ?

2016-09-01 Thread Peter Uhnak
On Thu, Sep 01, 2016 at 07:45:45PM +0800, Ben Coman wrote: > I don't know the answer but I assume you a looking for a memory > efficient way of storing booleans. So perhaps the Bit Field layouts > discussed here [1] may be of interest considering the recent > introduction of Slots to Pharo. Other

Re: [Pharo-users] Spec Text Emphasis

2016-09-01 Thread Peter Uhnak
On Thu, Sep 01, 2016 at 09:18:47PM -0700, Sean P. DeNigris wrote: > Is there a way to change the emphasis of Spec text (TextModel/TextInputModel, > or even LabelModel - I would trade edit-ability for styling)? LabelModel has #emphasis: LabelModel new emphasis: #(bold); label: 'bol

Re: [Pharo-users] Spec Text Emphasis

2016-09-02 Thread Peter Uhnak
On Fri, Sep 02, 2016 at 06:40:01AM -0700, Sean P. DeNigris wrote: > > > > Peter Uhnak wrote > > TextInputFieldModel will most likely require #whenBuiltDo: and Morphic > > hacking. > > That is unfortunate. As a subclass, and conceptually in the model, it should

Re: [Pharo-users] letsencrypt smalltalkhub ?

2016-09-15 Thread Peter Uhnak
Not enough manpower, I asked about this before, but it's not a priority. It was "good" enough until now, and with move to git it probably won't matter for much longer. Also let's encrypt isn't just about getting a cert... you need to fully automate updating the certs (which occurs every three mon

Re: [Pharo-users] Spec: Class pop list code completion

2016-09-23 Thread Peter Uhnak
Something like this? TextInputFieldModel new enableGlobalsCompletion; openWithSpec On Thu, Sep 22, 2016 at 12:04:50PM -0700, Brad Selfridge wrote: > Is there a way in Spec to pop a list widget that contains class names when > entering a partial class name in a test field, (like G

Re: [Pharo-users] Small "code" editor example for improving a GUI

2016-10-06 Thread Peter Uhnak
On Thu, Oct 06, 2016 at 10:41:10AM -0500, Offray Vladimir Luna Cárdenas wrote: > Hi, > > I would like to create some GUI that would be essentially a text > area field plus some buttons. The idea is to support > > - Font size increasing/decreasing. > > - Syntaxt highlighting for markup languages.

Re: [Pharo-users] Spec: DropList question

2016-10-10 Thread Peter Uhnak
You can just provide `nil` as the first option, e.g. ui := DynamicComposableModel new. ui instantiateModels: #(select DropListModel). ui select items: #(nil a b c); displayBlock: [ :each | each ifNil: [ '' ] ifNotNil: #asString ]. layout := SpecLayout composed add: #sele

Re: [Pharo-users] CodeGenerator, your opinions?

2016-10-18 Thread Peter Uhnak
Hi Hernan, I wrote some time ago two basic code generators (both in Pharo) from UML-ified FAMIX for a particular user (so there are some domain-specific patterns), one for Pharo syntax ( https://github.com/OpenPonk/class-editor/blob/master/docs/code-generation/uml-to-code.md ) and one for VW sy

Re: [Pharo-users] CodeGenerator, your opinions?

2016-10-18 Thread Peter Uhnak
On Tue, Oct 18, 2016 at 02:24:28AM -0300, Hernán Morales Durand wrote: > - A Spec UI generator. Oh, and Stephan did CRUD(e) Spec generator http://forum.world.st/ANN-SpecGenerator-easy-CRUD-applications-with-Spec-td4889624.html Peter

[Pharo-users] image shrinking and cleanup

2016-10-22 Thread Peter Uhnak
Hi, I know that I can cleanup the image with `Smalltalk cleanUp: true except: {} confirming: false.`, however that doesn't seem to help much. My guess is that there are some objects that the system is permanently unable to GC, however I have no idea how to find them (or even where to begin the

Re: [Pharo-users] Progress Bar with unknown state or showing animated gifs

2016-11-15 Thread Peter Uhnak
Hmm, thanks. I can write it myself, that's not a problem. I am just surprised that there is no native support/lib... I'll see if I can do something about it. Peter On Fri, Nov 11, 2016 at 07:01:26PM +, Dimitris Chloupis wrote: > You can take a look at how I do seconds indicator in my Chrono

[Pharo-users] NeoCSVWriter automatic quotes

2016-11-25 Thread Peter Uhnak
Hi, is it/would it be possible to modify NeoCSVWriter to add quotes only where necessary? So only if the written value contains the separator (is there any other case that would require the quotes?). Thanks, Peter

Re: [Pharo-users] NeoCSVWriter automatic quotes

2016-11-25 Thread Peter Uhnak
rator ]) ifTrue: [ writeStream nextPut: $"; nextPutAll: string; nextPut: $" ] ifFalse: [ writeStream nextPutAll: string ] ``` Peter On Fri, Nov 25, 2016 at 07:35:29PM +0100, Pet

Re: [Pharo-users] NeoCSVWriter automatic quotes

2016-12-05 Thread Peter Uhnak
On Fri, Nov 25, 2016 at 09:38:42PM +0100, Sven Van Caekenberghe wrote: > Peter, > > > On 25 Nov 2016, at 19:35, Peter Uhnak wrote: > > > > Hi, > > > > is it/would it be possible to modify NeoCSVWriter to add quotes only where > > necessary? So only i

[Pharo-users] accessing local/instance variables with metalinks

2016-12-05 Thread Peter Uhnak
Hi, what is the best way to access variables from within a metalink? for example I have a message send `surface clear` and I want to change it to `surface clear: trachelCanvas color`. I can use #instVarNamed: ``` MetaLink new metaObject: [ :object | (object instVarNamed

Re: [Pharo-users] 6.0 vm crash in FreeTypeFace

2016-12-21 Thread Peter Uhnak
This bug resurfaced after switch to Spur about a year ago. I envy you that you ran into that only now. :) (my favorite crashes for FT is during saving the image...) P On Wed, Dec 21, 2016 at 12:49:23PM -0300, Johan Fabry wrote: > Hi all, > > I’d like to report a vm crash of the 6.0 vm in a 5.0

Re: [Pharo-users] About Git

2017-01-15 Thread Peter Uhnak
I find these endless git vs monticello discussions confusing and pointless. Maybe we can hang Q&A list somewhere on pharo website to point to? Because git is getting increased traction in Pharo, so the same questions and endless discussions will popup over and over again. 1. Some people here ar

Re: [Pharo-users] STON encoding of slashes

2017-01-18 Thread Peter Uhnak
On Wed, Jan 18, 2017 at 11:11:06AM +0100, Christophe Demarey wrote: > > > Le 18 janv. 2017 à 09:51, Sven Van Caekenberghe a écrit : > > > > Hi Christophe, > > > >> STON toString: 'g...@github.com:foo/bar.git’ => > >> ''g...@github.com:foo\/bar.git’' > >> It used to be ''g...@github.com:foo/bar

Re: [Pharo-users] STON encoding of slashes

2017-01-18 Thread Peter Uhnak
ls like an arbitrary restriction for STON; would STON benefit from dropping this requirement and instead only worry about good smalltalk object representation? (And leave JSON to NeoJSON or something.) Peter > > On 18 Jan 2017, at 15:25, Peter Uhnak wrote: > > > >

Re: [Pharo-users] STON encoding of slashes

2017-01-19 Thread Peter Uhnak
nary)) Thanks! Peter > > Peter > > > >>> On 18 Jan 2017, at 15:25, Peter Uhnak wrote: > >>> > >>> On Wed, Jan 18, 2017 at 11:11:06AM +0100, Christophe Demarey wrote: > >>>> > >>>>> Le 18 janv. 2017

[Pharo-users] Couple grafoscopio notes

2017-01-19 Thread Peter Uhnak
Hi, I've started playing around with grafoscopio, I am happy that I can finally organize all those little scripts and not lose them all the time. :) However there are couple of issues and notes I've ran into (don't worry about fixing them in any timely fashion, it is not blocking me) 1. For sa

[Pharo-users] is PetitParser eager by default?

2017-01-20 Thread Peter Uhnak
Is PetitParser eager by default? I've used PetitParser countless times so I am really baffled why this doesn't work str := 'a0b'. #any asParser star, #digit asParser, #any asParser star parse: str. -> PPFailure (input expected at: 3) Thanks, Peter

[Pharo-users] Tools for easy subtext extraction from text

2017-01-20 Thread Peter Uhnak
Hi, what are the tools available from easier text extraction? The input is unstructured text, but I want to extract portion from it. I am not looking for an engineered approach (writing a parser or something), but something that can be done quickly by hand (i.e. interactively). For example I h

Re: [Pharo-users] is PetitParser eager by default?

2017-01-20 Thread Peter Uhnak
ing for this in the debugger (because I remember there was some extension related to PetitParser) and completely missed it in the playground. > >> Am 20.01.2017 um 15:24 schrieb Peter Uhnak : > >> > >> Is PetitParser eager by default? > >> > >> I&#x

Re: [Pharo-users] singleton trait

2017-01-21 Thread Peter Uhnak
On Sat, Jan 21, 2017 at 11:19:24AM +0100, stepharong wrote: > Pay attention that Singleton should not be about access but time. > > If you can by adding on instance variable avoid to need a singleton > then it means that it was not a singleton. > > A singleton is often: >you **CANNOT** ha

Re: [Pharo-users] Tools for easy subtext extraction from text

2017-01-21 Thread Peter Uhnak
On Sat, Jan 21, 2017 at 02:01:59PM +0100, Denis Kudriashov wrote: > Hi. > > 2017-01-20 16:15 GMT+01:00 Peter Uhnak : > > > In Ruby it is dead simple: > > str[/\[(.*)\]/,1].hex # "=> 37" > > > > I always wondering when people think it is dead simp

Re: [Pharo-users] super super

2017-01-21 Thread Peter Uhnak
Out of curiosity, wouldn't it be better to temporarily duplicate the code in your class and talk with the upstream owner? (That would be my usual approach.) Peter On Sat, Jan 21, 2017 at 06:04:12PM +0100, Hilaire wrote: > Agree on the hook. However the super class are not mine. Not an ideal > s

Re: [Pharo-users] Tools for easy subtext extraction from text

2017-01-21 Thread Peter Uhnak
On Sat, Jan 21, 2017 at 07:09:19PM +0100, Denis Kudriashov wrote: > 2017-01-21 17:09 GMT+01:00 p...@highoctane.be : > > > I collected some content about that and wanted to do something about it > > but, yeah, it got on the backburner. > > > > This is currently just the extract of the package comme

[Pharo-users] Xtreams docs (previously: Tools for easy subtext extraction from text)

2017-01-21 Thread Peter Uhnak
gt; > On Sat, Jan 21, 2017 at 3:08 PM, Peter Uhnak wrote: > > > On Sat, Jan 21, 2017 at 02:01:59PM +0100, Denis Kudriashov wrote: > > > Hi. > > > > > > 2017-01-20 16:15 GMT+01:00 Peter Uhnak : > > > > > > > In Ruby it is dead simple: >

Re: [Pharo-users] Tools for easy subtext extraction from text

2017-01-22 Thread Peter Uhnak
> Check some Perl code from a few years ago and come back with terseness and > readability arguments. Yeah, sure. I've been using Perl years ago. ;) When you are using it actively its very compact syntax is very cool once it becomes habitual; but of course Perl is write-only language. But we ar

[Pharo-users] loading Icerberg repo with dependencies

2017-02-05 Thread Peter Uhnak
Hi, I finally started to move to Pharo 6, so now I can play with Icerberg... my question is: how can I load a repository with all its dependencies? In other words... can I tell Icerberg that for the given Ice Repository to execute BaselineOf? Or is the use case: 1. use metacello to load proj

[Pharo-users] visualizing ConfigurationOf dependencies with GTInspector?

2017-02-05 Thread Peter Uhnak
Hi, maybe I was dreaming but I thought I saw somewhere that GTInspector could show the dependencies and groups in ConfigurationOf classes. Does something like that exist? (Obviously when I inspect any such class it doesn't show it). Thanks, Peter

Re: [Pharo-users] visualizing ConfigurationOf dependencies with GTInspector?

2017-02-07 Thread Peter Uhnak
ers, > Doru > > > > > On Feb 5, 2017, at 4:51 PM, Peter Uhnak wrote: > > > > Hi, > > > > maybe I was dreaming but I thought I saw somewhere that GTInspector could > > show the dependencies and groups in ConfigurationOf classes. Does somethi

[Pharo-users] Depending on MetaRepo instead of the target repo

2017-02-12 Thread Peter Uhnak
Hi, would it make sense to take configurations from metarepos instead directly from the source? And more imporantly: would be considered bad practice for users to do it right now? E.g. spec project: 'Magritte' with: [ spec className: #ConfigurationOfMagritte3;

[Pharo-users] getting real changes from RB refactoring

2017-02-12 Thread Peter Uhnak
Hi, is there some filter that will reject RB changes that actually do not do anything? I.e. applying them would have no effect (same method code, class, inst var exists, ...). For methods I can do reject: [ :each | each oldVersionTextToDisplay = each textToDisplay ] for adding classes I had t

Re: [Pharo-users] Depending on MetaRepo instead of the target repo

2017-02-13 Thread Peter Uhnak
> I meant, can a Baseline be stored in / operate from a mcz file, without a > Configuration? > I thought git made Baselines feasible since git takes care of versioning. Git takes care of the versioning, so the Baseline is really just a baseline, like it would be in a ConfigurationOf.

Re: [Pharo-users] Trait Searchability

2017-02-13 Thread Peter Uhnak
Traits are instances of class Trait, so you can do `Trait allInstances`. Peter On Mon, Feb 13, 2017 at 11:52:03AM -0800, Sean P. DeNigris wrote: > Forgive me if I'm missing something obvious, but how does one browse Traits > in the system for inspiration when creating a new one? > > > > -

Re: [Pharo-users] GitFiletree on Pharo 6

2017-02-13 Thread Peter Uhnak
On Mon, Feb 13, 2017 at 09:04:40PM +, Dimitris Chloupis wrote: > hey guys I was wondering where I can find the metadata less version of > GitFiletree, the one without the meta data that caused the merge confilcts > > Anyone knows ? GitFileTree uses metadata-less format by default; if you hav

[Pharo-users] expanding Pharo window to left and Window positioning

2017-02-15 Thread Peter Uhnak
Hi, what rules govern window positioning? I have a dual monitor setup and and sometimes extend the Pharo window over both of them; for some reason however World submorphs (all Windows) are locked to the left side, which is what I am dragging, so all the windows move to the secondary screen. I

Re: [Pharo-users] [ANN] Pharo Association: Join or Renew now!

2017-02-16 Thread Peter Uhnak
On Tue, Feb 14, 2017 at 03:17:42PM +0100, Marcus Denker wrote: > Hi, > > The new Pharo Association website is up and running for some month. > > If you are a member, it will bug you once a year to renew. Maybe there should be information that the membership (and fee) is automatic due to contri

Re: [Pharo-users] [State Machine] Implementation for pharo

2017-02-16 Thread Peter Uhnak
Hi, there's to my knowledge: * Grafeo http://oohito.com/nqthm/grafeo * StateMachine http://smalltalkhub.com/#!/~sbragagnolo/StateMachine (available in catalog) * LRP has state machines https://github.com/jfabry/LiveRobotProgramming * OpenPonk has state machines https://openponk.github.io/ Peter

[Pharo-users] changing font size in Spec TreeModel or FastTable Tree

2017-02-25 Thread Peter Uhnak
Hi, how can I change the font size of either (or both) Spec TreeModel or FastTable's tree? The font size is by default taken from the StandardFonts defaultFont, but I see no option to change it anywhere for _a specific tree only_. (Also odd that both use #defaultFont and not #listFont). Thank

Re: [Pharo-users] Fwd: GSoC 2017: Pharo Consortium has been accepted as a mentor organization!

2017-02-27 Thread Peter Uhnak
Congratulations! p.s. I think my name was there from last year (I didn't have time for this this year), so if you encounter it anywhere, feel free to remove it. Peter On Mon, Feb 27, 2017 at 06:07:18PM +0100, Serge Stinckwich wrote: > Great news ! > > Thank you Jigyasa, Uko, Peter and Alex fo

Re: [Pharo-users] 4 new chapters for new book on OOP and Design

2017-02-27 Thread Peter Uhnak
Hi Stef, I also noticed this but thought the problem was on my end. _All PDFs_ (books, mooc, ...) here https://ci.inria.fr/pharo-contribution/view/Books do not work in my Google Chrome (version 57). PDFs on different sites work fine. Looking at console I see some errors related to content secu

Re: [Pharo-users] suggestions mini-pane shut up

2017-02-28 Thread Peter Uhnak
1. Open settings 2. Type in quality 3. Uncheck nautilus plugin (or remove the plugin via top-right corner of nautilus window -> plugins manager -> remove QA) Peter On Tue, Feb 28, 2017 at 03:16:31PM +0100, Raffaello Giulietti wrote: > I'm using the latest "official" release, namely Pharo 5. I h

Re: [Pharo-users] spotting methods with TODO, FIXME, etc. comments?

2017-03-01 Thread Peter Uhnak
On Wed, Mar 01, 2017 at 06:53:16PM +0100, Raffaello Giulietti wrote: > Hi community, > > many IDEs for other language usually offer a way to annotate methods > with special comments like "TODO ...", "FIXME ...". Such methods can > then be later retrieved easily in task lists and selected by simple

Re: [Pharo-users] [Pharo-dev] [ANN] Regex Tester Tool for Pharo

2017-03-02 Thread Peter Uhnak
On Thu, Mar 02, 2017 at 09:20:12AM +0100, Esteban Lorenzano wrote: > > > On 1 Mar 2017, at 22:40, stepharong wrote: > > > > > > And I think that his remark makes sense. I was wondering if we should not > > ressurect > > the RePlugin to make sure that users can use perlish regexp and do not fee

Re: [Pharo-users] [Pharo-dev] [ANN] XML Metadata Interchange (XMI) for Pharo

2017-03-02 Thread Peter Uhnak
We spoke briefly on Tuesday. I need to take a look (also at his EMF generator) and see how the tools could benefit from each other. I think it could simplify some of my code or streamline the use of it. (Also I have about a billion code generators at the moment with small differences... so I wi

Re: [Pharo-users] customizing veryDeepCopy

2017-03-02 Thread Peter Uhnak
Thanks, I'll look at those. Peter On Thu, Mar 02, 2017 at 05:20:25PM -0300, Esteban A. Maringolo wrote: > I implemented our own copier based on how Morph does it, with our own > copy/deep selectors. > The copier has the option of which classes to copy and which to use > the same (it is, no copy).

[Pharo-users] why is concat of Symbols a string?

2017-03-04 Thread Peter Uhnak
Hi, why is the concatenation of symbols a string? e.g. #desc, #Name -> 'descName' this means that I have to always wrap in parentheses and recast, or stream it, e.g. (#desc, #Name) asSymbol -> #descName Symbol streamContents: [ :s | s << #desc; << #Name ] -> #descName both of which introduce

Re: [Pharo-users] why is concat of Symbols a string?

2017-03-05 Thread Peter Uhnak
eed to concatenate symbols and get a symbol out > > of it, you can define a new method in Symbol to do what you want. > > > > For example: > > > > Symbol >> ,, arg > > ^ (self , arg) asSymbol > > > > Then > > > > #foo ,, #bar > > > >

Re: [Pharo-users] why is concat of Symbols a string?

2017-03-06 Thread Peter Uhnak
>> immutability contract. > >> > >> As a thought experiment, what could be the problem with adding > >> > >> Symbol >> , arg > >>^ (self , arg) asSymbol > >> > >> ? > >> > > > > Aside from the infinite r

Re: [Pharo-users] Pharo Spur 64 VM

2017-03-08 Thread Peter Uhnak
On Tue, Mar 07, 2017 at 10:20:10AM +0100, Raffaello Giulietti wrote: > probably most of the developers related to Pharo use macOS Last time (~two years ago) I asked it was about ~1/3 each platform http://www.strawpoll.me/4001583/r (also I didn't make a distinction between desktop and server, so

[Pharo-users] Spec way to embed something into Scrollable Wrapper

2017-03-11 Thread Peter Uhnak
Hi, is there a Spec way to take something and embed it into scrollable pane? I haven't seen anything like that in Spec itself (List/Tree that has scrollbar has it on Morphic side); but maybe there is a way to embed Spec inside some Morph and then embed the Morph back into Spec? Obviously that'

[Pharo-users] Roassal IdentityGroup regression?

2017-03-13 Thread Peter Uhnak
Hi, apparently there used to be RTIdentityGroup (and Collection>>asIdentityGroup) in Rossal, but I can't find any mention of it http://forum.world.st/AST-visualization-with-Roassal-td4840243.html did it vanish on its own (bug) or was that a deliberate choice (feature)? Peter

Re: [Pharo-users] [Moose-dev] Re: Roassal IdentityGroup regression?

2017-03-13 Thread Peter Uhnak
Thanks! Peter On Mon, Mar 13, 2017 at 07:20:04PM -0300, Alexandre Bergel wrote: > Hi Peter! > > No idea why this code was removed. > The class is back now. > > Alexandre > > > On Mar 13, 2017, at 6:58 PM, Peter Uhnak wrote: > > > > Hi, > > &g

[Pharo-users] MetaLinks with arbitrary number of arguments

2017-03-15 Thread Peter Uhnak
Hi, is it possible to create a metalink on arbitrary amount of arguments? Right now the metaObject and selector must have the same number of arguments, e.g. MetaLink new metaObject: [ :object :selector :args | ... ]; selector: #value:value:value; arguments: #(object sele

Re: [Pharo-users] MetaLinks with arbitrary number of arguments

2017-03-15 Thread Peter Uhnak
On Wed, Mar 15, 2017 at 10:49:51AM +0100, denker wrote: > > > On 15 Mar 2017, at 10:35, Peter Uhnak wrote: > > > > Hi, > > > > is it possible to create a metalink on arbitrary amount of arguments? > > > > Right now the metaObject and selector mus

Re: [Pharo-users] Creating Dates before/after Daylight Saving Time change

2017-03-26 Thread Peter Uhnak
Date>>year:month:day: (respectively Date>>#starting:) is using DateAndTime to specify the start, and DateAndTime will of course differ. To me it seems like someone was reusing implementation; because Date normally shouldn't have/care about time information, and yet it subclasses from Timespan c

[Pharo-users] using UFFI in non-crashing way

2017-03-26 Thread Peter Uhnak
Hi, is it possible to use UFFI and avoid crashing the image when the called code segfaults? In other words, can I somehow wrap the call and throw in-image Exception/Error on failure instead of the whole thing crashing? Or is the only way to do that have the called thing running as a separate a

Re: [Pharo-users] using UFFI in non-crashing way

2017-03-26 Thread Peter Uhnak
On Sun, Mar 26, 2017 at 05:45:04PM +0200, Esteban Lorenzano wrote: > > > On 26 Mar 2017, at 15:40, Peter Uhnak wrote: > > > > Hi, > > > > is it possible to use UFFI and avoid crashing the image when the called > > code segfaults? > > > > In

[Pharo-users] Morphic component to display images/pictures

2017-03-30 Thread Peter Uhnak
Hi, do we have a Morphic/Brick/whatever component for displaying pictures/images in Pharo? The "best" I found was GTInspector extension on PNG files, which provides scrollbars, however I would like to also have: 1) zooming with mousewheel (now it scrolls vertically) 2) dragging the image aroun

Re: [Pharo-users] Morphic component to display images/pictures

2017-04-01 Thread Peter Uhnak
The mooc challenge (no #4) doesn't really address any of the things I am interested in (the result is the same as what inspector can currently do). Spec has ImageModel, but that doesn't even have scrollbars... anyway... I am currently refactoring Spec interpreter and after that I would like to

Re: [Pharo-users] How childrenBlock: in TreeModel works

2017-04-01 Thread Peter Uhnak
Hi, I wanted to point you to the new Spec book ( http://files.pharo.org/books-pdfs/spec/2017-01-23-SpecBooklet.pdf ), but apprently it's not there. Many Spec widgets have examples accompanying them, so always check class side (not for all though). For TreeModel you can see couple there - good

[Pharo-users] why is adding instance variables so slow?

2017-04-12 Thread Peter Uhnak
Hi, does anyone know why adding instance variables is so slow? I did some quick benchmarks (see below), resulting in more than order of magnitude speed difference between having it in the class definition and adding it later. In fact it is still much faster to delete the class and then recreat

Re: [Pharo-users] Methods & Classes using the command line.

2017-04-13 Thread Peter Uhnak
This should be similar to having the code in playground and executing it at once. I guess it's more forgiving. What I sometimes do to work around it is to store the created class into variable, or use symbol and asClass cast e.g. cls := Object subclass: #TestClass. cls compile:'meth'. or Obj

[Pharo-users] best practices for using external files for testing

2017-04-15 Thread Peter Uhnak
Hi, is there a common/best practice for using external files in tests? In my specific case I am interested in git-based projects, where I have a big (~1MB) file stored in repository and I would like to use it in my tests. For GitFileTree project I could presumably use the following to access it

Re: [Pharo-users] Exporting Packages to Cincom Smalltalk (VisualWorks)

2017-04-17 Thread Peter Uhnak
Some time ago I hacked together a very simple thing that generates VW XML from code represented in Moose/UML... I guess you could use it as a starting point: https://github.com/OpenPonk/class-editor/tree/master/repository/UML-CodeGenerator.package/UCMVWXmlExporter.class Also take a look at SIF (

Re: [Pharo-users] best practices for using external files for testing

2017-04-17 Thread Peter Uhnak
ed and fetch only that but I have not felt the > need so far to do this. > On Sat, 15 Apr 2017 at 19:52, Peter Uhnak wrote: > > > Hi, > > > > is there a common/best practice for using external files in tests? > > > > In my specific case I am interested in

Re: [Pharo-users] How childrenBlock: in TreeModel works

2017-04-17 Thread Peter Uhnak
I guess something like this could work... ``` d := { Dictionary with: #n -> 'whatever' with: #d -> { Dictionary with: #a -> #AA with: #b -> #BB. Dictionary with: #c -> #CC with: #d -> #DD }.

Re: [Pharo-users] Exporting Packages to Cincom Smalltalk (VisualWorks)

2017-04-18 Thread Peter Uhnak
inted me to Roassal export classes, which does > something similar to the code you pointed me to (yours seems more > tidy). > > Thanks again, > > Esteban A. Maringolo > > > 2017-04-17 12:57 GMT-03:00 Peter Uhnak : > > Some time ago I hacked together a very simple th

Re: [Pharo-users] best practices for using external files for testing

2017-04-18 Thread Peter Uhnak
download and extract all test files in the Configuration > and then use a method in abstract test class to access test files. > Cheers, > > Hernán > > > 2017-04-15 13:52 GMT-03:00 Peter Uhnak : > > > Hi, > > > > is there a common/best practice for using ex

Re: [Pharo-users] Octal multiplication

2017-04-23 Thread Peter Uhnak
On Sun, Apr 23, 2017 at 06:13:42AM -0700, nacho wrote: > Hello, > This could sound like a dumb question, it may be. > If I print: > 8r3 * 8r3 I get 9. > It seems that Pharo converts first to decimal and then performs the > multiplication. How do I get the result in octal which should be 8r11? #pr

Re: [Pharo-users] Hot to retrieve values from Nested Dictionaries

2017-04-24 Thread Peter Uhnak
Maybe we could introduce `@` message, so one can chain them and then even execute keyword without parenthesis Dictionary>>@ aKey ^ at: aKey dict @ 'key1' @ 'key2' @ 'key3' dict @ 'key1' @ 'key2' @ 'key3' select: [ :each | ... ] I'm always adding this when hacking around, maybe we could

[Pharo-users] improving audio/video quality of pharo days recordings

2017-04-25 Thread Peter Uhnak
Hi, we had a small discussion on discord about improving the audio/video quality of recordings of past pharo days, where many recordings are really hard to see (or completely unreadable), or the presenter is really hard to understand (especially if they speak quietly or have a strong accent).

[Pharo-users] Epicea vs RB refactorings

2017-04-26 Thread Peter Uhnak
Hi, I'm under the impression that Epicea is supposed to replace RB refactorings at some point. If that is true, is it currently possible to build refactorings by hand? For example in RB I often do: ``` model := RBNamespace new. model defineClass: ('<1s> subclass: #<2s>instanceVariableNames:

Re: [Pharo-users] Sending byte array in a JSON format

2017-04-26 Thread Peter Uhnak
Maybe the content is not properly stored in the JSON on github' side? But you can use base64 in `accept:` to make it work. json := STONJSON fromString: (ZnClient new url: 'https://api.github.com/gists/5503544'; accept: 'application/vnd.github.v3.base64+

Re: [Pharo-users] Sending byte array in a JSON format

2017-04-26 Thread Peter Uhnak
It is also possible that ZnEasy is doing some encoding transformations that breaks it; after all, you are retrieving binary data as text data, so encoding should be applied on it. Peter On Wed, Apr 26, 2017 at 04:50:04PM +0200, Sven Van Caekenberghe wrote: > I am puzzled by how they actually en

Re: [Pharo-users] MOOC offline download

2017-04-27 Thread Peter Uhnak
Everything is also on github so you can clone it locally https://github.com/SquareBracketAssociates/PharoMooc On Thu, Apr 27, 2017 at 11:50:22PM +0800, Ben Coman wrote: > I was just chatting with someone with limited Internet who was looking to > odownload the mooc files [1] for use offline. Doe

Re: [Pharo-users] Spec Adapter Advice

2017-04-27 Thread Peter Uhnak
Hi Rob, I guess the best resource at the moment is to just look at existing adapters. But here are some thoughts to get you started: (Spec) ComposableModel has as its widget (Spec) Adapter Adapter has as its widget the actual visual component, which currently means Morphic. The simplest examp

Re: [Pharo-users] Spec Adapter Advice

2017-04-28 Thread Peter Uhnak
ause it feels like all the right pieces > are there and a lot of this could mostly be "just work" once I get going. > > Thanks again, > > Rob > > On Thu, Apr 27, 2017 at 6:04 PM, Peter Uhnak wrote: > > > Hi Rob, > > > > I guess the best resour

Re: [Pharo-users] Spec Adapter Advice

2017-04-28 Thread Peter Uhnak
ave new SpecInterpreter (it took me two weeks and I've created two extra tools to understand the old one and there are still some special exceptions), so then we can rethink the way it is done. Peter > > 2017-04-28 0:04 GMT+02:00 Peter Uhnak : > > > Hi Rob, > > > &g

Re: [Pharo-users] Spec Adapter Advice

2017-04-29 Thread Peter Uhnak
On Fri, Apr 28, 2017 at 04:20:57PM -0400, Rob Rothwell wrote: > Hi Peter, > > However, I have discovered by creating new ComposableModel, WindowModel, > and MorphicWindowAdapter classes that even the SpecInterpreter itself is > hard-wired to use Morphic. No, it is not. It has hard wired bindings

Re: [Pharo-users] Spec Adapter Advice

2017-04-29 Thread Peter Uhnak
On Sat, Apr 29, 2017 at 09:22:46PM +0200, Denis Kudriashov wrote: > Hi > > 2017-04-29 20:36 GMT+02:00 Peter Uhnak : > > > No, it is not. It has hard wired bindings from certain names to morphic > > adapters, but only if you don't actually specify the target calss. &

Re: [Pharo-users] Spec Adapter Advice

2017-04-29 Thread Peter Uhnak
On Sat, Apr 29, 2017 at 09:24:28PM +0200, Denis Kudriashov wrote: > 2017-04-29 20:36 GMT+02:00 Peter Uhnak : > > > > > > > You can set the bindings on the class side, but I currently don't see a > > way > > > to say "open this spec using these

Re: [Pharo-users] Put FTTableMorph layout into ComposableModel lyout

2017-05-02 Thread Peter Uhnak
Hi, you can look at chapter 9.1 in the Spec Booklet http://files.pharo.org/books-pdfs/spec/2017-01-23-SpecBooklet.pdf it shows how to integrate any morph inside a Spec Model. But did you look at FastTabelModel? It uses FTTableMorph underneath, so maybe it can already do what you need. Peter

Re: [Pharo-users] Epicea vs RB refactorings

2017-05-03 Thread Peter Uhnak
anyone? On Wed, Apr 26, 2017 at 11:19:07AM +0200, Peter Uhnak wrote: > Hi, > > I'm under the impression that Epicea is supposed to replace RB refactorings > at some point. > > If that is true, is it currently possible to build refactorings by hand? > >

Re: [Pharo-users] [ANN] git migration tool

2017-05-06 Thread Peter Uhnak
Hi, the code generated from the migration tool can be used by both Iceberg and GitFileTree (because they both use FileTree format to store the code). So you can just migrate your code, install Iceberg and you're good to go. I can write a blog post about this I guess... (maybe I could add the mi

Re: [Pharo-users] Intro to git-only Pharo

2017-05-10 Thread Peter Uhnak
Hi, this is my (=not canonical) perspective On Wed, May 10, 2017 at 07:56:19AM +0200, Joachim Tuchel wrote: > Hi guys, > > please forgive me if this mail is a sign of ignorance. I am not a > regular Pharo user and one of the reasons for this is that I didn't > like most of the source management

Re: [Pharo-users] Ston feature idea?

2017-05-17 Thread Peter Uhnak
Just curious... why don't you use MSE? Peter On Wed, May 17, 2017 at 12:44:58PM +0200, Sven Van Caekenberghe wrote: > Hi Cyril, > > This can be done quite easily in STON, I will make you a small example and > add it to the unit tests. > > Sven > > > On 17 May 2017, at 12:19, Cyril Ferlicot D

[Pharo-users] YAML parser (2017)

2017-05-29 Thread Peter Uhnak
Hi, do we have a working parser for YAML? There's PPYAMLGrammar (in PetitParser), however it doesn't seem to work in Pharo 6 at all (not even tests pass). In Pharo 5 the tests are green, but using it on YAML content still fails... with small fix I managed it to "pass", however the output seems

Re: [Pharo-users] Porting Transducers to Pharo

2017-05-31 Thread Peter Uhnak
You can also give a try to use SIF (Smalltalk Interchange Format) https://github.com/peteruhnak/sif There is parcel file in VW subfolder, and docs here: https://github.com/peteruhnak/sif/blob/master/docs.md I've used it about year ago for some small code exchanges; but of course you will have

[Pharo-users] snap morphs/windows to each other when dragging

2017-06-04 Thread Peter Uhnak
Hi, is it possible to tell windows to "snap" to other windows when dragging? So e.g. when I am dragging Playground window, it will try to snap side by side with a close-by another window, so they don't overlap (unless I e.g. press shift or something). Thanks, Peter

Re: [Pharo-users] Saving selected changes in Monticello

2017-06-05 Thread Peter Uhnak
Komitter could indeed help you, see https://www.peteruhnak.com/blog/2016/08/12/fine-grained-committing-and-extending-nautilus/ Peter On Mon, Jun 05, 2017 at 08:27:23AM +0200, serge.stinckw...@gmail.com wrote: > Kommiter available in default image allows you do cherry pick quite easily. > > Envo

Re: [Pharo-users] Bloc/Brick/Spec

2017-06-05 Thread Peter Uhnak
* Bloc - low level library (think basic shapes, rectangles, ...) * Brick - widget library on top of Bloc akin to the widget part of Morphic (buttons, checkboxes, ...) * Spec - UI framework with adaptable backend; currently using Morphic as a backend, however once Bloc/Brick matures, Bloc/Brick wi

Re: [Pharo-users] Playground auto-save?

2019-06-19 Thread Peter Uhnak
Hi Hilaire, this is a known problem. I've been losing code to Playground for years. (e.g. using undo (ctrl+z) is a good way to lose code) What helps a lot is to look into pharo-local/play-cache directory (you can open Spotter and type in "pharo-local" (without quotes)) which contains a log of pro

[Pharo-users] XML Writer not pretty printing

2018-08-14 Thread Peter Uhnak
Hi, I am trying to output a pretty printed document, but it seems that the configuration is being ignored doc := ' ' parseXML. String << [ :stream | doc printOn: stream beforeWritingDo: [ :writer | writer enablePrettyPrinting; enablePlatformSpecificLineBreak. writer formatter indentStri

<    1   2   3   >