Update imports, copyright notices.

This commit is contained in:
Simon Forman
2019-05-06 13:26:07 -07:00
parent d3b413493f
commit 9292d00534
9 changed files with 113 additions and 23 deletions
+19
View File
@@ -1,3 +1,22 @@
# -*- coding: utf-8 -*-
#
# Copyright © 2019 Simon Forman
#
# This file is part of Thun
#
# Thun is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# Thun is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Thun. If not see <http://www.gnu.org/licenses/>.
#
from sys import stderr
from traceback import format_exc
import pygame
+1 -1
View File
@@ -16,7 +16,7 @@ from joy.library import (
SimpleFunctionWrapper,
)
from joy.utils.stack import list_to_stack, concat
from vui import core, text_viewer, stack_viewer
from joy.vui import core, text_viewer, stack_viewer
def install(command): D[command.name] = command
+8 -8
View File
@@ -1,21 +1,21 @@
# -*- coding: utf-8 -*-
#
# Copyright © 2018 Simon Forman
# Copyright © 2019 Simon Forman
#
# This file is part of joy.py
# This file is part of Thun
#
# joy.py is free software: you can redistribute it and/or modify
# Thun is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# joy.py is distributed in the hope that it will be useful,
# Thun is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with joy.py. If not see <http://www.gnu.org/licenses/>.
# along with Thun. If not see <http://www.gnu.org/licenses/>.
#
'''
This module implements a simple visual display system modeled on Oberon.
@@ -29,13 +29,13 @@ from copy import copy
from sys import stderr
from traceback import format_exc
import pygame
from core import (
from .core import (
open_viewer_on_string,
GREY,
MOUSE_EVENTS,
)
from viewer import Viewer
import text_viewer
from .viewer import Viewer
from joy.vui import text_viewer
class Display(object):
+20 -6
View File
@@ -1,8 +1,26 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# Copyright © 2019 Simon Forman
#
# This file is part of Thun
#
# Thun is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# Thun is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Thun. If not see <http://www.gnu.org/licenses/>.
#
import os, sys, traceback
import pygame
from joy.library import initialize, DefinitionWrapper, SimpleFunctionWrapper
import core, display, persist_task
from joy.vui import core, display, persist_task
FULLSCREEN = '-f' in sys.argv
@@ -107,7 +125,3 @@ def main(screen, clock, pt):
sys.stdout = old_stdout
return name_space['d']
if __name__ == '__main__':
main(*init())
+20 -1
View File
@@ -1,8 +1,27 @@
# -*- coding: utf-8 -*-
#
# Copyright © 2019 Simon Forman
#
# This file is part of Thun
#
# Thun is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# Thun is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Thun. If not see <http://www.gnu.org/licenses/>.
#
import os, pickle, traceback
from collections import Counter
from dulwich.errors import NotGitRepository
from dulwich.repo import Repo
import core, init_joy_home
from joy.vui import core, init_joy_home
def open_repo(repo_dir=None, initialize=False):
+20 -1
View File
@@ -1,5 +1,24 @@
# -*- coding: utf-8 -*-
#
# Copyright © 2019 Simon Forman
#
# This file is part of Thun
#
# Thun is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# Thun is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Thun. If not see <http://www.gnu.org/licenses/>.
#
from joy.utils.stack import expression_to_string, iter_stack
import core, text_viewer
from joy.vui import core, text_viewer
MAX_WIDTH = 64
+22 -3
View File
@@ -1,7 +1,26 @@
# -*- coding: utf-8 -*-
#
# Copyright © 2019 Simon Forman
#
# This file is part of Thun
#
# Thun is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# Thun is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Thun. If not see <http://www.gnu.org/licenses/>.
#
import string
import pygame
from joy.utils.stack import expression_to_string
from core import (
from joy.vui.core import (
ARROW_KEYS,
BACKGROUND as BG,
FOREGROUND as FG,
@@ -11,8 +30,8 @@ from core import (
SUCCESS,
push,
)
import viewer, font_data
reload(viewer)
from joy.vui import viewer, font_data
#reload(viewer)
MenuViewer = viewer.MenuViewer
+2 -2
View File
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
#
# Copyright © 2018 Simon Forman
# Copyright © 2019 Simon Forman
#
# This file is part of joy.py
#
@@ -18,7 +18,7 @@
# along with joy.py. If not see <http://www.gnu.org/licenses/>.
#
import pygame
from core import BACKGROUND, FOREGROUND
from joy.vui.core import BACKGROUND, FOREGROUND
class Viewer(object):