This file is indexed.

/usr/lib/python2.7/dist-packages/PythonCard/spec.py is in python-pythoncard 0.8.2-5.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  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
104
105
106
107
108
109
110
111
112
113
# __version__ = "$Revision: 1.24 $"
# __date__ = "$Date: 2004/05/10 05:01:58 $"

# The format of an entry is:
#
#    '<entry-name>' : {
#        'parent' : < <class-name> | None > ,
#        'events' : < [ '<event-name>', ... ] >,
#        'attributes' : < { '<attribute-name>' : { 
#                         'presence' : < 'mandatory' | 'optional' >,
#                         'default' : <valid-python-value> 
#                       > }
#   }

# How do we distinguish between resource/runtime

# Will 'mouseClick' work if specified in Widget's event list?

# Note that events and attributes are inherited.  The res.Spec class
# depends on the following entries being in order from top to bottom
# based on inheritance.  Component must appear before Widget, Widget
# must appear before TextField, Textfield must appear before PasswordField,
# ad nauseum ;)

specList = [

   { 'name':'Component', 'info':{
        'parent' : None,
        'events' : [],
        'attributes' : {
            'name' : { 'presence' : 'mandatory' },
            'command' : { 'presence' : 'optional', 'default' : None }
        }
    }},

   { 'name':'Application', 'info': {
        'parent' : None,
        'events' : [],
        'attributes' : {
            'name' : { 'presence' : 'mandatory' },
        }
    }},

   { 'name':'MenuBar', 'info': {
        'parent' : None,
        'events' : [],
        'attributes' : {
            'menus' : { 'presence' : 'optional', 'default': [] }
        }
    }},

   { 'name':'Menu' , 'info': {
        'parent' : None,
        'events' : [],
        'attributes' : {
            'name' : { 'presence' : 'mandatory' },
            'label' : { 'presence' : 'mandatory' },
            'enabled' : { 'presence' : 'optional', 'default' : 1 },
            'items' : { 'presence' : 'optional', 'default': [] }
        }
    }},

   { 'name':'MenuItem', 'info': {
        'parent' : 'Component',
        'events' : [],
        'attributes' : {
            'label' : { 'presence' : 'mandatory' },
            'checkable' : { 'presence' : 'optional', 'default': 0 },
            'checked' : { 'presence' : 'optional', 'default': 0 },
            'enabled' : { 'presence' : 'optional', 'default' : 1 }
            }
    }},

   { 'name':'Background', 'info': {
        'parent' : None,
        'events' : ['openBackground'],
        'attributes' : {
            'name' : { 'presence' : 'mandatory' },
            'title' : { 'presence' : 'mandatory' },
            'position' : { 'presence' : 'optional', 'default' : [ -1, -1 ] },
            'size' : { 'presence' : 'optional', 'default' : [ -1, -1 ] },
            'menubar' : { 'presence' : 'optional', 'default' : None },
            'statusBar' : { 'presence' : 'optional', 'default' : 0 },
            'icon' : { 'presence' : 'optional', 'default' : None },
            'foregroundColor' : { 'presence' : 'optional', 'default' : None },
            'backgroundColor' : { 'presence' : 'optional', 'default' : None },
            'image' : { 'presence' : 'optional', 'default' : None } ,
            'tiled' : { 'presence' : 'optional', 'default' : 0 },
            'visible' : { 'presence' : 'optional', 'default' : 1 },
            'style' : { 'presence' : 'optional', 'default' : [] },
            'strings': { 'presence' : 'optional', 'default' : {} },

        }
    }},

   { 'name':'CustomDialog', 'info': {
        'parent' : None,
        #'events' : ['openBackground'],
        'events' : [],
        'attributes' : {
            'name' : { 'presence' : 'mandatory' },
            'title' : { 'presence' : 'mandatory' },
            'position' : { 'presence' : 'optional', 'default' : [ -1, -1 ] },
            'size' : { 'presence' : 'optional', 'default' : [ -1, -1 ] },
            #'file' : { 'presence' : 'mandatory' } ,
            #'foregroundColor' : { 'presence' : 'optional', 'default' : None },
            #'backgroundColor' : { 'presence' : 'optional', 'default' : None },
            'strings': { 'presence' : 'optional', 'default' : {} },
        }
    }},


]