Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/qgis/Quantum-GIS
Browse files Browse the repository at this point in the history
  • Loading branch information
volaya committed Oct 29, 2012
2 parents e5437c4 + d6e3188 commit 404bce6
Show file tree
Hide file tree
Showing 34 changed files with 886 additions and 1,051 deletions.
30 changes: 9 additions & 21 deletions CMakeLists.txt
Expand Up @@ -388,12 +388,9 @@ ELSE (WIN32)
SET (DEFAULT_PLUGIN_SUBDIR ../PlugIns/qgis)
SET (QGIS_PLUGIN_SUBDIR_REV ../../MacOS)
SET (DEFAULT_INCLUDE_SUBDIR include/qgis)
# path for framework references
IF (ENABLE_TESTS)
SET (CMAKE_INSTALL_NAME_DIR ${CMAKE_BINARY_DIR}/output/lib)
ELSE (ENABLE_TESTS)
SET (CMAKE_INSTALL_NAME_DIR @executable_path/${QGIS_FW_SUBDIR})
ENDIF (ENABLE_TESTS)
# path for framework references when running from build directory
# changed later to reference in-app resources upon install
SET (CMAKE_INSTALL_NAME_DIR ${CMAKE_BINARY_DIR}/output/lib)
IF (WITH_GLOBE)
SET (OSG_PLUGINS_PATH "" CACHE PATH "Path to OSG plugins for bundling")
ENDIF (WITH_GLOBE)
Expand Down Expand Up @@ -480,16 +477,6 @@ SET (CMAKE_LIBRARY_OUTPUT_DIRECTORY ${QGIS_OUTPUT_DIRECTORY}/${QGIS_LIB_SUBDIR})
# if run from the build directory QGIS will detect it and alter the paths
FILE(WRITE ${QGIS_OUTPUT_DIRECTORY}/${QGIS_BIN_SUBDIR}/path.txt "${CMAKE_SOURCE_DIR}\n${QGIS_OUTPUT_DIRECTORY}")

# symlink extra provider plugin frameworks for Mac unit tests
IF (APPLE AND ENABLE_TESTS)
EXECUTE_PROCESS(COMMAND ${CMAKE_COMMAND} -E create_symlink
"${CMAKE_BINARY_DIR}/Plugins/qgis/qgisgrass.framework"
"${CMAKE_BINARY_DIR}/output/lib/qgisgrass.framework")
EXECUTE_PROCESS(COMMAND ${CMAKE_COMMAND} -E create_symlink
"${CMAKE_BINARY_DIR}/Plugins/qgis/qgissqlanyconnection.framework"
"${CMAKE_BINARY_DIR}/output/lib/qgissqlanyconnection.framework")
ENDIF (APPLE AND ENABLE_TESTS)

# manual page - makes sense only on unix systems
IF (UNIX AND NOT APPLE)
SET (DEFAULT_MANUAL_SUBDIR man)
Expand Down Expand Up @@ -625,11 +612,12 @@ IF (APPLE)
# must be last for install, so install_name_tool can do its work
ADD_SUBDIRECTORY(mac)

# make hard link to embedded app bundle binary (symlink won't work)
# allows QGIS to be run directly from build directory
ADD_CUSTOM_TARGET(mac_hardlink ALL
COMMAND /bin/ln -f QGIS.app/Contents/MacOS/QGIS QGIS
WORKING_DIRECTORY "${CMAKE_BINARY_DIR}/output/bin"
# allow QGIS to be run directly from build directory and to run unit tests
ADD_CUSTOM_TARGET(mac_run_from_build ALL
# make symlinks to extra provider-plugin
COMMAND /bin/ln -fs ../../Plugins/qgis/qgisgrass.framework lib/
COMMAND /bin/ln -fs ../../Plugins/qgis/qgissqlanyconnection.framework lib/
WORKING_DIRECTORY "${QGIS_OUTPUT_DIRECTORY}"
DEPENDS QGIS
)
ENDIF (APPLE)
Expand Down
12 changes: 0 additions & 12 deletions build.xml

This file was deleted.

1 change: 1 addition & 0 deletions cmake/MacBundleMacros.cmake
Expand Up @@ -75,6 +75,7 @@ FUNCTION (COPY_FRAMEWORK FWPREFIX FWNAME FWDEST)
EXECUTE_PROCESS (COMMAND cp -Rfp "${FWPREFIX}/${FWNAME}.framework/Versions/${FWVER}/Resources" "${FWDEST}/${FWNAME}.framework/Versions/${FWVER}")
EXECUTE_PROCESS (COMMAND ln -sfh Versions/Current/Resources "${FWDEST}/${FWNAME}.framework/Resources")
ENDIF (IS_DIRECTORY "${FWPREFIX}/${FWNAME}.framework/Versions/${FWVER}/Resources")
EXECUTE_PROCESS (COMMAND install_name_tool -id "${ATEXECUTABLE}/${QGIS_FW_SUBDIR}/${FWNAME}" "${FWDEST}/${FWNAME}.framework/${FWNAME}")
# debug variants
SET (FWD "${FWNAME}_debug")
IF ("${FWDEBUG}" STREQUAL "Debug" AND EXISTS "${FWPREFIX}/${FWNAME}.framework/Versions/${FWVER}/${FWD}")
Expand Down
1 change: 1 addition & 0 deletions doc/AUTHORS
Expand Up @@ -49,3 +49,4 @@ René-Luc D'Hont <rldhont at gmail.com>
Etienne Tourigny <etourigny.dev at gmail.com>
Larry Shaffer <larrys at dakotacarto.com>
Victor Olaya <volayaf at gmail.com>
Dave DeHaan <dave.dehaan@sap.com>
Binary file added images/developers/essen-2012.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
972 changes: 486 additions & 486 deletions images/images.qrc

Large diffs are not rendered by default.

Binary file modified images/splash/splash.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified images/splash/splash.xcf.bz2
Binary file not shown.
4 changes: 4 additions & 0 deletions mac/cmake/0qgis.cmake.in
Expand Up @@ -20,5 +20,9 @@ IF (@OSX_HAVE_LOADERPATH@)
GET_INSTALL_NAME ("${QFWDIR}/${QL}.framework/${QL}" ${QL}.framework QQ)
SET (QFW_CHG "${QQ}")
UPDATEQGISPATHS ("${QFW_CHG}" ${QL})
# change id of the framework
IF (NOT @QGIS_MACAPP_INSTALL_DEV@)
EXECUTE_PROCESS(COMMAND install_name_tool -id "${ATEXECUTABLE}/${QGIS_FW_SUBDIR}/${QL}.framework/${QL}" "${QFWDIR}/${QL}.framework/${QL}")
ENDIF ()
ENDFOREACH (QL)
ENDIF (@OSX_HAVE_LOADERPATH@)
7 changes: 4 additions & 3 deletions python/console_help.py
Expand Up @@ -35,7 +35,7 @@ def __init__(self):
QtGui.QDialog.__init__(self)
self.setModal(True)
self.setupUi()

def setupUi(self):
self.setMaximumSize(500, 300)
self.webView = QtWebKit.QWebView()
Expand All @@ -58,15 +58,16 @@ def setupUi(self):
qgisDataDir = QgsApplication.pkgDataPath()
listFile = os.listdir(qgisDataDir + "/python/console_help/i18n")
localeFullName = QSettings().value( "locale/userLocale", QVariant( "" ) ).toString()
locale = "en_US"
for i in listFile:
lang = i[0:5]
if localeFullName in (lang[0:2], lang):
locale = lang

filename = qgisDataDir + "/python/console_help/help.htm? \
lang=" + locale \
+ "&pkgDir=" + qgisDataDir

url = QtCore.QUrl(filename)
self.webView.load(url)

Expand Down
4 changes: 2 additions & 2 deletions python/console_help/help.htm
@@ -1,5 +1,5 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "httpqrc://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="httpqrc://www.w3.org/1999/xhtml">
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Help Python Console</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
Expand Down
25 changes: 17 additions & 8 deletions python/console_output.py
Expand Up @@ -108,6 +108,12 @@ def __init__(self, parent=None):
self.SendScintilla(QsciScintilla.SCI_SETWRAPMODE, 2)
self.SendScintilla(QsciScintilla.SCI_SETHSCROLLBAR, 0)

self.runShortcut = QShortcut(QKeySequence(Qt.CTRL + Qt.Key_E), self)
self.runShortcut.activated.connect(self.enteredSelected)
# Reimplemeted copy action to prevent paste prompt (>>>,...) in command view
self.copyShortcut = QShortcut(QKeySequence(Qt.CTRL + Qt.Key_C), self)
self.copyShortcut.activated.connect(self.copy)

def refreshLexerProperties(self):
self.setLexers()

Expand Down Expand Up @@ -143,18 +149,16 @@ def clearConsole(self):

def contextMenuEvent(self, e):
menu = QMenu(self)
runAction = menu.addAction("Enter Selected")
copyAction = menu.addAction("Copy CTRL+C")
iconRun = QIcon(":/images/console/iconRunConsole.png")
runAction = menu.addAction(iconRun, "Enter Selected", self.enteredSelected, QKeySequence(Qt.CTRL + Qt.Key_E))
menu.addSeparator()
copyAction = menu.addAction("Copy", self.copy, QKeySequence.Copy)
runAction.setEnabled(False)
copyAction.setEnabled(False)
if self.hasSelectedText():
runAction.setEnabled(True)
copyAction.setEnabled(True)
action = menu.exec_(self.mapToGlobal(e.pos()))
if action == runAction:
cmd = self.selectedText()
self.edit.insertFromDropPaste(cmd)
self.edit.entered()
if action == copyAction:
self.copy()

def copy(self):
"""Copy text to clipboard... or keyboard interrupt"""
Expand All @@ -165,3 +169,8 @@ def copy(self):
else:
self.emit(SIGNAL("keyboard_interrupt()"))

def enteredSelected(self):
cmd = self.selectedText()
self.edit.insertFromDropPaste(cmd)
self.edit.entered()

15 changes: 6 additions & 9 deletions python/console_sci.py
Expand Up @@ -119,9 +119,7 @@ def __init__(self, parent=None):
self.newShortcutCAS.activated.connect(self.showHistory)
self.connect(self, SIGNAL('userListActivated(int, const QString)'),
self.completion_list_selected)

self.createStandardContextMenu()


def showHistory(self):
self.showUserList(1, QStringList(self.history))

Expand Down Expand Up @@ -413,13 +411,12 @@ def keyPressEvent(self, e):

def contextMenuEvent(self, e):
menu = QMenu(self)
copyAction = menu.addAction("Copy CTRL+C")
pasteAction = menu.addAction("Paste CTRL+V")
copyAction = menu.addAction("Copy", self.copy, QKeySequence.Copy)
pasteAction = menu.addAction("Paste", self.paste, QKeySequence.Paste)
copyAction.setEnabled(False)
if self.hasSelectedText():
copyAction.setEnabled(True)
action = menu.exec_(self.mapToGlobal(e.pos()))
if action == copyAction:
self.copy()
elif action == pasteAction:
self.paste()

def mousePressEvent(self, e):
"""
Expand Down
4 changes: 0 additions & 4 deletions python/console_settings.py
Expand Up @@ -40,10 +40,6 @@ def __init__(self, parent):
self.fontConfig()

self.lineEdit.setReadOnly(True)
self.tabWidget.setTabText(0, QCoreApplication.translate("PythonConsole", "General"))
self.tabWidget.setTabIcon(0, QIcon(":/images/themes/default/propertyicons/general.png"))
self.tabWidget.setTabText(1, QCoreApplication.translate("PythonConsole", "About"))
self.tabWidget.setTabIcon(1, QIcon(":/images/console/iconAboutConsole.png"))

self.addAPIpath.setIcon(QIcon(":/images/themes/default/symbologyAdd.png"))
self.addAPIpath.setToolTip(QCoreApplication.translate("PythonConsole", "Add API path"))
Expand Down

0 comments on commit 404bce6

Please sign in to comment.