mteb/BrightProStackoverflowRetrieval huggingface dataset:
![](gtk-logo.svg)

###  [ Gtk ](index.html)

API Version: 3.0

Library Version: 3.24

#####  Type

[ MessageDialog ](class.MessageDialog.html)

#####  Methods

[ format_secondary_markup ](method.MessageDialog.format_secondary_markup.html)
[ format_secondary_text ](method.MessageDialog.format_secondary_text.html) [
get_image ](method.MessageDialog.get_image.html) [ get_message_area
](method.MessageDialog.get_message_area.html) [ set_image
](method.MessageDialog.set_image.html) [ set_markup
](method.MessageDialog.set_markup.html)

Generated by [ gi-docgen ](https://gitlab.gnome.org/GNOME/gi-docgen) 2023.4

###  Method

#  [ Gtk ](index.html) [ MessageDialog ](class.MessageDialog.html)
format_secondary_markup

since: 2.6

####  Declaration  [ [src]
](https://gitlab.gnome.org/GNOME/gtk/-/blob/gtk-3-24/gtk/gtkmessagedialog.h#L131
"go to source location")

    
    
    void
    gtk_message_dialog_format_secondary_markup (
      GtkMessageDialog* message_dialog,
      const gchar* message_format,
      ...
    )
    

`

####  Description  [ [src]
](https://gitlab.gnome.org/GNOME/gtk/-/blob/gtk-3-24/gtk/gtkmessagedialog.c#L845
"go to source location")

Sets the secondary text of the message dialog to be ` message_format ` (with
printf()-style), which is marked up with the [Pango text markup
language][PangoMarkupFormat].

Due to an oversight, this function does not escape special  XML  characters
like ` gtk_message_dialog_new_with_markup() ` does. Thus, if the arguments may
contain special  XML  characters, you should use ` g_markup_printf_escaped() `
to escape it.

    
    
    gchar *msg;
    
    msg = g_markup_printf_escaped (message_format, ...);
    gtk_message_dialog_format_secondary_markup (message_dialog,
                                                "%s", msg);
    g_free (msg);
    

Available since: 2.6

This method is not directly available to language bindings.

####  Parameters

` message_format `

    

_Type:_ ` const gchar* `

Printf()-style markup string (see [Pango markup format][PangoMarkupFormat]),
or ` NULL ` .

The data is owned by the caller of the method.  
---  
The value is a NUL terminated UTF-8 string.  
` ... `

    

_Type:_ ` `

Arguments for ` message_format ` .
![](gtk-logo.svg)

###  [ Gtk ](index.html)

API Version: 3.0

Library Version: 3.24

#####  Type

[ MessageDialog ](class.MessageDialog.html)

#####  Methods

[ format_secondary_markup ](method.MessageDialog.format_secondary_markup.html)
[ format_secondary_text ](method.MessageDialog.format_secondary_text.html) [
get_image ](method.MessageDialog.get_image.html) [ get_message_area
](method.MessageDialog.get_message_area.html) [ set_image
](method.MessageDialog.set_image.html) [ set_markup
](method.MessageDialog.set_markup.html)

Generated by [ gi-docgen ](https://gitlab.gnome.org/GNOME/gi-docgen) 2023.4

###  Method

#  [ Gtk ](index.html) [ MessageDialog ](class.MessageDialog.html) set_image

deprecated: 3.12  since: 2.10

####  Declaration  [ [src]
](https://gitlab.gnome.org/GNOME/gtk/-/blob/gtk-3-24/gtk/gtkmessagedialog.h#L115
"go to source location")

    
    
    void
    gtk_message_dialog_set_image (
      GtkMessageDialog* dialog,
      GtkWidget* image
    )
    

`

####  Description  [ [src]
](https://gitlab.gnome.org/GNOME/gtk/-/blob/gtk-3-24/gtk/gtkmessagedialog.c#L714
"go to source location")

Sets the dialog’s image to ` image ` .

Available since: 2.10

Deprecated since: 3.12

Use ` GtkDialog ` to create dialogs with images.

Sets property  |  [ ` Gtk.MessageDialog:image ` ](property.MessageDialog.image.html)  
---|---  
  
####  Parameters

` image `

    

_Type:_ [ ` GtkWidget ` ](class.Widget.html)

The image.

