File: elements.html

package info (click to toggle)
pygame 2.1.2%2Bdfsg-5
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 32,416 kB
  • sloc: ansic: 66,042; python: 46,176; javascript: 9,214; objc: 273; sh: 78; makefile: 56; cpp: 25
file content (103 lines) | stat: -rw-r--r-- 3,570 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
{%- extends "!layout.html" %}

{%- if not theme_relbar %}
{%-   block relbar1 %}{# Do not want bar across the top #}{% endblock %}
{%- endif %}

{#- Classic header with Snakey on the left, page links on the right.
 #}
{%- macro header() %}
  <div class="header">
    <table>
      <tr>
	<td class="logo">
	  <a href="{{ theme_home_uri }}">
{%-         set logo_path = '_static/' + logo %}
	    <img src="{{ pathto(logo_path, 1) }}"/>
	  </a>
	  <h5>pygame documentation</h5>
	</td>
	<td class="pagelinks">
	  <div class="top">
	    <a href="{{ theme_home_uri }}">Pygame Home</a> ||
	    <a href="{{ pathto(master_doc) }}">Help Contents</a> ||
	    <a href="{{ pathto('genindex') }}">Reference Index</a>

        <form action="{{ pathto('search') }}" method="get" style="display:inline;float:right;">
          <input name="q" value="" type="text">
          <input value="search" type="submit">
        </form>
	  </div>
	  <hr style="color:black;border-bottom:none;border-style: dotted;border-bottom-style:none;">
{#-

We render three sets of items based on how useful to most apps.

#}
{%- set basic = ['Color', 'display', 'draw', 'event', 'font', 'image', 'key', 'locals', 'mixer', 'mouse', 'music', 'pygame', 'Rect', 'Surface', 'time'] %}
{%- set advanced = ['BufferProxy', 'freetype', 'gfxdraw', 'midi', 'PixelArray', 'pixelcopy', 'sndarray', 'surfarray', 'cursors', 'joystick', 'mask', 'math', 'sprite', 'transform'] %}
{%- set hidden = ['Overlay', 'cdrom', 'sdl2_video', 'sdl2_controller'] %}
{%-   if pyg_sections %}
	  <p class="bottom"><b>Most useful stuff</b>:
{%      set sep = joiner(" | \n") %}
{%-     for section in pyg_sections %}
{%-       set docname = section['docname'] %}
{%-       set simpledocname = docname.split('/')[-1] %}
{%-       set name = section['fullname'].split('.')[-1] %}
{%-       set uri = pathto(docname, 1) + file_suffix -%}
{%-       if name|lower != simpledocname %}
{%-         set uri = uri + '#' + section['refid'] %}
{%-       endif %}
{%-       if name in basic %}
{{- sep() }}	    <a href="{{ uri }}">{{ name }}</a>
{%-       endif %}
{%-     endfor %}
	  </p>

	  <p class="bottom"><b>Advanced stuff</b>:
{%      set sep = joiner(" | \n") %}
{%-     for section in pyg_sections %}
{%-       set docname = section['docname'] %}
{%-       set simpledocname = docname.split('/')[-1] %}
{%-       set name = section['fullname'].split('.')[-1] %}
{%-       set uri = pathto(docname, 1) + file_suffix -%}
{%-       if name|lower != simpledocname %}
{%-         set uri = uri + '#' + section['refid'] %}
{%-       endif %}
{%-       if name in advanced %}
{{- sep() }}	    <a href="{{ uri }}">{{ name }}</a>
{%-       endif %}
{%-     endfor %}
	  </p>

	  <p class="bottom"><b>Other</b>:
{%      set sep = joiner(" | \n") %}
{%-     for section in pyg_sections %}
{%-       set docname = section['docname'] %}
{%-       set simpledocname = docname.split('/')[-1] %}
{%-       set name = section['fullname'].split('.')[-1] %}
{%-       set uri = pathto(docname, 1) + file_suffix -%}
{%-       if name|lower != simpledocname %}
{%-         set uri = uri + '#' + section['refid'] %}
{%-       endif %}
{%-       if name not in basic and name not in advanced and name not in hidden %}
{{- sep() }}	    <a href="{{ uri }}">{{ name }}</a>
{%-       endif %}
{%-     endfor %}
	  </p>


{%-   endif  %}
	</td>
      </tr>
    </table>
  </div>
{%- endmacro %}

{%- block body %}
{%-   block section %}{% endblock %}

<br /><br />
<hr />
<a href="{{ edit_on_github_url }}" rel="nofollow">{{ _('Edit on GitHub') }}</a>
{%- endblock %}