LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 04-20-2010, 09:09 PM   #1
cola
Senior Member
 
Registered: Sep 2007
Location: Dhaka,Bangladesh
Distribution: Debian
Posts: 1,031

Rep: Reputation: 63
How to open Emacs in maximized window?


Every time i open Emacs window,it opens with a
width=(monitor-width)/2;
height=(3/4)*(monitor-height)

I click the maximized icon every time.
How can i set the maximized emacs window as default?
 
Old 04-20-2010, 09:18 PM   #2
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,066
Blog Entries: 11

Rep: Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910
Let me google this for you ...
 
Old 04-20-2010, 09:33 PM   #3
cola
Senior Member
 
Registered: Sep 2007
Location: Dhaka,Bangladesh
Distribution: Debian
Posts: 1,031

Original Poster
Rep: Reputation: 63
Done adding these lines in .emacs
Code:
(defun toggle-fullscreen ()
  (interactive)
  (x-send-client-message nil 0 nil "_NET_WM_STATE" 32
                         '(2 "_NET_WM_STATE_MAXIMIZED_VERT" 0))
  (x-send-client-message nil 0 nil "_NET_WM_STATE" 32
                         '(2 "_NET_WM_STATE_MAXIMIZED_HORZ" 0))
)
(toggle-fullscreen)
 
Old 10-19-2010, 08:23 PM   #4
metaposter
LQ Newbie
 
Registered: Oct 2010
Posts: 1

Rep: Reputation: 0
Quote:
Originally Posted by cola View Post
Done adding these lines in .emacs
Code:
(defun toggle-fullscreen ()
  (interactive)
  (x-send-client-message nil 0 nil "_NET_WM_STATE" 32
                         '(2 "_NET_WM_STATE_MAXIMIZED_VERT" 0))
  (x-send-client-message nil 0 nil "_NET_WM_STATE" 32
                         '(2 "_NET_WM_STATE_MAXIMIZED_HORZ" 0))
)
(toggle-fullscreen)
The above code used to work perfectly, but in emacs 23.1 it somehow conflicts with the option to turn off the toolbar.

Any suggestions? (and there's no need to google it for me, I have)
 
Old 10-19-2010, 09:46 PM   #5
sycamorex
LQ Veteran
 
Registered: Nov 2005
Location: London
Distribution: Slackware64-current
Posts: 5,811
Blog Entries: 1

Rep: Reputation: 1191Reputation: 1191Reputation: 1191Reputation: 1191Reputation: 1191Reputation: 1191Reputation: 1191Reputation: 1191Reputation: 1191
Quote:
Originally Posted by metaposter View Post
The above code used to work perfectly, but in emacs 23.1 it somehow conflicts with the option to turn off the toolbar.

Any suggestions? (and there's no need to google it for me, I have)
What's wrong with simple "emacs -fs"?

or actually you need "emacs -mm"

Last edited by sycamorex; 10-19-2010 at 09:48 PM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
TwinView: want maximized window on [B]one[/B] monitor. pingu Linux - Hardware 0 10-25-2005 03:13 AM
Adjust KDE Maximized Window Size elempoimen Linux - Software 2 11-08-2004 06:19 PM
how to cause a program in kde to start up in a maximized window zensufi Linux - Newbie 2 08-05-2004 01:05 AM
running emacs in su mode wont open x window true_atlantis Linux - Software 2 05-05-2004 01:05 AM
Display is horizontally smaller than a maximized window oulevon Slackware 7 11-26-2003 06:41 PM


All times are GMT -5. The time now is 10:45 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration