7 Commits

Author SHA1 Message Date
cqc
df39308b7a widgets are drawn via a ref'd data structure so we can maybe manipulate it 2021-08-17 23:35:48 -05:00
cqc
75417c7699 text editing and events 2021-08-15 15:44:05 -05:00
cqc
15efe3efdd new key handling and keybinding 2021-08-13 02:09:35 -05:00
cqc
2e1c66f7b6 pretty good 2021-08-10 23:31:52 -05:00
cqc
a4c10bbf57 hehe it's all inside the toplevel now 2021-08-10 20:45:06 -05:00
cqc
73d9260b1f output to draw_pp's ppf 2021-08-10 02:37:00 -05:00
cqc
58975feee5 fixed pane_*box 2021-08-10 01:50:57 -05:00
9 changed files with 1654 additions and 1524 deletions

View File

@ -1 +1 @@
profile = compact

1
.ocamlformat-ignore Normal file
View File

@ -0,0 +1 @@
init.ml

7
README
View File

@ -2,9 +2,4 @@
- `console/rootstore` must exist at `../rootstore` - `console/rootstore` must exist at `../rootstore`
$ dune exec ./main.exe $ dune exec ./boot.exe
Type in:
`#use "init.ml"`
Ctrl-Enter runs the command

View File

@ -1,6 +1,2 @@
let eval = (Topinf.init Format.std_formatter) Format.std_formatter in let eval = (Topinf.init Format.std_formatter) Format.std_formatter in
eval "#use \"init.ml\";;"; eval "#use \"init.ml\";;"

15
dune
View File

@ -13,24 +13,33 @@
tgls.tgles2 tgls.tgles2
wall wall
zed zed
lambda-term
irmin-unix irmin-unix
ocaml-compiler-libs.common ocaml-compiler-libs.common
ocaml-compiler-libs.bytecomp ocaml-compiler-libs.bytecomp
ocaml-compiler-libs.toplevel)) ocaml-compiler-libs.toplevel))
(executable (executable
(name test) (name boot)
(modes byte) (modes byte)
(modules test) (modules boot)
(link_flags (-linkall)) (link_flags (-linkall))
(libraries (libraries
lambda-term
topinf)) topinf))
(library (library
(name topinf) (name topinf)
(modes byte) (modes byte)
(modules topinf) (modules topinf)
(libraries (libraries
fmt fmt
tsdl
tgls.tgles2
wall
zed
lambda-term
irmin-unix
ocaml-compiler-libs.common
ocaml-compiler-libs.bytecomp
ocaml-compiler-libs.toplevel)) ocaml-compiler-libs.toplevel))

14
init.ml
View File

@ -1,14 +1,16 @@
(* $Id$ -*- tuareg -*- *) (* $Id$ -*- tuareg -*- *)
#directory "/home/cqc/p/pinephone/komm/komm/_build/default/.topinf.objs/byte";; #use_output "dune top | grep -v \"ocamltoplevel.cma\\|ocaml_toplevel.cma\\|topinf.cma\"";; (* grep to remove the topinf.cma which fuck this shit all up *)
open Topinf;; open Topinf;;
let print_directives () = let print_directives () =
Format.eprintf "directive_info_table:@."; Format.printf "directive_info_table:@.";
Hashtbl.iter (fun n _ -> Format.eprintf "\t%s@." n) Topinf.directive_info_table;; Hashtbl.iter (fun n _ -> Format.printf "\t%s@." n) Topinf.directive_info_table;;
#directory "+compiler-libs";; #directory "+compiler-libs";;
let print_modules () = let print_modules () =
Format.eprintf "Env.fold_modules:\n"; Format.printf "Env.fold_modules !Topinf.toplevel_env :\n";
Env.fold_modules (fun modname _ _ () -> Format.eprintf "\t%s@." modname) None !Topinf.toplevel_env ();; Env.fold_modules (fun modname _ _ () -> Format.printf "\t%s@." modname) None !Topinf.toplevel_env ();;
print_modules ();;
#use_silently "main.ml";;

1309
main.ml

File diff suppressed because it is too large Load Diff

1474
topinf.ml

File diff suppressed because it is too large Load Diff

View File

@ -3,7 +3,7 @@
(See module Translmod.) *) (See module Translmod.) *)
val getvalue : string -> Obj.t val getvalue : string -> Obj.t
val setvalue : string -> Obj.t -> unit val setvalue : string -> Obj.t -> unit
(* End accessors for table of toplevel value bindings that must be first in the module signature *) (* End of: accessors for table of toplevel value bindings that must be first in the module signature *)
val print_toplevel_value_bindings : Format.formatter -> unit val print_toplevel_value_bindings : Format.formatter -> unit
@ -22,4 +22,10 @@ type directive_fun =
type directive_info = { section : string; doc : string } type directive_info = { section : string; doc : string }
val add_directive : Misc.filepath -> directive_fun -> directive_info -> unit
val directive_info_table : (string, directive_info) Hashtbl.t val directive_info_table : (string, directive_info) Hashtbl.t
val ppf : Format.formatter ref
val eval : evalenv option ref