gg: resizable window option
							parent
							
								
									8b74c711c6
								
							
						
					
					
						commit
						a6aad880f7
					
				
							
								
								
									
										4
									
								
								Makefile
								
								
								
								
							
							
						
						
									
										4
									
								
								Makefile
								
								
								
								
							|  | @ -27,7 +27,7 @@ else | ||||||
| 	V_V=`git rev-parse --short HEAD`; \
 | 	V_V=`git rev-parse --short HEAD`; \
 | ||||||
| 	if [ $$VC_V != $$V_V ]; then \
 | 	if [ $$VC_V != $$V_V ]; then \
 | ||||||
| 		echo "Self rebuild ($$VC_V => $$V_V)"; \
 | 		echo "Self rebuild ($$VC_V => $$V_V)"; \
 | ||||||
| 		./v v.v; \
 | 		./v -o v v.v; \
 | ||||||
| 	fi) | 	fi) | ||||||
| endif | endif | ||||||
| 	rm -rf vc/ | 	rm -rf vc/ | ||||||
|  | @ -49,4 +49,4 @@ ifdef LINUX | ||||||
| endif | endif | ||||||
| 
 | 
 | ||||||
| selfcompile: | selfcompile: | ||||||
| 	./v v.v | 	./v -o v v.v | ||||||
|  |  | ||||||
|  | @ -44,7 +44,6 @@ fn generate_vh(mod string) { | ||||||
| 	for file in filtered { | 	for file in filtered { | ||||||
| 		mut p := v.new_parser_from_file(file) | 		mut p := v.new_parser_from_file(file) | ||||||
| 		p.scanner.is_vh = true | 		p.scanner.is_vh = true | ||||||
| 		println('kek $file') |  | ||||||
| 		p.parse(.decl) | 		p.parse(.decl) | ||||||
| 		for i, tok in p.tokens { | 		for i, tok in p.tokens { | ||||||
| 			if !p.tok.is_decl() { | 			if !p.tok.is_decl() { | ||||||
|  |  | ||||||
|  | @ -38,6 +38,7 @@ pub: | ||||||
| 	height    int | 	height    int | ||||||
| 	use_ortho bool | 	use_ortho bool | ||||||
| 	retina    bool | 	retina    bool | ||||||
|  | 	resizable bool | ||||||
| 
 | 
 | ||||||
| 	font_size int | 	font_size int | ||||||
| 	font_path string | 	font_path string | ||||||
|  | @ -70,6 +71,11 @@ pub mut: | ||||||
| pub fn new_context(cfg Cfg) &GG { | pub fn new_context(cfg Cfg) &GG { | ||||||
| 	mut window := &glfw.Window{!} | 	mut window := &glfw.Window{!} | ||||||
| 	if cfg.create_window { | 	if cfg.create_window { | ||||||
|  | 		if cfg.resizable { | ||||||
|  | 			glfw.window_hint(C.GLFW_RESIZABLE, 1) | ||||||
|  | 		} else { | ||||||
|  | 			glfw.window_hint(C.GLFW_RESIZABLE, 0) | ||||||
|  | 		}	 | ||||||
| 		window = glfw.create_window(glfw.WinCfg{ | 		window = glfw.create_window(glfw.WinCfg{ | ||||||
| 			title: cfg.window_title | 			title: cfg.window_title | ||||||
| 			width: cfg.width | 			width: cfg.width | ||||||
|  |  | ||||||
		Loading…
	
		Reference in New Issue