Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index Assistance Desktop Environments
  • Search

twinview: make laptop screen the primary screen?

Problems with GUI applications? Questions about X, KDE, Gnome, Fluxbox, etc.? Come on in. NOTE: For multimedia, go up one forum
Post Reply
Advanced search
16 posts • Page 1 of 1
Author
Message
breakerfall
Guru
Guru
Posts: 509
Joined: Sat Aug 02, 2003 11:13 pm
Location: Manchester, UK

twinview: make laptop screen the primary screen?

  • Quote

Post by breakerfall » Tue Jan 30, 2007 4:29 pm

Hi, I have twinview working quite nicely - in fact, I'm almost completely happy with the setup, however, there's just one hiccup I hope should be an easy fix.

When I startx (I'm running xfce4.4) from tty1, both screens startup, however, my taskbar and panel are on the TFT (the external screen connected to my laptop via VGA), in fact, the external screen is recognised as the primary screen. Apart from that, everything functions perfectly. I would just prefer to have the taskbar and panel on the laptop screen by default, just in case I decide to disconnect the external screen and don't want to restart X to have my laptop screen recognised as the default again.

Any ideas?

Thanks

[edit]
The relevant section of my xorg.conf

Code: Select all

Section "Monitor"
	Identifier   "Monitor0"
	VendorName   "Sony"
	Option       "UseEdidFreqs"   "1"
	ModelName    "Vaio notebook LCD"
        HorizSync    29.0 - 49.0
        VertRefresh  0.0 - 60.0
        Option       "DPMS"
EndSection

Section "Device"
	Identifier  "Card0"
	Driver      "nvidia"
	VendorName  "nVidia Corporation"
	BoardName   "Nvidia GeForce Go 7400"
	BusID       "PCI:1:0:0"
        Option      "NoLogo" "true"
        #Option      "TripleBuffer" "True"
#        Option      "RenderAccel" "true"
        Option      "backingstore" "true"
        Option      "AllowGLXWithComposite" "true"
        Option      "AddARGBGLXVisuals" "true"
EndSection

Section "Screen"
	Identifier "Screen0"
	Device     "Card0"
	Monitor    "Monitor0"
        Option     "metamodes" "1280x800_60 +0+0"
        DefaultDepth 24
	SubSection "Display"
		Depth     24
                Modes     "1600x1200" "1280x1024" "1024x768" "800x600" "640x480"
	EndSubSection
	Option     "TwinView"  "1"
	Option     "TwinViewOrientation"  "LeftOf"
	Option     "MetaModes"  "1280x800,1280x1024"
	Option     "Xinerama"  "1"
	Option     "UseDisplayDevice"  "DFP,CRT"
EndSection
Top
Dan
Veteran
Veteran
Posts: 1302
Joined: Tue Oct 25, 2005 3:04 pm

  • Quote

Post by Dan » Tue Jan 30, 2007 6:45 pm

use twinview or xinerama , probably dont want both, nvidia's twinview does its own xinerama.
unmask and install nvidia-settings- 1.0.20061102 and you can set some orientation in there.
- Failure is not an option. It's bundled with your software.
Top
krinn
Watchman
Watchman
User avatar
Posts: 7476
Joined: Fri May 02, 2003 6:14 am

  • Quote

Post by krinn » Tue Jan 30, 2007 11:55 pm

See your xorg log to catch how your card named your monitors

Code: Select all

(--) NVIDIA(0): Connected display device(s) on GeForce 6800 at PCI:1:0:0:
(--) NVIDIA(0):     Mitsubishi DPLUS93SB (CRT-0)
(--) NVIDIA(0):     Iiyama HM903D/DT (CRT-1)
(--) NVIDIA(0): Mitsubishi DPLUS93SB (CRT-0): 400.0 MHz maximum pixel clock
(--) NVIDIA(0): Iiyama HM903D/DT (CRT-1): 400.0 MHz maximum pixel clock
(II) NVIDIA(0): Assigned Display Devices: CRT-0, CRT-1
you can now use OPTION ConnectedMonitors CRT-1,CRT-0 to swap them, there's a know nvidia bug that bypass this if your monitor is DFP-0 and CRT-0 for example, in this case DFP-0 or CRT-0 will always be default monitor even if you don't wish it... That bug might have been corrected, just try.
ps: look out in nvidia manual for correct spelling of the OPTION (connectedmonitor, connectedmonitors... or even something else if nvidia changed the function name).
[/list]
Top
Gusar
Advocate
Advocate
Posts: 2665
Joined: Sat Apr 09, 2005 10:19 pm
Location: Slovenia

  • Quote

Post by Gusar » Wed Jan 31, 2007 8:53 am

Actually, the correct option is "TwinViewXineramaInfoOrder". In your case breakerfall, I think it should be set like this:

Code: Select all

Option "TwinViewXineramaInfoOrder" "DFP,CRT"
Top
breakerfall
Guru
Guru
Posts: 509
Joined: Sat Aug 02, 2003 11:13 pm
Location: Manchester, UK

  • Quote

Post by breakerfall » Wed Jan 31, 2007 9:44 am

Gusar wrote:Actually, the correct option is "TwinViewXineramaInfoOrder". In your case breakerfall, I think it should be set like this:

Code: Select all

Option "TwinViewXineramaInfoOrder" "DFP,CRT"
Winner!

Thanks, that's great, but now it's thrown up a new problem :x

When I login, the primary monitor displays the panel and taskbar as it should, however, the actual screen isn't at the right resolution, if you get what I mean. It's like a virtual desktop (extended past the boundary of the screen), but it doesn't scroll when you move your mouse. Of course, I think this is done to match the resolution of the external screen. Is there a way I can make the screen boundary on the laptop screen solid - so the mouse can't go past it?

Small screenshot here: http://steven.nonlogic.org/dual.jpg

The black void, bottom left, I can't see it on my screen, but the mouse can disappear down there, so it's not like the side and top boundaries, which block the mouse from going past them.

Also, one last question (if I may)... If I wanted to use the nvidia-settings tool to set dual monitors on the fly (which I already tried), how could I do it with the xinerama info, to stop everything stretching across the 2 screens? For example, if I set the dual screen in nvidia-settings, the taskbar stretches across both displays and any dialogs appear inbetween the two screens. When I maximise windows, they stretch to both displays.

Is it possible to get the same setup I have now, through the nvidia-settings control panel, or any other method that I can use on the fly, without restarting x?

Thanks again
Top
Dan
Veteran
Veteran
Posts: 1302
Joined: Tue Oct 25, 2005 3:04 pm

  • Quote

Post by Dan » Wed Jan 31, 2007 1:19 pm

remove xinerama from xorg.conf and use twinview only.
then In nvidia-settings set the X Server Display Configuration to "TwinView" and adjust the resolution you want each monitor.

Mine works as you would like and may provide as a good example for you.
Section "Device"
Identifier "Card0"
Driver "nvidia"
VendorName "NVIDIA Corporation"
BoardName "Geforce 6200"
BusID "PCI:2:0:0"
VideoRam 262144
Screen 0
Option "RenderAccel" "True"
Option "XAANoOffscreenPixmaps" "true"
Option "DRI" "true"
Option "HWcursor"
Option "CursorShadow"
Option "CursorShadowAlpha" "32"
Option "CursorShadowXOffset" "3"
Option "CursorShadowYOffset" "3"
Option "AddARGBGLXVisuals" "true"
Option "AllowGLXWithComposite" "true"
Option "TwinView" "on"
Option "MetaModes" "1024x768,1024x768; 1024x768"
Option "ConnectedMonitor" "CRT,CRT"
Option "TwinViewOrientation" "RightOf"
Option "TwinViewXineramaInfoOrder" "CRT-0, CRT-1"
EndSection

Section "Screen"
Identifier "Screen0"
Device "Card0"
Monitor "Monitor0"
DefaultDepth 24
Option "DisableGLXRootClipping" "True"
Option "RenderAccel" "True"
Option "NoRenderExtension" "False"
#Option "AllowGLXWithComposite" "True"
Option "UseEdidFreqs" "True"
#Option "AddARGBGLXVisuals" "True"
SubSection "Display"
Viewport 0 0
Depth 24
Modes "1024x768"
EndSubSection
EndSection
Also note the way the "MetaModes" are done. That may be what you need to get your desired result. Why do you have it specified twice?
- Failure is not an option. It's bundled with your software.
Top
breakerfall
Guru
Guru
Posts: 509
Joined: Sat Aug 02, 2003 11:13 pm
Location: Manchester, UK

  • Quote

Post by breakerfall » Wed Jan 31, 2007 3:45 pm

I'll try removing the xinerama option from xorg.conf, but I'm not sure how that would make a difference with the layout. I though the xinerama flag was for applications that use the xinerama extension so they don't stretch across the entire desktop (seeing as I'm not actually using xinerama).

