Skip to content

Commit

Permalink
Update copyright text, resolves #8
Browse files Browse the repository at this point in the history
  • Loading branch information
Joonalai committed Feb 19, 2021
1 parent ec59334 commit a669f1c
Show file tree
Hide file tree
Showing 19 changed files with 366 additions and 207 deletions.
40 changes: 18 additions & 22 deletions GlobeBuilder/__init__.py
Original file line number Diff line number Diff line change
@@ -1,27 +1,23 @@
# -*- coding: utf-8 -*-
"""
/***************************************************************************
GlobeBuilder
A QGIS plugin
This plugin adds Globe view
Generated by Plugin Builder: http://g-sherman.github.io/Qgis-Plugin-Builder/
-------------------
begin : 2020-01-10
copyright : (C) 2020 by Gispo Ltd.
email : [email protected]
git sha : $Format:%H$
***************************************************************************/

/***************************************************************************
* *
* This program 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 2 of the License, or *
* (at your option) any later version. *
* *
***************************************************************************/
This script initializes the plugin, making it known to QGIS.
"""
# Gispo Ltd., hereby disclaims all copyright interest in the program GlobeBuilder
# Copyright (C) 2020-2021 Gispo Ltd (https://www.gispo.fi/).
#
#
# This file is part of GlobeBuilder.
#
# GlobeBuilder 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 2 of the License, or
# (at your option) any later version.
#
# GlobeBuilder 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 GlobeBuilder. If not, see <https://www.gnu.org/licenses/>.

import os

Expand Down
20 changes: 20 additions & 0 deletions GlobeBuilder/build.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,25 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-

# Gispo Ltd., hereby disclaims all copyright interest in the program GlobeBuilder
# Copyright (C) 2020-2021 Gispo Ltd (https://www.gispo.fi/).
#
#
# This file is part of GlobeBuilder.
#
# GlobeBuilder 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 2 of the License, or
# (at your option) any later version.
#
# GlobeBuilder 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 GlobeBuilder. If not, see <https://www.gnu.org/licenses/>.

import glob

from qgis_plugin_tools.infrastructure.plugin_maker import PluginMaker
Expand Down
18 changes: 18 additions & 0 deletions GlobeBuilder/core/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Gispo Ltd., hereby disclaims all copyright interest in the program GlobeBuilder
# Copyright (C) 2020-2021 Gispo Ltd (https://www.gispo.fi/).
#
#
# This file is part of GlobeBuilder.
#
# GlobeBuilder 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 2 of the License, or
# (at your option) any later version.
#
# GlobeBuilder 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 GlobeBuilder. If not, see <https://www.gnu.org/licenses/>.
41 changes: 20 additions & 21 deletions GlobeBuilder/core/globe.py
Original file line number Diff line number Diff line change
@@ -1,25 +1,24 @@
# -*- coding: utf-8 -*-
"""
/***************************************************************************
GlobeBuilder
A QGIS plugin
This plugin adds Globe view
-------------------
begin : 2020-01-22
git sha : $Format:%H$
copyright : (C) 2020 by Gispo Ltd.
email : [email protected]
***************************************************************************/
/***************************************************************************
* *
* This program 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 2 of the License, or *
* (at your option) any later version. *
* *
***************************************************************************/
"""

# Gispo Ltd., hereby disclaims all copyright interest in the program GlobeBuilder
# Copyright (C) 2020-2021 Gispo Ltd (https://www.gispo.fi/).
#
#
# This file is part of GlobeBuilder.
#
# GlobeBuilder 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 2 of the License, or
# (at your option) any later version.
#
# GlobeBuilder 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 GlobeBuilder. If not, see <https://www.gnu.org/licenses/>.

import logging
import os

