~rabbits/left

e81e1ff9bfbf92e14bd43a1c232d52d52839a936 — neauoire a month ago 2c0f1b0
Implemented theme support
1 files changed, 35 insertions(+), 7 deletions(-)

M src/main.tal
M src/main.tal => src/main.tal +35 -7
@@ 118,14 118,15 @@
	#0004 DUP2 .widget/y0 STZ2 #0010 ++ .widget/y1 STZ2

	;untitled-txt ;new-file JSR2

	( init scroll ) #0000 ;scroll-to JSR2
	( init body ) ;document/body ;select-addr JSR2

	#00 .textarea/highlight STZ
	
	#21 ;draw-filepath JSR2
	#0000 .Screen/width DEI2 #0018 #01 ;line-hor JSR2
	( defaults )
	#00 .textarea/highlight STZ
	#0000 ;scroll-to JSR2
	;document/body ;select-addr JSR2
	;redraw JSR2

	( theme support )
	;load-theme JSR2

BRK



@@ 348,6 349,7 @@ RTN
	&escape ( key -- )
		POP
		RESET-SELECTION
		;load-theme JSR2
	BRK

	&erase ( key -- )


@@ 759,6 761,15 @@ RTN

( Drawing )

@redraw ( -- )

	#0000 .Screen/width DEI2 #0018 #01 ;line-hor JSR2
	#21 ;draw-filepath JSR2
	;draw-widget/memory JSR2
	;draw-textarea JSR2

RTN

@draw-short ( x* y* addr* color -- )
	
	STH


@@ 1090,6 1101,23 @@ RTN

RTN

@theme-txt ".theme $1

@load-theme ( -- )

	;theme-txt .File/name DEO2 
	#0006 .File/length DEO2 
	#fffa .File/load DEO2

	.File/success DEI2 #0006 !! ,&ignore JCN
		#fffa LDA2 .System/r DEO2
		#fffc LDA2 .System/g DEO2
		#fffe LDA2 .System/b DEO2
		;redraw JSR2
		&ignore

RTN

( snarf )

@cut-snarf ( -- )