Also, from what I can see with your metamodes, both of your displays use the same resolution, so you wouldn't have come across the problem I'm having. Like I mentioned, the layout I have now is perfect, I just want to know if it's possible to limit the edge of the window on the screen with the lower resolution... maybe if you could try with running different resolutions on each screen? That would be great.

Also, how would I go about using the nvidia setting tool to run dual screen on the fly, without the taskbar etc stretching over both displays?

Thanks for the response. =]
Top
Dan
Veteran
Veteran
Posts: 1302
Joined: Tue Oct 25, 2005 3:04 pm

  • Quote

Post by Dan » Wed Jan 31, 2007 3:51 pm

My taskbar doesn't stretch across both displays but I can drag it to which ever one I want it on. and yes I can and change display resolutions of either monitor I want just by changing the metamode line in the device section.

You should remove the 2 metamode lines from your screen section as well as the TwinVeiw things and use them in the Device Section. See mine.

This metamode will probably give you what you want If it is in the Device Section along with your twinview statements.
Option "MetaModes" "1280x800,1280x1024" If you want to specify more modes you seperate them by a colon.
like Option "MetaModes" "1280x800,1280x1024;1024x768,1024x768"
you can also specify single resolutions like "MetaModes" "1280x800,1280x1024;1024x768,1024x768;1280x800,;1280x1024,;1024x768,"
The single resolutions in metamode defines a mode where the primary monitor is at a specific resolution and the secondary monitor is switched off.
This is useful when playing games so that the games don’t spread themselves out over both monitors.
- Failure is not an option. It's bundled with your software.
Top
breakerfall
Guru
Guru
Posts: 509
Joined: Sat Aug 02, 2003 11:13 pm
Location: Manchester, UK

  • Quote

