37a38,42 > --[FW] > local list_sessions = gui.list() > local list_ses_height = 80 > tab0:add(list_sessions, "bottom", list_ses_height) > --[/FW] 327a333 > local sessions_filename = props['SciteUserHome']..'\\sessions.lst' 356,357c362,369 < list_favorites:add_item(filename, current_path..filename) < table.insert(list_fav_table, current_path..filename) --- > --[FW] > -- list_favorites:add_item(filename, current_path..filename) > -- table.insert(list_fav_table, current_path..filename) > my_path=string.gsub(my_path,EscapeString(props["SciteUserHome"]),"$(SciteUserHome)") > my_path=string.gsub(my_path,EscapeString(props["SciteDefaultHome"]),"$(SciteDefaultHome)") > list_favorites:add_item(filename, my_path..filename) > table.insert(list_fav_table, my_path..filename) > --[/FW] 375a388,392 > --[FW] > for c in string.gfind(filename, "%$%(([^\)]*)%)") do > filename=string.gsub(filename,"%$%(([^\)]*)%)",props[c]) > end > --[/FW] 390a408,435 > --[FW] > local function Sessions_ListFILL() > local sessions_file = io.open(sessions_filename) > if sessions_file then > for line in sessions_file:lines() do > if line.len ~= 0 then > local caption = line:gsub('.+\\','') > list_sessions:add_item(caption, line) > end > end > sessions_file:close() > end > end > Sessions_ListFILL() > > list_sessions:on_double_click(function() > local idx = list_sessions:get_selected_item() > if idx == -1 then return end > local filename = list_sessions:get_item_data(idx) > --replace vars > for c in string.gfind(filename, "%$%(([^\)]*)%)") do > filename=string.gsub(filename,"%$%(([^\)]*)%)",props[c]) > end > --end replace vars > OpenFile(filename) > end) > --[FW] > 424a470,474 > --[FW] > local Lang2CodeStart ={ > ['Pascal']="implementation" > } > --[/FW] 466,467c516,535 < local textAll = editor:GetText() < -- output:ClearAll() --- > --[FW] > local CodeStart=Lang2CodeStart[Ext2Lang[props["FileExt"]]] > if CodeStart~=nil then > start=editor:findtext("^"..CodeStart.."$",SCFIND_REGEXP) > end > if start ~= nil then > startline = editor:LineFromPosition(start) + 1 > else > startline=0; > end > --print(startline) > s=editor:PositionFromLine(startline) > local textAll = '' > if editor.Length>0 then > textAll = editor:textrange(s, editor.Length - 1) > end > --local textAll = editor:GetText() > --[/FW] > > -- output:ClearAll() 470c538,541 < local line_number = editor:LineFromPosition(_start) --- > --[FW] > --local line_number = editor:LineFromPosition(_start) > local line_number = editor:LineFromPosition(_start+s) > --[/FW]