summaryrefslogtreecommitdiffstats
path: root/main.go
diff options
context:
space:
mode:
authorChristian Rocha <christian@rocha.is>2020-06-23 12:03:00 -0400
committerChristian Muehlhaeuser <muesli@gmail.com>2020-10-05 13:47:16 +0200
commitc954898009f8f5e229630cccbb73490c072c7965 (patch)
tree8962835ceb26f503eb2315db3b168ad328b3c57a /main.go
parent5b3feb41a2f28c181771160797381f45aca1d3eb (diff)
Add basic mouse wheel support to pager
Diffstat (limited to 'main.go')
-rw-r--r--main.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/main.go b/main.go
index 233ace3..b51ec1d 100644
--- a/main.go
+++ b/main.go
@@ -187,10 +187,12 @@ func executeArg(cmd *cobra.Command, arg string, w io.Writer) error {
// Run Bubble Tea program
p := ui.NewProgram(style, cfg)
p.EnterAltScreen()
+ p.EnableMouseCellMotion()
if err := p.Start(); err != nil {
return err
}
p.ExitAltScreen()
+ p.DisableMouseCellMotion()
// Exit message
fmt.Printf("\n Thanks for using Glow!\n\n")