Post by breakerfall » Wed Jan 31, 2007 5:10 pm

Thanks for replying again... I made the changes to my config file.

It now looks like so:

Code: Select all

Section "Device"
	Identifier  "Card0"
	Driver      "nvidia"
	VendorName  "nVidia Corporation"
	BoardName   "Nvidia GeForce Go 7400"
	BusID       "PCI:1:0:0"
	Option      "NoLogo" "true"
	#Option      "TripleBuffer" "True"
#	Option      "RenderAccel" "true"
	Option      "backingstore" "true"
	Option      "AllowGLXWithComposite" "true"
	Option      "AddARGBGLXVisuals" "true"
	Option      "TwinView"  "1"
	Option      "TwinViewOrientation"  "LeftOf"
	Option      "MetaModes"  "1280x800,1280x1024;1280x800,;"
	Option      "ConnectedMonitor" "DFP,CRT" 
	Option      "TwinViewXineramaInfoOrder" "DFP,CRT"
EndSection

Section "Screen"
	Identifier "Screen0"
	Device     "Card0"
	Monitor    "Monitor0"
	DefaultDepth 24
	SubSection "Display"
		Depth     24
		Modes     "1280x800"
	EndSubSection
EndSection
The result is unchanged, although it seems I can do everything on the fly through nvidia-settings. I still have the black void where my mouse can disappear to.

So thanks, for fixing the nvidiasettings thing, now I just need to be rid of this damned void. :mrgreen:

Any ideas?

[edit]
Arghh NEG!

I'm going to have to play with the metamodes because it's not playing nice when I load X without any additional screens. In fact, it's throwing me into weird resolutions, my fonts go TINY and it still creates the full size dual desktop, even with only 1 screen. Sigh... I figured the config was good now....
Last edited by breakerfall on Wed Jan 31, 2007 5:22 pm, edited 1 time in total.
Top
Dan
Veteran
Veteran
Posts: 1302
Joined: Tue Oct 25, 2005 3:04 pm

  • Quote

Post by Dan » Wed Jan 31, 2007 5:21 pm

try this exactly as it is
Section "Device"
Identifier "Card0"
Driver "nvidia"
VendorName "NVIDIA Corporation"
BoardName "Nvidia GeForce Go 7400"
BusID "PCI:1:0:0"
Screen 0
Option "RenderAccel" "True"
Option "XAANoOffscreenPixmaps" "true"
Option "DRI" "true"
Option "HWcursor"
Option "CursorShadow"
Option "CursorShadowAlpha" "32"
Option "CursorShadowXOffset" "3"
Option "CursorShadowYOffset" "3"
Option "AddARGBGLXVisuals" "true"
Option "AllowGLXWithComposite" "true"
Option "TwinView" "on"
Option "MetaModes" "1280x800,1280x1024; 1280x800"
Option "ConnectedMonitor" "DFP,CRT"
Option "TwinViewOrientation" "LeftOf"
Option "TwinViewXineramaInfoOrder" "DFP, CRT"
EndSection

