Home Download Buy Blog Forum Support

Toggle Read Only of a Buffer

Toggle Read Only of a Buffer

Postby axxl on Tue Sep 18, 2012 5:37 pm

Hi all.

I've implemented an easy plugin for Sublime Text 2. It's my first plugin and I hope, that it helps some people who haven't implemented it for themself.

It's called toggle-readonly and allows you to toggle the active view/buffer as readonly. It doesn't change the file parameters in the file system it only changes the read only property of the buffer.

So it's a very small and handy plugin which calls:

Code: Select all
sublime.View.set_read_only(value)


You can set this with a mouse-click on the buffer-tab, the open file menu and on the edit-area of the buffer itself.

Unfortunetaly it's not available via the Package Control yet, I'll change that later...

You can download it here: https://github.com/AxxL/sublime-toggle-readonly

What I would like to have is a change of the buffer-tab. Some change of the buffer-text or a change of the color of the tab. Maybe later. Credits: Some forum post where this topic was discussed. *g*.

Have fun.
axxl
 
Posts: 3
Joined: Tue Sep 18, 2012 5:29 pm

Re: Toggle Read Only of a Buffer

Postby Xaapyks on Thu Sep 27, 2012 3:48 pm

Hi, dowloaded this via package manager.
It doe snot seem to work, I can still edit my buffers after I click on toggle.
Moreover the toggle readonly option never gets checked.
Xaapyks
 
Posts: 34
Joined: Tue Apr 17, 2012 8:33 am

Re: Toggle Read Only of a Buffer

Postby axxl on Tue Oct 30, 2012 8:36 pm

Sorry for the huge delay.

I didn't manage yet to bring this package to the Package Control. So please download it here: https://github.com/AxxL/sublime-toggle-readonly

Thank you.
AxxL
axxl
 
Posts: 3
Joined: Tue Sep 18, 2012 5:29 pm

Re: Toggle Read Only of a Buffer

Postby Xaapyks on Fri Nov 09, 2012 11:26 am

Hi,

OK, I think I installed this : https://github.com/reflog/toggle-readonly which does not work.

I installed from github archive, it works :)

Thanks
Xaapyks
 
Posts: 34
Joined: Tue Apr 17, 2012 8:33 am


Return to Plugin Announcements

Who is online

Users browsing this forum: Yahoo [Bot] and 14 guests