Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Disabling the auto-hiding of scroll bars on Lion

Tags:

cocoa

In Mac Lion, the scroll bar hides itself after a few seconds if no activity occurs. I have written an apple script to modify that behavior. I have to turn on the radio button every time my app launches. My question is, I have a cocoa application. Is it possible to keep the scroll enabled for the application always with out having to change the settings in system preferences.I don't want to enable for all the other apps always. And is the only way via the applescript. Or is there a defaults write to enable the scroll bars in lion ?.

like image 676
Prashant Avatar asked Dec 13 '11 05:12

Prashant


People also ask

How do I stop the scroll bar from disappearing?

Click Start > Settings. Under Windows Settings, scroll down, and then click Ease of Access > Display. Scroll down, and then set Automatically hide scroll bars in Windows to Off.

How do I keep scroll bars visible?

To always show the scrollbar, you need to enable a setting in Windows Settings. For that, press Win+I to open Windows Settings and go to Accessibility > Visual effects. Then, Toggle the Always show scrollbars button to turn it on.

Why is the scrollbar hidden from view in Macos?

A. In an attempt to streamline the user interface, Apple's Safari browser for the Mac has scroll bars that can disappear from view if you are not actively scrolling through a web page.


1 Answers

I don't know about a defaults key to set up the style.

When you change the Appearance preference panel's "Show scroll bars", all the NSScrollView instances are notified and receive a setScrollerStyle: with the new style (through the NSPreferredScrollerStyleDidChangeNotification notification).

You can achieve the same result by explictly calling setScrollerStyle: on the NSScrollView with the NSScrollerStyleLegacy scroller style.

like image 137
Laurent Etiemble Avatar answered Oct 19 '22 01:10

Laurent Etiemble