Section "Screen"
Identifier "Screen0"
Device "Card0"
Monitor "Monitor0"
DefaultDepth 24
Option "DisableGLXRootClipping" "True"
Option "RenderAccel" "True"
Option "NoRenderExtension" "False"
Option "UseEdidFreqs" "True"
SubSection "Display"
Viewport 0 0
Depth 24
Modes "1280x1024" "1280x800"
EndSubSection
EndSection

Section "DRI"
Group 0
Mode 0666
EndSection
Last edited by Dan on Wed Jan 31, 2007 5:23 pm, edited 1 time in total.
- Failure is not an option. It's bundled with your software.
Top
breakerfall
Guru
Guru
Posts: 509
Joined: Sat Aug 02, 2003 11:13 pm
Location: Manchester, UK

  • Quote

Post by breakerfall » Wed Jan 31, 2007 5:23 pm

I'll try again... can you also try changing your primary display (the one with your taskbars etc) to a smaller resolution than the other display and see if your mouse is bound to the edges?

Cheers

Also, see my edit above. :P
Top
breakerfall
Guru
Guru
Posts: 509
Joined: Sat Aug 02, 2003 11:13 pm
Location: Manchester, UK

  • Quote

Post by breakerfall » Wed Jan 31, 2007 7:04 pm

Ok nope, sorry - that doesn't work. I noticed that the setting:

Option "ConnectedMonitor" "DFP,CRT"

instead of:

Option "UseDisplayDevice" "DFP, CRT"

causes the problems I'm having. I stcik the usedisplaydevice option back in (which you don't have) and it's perfect again. I also still can't start X with no external screen, then plug one in and use nvidia-settings to enable twinview, without having windows, titlebars, dialogs etc, stretched out over both screens.

Also, why do you have the DRI option in your config? This is not for nvidia cards, it's used in conjunction with nvidia devices only.

Nvidia list of options:

http://download.nvidia.com/solaris/1.0- ... dix-d.html

Can you at least experiment for me? Try disconnected your second display. Restart X with only a single display. Now hook up your screen, it shouldn't come to life - then using nvidia-settings, enable / detect the screen and see if your windows don't start stretching across both windows....
Top
Dan
Veteran
Veteran
Posts: 1302
Joined: Tue Oct 25, 2005 3:04 pm

  • Quote

Post by Dan » Wed Jan 31, 2007 8:02 pm

mine looks normal even with monitor0 at 1024x768 and monitor1 at 1280x1024
and no windows do not stretch across both monitors unless I want them to and manually stretch them.
It is xinerama that does this and If you don't use xinerama in xorg.conf then I wouldn't think you should have this problem.
I do have xinerama in global USE but IT is not in xorg.conf
- Failure is not an option. It's bundled with your software.
Top
breakerfall
Guru
Guru
Posts: 509
Joined: Sat Aug 02, 2003 11:13 pm
Location: Manchester, UK

  • Quote

Post by breakerfall » Wed Jan 31, 2007 8:13 pm

dcoats wrote:mine looks normal even with monitor0 at 1024x768 and monitor1 at 1280x1024
and no windows do not stretch across both monitors unless I want them to and manually stretch them.
It is xinerama that does this and If you don't use xinerama in xorg.conf then I wouldn't think you should have this problem.
I do have xinerama in global USE but IT is not in xorg.conf
Yes, I understand it "looks" normal when you have the resolutions like that. The issue is the black void, You don't see it, but the mouse can go there. Can you at least take a screenshot and upload it somewhere, then you will see the black void...

Also, windows don't stretch when I use my xorg.conf and startx with both displays connected. It just happens when I connect the display after starting x and then use nvidia-settings to enable twinview.

