Commit Graph

4631 Commits

Author SHA1 Message Date
Matthew Flatt
dfeb8956ed racket/draw, racket/gui: modernize contracts, mostly in documentation
Use `or/c' instead of `one-of/c', `#f' instead of `false/c'.

original commit: 2bdcdbb1970bc65625be295eac1f510b97d3df10
2012-04-06 18:51:10 -06:00
Robby Findler
4bee9aeb19 add splicing-syntax-parameterize to the default indentation prefs
original commit: a475c078e26dca8dcdb605fa1212125d4525c7ce
2012-04-05 17:34:45 -05:00
Matthew Flatt
8cff831246 racket/gui, win32: fix problem with modal dialogs
Although most events in other frames were blocked, it was
possible to bring other frames to the front and to select
menu items in other frames.

original commit: 9d563c786a71b621fcd2909c917b49939e0d11b0
2012-04-05 06:58:53 -06:00
Matthew Flatt
15cf494c3e racket/gui: fix reparent' with a pane%' target
original commit: 6afc9d5e8c354dbe444e6f8bf16c6a87c4bc7191
2012-04-03 18:36:28 -06:00
Matthew Flatt
2d667d8eac racket/gui: fix `slider%' range checking
Closes PR 12669

original commit: 3bf538923781dc132b9a30bc0eb49d43d20e8bb0
2012-04-02 15:25:47 -06:00
Asumu Takikawa
5793daf323 Fix docs for get-selected-text-color method.
original commit: 0f5f611f128bacdf991e89897386de191a1c93df
2012-03-31 00:43:43 -04:00
Asumu Takikawa
3364cd3fdd Fix requires to avoid circular dependencies.
original commit: d7fefc848bd734b2623014419052bb22819815fb
2012-03-30 23:34:34 -04:00
Robby Findler
6b7420df8f forgot the result contract
original commit: 8e35fd01a5d13219d2fc2adb955ed9dc24158bc7
2012-03-30 20:57:53 -05:00
Robby Findler
608168b0dc adjust DrRacket submodule-running options so the user
has more control over which ones get run

original commit: 4b57482298c51289c408aee0256b584b08357bf2
2012-03-30 16:42:34 -05:00
Robby Findler
878a7c1a12 add the #:validate argument to get-text-from-user
original commit: 92e874010587c1af3a95007d006b0c7d7aba1c21
2012-03-30 16:42:34 -05:00
Matthew Flatt
d4643b300a fix `record-dc%' problem with regions
Closes PR 12655

original commit: 4b36e708a352f92eda50b2dd108d569e2e391620
2012-03-28 06:26:58 -06:00
Robby Findler
2450c4ad0f be a bit more systematic with tabbing and magic square-bracket-ing for 'for's
also, add in for/sum and for/product

original commit: a1446a037b6dcf083a6e7edeefbc05b5e4a34cf2
2012-03-28 07:21:09 -05:00
Matthew Flatt
fc7b0420da racket/draw: add get-handle' to bitmap%'; add `make-handle-brush'
The `get-handle' method provides the underlying Cairo surface for
a bitmap, while the unsafe `make-handle-brush' function supports the
use of a Cairo surface as a `brush%'.

Also, add `racket/draw/unsafe/cairo-lib', which simplifies access
Cairo from external libraries. Documenting `racket/draw/unsafe/cairo'
might be better, but that's a lot more work.

original commit: 4f197f4ba944ee802e15fb3323f34a074e915db6
2012-03-27 18:14:26 -06:00
Robby Findler
46cd9ed627 added a test suite for DrRacket that checks to make sure the Dear Dr
starts up on all of the days that have easter eggs (well, except 7/2,
since that one is hard to interpose on and hasn't changed in a long
time)

original commit: 617df05ef7d43c04cfaf6978c52619e1865a4812
2012-03-26 15:43:56 -05:00
Robby Findler
eabea09e88 fix splash screen error handling code
original commit: b640b6b41c721bdbd70697e996dd8072a464da73
2012-03-26 15:43:55 -05:00
Robby Findler
018fd62d43 add a preference to control whether or not there is an extra
pixel of space in between lines in DrRacket.

This change is based on Matthew's experience having a look
at the font setup on the three platforms.

He writes:
>  * Mac OS X: the convention seems to be to add space between lines.
>   TextEdit, for example, looks like DrRacket: the maze has spaces.
>
>   (I can't find a font that makes the maze look right, actually, even
>   if I adjust the line spacing.)
>
>  * Windows: the convention seems to be that space is built into the
>   font. DrRacket (and SirMail) draw lines more sparsely than Notepad.
>
>   Perhaps consistent with the differing conventions, the height of
>   "Courier New" at 11-pixel size is 14 on Windows, 13 on Mac OS X.
>
>  * Unix: the convention seems to be to add space. DrRacket looks like
>   the default Terminal and Text Editor programs on Ubuntu.
>
>   The maze nevertheless looks right everywhere, because the glyphs
>   extend an extra pixel above the declared bounding box!

original commit: 0d6b82537776ad4bd850e3b7c5cc1bdaa209b865
2012-03-24 20:20:05 -05:00
Matthew Flatt
4d109759b7 more load[/use-compiled] handler fixes for submodules
Closes PR 12630

original commit: 415b1eabc4451285cffd0f2c5e37bfca3dc3312b
2012-03-13 14:31:40 -06:00
Matthew Flatt
cd76937049 try module+' in place of slice'
original commit: e01ebf6095682d9e8ac51d4ce8bf01bf14e9cfdc
2012-03-13 14:31:40 -06:00
Robby Findler
2da0f72492 small improvements to the memory usage for files opened in DrRacket.
Before this commit, opening collects/drracket/private/unit.rkt required
about 17.5 megabytes of memory and after this commit, it is down to
about 15 megabytes.

The precise measurement I did was to create a frame and a scheme:text%
object in it, record the result of current-memory-use, open the file,
and record current-memory-use again.

For comparison, using a text:standard-style-list% object instead of
the scheme:text% requires only about 4.1 megabytes. One difference
being that there are about 3x more snips (10,204 vs 33,901 (after the
commit)), since we have one snip for each region that has a different
color in the scheme:text version, and the text:standard-style-list has
no colors and thus about two per line (there are 5006 lines in the
file).

original commit: a7cb8fdc84f3b592c812468e5e7486d4f7d5bbb6
2012-03-10 20:18:49 -06:00
Matthew Flatt
618ab0567b no callback for `tab-panel%' tab additions and deletions
original commit: 97a64b1166315382945826c0fb6d654f95ed7f0b
2012-03-10 10:07:37 -07:00
Matthew Flatt
0f58af9a51 DrRacket default `module*' indentation
original commit: 54a441c0e376ace19d705a9fe9717253bd56f50b
2012-03-09 10:34:57 -07:00
Matthew Flatt
25aa68cf95 fix race condition on GetLastError() call
original commit: d74793a5f9956c44ff9ec4dbcdcf5b1ec17515f0
2012-03-09 10:34:56 -07:00
Matthew Flatt
9fecb1cd54 racket/sandbox: use `gui-available?' at sandbox creation
Previously, sandbox creation used `gui?', which is the result of
`gui-available?' at the time that `racket/sandbox' is instanited.
This change makes sandbox behavior less sensitive tothe order in
which modules `require'd into a program are intiantiated.

The change depends on a new `sandbox-make-namespace' default
function for `sandbox-namespace-specs'. The new function uses
either  `make-base-namespace' or `make-gui-namespace', depending
on whether the GUI library is available at that point.