Expand Down
42 changes: 21 additions & 21 deletions GlobeBuilder/core/graticules.py
Original file line number Diff line number Diff line change
@@ -1,24 +1,21 @@
"""
/***************************************************************************
GlobeBuilder
A QGIS plugin
This plugin adds Globe view
-------------------
begin : 2020-09-22
git sha : $Format:%H$
copyright : (C) 2020 by Gispo Ltd.
email : [email protected]
***************************************************************************/
/***************************************************************************
* *
* This program 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 2 of the License, or *
* (at your option) any later version. *
* *
***************************************************************************/
"""
# Gispo Ltd., hereby disclaims all copyright interest in the program GlobeBuilder
# Copyright (C) 2020-2021 Gispo Ltd (https://www.gispo.fi/).
#
#
# This file is part of GlobeBuilder.
#
# GlobeBuilder 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 2 of the License, or
# (at your option) any later version.
#
# GlobeBuilder 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 GlobeBuilder. If not, see <https://www.gnu.org/licenses/>.

from PyQt5.QtGui import QColor
from qgis.core import (QgsProcessingFeedback, QgsVectorLayer, QgsFillSymbol,
Expand Down Expand Up @@ -61,10 +58,12 @@ def _set_styles(layer, stroke_color):
fill_color.setAlpha(0)
fill_symbol_layer.setFillColor(fill_color)
fill_symbol_layer.setStrokeColor(stroke_color)
# noinspection PyUnresolvedReferences
renderer.setSymbol(fill_symbol)
layer.triggerRepaint()

def _create_graticule_layer(self, tmp_grid_layer) -> QgsVectorLayer:
# noinspection PyUnresolvedReferences
import processing
params = {
'INPUT': tmp_grid_layer,
Expand All @@ -75,6 +74,7 @@ def _create_graticule_layer(self, tmp_grid_layer) -> QgsVectorLayer:
return layer

def _create_grid_layer(self) -> QgsVectorLayer:
# noinspection PyUnresolvedReferences
import processing
params = {'CRS': WGS84,
'EXTENT': '-180,180,-90,90 [EPSG:4326]', 'HOVERLAY': 0, 'HSPACING': self.spacing,
Expand Down
44 changes: 21 additions & 23 deletions GlobeBuilder/core/halo.py
Original file line number Diff line number Diff line change
@@ -1,28 +1,26 @@
"""
/***************************************************************************
GlobeBuilder
A QGIS plugin
This plugin adds Globe view
-------------------
begin : 2020-09-22
git sha : $Format:%H$
copyright : (C) 2020 by Gispo Ltd.
email : [email protected]
***************************************************************************/
/***************************************************************************
* *
* This program 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 2 of the License, or *
* (at your option) any later version. *
* *
***************************************************************************/
"""
from qgis.gui import QgisInterface
# Gispo Ltd., hereby disclaims all copyright interest in the program GlobeBuilder
# Copyright (C) 2020-2021 Gispo Ltd (https://www.gispo.fi/).
#
#
# This file is part of GlobeBuilder.
#
# GlobeBuilder 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 2 of the License, or
# (at your option) any later version.
#
# GlobeBuilder 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 GlobeBuilder. If not, see <https://www.gnu.org/licenses/>.

from qgis.core import (QgsFillSymbol, QgsEffectStack, QgsDropShadowEffect, QgsInnerShadowEffect,
QgsGeometryGeneratorSymbolLayer, QgsVectorLayer, QgsFeature, QgsGeometry, QgsPointXY,
QgsCoordinateTransform, QgsProject)
from qgis.gui import QgisInterface

from ..definitions.projections import Projections
from ..definitions.settings import (TRANSPARENT_COLOR, HaloDrawMethod, EARTH_RADIUS, DEFAULT_HALO_DRAW_METHOD,
Expand Down Expand Up @@ -55,8 +53,8 @@ def create_halo_layer(self, use_effects, stroke_color, fill_color=None):
self.iface.mainWindow().blockSignals(False)

feature = QgsFeature()
# noinspection PyArgumentList
if self.projection == Projections.AZIMUTHAL_ORTHOGRAPHIC:
# noinspection PyArgumentList
geom = QgsGeometry.fromPointXY(QgsPointXY(self.origin['lat'], self.origin['lon']))
if draw_method == HaloDrawMethod.buffered_point:
geom = geom.buffer(EARTH_RADIUS, DEFAULT_NUMBER_OF_SEGMENTS)
Expand Down
18 changes: 18 additions & 0 deletions GlobeBuilder/core/utils/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Gispo Ltd., hereby disclaims all copyright interest in the program GlobeBuilder
# Copyright (C) 2020-2021 Gispo Ltd (https://www.gispo.fi/).
#
#
# This file is part of GlobeBuilder.
#
# GlobeBuilder 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 2 of the License, or
# (at your option) any later version.
#
# GlobeBuilder 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 GlobeBuilder. If not, see <https://www.gnu.org/licenses/>.
39 changes: 19 additions & 20 deletions GlobeBuilder/core/utils/geocoder.py
Original file line number Diff line number Diff line change
@@ -1,25 +1,24 @@
# -*- coding: utf-8 -*-
"""
/***************************************************************************
GlobeBuilder
A QGIS plugin
This plugin adds Globe view
-------------------
begin : 2020-01-23
git sha : $Format:%H$
copyright : (C) 2020 by Gispo Ltd.
email : [email protected]
***************************************************************************/

/***************************************************************************
* *
* This program 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 2 of the License, or *
* (at your option) any later version. *
* *
***************************************************************************/
"""
# Gispo Ltd., hereby disclaims all copyright interest in the program GlobeBuilder
# Copyright (C) 2020-2021 Gispo Ltd (https://www.gispo.fi/).
#
#
# This file is part of GlobeBuilder.
#
# GlobeBuilder 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 2 of the License, or
# (at your option) any later version.
#
# GlobeBuilder 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 GlobeBuilder. If not, see <https://www.gnu.org/licenses/>.

import json
import logging

Expand Down
43 changes: 21 additions & 22 deletions GlobeBuilder/core/utils/utils.py
Original file line number Diff line number Diff line change
@@ -1,25 +1,24 @@
# -*- coding: utf-8 -*-
"""
/***************************************************************************
GlobeBuilder
A QGIS plugin
This plugin adds Globe view
-------------------
begin : 2020-01-22
git sha : $Format:%H$
copyright : (C) 2020 by Gispo Ltd.
email : [email protected]
***************************************************************************/
/***************************************************************************
* *
* This program 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 2 of the License, or *
* (at your option) any later version. *
* *
***************************************************************************/
"""

# Gispo Ltd., hereby disclaims all copyright interest in the program GlobeBuilder
# Copyright (C) 2020-2021 Gispo Ltd (https://www.gispo.fi/).
#
#
# This file is part of GlobeBuilder.
#
# GlobeBuilder 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 2 of the License, or
# (at your option) any later version.
#
# GlobeBuilder 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 GlobeBuilder. If not, see <https://www.gnu.org/licenses/>.

from qgis.core import QgsPrintLayout, QgsFillSymbol, QgsRuleBasedRenderer, QgsFeatureRequest, \
QgsCoordinateTransformContext, QgsCoordinateTransform

Expand All @@ -42,7 +41,7 @@ def create_layout(layout_name, qgis_instance):


def set_selection_based_style(layer, s_color, else_color):
# noinspection PyCallByClass
# noinspection PyCallByClass,PyArgumentList
fill_for_selected = QgsFillSymbol.createSimple({'color': 'blue'})
fill_for_selected.setColor(s_color)
rule_s = QgsRuleBasedRenderer.Rule(fill_for_selected, label=tr(u"Selected"),
Expand Down
18 changes: 18 additions & 0 deletions GlobeBuilder/definitions/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Gispo Ltd., hereby disclaims all copyright interest in the program GlobeBuilder
# Copyright (C) 2020-2021 Gispo Ltd (https://www.gispo.fi/).
#
#
# This file is part of GlobeBuilder.
#
# GlobeBuilder 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 2 of the License, or
# (at your option) any later version.
#
# GlobeBuilder 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 GlobeBuilder. If not, see <https://www.gnu.org/licenses/>.
Loading

0 comments on commit a669f1c

Please sign in to comment.