Re: [racket] Racket macros that run on files

2012-11-14 Thread Patrick Mahoney
Thank you for the responses Vincent and Neil. Neil, thanks for the information here-I will meditate on this and how to utilize it. -Patrick On 4 November 2012 22:34, Neil Van Dyke wrote: > So you would like to be able to do things like rename an identifier, > change "(if X Y)" to "(and X Y)",

[racket] Racket macros that run on files

2012-11-01 Thread Patrick Mahoney
Hello all, Is there a package out there wherein a user can specify a syntax transformer, and the macro expansions are used to replace invocations of the syntax transformer in the source syntax, within the source file itself. I guess I'm envisioning a sort of syntax aware find and replace. Thanks,

Re: [racket] Typed Racket vs. Haskell

2012-09-20 Thread Patrick Mahoney
Hey all, One feature of typed racket that makes translation between untyped and typed code somewhat less simple than adding or removing type signatures is that certain forms require rewriting/alteration of the untyped form itself. Others allow stand-alone declaration of the types prior to the for

[racket] Adding contracts to frtime/core/dv.rkt produces errors

2012-08-23 Thread Patrick Mahoney
Hello all, I am attempting to do some further work on the frtime lang. Specifically, I'm working out of a branch based on the pull request https://github.com/plt/racket/pull/138 - this new branch is the frtime-contracts branch. Link to frtime-contracts branch: https://github.com/paddymahoney/racke

Re: [racket] Moving frtime to racket: animation demos hang - require assistance salvaging work on this branch

2012-08-21 Thread Patrick Mahoney
, Matthias Felleisen wrote: > > Can you create a git pull request? -- Matthias > > > > On Aug 21, 2012, at 8:13 PM, Patrick Mahoney wrote: > > Upon changing the 3 occurrences of make-hash in lang-core.rkt to > make-hasheq, the demos/ animations begin to animate. At this moment

Re: [racket] Moving frtime to racket: animation demos hang - require assistance salvaging work on this branch

2012-08-21 Thread Patrick Mahoney
while since I've looked at > > this code, but I'll try to investigate a bit more and see what might > > be going wrong. > > > > Cheers, > > Greg > > > > On Fri, Aug 17, 2012 at 12:51 PM, Patrick Mahoney > > wrote: > >> Hello All

Re: [racket] Are there Racket structures similar to Common Lisp's?

2012-08-17 Thread Patrick Mahoney
I like the idea of having optional keyword arguments available in struct field construction. In many cases, I find it more declarative upon reading the code, though input takes longer. I just tend to recall names better than constructor/argument order. It could help to understand the code if the st

[racket] Moving frtime to racket: animation demos hang - require assistance salvaging work on this branch

2012-08-17 Thread Patrick Mahoney
Hello All, I have been working on updating the frtime collection to use the Racket lang rather than the mzscheme language. To this end, I forked on github and created a new branch frtime-to-racket, which can be found at: https://github.com/paddymahoney/racket.git This branch contains 36 commits.

Re: [racket] Racket development: Running/compiling from source rather than from a pre-built collection

2012-08-03 Thread Patrick Mahoney
t; https://github.com/takikawa/racket-dev-goodies/blob/master/plt-bin > > Vincent > > > At Tue, 24 Jul 2012 21:12:01 -0400, > Patrick Mahoney wrote: > > > > [1 ] > > [1.1 ] > > Hello again, > > > > I was able to resolve my problem. First

Re: [racket] Racket development: Running/compiling from source rather than from a pre-built collection

2012-07-24 Thread Patrick Mahoney
ctory Following linking to this location, the language declaration resolved to the frtime language within my github tree. Thanks all, -Patrick On 24 July 2012 18:52, Patrick Mahoney wrote: > Hello All, > > I forked the github Racket repo, and created a new branch in order to > update Frtim

[racket] Racket development: Running/compiling from source rather than from a pre-built collection

2012-07-24 Thread Patrick Mahoney
Hello All, I forked the github Racket repo, and created a new branch in order to update Frtime from the scheme or mzscheme #langs to Racket. This has been progressing well, until I ran into a small issue that I think likely affects most individuals working on Racket source for which collections ex

Re: [racket] idioms for abstracting over definitions