A new `sandbox-gui-enabled' parameter can disable use of the
GUI library even if it is available.

The `gui?' binding is still exported for backward compatibility,
but it shouldn't be used anymore.

original commit: 5630a3a1cab8d7953bfbb290bd6ae63c84ead605
2012-03-02 07:47:16 -07:00
Asumu Takikawa
f9e4af3567 framework: add missing methods to interface and docs
The set-replace-start and get-replace-search-hit methods were
missing in the text:searchable<%> interface. The latter was
also undocumented.

original commit: 04f7bdbb021d1dbcac959eed439050abc36ee1b7
2012-03-01 13:17:48 -05:00
Eli Barzilay
c56a523200 Big newline at EOF scan.
original commit: f7c67b49a49a723534454ce561cd060e63889480
2012-02-29 00:28:11 -05:00
Robby Findler
d88dbed20c edit wxme docs to clarify the text-only? argument passed to read-snip
original commit: fffafbab184743c11fe2ae433374e67aefbe7e4f
2012-02-26 21:43:44 -06:00
Matthew Flatt
286e0527e7 fix problems with `record-dc%' and composition
Recorded clipping, transformations, and alpha didn't compose with
the target DC's existing clipping, transformations, and alpha.

original commit: f79e2b4ee0bbe6a7302f658e78155b11d9dd7db8
2012-02-26 22:13:01 -05:00
Matthew Flatt
9f45143c24 racket/draw: add `record-dc%'
original commit: 645ca02e927e2ef0bc9857bc3fa6cb3725bcdca8
2012-02-25 20:57:56 +00:00
Matthew Flatt
76320f0ea1 improvements to the bitmap docs
original commit: eb032c2fef1767e2c747555bc34bf2fbc66455b5
2012-02-23 07:12:22 -06:00
Robby Findler
90dc4e7829 fix a bug I thought I'd fixed a while back...?
original commit: d476d3f21a381d3ca092580ef7bfd2489cba81ee
2012-02-22 16:51:48 -06:00
Robby Findler
94be0ced5e add make-platform-bitmap
also: use it in pict's rendering and
remove redex's platform-specific font choice
(going back to using 'modern on all platforms)

closes PR 12554

original commit: 1945ff270962679e13f66131c5b3eb91cc1edb2f
2012-02-21 16:19:45 -06:00
Matthew Flatt
6e8c3e072b racket/draw: change font face name interpretation again
Treat a "face" as a font description only if it has a comma,
otherwise go back to treating it as a family name.

This change fixes the problem of parsing "Times New Roman"
as "Times New, Roman".

original commit: 530b35379830819f7de46c80dc9f9691a17fcc7b
2012-02-17 11:25:15 -07:00
Matthew Flatt
669232d35a fix test to not write to stderr
original commit: 08303d9db827a037db98df57833766cd073116db
2012-02-14 14:27:40 -07:00
Robby Findler
6878919906 Lost the snipclass with the name (lib "collapsed-snipclass.ss" "framework")
somewhere between 5.1.3 and 5.2.1. Bring it back.

closes PR 12563

original commit: eda4d294cc08a37fb1e94161fbd1fa9440381bdb
2012-02-14 11:26:20 -06:00
Matthew Flatt
bc8232d8c2 make an eventspace thread survive a break exception
When an eventspace is created, its thread implicitly calls
`yield'. It now effectively loops with `yield' and while
catching continuation aborts.

Closes PR 12566

original commit: 967372c23d9b68d011993435cc91e99e26616c20
2012-02-13 16:28:10 -07:00
Matthew Flatt
05101401af add test for bad missing-glyph handling
original commit: 573ce9492a254c67280168bc341ec733ccb1c1b4
2012-02-13 16:27:51 -07:00
Robby Findler
8af50844a0 clarify auto scrollbars & on-event interaction (ie, they don't interact)
original commit: f2d244cb1fd24cf4fc99a49f1d8f5d15f6e9fb43
2012-02-12 20:24:17 -06:00
Matthew Flatt
233cfe5643 win32: fix canvas% control border drawing
Use the system-supplied region to intersect with the
window region, so that drawng the border doesn't replace
the window content.

See also Kieron Hardy's post on the users' list, 2/7/12.

original commit: af62391c8cf8204b96299a0906e2e8656b921213
2012-02-11 08:45:32 -07:00
Matthew Flatt
5ee24043d5 racket/gui: fix refresh for right-aligned or centered paragraphs in text%
original commit: 6e01d1586a4b12de7fd0f9fe985a9dbdfa476d35
2012-01-30 11:01:18 -07:00
Matthew Flatt
43bf844f51 racket/gui: correct some casts in GUI bindings
original commit: 01dce002717564df1b0ba9da9e2179be420f7f9d
2012-01-23 11:20:21 -07:00
Matthew Flatt
0836e93973 gtk: fix problem wth window freeze & thaw
Closes PR 12496

Merge to 5.2.1

original commit: 484803a896eb8d1eb3ea46dcb1223fb21af24110
2012-01-19 16:20:45 -07:00
Robby Findler
0fad9040a0 make the tooltips for the drracket toolbar buttons go away when they
get any events (this shouldn't be necessary unless one gets lost
somehow, but apparently that can happen)

original commit: 3b2cf3f7a4bc4949fc5fa3f626f789ff983be64a
2012-01-19 12:14:35 -06:00
Robby Findler
92d21649fb adjust the names of the dot/neato binaries to be platform-specific
original commit: 71595a55e67f4701eae93bd60d52d785d83cef6f
2012-01-17 12:42:42 -06:00
Sam Tobin-Hochstadt
dc8edd7062 Refactor and improve fuzzy searching in completion.
original commit: e3609cdb3281993854f7ea57ae63b89be07f3d43
2012-01-13 14:39:05 -05:00
Robby Findler
57f229d37d fix call to message box to remove incorrect style flag
merge to the release branch, please

original commit: e067a4415a03ec6572135ce584a17050690873ca
2012-01-11 13:16:46 -06:00
Matthew Flatt
b7b8aff107 make draw-mem test more reliable
original commit: 7b4fd9b2758ab623ce278a62a62c4f7ab8107eb8
2012-01-09 16:08:28 -07:00
Robby Findler
bbde125b1e fixed bug in the way aug:keymap extracts the names
now it should return only the canonical names of the keybindings
(instead of potentially returning both the canonical and
non-canonicalized names)

original commit: 95ac3c86f789d6514a3a6c6a2f16d28f7d6f0ea9
2012-01-08 07:07:56 -06:00
Matthew Flatt
c280690be5 clarify docs on is-enabled?' and is-shown?'
original commit: 9389947f6ffbb297455c7532a008ca417a0114a0
2012-01-07 21:17:12 -07:00
Matthew Flatt
d80906a5c7 add on-subwindow-focus' to window<%>'
relevant to PR 12474

original commit: fd019a34787805021f9924bb7c9253966bf58f8e
2012-01-07 21:17:12 -07:00
Robby Findler
1c40749acf fix the not-a-language message so that the styles in the REPL are right
original commit: 950d165133768ac8fe500b7bfea5eb22f8d5286c
2012-01-06 20:59:34 -06:00