============================== Type deai.plugin.xorg:RandrExt ============================== .. lua:module:: deai.plugin.xorg.RandrExt See :lua:attr:`Connection.randr ` for more information about this type Properties ========== .. list-table:: :header-rows: 0 * - :lua:attr:`modes ` - Available modes from RandR * - :lua:attr:`outputs ` - Outputs .. lua:attribute:: modes: [Mode] :type: :lua:mod:`[Mode] ` Available modes from RandR .. lua:attribute:: outputs: [Output] :type: :lua:mod:`[Output] ` Outputs Generally, outputs are what we would call monitors. Methods ========== .. list-table:: :header-rows: 0 * - :lua:meth:`configure_outputs(configs) ` - Configure the outputs. * - :lua:meth:`find_output(monitor_info) ` - Find the output that corresponds to a monitor. * - :lua:meth:`monitor_info() ` - Get the monitor information for each connected monitor. .. lua:method:: configure_outputs(configs) -> void :rtype: void :param configs: The configuration :type configs: :lua:mod:`[OutputConfig] ` Configure the outputs. Set the position and size of the outputs according to configuration. The outputs you want to configure must ALL appear in the configuration list, even if you don't place any positional constraints on them. The positional constraints MUST NOT refer to any outputs that are not in the configuration list. If the constraints are impossible to satisfy, then an error will be raised. .. lua:method:: find_output(monitor_info) -> Output :rtype: :lua:mod:`Output ` :param monitor_info: The monitor information. This can also be a string, in which case it is treated as the name of the output. :type monitor_info: :lua:mod:`MonitorInfo ` Find the output that corresponds to a monitor. The argument is a :lua:mod:`~deai.plugin.xorg.randr.MonitorInfo` object. But not all of its fields need to be filled in. Only the fields present will be used in the search, and the `output` field will be ignored. If there are multiple outputs that match the information given, any of them may be returned. .. lua:method:: monitor_info() -> object :rtype: object Get the monitor information for each connected monitor. Returns a table of monitor information, indexed by the name of the output, each value is of type :lua:mod:`~deai.plugin.xorg.randr.MonitorInfo`. Signals ========== .. list-table:: :header-rows: 0 * - :lua:sgnl:`output-change(output) ` - An output's configuration changed * - :lua:sgnl:`view-change(view) ` - A view's configuration changed .. lua:signal:: output-change(output) :param output: the output that changed. :type output: :lua:mod:`Output ` An output's configuration changed .. lua:signal:: view-change(view) :param view: the view that changed. :type view: :lua:mod:`View ` A view's configuration changed