This provides the UI support for the qemu-vdagent channel which allows
clipboard sharing with VNC graphics (see previous commit for more
information).
The channel name in the device list was changed slightly in order to
avoid confusion. Due to the fact that both the spice-vdagent and the
qemu-vdagent specify the same virtio name (com.redhat.spice.0), both of
these channels were showing up in the device list as "Channel spice",
which is a bit confusing.
In order to disambiguate these, channels now show up in the device list
as "Channel {type} ({name})" instead of "Channel {name}". So for
example, a qemu-vdagent channel would show up as:
Channel Qemu vdagent (spice)
Whereas a spice-vdagent channel would show up as:
Channel Spice agent (spice)
Signed-off-by: Jonathon Jongsma <jjongsma@redhat.com>
- Remove most use of deprecated stock icons. Without it the UI will
be a lot more ugly in Fedora 36
- Remove deprecated ImageMenuItem usage, convert to regular MenuItem
- Remove most embedded button images
Signed-off-by: Cole Robinson <crobinso@redhat.com>
Split out tpmdetails.py, following the pattern of fsdetails.py. This
adds more UI editing fields for an already attached TPM.
Move the model and version under an 'Advanced options' expander,
since we should be getting this correct by default.
Signed-off-by: Cole Robinson <crobinso@redhat.com>
It creates a lot of churn.
Adjust phantom grid rows + columns while we are at it, not sure why
those counts are suddenly wrong
Signed-off-by: Cole Robinson <crobinso@redhat.com>
Share the UI for changing all these disk properties:
- shareable
- readonly
- removable
- cache
- discard
- detect zeroes
Move them all under the 'Advanced options' expander in details, and
add the checkbox options to the addhardware wizard.
Signed-off-by: Cole Robinson <crobinso@redhat.com>
* Add CSS data in config.py and install it
* Strip out all hardcoded colors and use style class annotations
* Fix colors to be more theme appropriate to fix dark theme look
Signed-off-by: Cole Robinson <crobinso@redhat.com>
These were removed from the Details dialog previously, but I forgot
to remove them from addhardware too
Signed-off-by: Cole Robinson <crobinso@redhat.com>
This was proposed here:
https://www.redhat.com/archives/virt-tools-list/2019-June/msg00117.html
"""
* network virtualport configuration: this is some really obscure
stuff for configuring VEPA for macvtap devices. I don't think it gets
any usage in practice. I think a smaller subset of this UI is shared
with openswitch config but I believe it's just a single field, we
could keep that even though I don't think many people use it either
"""
This removes it all. The openvswitch piece was not properly wired
up anyways, since it requires setting virtualport type for a bridge.
For users that know they need that, they can add it via the XML
editor.
Signed-off-by: Cole Robinson <crobinso@redhat.com>
Given that we bumped deps to fairly modern distros with the
python3 change, I think this is safe. gtk 3.22 is from sep 2016, it's
in debian9 and fedora 25+, which seems fine for our needs.
I know openstack uses tcp consoles but for end users I've never
really heard about it. RHEL compiles out udp as well. I'm fine telling
users to go to the cli and use virt-xml for this use case.
Use this opportunity to drop a lot of code that only simplified the
case when there are tons of char options we need to consider
There is only one for now, but we are adding CRB next (and SPAPR is
being added too in qemu/libvirt).
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
There are multiple models of the panic device, the address type is only
one and is valid only for "isa" model.
To not break the virt-install/virt-xml the command line parser needs to
be updated. Before this patch there was only one parameter that
configured the "iobase". Now the first parameter configures a model
but to keep it backward compatible it follows these rules:
1. there is only one parameter and it matches known model:
--panic isa
<panic model='isa'>
<address iobase='0x505' type='isa'/>
</panic>
2. there is only one parameter and it doesn't match any model:
--panic 0x505
<panic model='isa'>
<address iobase='0x505' type='isa'/>
</panic>
3. there are two parameters:
--panic isa,iobase=0x505
<panic model='isa'>
<address iobase='0x505' type='isa'/>
</panic>
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
This is advanced configuration and it's not required to configure
at all to have a working panic device.
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
GtkTable was deprecated since Gtk version 3.4 and should not be used
in newly-written code. It should be replaced by GtkGrid.
https://developer.gnome.org/gtk3/stable/GtkTable.htmlhttps://developer.gnome.org/gtk3/stable/GtkGrid.html
GtkTable is mapped to GtkGrid following these rules:
----------------
- n_(row|columns) are removed because they are not required for
GtkGrid
----------------
- Missing "left_attach" and "top_attach" are added with value set to
0.
Example:
<property name="left_attach">0</property>
<property name="top_attach">0</property>
----------------
- (right_attach - left_attach) > 1 is stored in new "width" property
Example:
In case of: (GtkTable)
<property name="left_attach">1</property>
<property name="right_attach">4</property>
Equivalent to: (GtkGrid)
<property name="width">3</property>
----------------
- (bottom_attach - top_attach) > 1 is stored in new "height" property
Example:
In case of: (GtkTable)
<property name="top_attach">1</property>
<property name="bottom_attach">3</property>
Equivalent to: (GtkGrid)
<property name="height">2</property>
----------------
- Missing packing "(x|y)_options" property is represented as no
"(h|v)align" object property and "(h|v)expand" object property
set to "true"
Example:
In case of: (GtkTable)
# Missing y_options property
Equivalent to: (GtkGrid)
<property name="vexpand">True</property>
# No valign property
----------------
- Packing "(x|y)_options" property set to "GTK_FILL" is represented
as no "(h|v)expand" object property and no "(h|v)align" object
property
Example:
In case of: (GtkTable)
<property name="x_options">GTK_FILL</property>
Equivalent to: (GtkGrid)
# No hexpand property
# No halign property
----------------
- Packing "(x|y)_options" property set to "GTK_EXPAND" is
represented as "(h|v)expand" object property set to "true" and
"(h|v)align" object property set to "center"
Example:
In case of: (GtkTable)
<property name="x_options">GTK_EXPAND</property>
Equivalent to: (GtkGrid)
<property name="hexpand">True</property>
<property name="halign">center</property>
----------------
- Packing "(x|y)_options" property set to nothing is represented as
"(h|v)align" object property set to "center"
Example:
In case of: (GtkTable)
<property name="y_options" />
Equivalent to: (GtkGrid)
<property name="valign">center</property>
----------------
- All "(x|y)_options" rules apply but don't change existing
"(h|v)align" and "(h|v)expand" object properties
----------------
- Packing "x_padding" property is converted to "margin_(start|end)"
object property
Example:
In case of: (GtkTable)
<property name="x_padding">6</property>
Equivalent to: (GtkGrid)
<property name="margin_start">6</property>
<property name="margin_end">6</property>
----------------
- Packing "y_padding" property is converted to "margin_(top|bottom)"
object property
Example:
In case of: (GtkTable)
<property name="y_padding">6</property>
Equivalent to: (GtkGrid)
<property name="margin_top">6</property>
<property name="margin_bottom">6</property>
GtkHButtonBox was deprecated since Gtk version 3.2 and should not
be used in newly-written code. Use GtkButtonBox instead. The property
orientation is set by default to horizontal.
https://developer.gnome.org/gtk3/stable/GtkHButtonBox.html
Problem:
- GtkHBox and GtkVBox have been deprecated since version 3.2 and should not be used in newly-written code.
Solution: Replace GtkHBox and GtkVBox with GtkBox.
- I have used the find function in text-editor to find all occurances of "GtkVBox" and "GtkHBox" then replaced them with "GtkBox".
- Then append on a new line immediately after "<property name="orientation">...</property>" with value "horizontal" or "vertical" accordingly.
We need to bump the gtk dep to at least 3.10 for GtkRevealer usage,
and I want to bump the pygobject higher to drop some bug workarounds.
But since the oldest thing I have that meets those requirements is
RHEL/Centos 7.3 which is at 3.14 for both, set those as the minimum
versions since that's what I'll be testing against. They are still
1.5 years old and only a bit over a year newer than the previous
versions, so it's not a huge change.
Originally this made sense, as it was the only way to specify a non-default
storage format when creating new storage.
Nowadays the storage browser is a full featured storage manager... and
this field is a bit confusing WRT whether it's used for creating new
storage, or informing libvirt about an existing image's format.
Drop it from the addhardware wizard, and simplify what we show in the
details wizard as well.