The data is owned by the caller of the method.  
---
![](gtk-logo.svg)

###  [ Gtk ](index.html)

API Version: 3.0

Library Version: 3.24

#####  Type

[ Widget ](class.Widget.html)

#####  Properties

[ app-paintable ](property.Widget.app-paintable.html) [ can-default
](property.Widget.can-default.html) [ can-focus ](property.Widget.can-
focus.html) [ composite-child ](property.Widget.composite-child.html) [
double-buffered ](property.Widget.double-buffered.html) [ events
](property.Widget.events.html) [ expand ](property.Widget.expand.html) [
focus-on-click ](property.Widget.focus-on-click.html) [ halign
](property.Widget.halign.html) [ has-default ](property.Widget.has-
default.html) [ has-focus ](property.Widget.has-focus.html) [ has-tooltip
](property.Widget.has-tooltip.html) [ height-request ](property.Widget.height-
request.html) [ hexpand ](property.Widget.hexpand.html) [ hexpand-set
](property.Widget.hexpand-set.html) [ is-focus ](property.Widget.is-
focus.html) [ margin ](property.Widget.margin.html) [ margin-bottom
](property.Widget.margin-bottom.html) [ margin-end ](property.Widget.margin-
end.html) [ margin-left ](property.Widget.margin-left.html) [ margin-right
](property.Widget.margin-right.html) [ margin-start ](property.Widget.margin-
start.html) [ margin-top ](property.Widget.margin-top.html) [ name
](property.Widget.name.html) [ no-show-all ](property.Widget.no-show-all.html)
[ opacity ](property.Widget.opacity.html) [ parent
](property.Widget.parent.html) [ receives-default ](property.Widget.receives-
default.html) [ scale-factor ](property.Widget.scale-factor.html) [ sensitive
](property.Widget.sensitive.html) [ style ](property.Widget.style.html) [
tooltip-markup ](property.Widget.tooltip-markup.html) [ tooltip-text
](property.Widget.tooltip-text.html) [ valign ](property.Widget.valign.html) [
vexpand ](property.Widget.vexpand.html) [ vexpand-set
](property.Widget.vexpand-set.html) [ visible ](property.Widget.visible.html)
[ width-request ](property.Widget.width-request.html) [ window
](property.Widget.window.html)

