Bearsampp
2026.3.26
API documentation
Loading...
Searching...
No Matches
class.tpl.app.python.php
Go to the documentation of this file.
1
<?php
2
/*
3
*
4
* * Copyright (c) 2021-2024 Bearsampp
5
* * License: GNU General Public License version 3 or later; see LICENSE.txt
6
* * Website: https://bearsampp.com
7
* * Github: https://github.com/Bearsampp
8
*
9
*/
10
18
class
TplAppPython
19
{
20
// Constant for the Python menu identifier
21
const
MENU
=
'python'
;
22
30
public
static
function
process
()
31
{
32
global
$bearsamppLang
;
33
34
return
TplApp::getMenu
(
$bearsamppLang
->getValue(
Lang::PYTHON
), self::MENU, get_called_class());
35
}
36
45
public
static
function
getMenuPython
()
46
{
47
global
$bearsamppLang
, $bearsamppTools;
48
49
// Generate menu item for Python console
50
$resultItems =
TplAestan::getItemPowerShell
(
51
$bearsamppLang
->getValue(
Lang::PYTHON_CONSOLE
),
52
TplAestan::GLYPH_PYTHON
,
53
null
,
54
$bearsamppTools->getPowerShell()->getTabTitlePython(),
55
$bearsamppTools->getPython()->getSymlinkPath(),
56
null
57
) . PHP_EOL;
58
59
// Generate menu item for Python IDLE
60
$resultItems .=
TplAestan::getItemExe
(
61
$bearsamppLang
->getValue(
Lang::PYTHON
) .
' IDLE'
,
62
$bearsamppTools->getPython()->getIdleExe(),
63
TplAestan::GLYPH_PYTHON
64
) . PHP_EOL;
65
66
return
$resultItems;
67
}
68
}
$bearsamppLang
global $bearsamppLang
Definition
ajax.apache.php:16
Lang\PYTHON_CONSOLE
const PYTHON_CONSOLE
Definition
class.lang.php:60
Lang\PYTHON
const PYTHON
Definition
class.lang.php:148
TplAestan\getItemPowerShell
static getItemPowerShell($caption, $glyph, $id=null, $title=null, $initDir=null, $command=null)
Definition
class.tpl.aestan.php:141
TplAestan\getItemExe
static getItemExe($caption, $exe, $glyph, $params=null)
Definition
class.tpl.aestan.php:232
TplAestan\GLYPH_PYTHON
const GLYPH_PYTHON
Definition
class.tpl.aestan.php:90
TplApp\getMenu
static getMenu($caption, $menu, $class)
Definition
class.tpl.app.php:190
TplAppPython
Definition
class.tpl.app.python.php:19
TplAppPython\MENU
const MENU
Definition
class.tpl.app.python.php:21
TplAppPython\process
static process()
Definition
class.tpl.app.python.php:30
TplAppPython\getMenuPython
static getMenuPython()
Definition
class.tpl.app.python.php:45
Bearsampp-development
sandbox
core
classes
tpls
app
class.tpl.app.python.php
Generated by
1.16.1