Surely, someone must know how to make nvidia-settings behave correctly when enabling twinview. :(
Top
lramos85
Tux's lil' helper
Tux's lil' helper
User avatar
Posts: 141
Joined: Tue Jun 29, 2004 10:58 pm
Location: Riverside, Ca

  • Quote

Post by lramos85 » Mon Mar 19, 2007 11:36 pm

I had your same problem breakerfall, I also had that Black Void where the mouse could go but I couldn't see what I was clicking, what I did to "handle" the Black Void on the bottom of my Laptop Screen is this:

Since my Laptop's Resolution is 1440x900 and my External LCD is 1280x1024 I have this in my MetaModes:

Code: Select all

Option      "MetaModes"  "1280x1024,1440x900 @ 1280x1024;1280x1024,NULL;NULL,1440x900"
This allows me to have Three Options:
1. Have Twinview 2720x1024
2. Have only my Laptop Screen 1440x900
3. Have only my External Monitor 1280x1024

Notice that the Resolution 1024 is bigger than 900 so when I'm doing TwinView it creates the "Black Void". Also notice on my MetaModes there is a 1440x900 @ 1280x1024, this will allow your laptop monitor to keep its Original Resolution and Span the Laptop's Monitor by following your mouse. There will still be a section of the Laptop's Monitor you can't see at all times but the screen will now span to your mouse. Its hard to explain but basically the Viewable Screen on your Laptop's Monitor will be following your Mouse.

This is my Xorg.conf:

Code: Select all

Section "Device"
	Identifier	"NVS-110M"
	VendorName	"NVIDIA Corporation"
	BoardName 	"256MB Quadro NVS-110M TurboCache"
	Driver		"nvidia"
	BusID		"PCI:1:0:0"

        #Twinview Options:
        Option      "backingstore" "true"
        Option      "AllowGLXWithComposite" "true"
        Option      "TwinView"  "1"
        Option      "TwinViewOrientation"  "LeftOf"
        #Option      "MetaModes"  "1280x1024,1440x900;1280x800,;"
        Option      "MetaModes"  "1280x1024,1440x900 @ 1280x1024;1280x1024,NULL;NULL,1440x900"
        #Option      "MetaModes"  "1440x900,1280x1024;1440x900,NULL;NULL,1280x1024"
        #Option      "MetaModes"  "1280x1024; , 1280x1024"
        #Option      "MetaModes"  "1440x900; , 1440x900"
        Option      "ConnectedMonitor" "DFP,CRT"
        Option      "TwinViewXineramaInfoOrder" "DFP,CRT" 

	#Beryl:
	Option "AddARGBGLXVisuals"	"true"
EndSection

The only thing I'm missing now is a nice 2720x1024 Background :P. Or learn how to have them displayed at both monitors.
Registered Linux User #328996
Register Now!
Adpot an unanswered post today!
Top
breakerfall
Guru
Guru
Posts: 509
Joined: Sat Aug 02, 2003 11:13 pm
Location: Manchester, UK

  • Quote

Post by breakerfall » Tue Mar 20, 2007 9:28 am

Thanks for replying... I finally settled on a setup I'm happy with. I thought I'd posted it here actually. :?:

Anyway, I know what you mean about the panning desktop mode and I didn't want that, so I didn't bother. I'm living with the black void, it's not a big deal, I suppose... though I still wish the mouse could be bound to the confines of my laptops resolution, when in the laptop display, but nevermind.

If you're interested, here's my section of config:

Code: Select all

Section "Device"
	Identifier  "Card0"
	Driver      "nvidia"
	VendorName  "nVidia Corporation"
	BoardName   "Nvidia GeForce Go 7400"
	BusID       "PCI:1:0:0"
	Option      "NoLogo" "true"
	Option      "TripleBuffer" "True"
	Option      "backingstore" "true"
	Option      "AddARGBGLXVisuals" "true"
EndSection

Section "Screen"
	Identifier  "Screen0"
	Device      "Card0"
	Monitor     "Monitor0"
	Option      "MetaModes" "1280x800_60 +0+0"
	Option      "TwinView" "1"
	Option      "TwinViewOrientation" "LeftOf"
	#Option      "UseDisplayDevice" "DFP,CRT"
	Option      "TwinViewXineramaInfoOrder" "DFP,CRT"
	Option      "UseEdidFreqs" "1"
	Option      "UseEDIDDpi" "DFP-0"
	DefaultDepth 24
	SubSection  "Display"
		Depth     24
		Modes     "1600x1200" "1280x1024" "1280x800" "1024x768"
	EndSubSection
EndSection
Top
Post Reply

16 posts • Page 1 of 1

Return to “Desktop Environments”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy

 

 

magic