Generated by [ gi-docgen ](https://gitlab.gnome.org/GNOME/gi-docgen) 2023.4

###  Property

#  [ Gtk ](index.html) [ Widget ](class.Widget.html) :expand

since: 3.0

####  Declaration

    
    
    property expand: gboolean [ read, write ]

####  Description  [ [src]
](https://gitlab.gnome.org/GNOME/gtk/-/blob/gtk-3-24/gtk/gtkwidget.c#L1594 "go
to source location")

Whether to expand in both directions. Setting this sets both `
GtkWidget:hexpand ` and ` GtkWidget:vexpand ` .

Type: ` gboolean `

Available since: 3.0

####  Flags

Readable  |  **yes**  
---|---  
Writable  |  **yes**  
Construct  |  **no**  
Construct only  |  **no**
![](gtk-logo.svg)

###  [ Gtk ](index.html)

API Version: 3.0

Library Version: 3.24

#####  Type

[ FileChooser ](iface.FileChooser.html)

#####  Properties

[ action ](property.FileChooser.action.html) [ create-folders
](property.FileChooser.create-folders.html) [ do-overwrite-confirmation
](property.FileChooser.do-overwrite-confirmation.html) [ extra-widget
](property.FileChooser.extra-widget.html) [ filter
](property.FileChooser.filter.html) [ local-only ](property.FileChooser.local-
only.html) [ preview-widget ](property.FileChooser.preview-widget.html) [
preview-widget-active ](property.FileChooser.preview-widget-active.html) [
select-multiple ](property.FileChooser.select-multiple.html) [ show-hidden
](property.FileChooser.show-hidden.html) [ use-preview-label
](property.FileChooser.use-preview-label.html)

Generated by [ gi-docgen ](https://gitlab.gnome.org/GNOME/gi-docgen) 2023.4

###  Property

#  [ Gtk ](index.html) [ FileChooser ](iface.FileChooser.html) :action

####  Declaration

    
    
    property action: Gtk.FileChooserAction [ read, write ]

####  Description

No description available.

Type: [ ` GtkFileChooserAction ` ](enum.FileChooserAction.html)

Getter method  |  [ ` gtk_file_chooser_get_action() ` ](method.FileChooser.get_action.html)  
---|---  
Setter method  |  [ ` gtk_file_chooser_set_action() ` ](method.FileChooser.set_action.html)  
  
####  Flags

Readable  |  **yes**  
---|---  
Writable  |  **yes**  
Construct  |  **no**  
Construct only  |  **no**
part5 -------------------
Notes[edit]
^ "Class: BasicObject (Ruby 1.9.2)". Retrieved April 7, 2014.

^ System.Object

^ Python type/class unification

^ Matilla, Hugo (2019-02-27). "Kotlin basics: types. Any, Unit and Nothing". Medium. Retrieved September 16, 2019.

^ "An Overview of the Scala Programming Language" (PDF). 2006. Retrieved April 7, 2014.

^ "Types — The Swift Programming Language (Swift 5.3)". docs.swift.org. Retrieved November 2, 2020.

^ "Types · The Julia Language". Retrieved May 15, 2021.

^ "The Any type". 2022. Retrieved October 26, 2022.

^ "Standard ECMA-367. Eiffel: Analysis, Design and Programming Language" (PDF). 2006. Retrieved March 10, 2016.

^ "std.variant - D Programming Language". dlang.org. Retrieved 2022-10-29.

^ "The top types 'any' and 'unknown' in TypeScript".

^ "The unknown Type in TypeScript". 15 May 2019.
part3 -------------------
In logic[edit]
The notion of top is also found in propositional calculus, corresponding to a formula which is true in every possible interpretation. It has a similar meaning in predicate calculus. In description logic, top is used to refer to the set of all concepts. This is intuitively like the use of the top type in programming languages. For example, in the Web Ontology Language (OWL), which supports various description logics, top corresponds to the class owl:Thing, where all classes are subclasses of owl:Thing. (the bottom type or empty set corresponds to owl:Nothing).
part2 -------------------
Support in programming languages[edit]
Several typed programming languages provide explicit support for the top type.
In statically-typed languages, there are two different, often confused, concepts when discussing the top type.
A universal base class or other item at the top of a run time class hierarchy (often relevant in object-oriented programming) or type hierarchy; it is often possible to create objects with this (run time) type, or it could be found when one examines the type hierarchy programmatically, in languages that support it
A (compile time) static type in the code whose variables can be assigned any value (or a subset thereof, like any object pointer value), similar to dynamic typing
The first concept often implies the second, i.e., if a universal base class exists, then a variable that can point to an object of this class can also point to an object of any class. However, several languages have types in the second regard above (e.g., void * in C++, id in Objective-C, interface {} in Go), static types which variables can accept any object value, but which do not reflect real run time types that an object can have in the type system, so are not top types in the first regard.
In dynamically-typed languages, the second concept does not exist (any value can be assigned to any variable anyway), so only the first (class hierarchy) is discussed. This article tries to stay with the first concept when discussing top types, but also mention the second concept in languages where it is significant.
Most object-oriented programming languages include a universal base class:
Other languages[edit]
Languages that are not object-oriented usually have no universal supertype, or subtype polymorphism support.
While Haskell purposefully lacks subtyping, it has several other forms of polymorphism including parametric polymorphism. The most generic type class parameter is an unconstrained parameter a (without a type class constraint). In Rust, <T: ?Sized> is the most generic parameter (<T> is not, as it implies the Sized trait by default).
The top type is used as a generic type, more so in languages without parametric polymorphism.  For example, before introducing generics in Java 5, collection classes in the Java library (excluding Java arrays) held references of type Object. In this way, any non-intrinsic type could be inserted into a collection.  The top type is also often used to hold objects of unknown type.
The top type may also be seen as the implied type of non-statically typed languages.  Languages with run time typing often provide downcasting (or type refinement) to allow discovering a more specific type for an object at run time.  In C++, downcasting from void * cannot be done in a safe way, where failed downcasts are detected by the language run time.
In languages with a structural type system, the empty structure serves as a top type. For example, objects in OCaml are structurally typed; the empty object type (the type of objects with no methods), < >, is the top type of object types. Any OCaml object can be explicitly upcasted to this type, although the result would be of no use. Go also uses structural typing; and all types implement the empty interface: interface {}, which has no methods, but may still be downcast back to a more specific type.
misc/process/wait.html)
    9. [ **20.6.** Filesystem Operations ](../std_misc/fs.html)
    10. [ **20.7.** Program arguments ](../std_misc/arg.html) â± 
    11.       1. [ **20.7.1.** Argument parsing ](../std_misc/arg/matching.html)
    12. [ **20.8.** Foreign Function Interface ](../std_misc/ffi.html)
  41. [ **21.** Testing ](../testing.html) â± 
  42.     1. [ **21.1.** Unit testing ](../testing/unit_testing.html)
    2. [ **21.2.** Documentation testing ](../testing/doc_testing.html)
    3. [ **21.3.** Integration testing ](../testing/integration_testing.html)
    4. [ **21.4.** Dev-dependencies ](../testing/dev_dependencies.html)
  43. [ **22.** Unsafe Operations ](../unsafe.html) â± 
  44.     1. [ **22.1.** Inline assembly ](../unsafe/asm.html)
  45. [ **23.** Compatibility ](../compatibility.html) â± 
  46.     1. [ **23.1.** Raw identifiers ](../compatibility/raw_identifiers.html)
  47. [ **24.** Meta ](../meta.html) â± 
  48.     1. [ **24.1.** Documentation ](../meta/doc.html)
    2. [ **24.2.** Playground ](../meta/playground.html)

__ __

  * Light (default) 
  * Rust 
  * Coal 
  * Navy 
  * Ayu 

__

#  Rust By Example

[ __ ](../print.html "Print this book") [ __ ](https://github.com/rust-
lang/rust-by-example "Git repository") [ __ ](https://github.com/rust-
lang/rust-by-example/edit/master/src/trait/supertraits.md "Suggest an edit")

#  Supertraits

Rust doesn't have "inheritance", but you can define a trait as being a
superset of another trait. For example:

    
    
    trait Person {
        fn name(&self) -> String;
    }
    
    // Person is a supertrait of Student.
    // Implementing Student requires you to also impl Person.
    trait Student: Person {
        fn university(&self) -> String;
    }
    
    trait Programmer {
        fn fav_language(&self) -> String;
    }
    
    // CompSciStudent (computer science student) is a subtrait of both Programmer 
    // and Student. Implementing CompSciStudent requires you to impl both supertraits.
    trait CompSciStudent: Programmer + Student {
        fn git_username(&self) -> String;
    }
    
    fn comp_sci_student_greeting(student: &dyn CompSciStudent) -> String {
        format!(
            "My name is {} and I attend {}. My favorite language is {}. My Git username is {}",
            student.name(),
            student.university(),
            student.fav_language(),
            student.git_username()
        )
    }
    
    fn main() {}
    

###  See also:

[ The Rust Programming Language chapter on supertraits ](https://doc.rust-
lang.org/book/ch19-03-advanced-traits.html#using-supertraits-to-require-one-
traits-functionality-within-another-trait)

[ __ ](../trait/clone.html "Previous chapter") [ __
](../trait/disambiguating.html "Next chapter")

[ __ ](../trait/clone.html "Previous chapter") [ __
](../trait/disambiguating.html "Next chapter")
misc/process/wait.html)
    9. [ **20.6.** Filesystem Operations ](../std_misc/fs.html)
    10. [ **20.7.** Program arguments ](../std_misc/arg.html) â± 
    11.       1. [ **20.7.1.** Argument parsing ](../std_misc/arg/matching.html)
    12. [ **20.8.** Foreign Function Interface ](../std_misc/ffi.html)
  41. [ **21.** Testing ](../testing.html) â± 
  42.     1. [ **21.1.** Unit testing ](../testing/unit_testing.html)
    2. [ **21.2.** Documentation testing ](../testing/doc_testing.html)
    3. [ **21.3.** Integration testing ](../testing/integration_testing.html)
    4. [ **21.4.** Dev-dependencies ](../testing/dev_dependencies.html)
  43. [ **22.** Unsafe Operations ](../unsafe.html) â± 
  44.     1. [ **22.1.** Inline assembly ](../unsafe/asm.html)
  45. [ **23.** Compatibility ](../compatibility.html) â± 
  46.     1. [ **23.1.** Raw identifiers ](../compatibility/raw_identifiers.html)
  47. [ **24.** Meta ](../meta.html) â± 
  48.     1. [ **24.1.** Documentation ](../meta/doc.html)
    2. [ **24.2.** Playground ](../meta/playground.html)

