> Would it be possible/easy to copy that script and make a version that applies 
> a "select all” and then performs the content delete?

"Select all" sounds like an unnecessary action, let's just try to replace the 
text
```lua
local iLines = geany.height()
local iEOL = geany.scintilla("SCI_GETEOLMODE")
local sLE
if iEOL == 0 then
  sLE = "\r\n"
elseif iEOL == 1 then
  sLE = "\r"
elseif iEOL == 2 then
  sLE = "\n"
else
  return
end
local sTmp = ""
for i = 1, iLines - 1 do
  sTmp = sTmp .. sLE
end
geany.text(sTmp)
```

> Would it be possible to add this functionality to a separate copy of the 
> script you provided?

Try to replace
```lua
if n1 > n2 then geany.select(start) end
```
on this
```lua
start = geany.rowcol(line + 1, 0)
geany.select(start)
```

-- 
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/discussions/4047#discussioncomment-11322618
You are receiving this because you are subscribed to this thread.

Message ID: <geany/geany/repo-discussions/4047/comments/[email protected]>

Reply via email to