autoscroll(3tk)

πŸ“¦
version 0.9 Β· 2 versions
, in debian trixie, ubuntu questing, ubuntu resolute, ubuntu stonking

πŸ’– autoscroll β€” bestie edition πŸ’–

okay so this is the autoscroll page from the tklib crew, and it's literally about scrollbars that know when to show up and when to ghost. main character energy fr.


✨ NAME ✨

autoscroll β€” the way it provides for a scrollbar to be automatically mapped and unmapped as needed πŸŽ€


🌸 SYNOPSIS 🌸

package require Tcl

package require autoscroll ?1.1?

::autoscroll::autoscroll scrollbar

::autoscroll::unautoscroll scrollbar

::autoscroll::wrap

::autoscroll::unwrap

πŸ¦‹ DESCRIPTION πŸ¦‹

This package lets scrollbars get mapped and unmapped as needed, depending on the size and content of the scrollbars' scrolled widget. slay. but heads up bestie: the scrollbar has to be managed by either pack or grid β€” other geometry managers are not supported. sorry πŸ’…

When it's managed by pack: any geometry changes made in the scrollbar's parent, between the time a scrollbar is unmapped and when it's mapped again, will be lost. and it is an error to destroy any of the scrollbar's siblings while the scrollbar is unmapped. 😭 When it's managed by grid: if anything becomes gridded in the same row and column the scrollbar occupied, it will be replaced by the scrollbar when it gets remapped. not a vibe, just facts.

This package may be used on any scrollbar-like widget, as long as it supports the set subcommand in the same style as scrollbar. If the set subcommand is not used, then this package will have no effect. πŸ’€


🌈 the commands, one by one 🌈

  • ::autoscroll::autoscroll scrollbar β€” Arranges for the already existing scrollbar scrollbar to be mapped and unmapped as needed. glow up time ✨
  • ::autoscroll::unautoscroll scrollbar β€” Returns the named scrollbar to its original static state. putting it back, no notes 🫢
  • ::autoscroll::wrap β€” Arranges for all scrollbars created after this command is run to be automatically mapped and unmapped as needed. every future scrollbar, blessed πŸ‘‘
  • ::autoscroll::unwrap β€” Turns off the automatic autoscrolling of all new scrollbars. Does not effect existing scrollbars β€” like, the ones already out there keep doing their thing. πŸ™ˆ

and here's the little example that lives right here, exactly as it is:

text .t -yscrollcommand ".scrolly set"
scrollbar .scrolly -orient v -command ".t yview"
pack .scrolly -side right -fill y
pack .t -side left -fill both -expand 1
::autoscroll::autoscroll .scrolly

πŸ’€ BUGS, IDEAS, FEEDBACK πŸ’€

This document, and the package it describes, will undoubtedly contain bugs and other problems. it's giving "we know". 😭 Please report such in the category autoscroll of the Tklib Trackers [http://core.tcl.tk/tklib/reportlist](http://core.tcl.tk/tklib/reportlist). Please also report any ideas for enhancements you may have for either package and/or documentation. we wanna hear it fr fr 🫢


⭐ KEYWORDS ⭐

scroll, scrollbar


ngl, that's the whole page. mapped, unmapped, iconic. periodt. πŸ’…

this has been autoscroll(3tk) from the tklib girlies, version 1.1, dated 1.1 β€” mwah, take care of ur scrollbars bestie πŸŽ€πŸ’–βœ¨

πŸ“¦ where this page comes from