Score:0

VcXsrv full screen

cz flag

I have installed Ubuntu on my windows via wsl. I have followed this guide: https://medium.com/geekculture/how-to-install-the-ubuntu-desktop-with-the-graphical-user-interface-in-wsl2-71f4b78431a4

Currently the GUI is being opened in frame, but i want to make it open in full screen mode. Is there any chance i can do it?

screenshot of VcXsrv Here is the script to launch VcXsrv :

' define variables
dim application_object, shell_object, userprofile, command_object, standard_output_string

' create application object
set application_object = createobject("shell.application")

' create shell object
set shell_object = createobject("wscript.shell")

' store environment variable
username = shell_object.expandenvironmentstrings("%username%")

' run powershell in the background
application_object.shellexecute "powershell", "-file c:\users\" & username & "\.ubuntu\scripts\reload_vcxsrv.ps1", "", "", 0

' wait for powershell script to complete
wscript.sleep 3000

' create command object
set command_object = shell_object.exec("wsl genie --is-in-bottle")

' store standard output
standard_output = command_object.stdout.readall

' execute contents if shell is inside the genie container
if instr(standard_output, "inside") > 0 then
  
  ' run bash script
  shell_object.run "bash /mnt/c/users/" & username & "/.ubuntu/scripts/start_desktop.sh", 0

' execute contents if shell is outside the genie container   
else 
  
  ' run bash script
  shell_object.run "wsl genie -c bash /mnt/c/users/" & username & "/.ubuntu/scripts/start_desktop.sh", 0

end if
Score:0
vn flag

For starters, that doesn't look like the script that starts VcXsrv. According to the blog post you referenced, that's found here, and is:

# stop vcxsrv proccess that contains "0.0" in the program window title
get-process vcxsrv | where { $_.mainwindowtitle -like "*0.0*" } | stop-process

# start vcxsrv process in a large program window on display number one
start-process "c:\program files\vcxsrv\vcxsrv.exe" -argument ":0.0 -ac -nowgl -multimonitors -dpms"

Second, according to the VcSrv docs, the commandline option -fullscreen is what you are looking for.

Try modifying the script above and adding -fullscreen to the commandline.

Ape Tim avatar
cz flag
thats awesome man! you're genius
NotTheDr01ds avatar
vn flag
You're welcome. As a heads-up, I recommend `xrdp` for connecting to full-screen Linux desktops under WSL. It has the advantage of capturing all keystrokes (like Alt-Tab, etc.) correctly.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.