2012-05-08 Thread Patrick Mahoney
o how difficult it is to develop a good name for the generic function. However, in this case, I'm on board. Thank you for your time. -Patrick On 8 May 2012 09:23, Matthias Felleisen wrote: > > > On May 7, 2012, at 5:41 PM, Patrick Mahoney wrote: > > > #| > > Hello all

[racket] idioms for abstracting over definitions

2012-05-07 Thread Patrick Mahoney
#| Hello all, in a quest for greater concision, I'm looking for a way to abstract over the following code containing mostly definitions. Is there an accepted practice for abstraction over definition introduction?|# (define top-right-x (lambda (a-grid-plane a-cell) ;;The next three definitions a

Re: [racket] is-empty? on region% with no device-context.

2012-05-02 Thread Patrick Mahoney
:55, Patrick Mahoney wrote: > #|Hello All, > I'm attempting to ensure that shapes drawn onto a canvas don't overlap. In > order to do so, I attempted to use region% objects.| # > > #|Takes two rectangles, and tells whether they overlap as regions.|# > (define overlaps

[racket] is-empty? on region% with no device-context.

2012-05-02 Thread Patrick Mahoney
#|Hello All, I'm attempting to ensure that shapes drawn onto a canvas don't overlap. In order to do so, I attempted to use region% objects.| # #|Takes two rectangles, and tells whether they overlap as regions.|# (define overlaps? (lambda (rect-a rect-b) (define region-a (rectangle->region re

Re: [racket] Macros that expand to field and method definitions

2012-04-25 Thread Patrick Mahoney
get-body)))])) Somewhat like http://msdn.microsoft.com/en-US/library/w86s7x04%28v=vs.80%29.aspx, but with mandatory initialization expressions for each property. -Patrick On 25 April 2012 10:10, Asumu Takikawa wrote: > On 2012-04-25 03:19:46 -0400, Patrick Mahoney wrote: > >I'm l

Re: [racket] message-box too small to display title

2012-04-25 Thread Patrick Mahoney
http://bugs.racket-lang.org/query/?debug=&database=default&cmd=view+audit-trail&cmd=view&pr=12714+ *this may be related* -Patrick On 25 April 2012 12:15, Patrick Mahoney wrote: > Hello Matthew, > > Mr. Spier reports that he is using windows Vista. If the message-bo

Re: [racket] message-box too small to display title

2012-04-25 Thread Patrick Mahoney
Hello Matthew, Mr. Spier reports that he is using windows Vista. If the message-box code uses the message% class under the hood, then this is probably related to the bug I noted: problem report 12714 Thank you! -Patrick On 25 April 2012 12:01, Matthias Felleisen wrote: > > Strange. Works okay

[racket] Macros that expand to field and method definitions

2012-04-25 Thread Patrick Mahoney
#|Hello all, I'm looking to define a macro that extends the forms within a racket/class class%. In particular, I would like a form to define a C# like class language form property, that implements the getters and setters for an initialized field automatically. I'm guessing that someone has writte

[racket] Typed Racket and GUI development

2012-04-23 Thread Patrick Mahoney
Hello All, Is it currently possible to type gui elements racket/gui/base in typed racket? I'm interested in migrating a small gui app to typed racket, but there isn't a typed/racket/gui/base module. I guess what I am really looking to determine is whether it is going to be possible to type objects

Re: [racket] message-box too small to display title

2012-04-20 Thread Patrick Mahoney
Hello Mr. Spier, I ran into this issue recently-are you using racket on Windows out of curiosity? In short, I think you need to set auto-resize to #t explicitly upon init'ing your message. I submitted problem report 12714 to track this. #|Setting up the first frame and parent.|# (define parent1

Re: [racket] gui issue > frame updating control thread painter > questions about how to resolve the problem, attain eventual reactive semantics

2012-04-20 Thread Patrick Mahoney
abel "No x-pos yet."])) >> >> (define discover-x >> (new frame% >> [label "frame for noticing mouse evets and their current x >> coordinates"] >>[width 200] >> [height 200] >> [enabled #t])) >> >>

[racket] gui issue > frame updating control thread painter > questions about how to resolve the problem, attain eventual reactive semantics

2012-04-19 Thread Patrick Mahoney
#lang racket #|Hello all, I'm PMah. |# (require racket/gui/base) #|Problem: I have a message% control called x-pos parented by a frame% called parent1. I have a canvas% called canvas parented under frame% parent2. I would like x-pos to always show the current x coordinate of the mouse position ov