mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2025-01-13 22:10:08 +00:00
Merge branch 'ebassi/docs-repo-link' into 'main'
docs: Point source links to the correct branch See merge request GNOME/gtk!4373
This commit is contained in:
commit
48dc6ecfe3
@ -20,7 +20,7 @@ name = "basic"
|
||||
show_index_summary = true
|
||||
|
||||
[source-location]
|
||||
base_url = "https://gitlab.gnome.org/GNOME/gtk/-/blob/master/"
|
||||
base_url = "https://gitlab.gnome.org/GNOME/gtk/-/blob/main/"
|
||||
|
||||
[extra]
|
||||
content_images = [
|
||||
|
@ -20,7 +20,7 @@ name = "basic"
|
||||
show_index_summary = true
|
||||
|
||||
[source-location]
|
||||
base_url = "https://gitlab.gnome.org/GNOME/gtk/-/blob/master/"
|
||||
base_url = "https://gitlab.gnome.org/GNOME/gtk/-/blob/main/"
|
||||
|
||||
[extra]
|
||||
content_images = [
|
||||
|
@ -43,7 +43,7 @@ show_index_summary = true
|
||||
show_class_hierarchy = true
|
||||
|
||||
[source-location]
|
||||
base_url = "https://gitlab.gnome.org/GNOME/gtk/-/blob/master/"
|
||||
base_url = "https://gitlab.gnome.org/GNOME/gtk/-/blob/main/"
|
||||
|
||||
[extra]
|
||||
content_files = [
|
||||
|
@ -38,7 +38,7 @@ show_index_summary = true
|
||||
show_class_hierarchy = true
|
||||
|
||||
[source-location]
|
||||
base_url = "https://gitlab.gnome.org/GNOME/gtk/-/blob/master/"
|
||||
base_url = "https://gitlab.gnome.org/GNOME/gtk/-/blob/main/"
|
||||
|
||||
[extra]
|
||||
content_images = [
|
||||
|
@ -170,7 +170,7 @@ activate (GtkApplication *app,
|
||||
box = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
|
||||
gtk_widget_set_halign (box, GTK_ALIGN_CENTER);
|
||||
gtk_widget_set_valign (box, GTK_ALIGN_CENTER);
|
||||
|
||||
|
||||
gtk_window_set_child (GTK_WINDOW (window), box);
|
||||
|
||||
button = gtk_button_new_with_label ("Hello World");
|
||||
@ -752,7 +752,7 @@ templates, resources, application menus, settings, [class@Gtk.HeaderBar], [class
|
||||
|
||||
The full, buildable sources for these examples can be found in the
|
||||
`examples` directory of the GTK source distribution, or
|
||||
[online](https://gitlab.gnome.org/GNOME/gtk/blob/master/examples) in the GTK
|
||||
[online](https://gitlab.gnome.org/GNOME/gtk/blob/main/examples) in the GTK
|
||||
source code repository. You can build each example separately by using make
|
||||
with the `Makefile.example` file. For more information, see the `README`
|
||||
included in the examples directory.
|
||||
@ -972,7 +972,7 @@ example_app_window_class_init (ExampleAppWindowClass *class)
|
||||
...
|
||||
```
|
||||
|
||||
([full source](https://gitlab.gnome.org/GNOME/gtk/blob/master/examples/application2/exampleappwin.c))
|
||||
([full source](https://gitlab.gnome.org/GNOME/gtk/blob/main/examples/application2/exampleappwin.c))
|
||||
|
||||
You may have noticed that we used the `_from_resource()` variant of the function
|
||||
that sets a template. Now we need to use
|
||||
@ -1043,7 +1043,7 @@ example_app_window_class_init (ExampleAppWindowClass *class)
|
||||
...
|
||||
```
|
||||
|
||||
([full source](https://gitlab.gnome.org/GNOME/gtk/blob/master/examples/application3/exampleappwin.c))
|
||||
([full source](https://gitlab.gnome.org/GNOME/gtk/blob/main/examples/application3/exampleappwin.c))
|
||||
|
||||
Now we revisit the `example_app_window_open()` function that is called for each
|
||||
commandline argument, and construct a GtkTextView that we then add as a page
|
||||
@ -1087,7 +1087,7 @@ example_app_window_open (ExampleAppWindow *win,
|
||||
...
|
||||
```
|
||||
|
||||
([full source](https://gitlab.gnome.org/GNOME/gtk/blob/master/examples/application3/exampleappwin.c))
|
||||
([full source](https://gitlab.gnome.org/GNOME/gtk/blob/main/examples/application3/exampleappwin.c))
|
||||
|
||||
Lastly, we add a [class@Gtk.StackSwitcher] to the titlebar area in the UI file, and we
|
||||
tell it to display information about our stack.
|
||||
@ -1188,7 +1188,7 @@ example_app_class_init (ExampleAppClass *class)
|
||||
...
|
||||
```
|
||||
|
||||
([full source](https://gitlab.gnome.org/GNOME/gtk/blob/master/examples/application4/exampleapp.c))
|
||||
([full source](https://gitlab.gnome.org/GNOME/gtk/blob/main/examples/application4/exampleapp.c))
|
||||
|
||||
Our preferences menu item does not do anything yet, but the Quit menu item
|
||||
is fully functional. Note that it can also be activated by the usual Ctrl-Q
|
||||
@ -1258,7 +1258,7 @@ example_app_window_init (ExampleAppWindow *win)
|
||||
...
|
||||
```
|
||||
|
||||
([full source](https://gitlab.gnome.org/GNOME/gtk/blob/master/examples/application5/exampleappwin.c))
|
||||
([full source](https://gitlab.gnome.org/GNOME/gtk/blob/main/examples/application5/exampleappwin.c))
|
||||
|
||||
The code to connect the font setting is a little more involved, since there
|
||||
is no simple object property that it corresponds to, so we are not going to
|
||||
@ -1429,7 +1429,7 @@ preferences_activated (GSimpleAction *action,
|
||||
...
|
||||
```
|
||||
|
||||
([full source](https://gitlab.gnome.org/GNOME/gtk/blob/master/examples/application6/exampleapp.c))
|
||||
([full source](https://gitlab.gnome.org/GNOME/gtk/blob/main/examples/application6/exampleapp.c))
|
||||
|
||||
After all this work, our application can now show a preference dialog
|
||||
like this:
|
||||
@ -1549,7 +1549,7 @@ example_app_window_init (ExampleAppWindow *win)
|
||||
...
|
||||
```
|
||||
|
||||
([full source](https://gitlab.gnome.org/GNOME/gtk/blob/master/examples/application7/exampleappwin.c))
|
||||
([full source](https://gitlab.gnome.org/GNOME/gtk/blob/main/examples/application7/exampleappwin.c))
|
||||
|
||||
With the search bar, our application now looks like this:
|
||||
|
||||
@ -1682,7 +1682,7 @@ example_app_window_init (ExampleAppWindow *win)
|
||||
...
|
||||
```
|
||||
|
||||
([full source](https://gitlab.gnome.org/GNOME/gtk/blob/master/examples/application8/exampleappwin.c))
|
||||
([full source](https://gitlab.gnome.org/GNOME/gtk/blob/main/examples/application8/exampleappwin.c))
|
||||
|
||||
What our application looks like now:
|
||||
|
||||
@ -1760,10 +1760,10 @@ example_app_window_init (ExampleAppWindow *win)
|
||||
...
|
||||
```
|
||||
|
||||
([full source](https://gitlab.gnome.org/GNOME/gtk/blob/master/examples/application9/exampleappwin.c))
|
||||
([full source](https://gitlab.gnome.org/GNOME/gtk/blob/main/examples/application9/exampleappwin.c))
|
||||
|
||||
We also need a function that counts the lines of the currently active tab,
|
||||
and updates the `lines` label. See the [full source](https://gitlab.gnome.org/GNOME/gtk/blob/master/examples/application9/exampleappwin.c)
|
||||
and updates the `lines` label. See the [full source](https://gitlab.gnome.org/GNOME/gtk/blob/main/examples/application9/exampleappwin.c)
|
||||
if you are interested in the details.
|
||||
|
||||
This brings our example application to this appearance:
|
||||
|
@ -43,7 +43,7 @@ show_index_summary = true
|
||||
show_class_hierarchy = true
|
||||
|
||||
[source-location]
|
||||
base_url = "https://gitlab.gnome.org/GNOME/gtk/-/blob/master/"
|
||||
base_url = "https://gitlab.gnome.org/GNOME/gtk/-/blob/main/"
|
||||
|
||||
[extra]
|
||||
# The same order will be used when generating the index
|
||||
|
@ -26,7 +26,7 @@ GTK with your code applied, and run the test suite, on multiple platforms
|
||||
and architectures, and verify that nothing breaks. They also allow us to
|
||||
do proper code reviews, so we can iterate over the changes.
|
||||
|
||||
You should follow the [contribution guide](https://gitlab.gnome.org/GNOME/gtk/blob/master/CONTRIBUTING.md)
|
||||
You should follow the [contribution guide](https://gitlab.gnome.org/GNOME/gtk/blob/main/CONTRIBUTING.md)
|
||||
for GTK, available on GitLab.
|
||||
|
||||
If you want to discuss your approach before or after working on it,
|
||||
|
@ -1,16 +1,16 @@
|
||||
#!/usr/bin/env perl
|
||||
|
||||
# Updates https://gitlab.gnome.org/GNOME/gtk/tree/master/gdk/gdkkeysyms.h from upstream (X.org 7.x),
|
||||
# Updates https://gitlab.gnome.org/GNOME/gtk/tree/main/gdk/gdkkeysyms.h from upstream (X.org 7.x),
|
||||
# from https://cgit.freedesktop.org/xorg/proto/x11proto/plain/keysymdef.h
|
||||
#
|
||||
#
|
||||
# Author : Simos Xenitellis <simos at gnome dot org>.
|
||||
# Author : Bastien Nocera <hadess@hadess.net>
|
||||
# Version : 1.2
|
||||
#
|
||||
# Input : https://cgit.freedesktop.org/xorg/proto/x11proto/plain/keysymdef.h
|
||||
# Input : https://cgit.freedesktop.org/xorg/proto/x11proto/plain/XF86keysym.h
|
||||
# Output : https://gitlab.gnome.org/GNOME/gtk/tree/master/gdk/gdkkeysyms.h
|
||||
#
|
||||
# Output : https://gitlab.gnome.org/GNOME/gtk/tree/main/gdk/gdkkeysyms.h
|
||||
#
|
||||
# Notes : It downloads keysymdef.h from the Internet, if not found locally,
|
||||
# Notes : and creates an updated gdkkeysyms.h
|
||||
# Notes : This version updates the source of gdkkeysyms.h from CVS to the GIT server.
|
||||
@ -24,7 +24,7 @@ if ( ! -f "keysymdef.h" )
|
||||
{
|
||||
print "Trying to download keysymdef.h from\n";
|
||||
print "http://cgit.freedesktop.org/xorg/proto/x11proto/plain/keysymdef.h\n";
|
||||
die "Unable to download keysymdef.h from http://cgit.freedesktop.org/xorg/proto/x11proto/plain/keysymdef.h\n"
|
||||
die "Unable to download keysymdef.h from http://cgit.freedesktop.org/xorg/proto/x11proto/plain/keysymdef.h\n"
|
||||
unless system("wget -c -O keysymdef.h \"http://cgit.freedesktop.org/xorg/proto/x11proto/plain/keysymdef.h\"") == 0;
|
||||
print " done.\n\n";
|
||||
}
|
||||
@ -39,7 +39,7 @@ if ( ! -f "XF86keysym.h" )
|
||||
{
|
||||
print "Trying to download XF86keysym.h from\n";
|
||||
print "http://cgit.freedesktop.org/xorg/proto/x11proto/plain/XF86keysym.h\n";
|
||||
die "Unable to download keysymdef.h from http://cgit.freedesktop.org/xorg/proto/x11proto/plain/XF86keysym.h\n"
|
||||
die "Unable to download keysymdef.h from http://cgit.freedesktop.org/xorg/proto/x11proto/plain/XF86keysym.h\n"
|
||||
unless system("wget -c -O XF86keysym.h \"http://cgit.freedesktop.org/xorg/proto/x11proto/plain/XF86keysym.h\"") == 0;
|
||||
print " done.\n\n";
|
||||
}
|
||||
@ -82,7 +82,7 @@ print OUT_GDKKEYSYMS $LICENSE_HEADER;
|
||||
print OUT_GDKKEYSYMS<<EOF;
|
||||
|
||||
/*
|
||||
* File auto-generated from script https://gitlab.gnome.org/GNOME/gtk/tree/master/gdk/gdkkeysyms-update.pl
|
||||
* File auto-generated from script https://gitlab.gnome.org/GNOME/gtk/tree/main/gdk/gdkkeysyms-update.pl
|
||||
* using the input file
|
||||
* http://cgit.freedesktop.org/xorg/proto/x11proto/plain/keysymdef.h
|
||||
* and
|
||||
@ -111,7 +111,7 @@ while (<IN_KEYSYMDEF>)
|
||||
|
||||
$_ = $keysymelements[1];
|
||||
die "Internal error, was expecting \"XC_*\", found: $_\n" if ( ! /^XK_/ );
|
||||
|
||||
|
||||
$_ = $keysymelements[2];
|
||||
die "Internal error, was expecting \"0x*\", found: $_\n" if ( ! /^0x/ );
|
||||
|
||||
|
@ -18,7 +18,7 @@
|
||||
|
||||
|
||||
/*
|
||||
* File auto-generated from script https://gitlab.gnome.org/GNOME/gtk/tree/master/gdk/gdkkeysyms-update.pl
|
||||
* File auto-generated from script https://gitlab.gnome.org/GNOME/gtk/tree/main/gdk/gdkkeysyms-update.pl
|
||||
* using the input file
|
||||
* http://cgit.freedesktop.org/xorg/proto/x11proto/plain/keysymdef.h
|
||||
* and
|
||||
|
Loading…
Reference in New Issue
Block a user