__ __

  * Light (default) 
  * Rust 
  * Coal 
  * Navy 
  * Ayu 

__

#  Rust By Example

[ __ ](../print.html "Print this book") [ __ ](https://github.com/rust-
lang/rust-by-example "Git repository") [ __ ](https://github.com/rust-
lang/rust-by-example/edit/master/src/std/arc.md "Suggest an edit")

#  Arc

When shared ownership between threads is needed, ` Arc ` (Atomically Reference
Counted) can be used. This struct, via the ` Clone ` implementation can create
a reference pointer for the location of a value in the memory heap while
increasing the reference counter. As it shares ownership between threads, when
the last reference pointer to a value is out of scope, the variable is
dropped.

    
    
    use std::time::Duration;
    use std::sync::Arc;
    use std::thread;
    
    fn main() {
        // This variable declaration is where its value is specified.
        let apple = Arc::new("the same apple");
    
        for _ in 0..10 {
            // Here there is no value specification as it is a pointer to a
            // reference in the memory heap.
            let apple = Arc::clone(&apple);
    
            thread::spawn(move || {
                // As Arc was used, threads can be spawned using the value allocated
                // in the Arc variable pointer's location.
                println!("{:?}", apple);
            });
        }
    
        // Make sure all Arc instances are printed from spawned threads.
        thread::sleep(Duration::from_secs(1));
    }
    

