Button

Search for usage in LXR

Properties

string configFile
 
string downloadNewWhat
 
NewStuffEngine engine
 
Connections engineConnections
 
int viewMode
 
bool visibleWhenDisabled
 

Signals

void aboutToShowDialog ()
 
void entryEvent (var entry, int event)
 

Public Member Functions

void showDialog ()
 

Detailed Description

A button which when clicked will open a dialog with a NewStuff.Page at the base.

This component is equivalent to the old Button

See also
KNewStuff::Button
Since
5.63

Definition at line 17 of file Button.qml.

Property Documentation

◆ configFile

string Button::configFile
read

The configuration file to use for this button.

Definition at line 31 of file Button.qml.

◆ downloadNewWhat

string Button::downloadNewWhat
read

Set the text that should appear on the button.

Will be set as i18nd("knewstuff6", "Download New %1…").

Note
For the sake of consistency, you should NOT override the text property, just set this one

Definition at line 38 of file Button.qml.

◆ engine

NewStuffEngine Button::engine
read

The engine which handles the content in this Button.

Definition at line 58 of file Button.qml.

◆ engineConnections

Connections Button::engineConnections
read

Definition at line 66 of file Button.qml.

◆ viewMode

int Button::viewMode
read

The view mode of the dialog spawned by this button, which overrides the default one (ViewMode.Tiles).

This should be set using the NewStuff.Page.ViewMode enum. Note that ViewMode.Icons has been removed, and asking for it will return ViewMode.Tiles.

See also
NewStuff.Page.ViewMode

Definition at line 49 of file Button.qml.

◆ visibleWhenDisabled

bool Button::visibleWhenDisabled
read

If this is true (default is false), the button will be shown when the Kiosk settings are such that Get Hot New Stuff is disallowed (and any other time enabled is set to false).

Usually you would want to leave this alone, but occasionally you may have a reason to leave a button in place that the user is unable to enable.

Definition at line 73 of file Button.qml.

Member Function Documentation

◆ aboutToShowDialog

void Button::aboutToShowDialog ( )
signal

emitted when the Hot New Stuff dialog is about to be shown, usually as a result of the user having click on the button

◆ entryEvent

void Button::entryEvent ( var entry,
int event )
signal

This forwards the entryEvent from the QtQuick engine.

See also
Engine::entryEvent
Since
5.82

◆ showDialog()

void Button::showDialog ( )

Show the dialog (same as clicking the button), if allowed by the Kiosk settings.


The documentation for this class was generated from the following file:
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Nov 22 2024 12:07:37 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.