VDXOEDS757ISV5KM5AUFZDFH223CHQB4FK3TQOQ75CDDJAPLCFQQC K5UKK5UVQBJN5Q27LLMJ7YQKENNHZOARPJQCJQOXQ4KFMKLINELQC 564RK5FW46AHODXU7LMSGA5LQND5SIFQTZMBFEKYEA3KGMED4JBAC FXI74QCLOZ4BS7UVZ3U2PE3LOL7MX3FWGHZCTGH3DYFXGTXVVIRAC 5YGO6JX5WTBNIRW2LKLJF7EE7Z5UNXAMLG24AUV5BK227S4AI4IQC U46N4W3QLSD5F7DNP6VB43CEE3OA2PJFLGNUG3MZ7EMNTFSUIP6AC 5FWVELA5XU72JOLKVJMIIEFUIFPJQD2MEQQZVGLB3PMNVJPJT2PAC KEFZWDCOCLPTLSZJKRV4VYAHRITV5T33YKG2VGT332YAUCOBS3EAC JGESC375DNF2CAB7ZOCSC45X5CGZVOXHSVCN643B3YHTRZRG6CIQC EMBBTRXDTL6DYNYUHOIZ2BXRCBS3BM6BPPZ4YLJAONG4K7DRSKNAC DASHC4CFQJQXKA2JXE4ONGBL5D53GZA25QQOB7MWM54YS2MNCGKAC LLKIX6AHIV5UDCHQWKQNY4SK2KCQ2CM2K7BRKH4D3PFVUDFDMZEQC KTSXR2MUTVMBEU7BGN5CHXL5UP6PPA6TTHN4CON7T67YWGZB72VAC AVTNUQYRBW7IX2YQ3KDLVQ23RGW3BAKTAE7P73ASBYNKOHMQMH5AC 7CLGG7J277QZGMNOVFEXBX6DRETCVK7GH66HJ7BYOBMPHTJCDFMAC 3QNOKBFMKBGXBVJIRHR2444JRRMBTABHE4674NR3DT67RRM2X6GAC AD34IX2ZSGYGU3LGY2IZOZNKD4HRQOYJVG5UWMWLXJZJSM62FFOAC PX7DDEMOBGPVK3FXKK5XEPG24CJXZSVW67DLG2JZZ5E77NVEAA3AC function source.detect_filetype(filename)-- assume logs have a unicode box character up top on the first linelocal infile = App.open_for_reading(filename)if infile == nil thenerror("file '"..filename.."' not found")endfor line in infile:lines() doif line:find('\u{250c}') or line:find('\u{2518}') thenreturn 'log_browser'elsereturn 'edit'endendreturn 'edit'end-- tenon auger side is already open; expand edit side as wellfunction source.expand_edit()-- temporarily disable resize--? print('disabling resize')love.handlers.resize = function() endRestore_resize_at = App.getTime() + 0.5-- use whole windowApp.screen.height = Display_height-100App.screen.width = Display_width--? App.screen.width = Display_width-100 -- for when I want to see prints on a window belowApp.screen.flags.resizable = trueApp.screen.flags.minwidth = math.min(App.screen.width, 200)App.screen.flags.minheight = math.min(App.screen.width, 200)love.window.setMode(App.screen.width, App.screen.height, App.screen.flags)--log_browser.make_room_for_edit()end
if chord == 'C-l' then--? print('C-l')Show_log_browser_side = not Show_log_browser_sideif Show_log_browser_side thenApp.screen.width = Log_browser_state.right + Margin_rightelseApp.screen.width = Editor_state.right + Margin_rightend--? print('setting window:', App.screen.width, App.screen.height)love.window.setMode(App.screen.width, App.screen.height, App.screen.flags)--? print('done setting window')returnend
Log_browser_state = edit.initialize_state(Margin_top, Margin_right, App.screen.width-Margin_right, Editor_state.font_height, Editor_state.line_height)Log_browser_state.filename = arg[1]
Log_browser_state = edit.initialize_state(Margin_top, Editor_state.right + Margin_right + Margin_left, (Editor_state.right+Margin_right)*2, Editor_state.font_height, Editor_state.line_height)Log_browser_state.filename = 'log'
if Show.spokecone == nil thenexpand_spokecone()initialize_spokecone{line.filename}Editor_state.right = App.screen.width/2 - Margin_right--? print('spokecone right', Editor_state.right)Show.spokecone = trueelseif line.filename ~= Editor_state.filename thenedit.switch_to_file(line.filename)
if line.filename ~= Editor_state.filename thensource.switch_to_file(line.filename)
App.open_for_reading = function(filename) return io.open(filename, 'r') endApp.open_for_writing = function(filename) return io.open(filename, 'w') end
App.open_for_reading =function(filename)local result = love.filesystem.newFile(filename)local ok, err = result:open('r')if ok thenreturn resultelsereturn ok, errendendApp.open_for_writing =function(filename)local result = love.filesystem.newFile(filename)local ok, err = result:open('w')if ok thenreturn resultelsereturn ok, errendend