[ __ ](../std/rc.html "Previous chapter") [ __ ](../std_misc.html "Next
chapter")

[ __ ](../std/rc.html "Previous chapter") [ __ ](../std_misc.html "Next
chapter")
traParameter(key) ` â

See  ` crashReporter.removeExtraParameter(key) ` .

##  Crash Report Payload  â

The crash reporter will send the following data to the ` submitURL ` as a `
multipart/form-data ` ` POST ` :

  * ` ver ` string - The version of Electron. 
  * ` platform ` string - e.g. 'win32'. 
  * ` process_type ` string - e.g. 'renderer'. 
  * ` guid ` string - e.g. '5e1286fc-da97-479e-918b-6bfb0c3d1c72'. 
  * ` _version ` string - The version in ` package.json ` . 
  * ` _productName ` string - The product name in the ` crashReporter ` ` options ` object. 
  * ` prod ` string - Name of the underlying product. In this case Electron. 
  * ` _companyName ` string - The company name in the ` crashReporter ` ` options ` object. 
  * ` upload_file_minidump ` File - The crash report in the format of ` minidump ` . 
  * All level one properties of the ` extra ` object in the ` crashReporter ` ` options ` object. 

[ Edit this page
](https://github.com/electron/electron/edit/main/docs/api/crash-reporter.md)

[ Previous  contentTracing  ](/docs/latest/api/content-tracing) [ Next
desktopCapturer  ](/docs/latest/api/desktop-capturer)

  * Methods 
    * ` start `
    * ` getLastCrashReport `
    * ` getUploadedReports `
    * ` getUploadToServer `
    * ` setUploadToServer `
    * ` addExtraParameter `
    * ` removeExtraParameter `
    * ` getParameters `
  * In Node child processes 
    * ` crashReporter.start `
    * ` crashReporter.getParameters `
    * ` crashReporter.addExtraParameter `
    * ` crashReporter.removeExtraParameter `
  * Crash Report Payload 

Docs

  * [ Getting Started ](/docs/latest/)
  * [ API Reference ](/docs/latest/api/app)

Checklists

  * [ Performance ](/docs/latest/tutorial/performance)
  * [ Security ](/docs/latest/tutorial/security)

Tools

  * [ Electron Forge ](https://electronforge.io)
  * [ Electron Fiddle ](/fiddle)

Community

  * [ Governance ](/governance)
  * [ Resources ](/community)
  * [ Discord  ](https://discordapp.com/invite/APGC3k5yaH)
  * [ Twitter  ](https://twitter.com/electronjs)
  * [ Mastodon  ](https://social.lfx.dev/@electronjs)
  * [ Stack Overflow  ](https://stackoverflow.com/questions/tagged/electron)

More

  * [ GitHub  ](https://github.com/electron/electron)
  * [ Open Collective  ](https://opencollective.com/electron)
  * [ Infrastructure Dashboard  ](https://p.datadoghq.com/sb/c44e1df0-85d7-11ee-94c9-da7ad0900002-c245f7ef47d0d0c32abecdc0938c2a85)

[ ![OpenJS Foundation Logo](/assets/img/openjsf_logo.svg) ![OpenJS Foundation
Logo](/assets/img/openjsf_logo-dark.svg) ](https://openjsf.org/)

Copyright Â© 2023 OpenJS Foundation and Electron contributors.

Hosting and infrastructure graciously provided by

![](/assets/third-parties/azure.png) ![](/assets/third-
parties/heroku_dark.png) ![](/assets/third-parties/heroku_light.png)
![](/assets/third-parties/datadog_dark.png) ![](/assets/third-
parties/datadog_light.png)
uirrel.Mac) README for more information. 

Sets the ` url ` and initialize the auto updater.

###  ` autoUpdater.getFeedURL() ` â

Returns ` string ` \- The current update feed URL.

###  ` autoUpdater.checkForUpdates() ` â

Asks the server whether there is an update. You must call ` setFeedURL `
before using this API.

**Note:** If an update is available it will be downloaded automatically.
Calling ` autoUpdater.checkForUpdates() ` twice will download the update two
times.

###  ` autoUpdater.quitAndInstall() ` â

Restarts the app and installs the update after it has been downloaded. It
should only be called after ` update-downloaded ` has been emitted.

Under the hood calling ` autoUpdater.quitAndInstall() ` will close all
application windows first, and automatically call ` app.quit() ` after all
windows have been closed.

**Note:** It is not strictly necessary to call this function to apply an
update, as a successfully downloaded update will always be applied the next
time the application starts.

[ Edit this page
](https://github.com/electron/electron/edit/main/docs/api/auto-updater.md)

[ Previous  app  ](/docs/latest/api/app) [ Next  BrowserView
](/docs/latest/api/browser-view)

  * Platform Notices 
    * macOS 
    * Windows 
  * Events 
    * ` 'error' `
    * ` 'checking-for-update' `
    * ` 'update-available' `
    * ` 'update-not-available' `
    * ` 'update-downloaded' `
    * ` 'before-quit-for-update' `
  * Methods 
    * ` setFeedURL `
    * ` getFeedURL `
    * ` checkForUpdates `
    * ` quitAndInstall `

Docs

  * [ Getting Started ](/docs/latest/)
  * [ API Reference ](/docs/latest/api/app)

Checklists

  * [ Performance ](/docs/latest/tutorial/performance)
  * [ Security ](/docs/latest/tutorial/security)

Tools

  * [ Electron Forge ](https://electronforge.io)
  * [ Electron Fiddle ](/fiddle)

Community

  * [ Governance ](/governance)
  * [ Resources ](/community)
  * [ Discord  ](https://discordapp.com/invite/APGC3k5yaH)
  * [ Twitter  ](https://twitter.com/electronjs)
  * [ Mastodon  ](https://social.lfx.dev/@electronjs)
  * [ Stack Overflow  ](https://stackoverflow.com/questions/tagged/electron)

More

  * [ GitHub  ](https://github.com/electron/electron)
  * [ Open Collective  ](https://opencollective.com/electron)
  * [ Infrastructure Dashboard  ](https://p.datadoghq.com/sb/c44e1df0-85d7-11ee-94c9-da7ad0900002-c245f7ef47d0d0c32abecdc0938c2a85)

[ ![OpenJS Foundation Logo](/assets/img/openjsf_logo.svg) ![OpenJS Foundation
Logo](/assets/img/openjsf_logo-dark.svg) ](https://openjsf.org/)

Copyright Â© 2023 OpenJS Foundation and Electron contributors.

Hosting and infrastructure graciously provided by

![](/assets/third-parties/azure.png) ![](/assets/third-
parties/heroku_dark.png) ![](/assets/third-parties/heroku_light.png)
![](/assets/third-parties/datadog_dark.png) ![](/assets/third-
parties/datadog_light.png)