[racket] Does Racket GUI scale?
Hello,
I have to do a simple spreadsheet editor and I wonder
whether Racket suits my needs. The main challenge
is that the spreadsheet editor should be able to edit
tables as big as 1000x1000 or 10000x100 cells.
Here is a stub that I have done, using williams/table-panel
package from PLaneT: http://pastebin.com/aAjg2TZT
It initializes pretty slow and does the scrolling pretty slow
even with 20x10 cells, and 100x100 is already almost
impossible to work with, let alone 1000x1000 or 10000x100.
OK, I thought, maybe I should use the single canvas
(not separate controls) for the cells, and leave only
buttons as controls for rows and columns.
But having just 1000 buttons with a scrollbar turned out
to be slow enough:
#lang racket
(require racket/gui/base)
(define frame
(instantiate frame%
("Test")))
(define scrolling-panel
(new vertical-panel%
(parent frame)
(style '(auto-vscroll))))
(for ((i (in-range 1000)))
(new button%
(parent scrolling-panel)
(horiz-margin 0)
(vert-margin 0)
(label (number->string (+ 1 i)))))
(send frame resize 100 400)
(send frame show #t)
It takes considerable time to initialize, and the scrolling
is pretty much of a slide-show kind. Raising the
number to 10000 makes it a complete no-go.
So I am wondering whether there are hacks to speed
up the GUI that I am creating.
Best regards,
Dmitry