At the moment when the user chooses to create a new virtual desktop, NoMachine runs the default X session set on the system or a different X session if it's configured to do that (see AR04K00667). User who needs to run an alternative virtual desktop can do that by creating a new custom session, specifying the command for launching their preferred X server and choosing to run that command in a virtual desktop. Another possibility is to configure the server for listing all the available desktops (ConnectPolicy desktop=1) supported by NoMachine (i.e. the default X desktop, GNOME and the KDE desktops if available).
The implementation of this feature request adds a further possibility i.e. to provide users with a list of all the desktops environments available on the remote host. If the administrator will install a new desktop environment, NoMachine will detect it automatically.
Similar to the standard used by recent versions of GDM/KDM/LightDM desktop managers, NoMachine can be instructed to run multiple X sessions, for example on Ubuntu Lubuntu.desktop, gnome-classic.desktop, kde-plasma.desktop, xfce.desktop etc...
In order to configure NoMachine to provide the list of all the available desktops, set xsessions=1 in the ConnectPolicy key in the server configuration (server.cfg). By default this is disabled (xsession=0).
Updated description of the ConnectPolicy key:
#
# Specify policies as a comma-separated list of options to tune the
# behaviour of clients 4 or higher and restore behaviors typical of
# version 3.x. Options accept value 1 (enabled) and 0 (disabled).
# This is the list of the available options:
#
# autocreate=1 run a new virtual desktop automatically when the ses-
# sion type is pre-defined in the player configuration.
#
# autoconnect=1 reconnect automatically the user's virtual desktop.
#
# automigrate=1 don't connect to a virtual desktop when there is a
# a user already connected but disconnect and reconnect
# the session on the new side (session migration).
#
# desktop=1 list all desktop types set in the AvailableSessionTypes
# key.
#
# dialog=1 display the disconnect/terminate dialog.
#
# xsessions=1 list all desktop types which are available in
# /usr/share/xsessions.
#
#ConnectPolicy autocreate=1,autoconnect=1,automigrate=1,desktop=0,dialog=0,xsessions=0