windows compatibility fix
This commit is contained in:
parent
44d8ef37e3
commit
bd85f91258
|
@ -3455,6 +3455,7 @@ void Editor::showCompletion(const QString& preWord,bool autoComplete, CodeComple
|
||||||
|
|
||||||
// Position it at the top of the next line
|
// Position it at the top of the next line
|
||||||
QPoint popupPos = mapToGlobal(rowColumnToPixels(displayXY()));
|
QPoint popupPos = mapToGlobal(rowColumnToPixels(displayXY()));
|
||||||
|
#if QT_VERSION >= QT_VERSION_CHECK(5, 15, 0)
|
||||||
QSize desktopSize = screen()->virtualSize();
|
QSize desktopSize = screen()->virtualSize();
|
||||||
if (desktopSize.height() - popupPos.y() < mCompletionPopup->height() && popupPos.y() > mCompletionPopup->height())
|
if (desktopSize.height() - popupPos.y() < mCompletionPopup->height() && popupPos.y() > mCompletionPopup->height())
|
||||||
popupPos-=QPoint(0, mCompletionPopup->height()+2);
|
popupPos-=QPoint(0, mCompletionPopup->height()+2);
|
||||||
|
@ -3464,6 +3465,9 @@ void Editor::showCompletion(const QString& preWord,bool autoComplete, CodeComple
|
||||||
if (desktopSize.width() - popupPos.x() < mCompletionPopup->width() ) {
|
if (desktopSize.width() - popupPos.x() < mCompletionPopup->width() ) {
|
||||||
popupPos.setX(std::max(0, desktopSize.width()-mCompletionPopup->width())-10);
|
popupPos.setX(std::max(0, desktopSize.width()-mCompletionPopup->width())-10);
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
popupPos+=QPoint(0,textHeight()+2);
|
||||||
|
#endif
|
||||||
|
|
||||||
mCompletionPopup->move(popupPos);
|
mCompletionPopup->move(popupPos);
|
||||||
|
|
||||||
|
|
|
@ -17,6 +17,12 @@ qsynedit.subdir = libs/qsynedit
|
||||||
RedPandaIDE.depends = astyle consolepauser qsynedit
|
RedPandaIDE.depends = astyle consolepauser qsynedit
|
||||||
qsynedit.depends = redpanda_qt_utils
|
qsynedit.depends = redpanda_qt_utils
|
||||||
|
|
||||||
|
APP_NAME = RedPandaCPP
|
||||||
|
|
||||||
|
APP_VERSION = 2.26
|
||||||
|
|
||||||
|
TEST_VERSION = alpha1
|
||||||
|
|
||||||
win32: {
|
win32: {
|
||||||
SUBDIRS += \
|
SUBDIRS += \
|
||||||
redpanda-win-git-askpass
|
redpanda-win-git-askpass
|
||||||
|
|
|
@ -36,6 +36,7 @@ cp "${SOURCE_DIR}/platform/windows/installer-scripts/redpanda-i686-nocompiler.ns
|
||||||
rm -f lang.nsh
|
rm -f lang.nsh
|
||||||
rm -f config32.nsh
|
rm -f config32.nsh
|
||||||
rm -f config.nsh
|
rm -f config.nsh
|
||||||
|
rm -f config-clang.nsh
|
||||||
rm -f redpanda-i686-nocompiler.nsi
|
rm -f redpanda-i686-nocompiler.nsi
|
||||||
|
|
||||||
SETUP_NAME=`ls *.Setup.exe`
|
SETUP_NAME=`ls *.Setup.exe`
|
||||||
|
@ -68,6 +69,7 @@ cp "${SOURCE_DIR}/platform/windows/installer-scripts/redpanda-i686.nsi" .
|
||||||
rm -f lang.nsh
|
rm -f lang.nsh
|
||||||
rm -f config32.nsh
|
rm -f config32.nsh
|
||||||
rm -f config.nsh
|
rm -f config.nsh
|
||||||
|
rm -f config-clang.nsh
|
||||||
rm -f redpanda-i686.nsi
|
rm -f redpanda-i686.nsi
|
||||||
|
|
||||||
SETUP_NAME=`ls *.Setup.exe`
|
SETUP_NAME=`ls *.Setup.exe`
|
||||||
|
|
|
@ -36,6 +36,7 @@ cp "${SOURCE_DIR}/platform/windows/installer-scripts/redpanda-nocompiler.nsi" .
|
||||||
rm -f lang.nsh
|
rm -f lang.nsh
|
||||||
rm -f config.nsh
|
rm -f config.nsh
|
||||||
rm -f config32.nsh
|
rm -f config32.nsh
|
||||||
|
rm -f config-clang.nsh
|
||||||
rm -f redpanda-nocompiler.nsi
|
rm -f redpanda-nocompiler.nsi
|
||||||
|
|
||||||
SETUP_NAME=`ls *.Setup.exe`
|
SETUP_NAME=`ls *.Setup.exe`
|
||||||
|
@ -70,6 +71,7 @@ cp "${SOURCE_DIR}/platform/windows/installer-scripts/redpanda-x64.nsi" .
|
||||||
rm -f lang.nsh
|
rm -f lang.nsh
|
||||||
rm -f config.nsh
|
rm -f config.nsh
|
||||||
rm -f config32.nsh
|
rm -f config32.nsh
|
||||||
|
rm -f config-clang.nsh
|
||||||
rm -f redpanda-x64.nsi
|
rm -f redpanda-x64.nsi
|
||||||
|
|
||||||
SETUP_NAME=`ls *.Setup.exe`
|
SETUP_NAME=`ls *.Setup.exe`
|
||||||
|
|
|
@ -0,0 +1,91 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
TARGET_DIR="/r/"
|
||||||
|
BUILD_DIR="${TEMP}/redpandacpp-build"
|
||||||
|
PACKAGE_DIR="${TEMP}/RedPanda-CPP"
|
||||||
|
GCC_DIR="/Qt/5.6.3/mingw81_32-redpanda"
|
||||||
|
PATH="${GCC_DIR}/bin:${PATH}"
|
||||||
|
QMAKE="${GCC_DIR}/bin/qmake"
|
||||||
|
QMAKE2="/mingw32/bin/qmake"
|
||||||
|
NSIS="/d/Program Files (x86)/NSIS/bin/makensis.exe"
|
||||||
|
SOURCE_DIR=`pwd`
|
||||||
|
MINGW="/e/Workspaces/contributes/MinGW/MinGW32"
|
||||||
|
MINGW_NAME="MinGW32"
|
||||||
|
|
||||||
|
rm -rf "${BUILD_DIR}"
|
||||||
|
test -z "${BUILD_DIR}" | mkdir "${BUILD_DIR}"
|
||||||
|
rm -rf "${PACKAGE_DIR}"
|
||||||
|
mkdir "${PACKAGE_DIR}"
|
||||||
|
|
||||||
|
echo "Building..."
|
||||||
|
pushd .
|
||||||
|
cd "${BUILD_DIR}"
|
||||||
|
make distclean
|
||||||
|
//hack: create nsh files
|
||||||
|
"$QMAKE2" PREFIX="${PACKAGE_DIR}" -o Makefile "${SOURCE_DIR}\Red_Panda_Cpp.pro"
|
||||||
|
make distclean
|
||||||
|
"$QMAKE" PREFIX="${PACKAGE_DIR}" -o Makefile "${SOURCE_DIR}\Red_Panda_Cpp.pro"
|
||||||
|
make -j16
|
||||||
|
make install
|
||||||
|
popd
|
||||||
|
|
||||||
|
echo "Making no-compiler installer ..."
|
||||||
|
pushd .
|
||||||
|
cd "${PACKAGE_DIR}"
|
||||||
|
|
||||||
|
cp "${SOURCE_DIR}/platform/windows/installer-scripts/lang.nsh" .
|
||||||
|
cp "${SOURCE_DIR}/platform/windows/installer-scripts/redpanda-i686-nocompiler.nsi" .
|
||||||
|
|
||||||
|
"${NSIS}" redpanda-i686-nocompiler.nsi
|
||||||
|
rm -f lang.nsh
|
||||||
|
rm -f config32.nsh
|
||||||
|
rm -f config.nsh
|
||||||
|
rm -f redpanda-i686-nocompiler.nsi
|
||||||
|
|
||||||
|
SETUP_NAME=`ls *.Setup.exe`
|
||||||
|
PORTABLE_NAME=`echo $SETUP_NAME | sed 's/Setup.exe/Portable.7z/'`
|
||||||
|
mv "$SETUP_NAME" "${TARGET_DIR}"
|
||||||
|
popd
|
||||||
|
|
||||||
|
pushd .
|
||||||
|
cd "${TARGET_DIR}"
|
||||||
|
echo "Making no-compiler Portable Package..."
|
||||||
|
7z a -mmt8 -mx9 "${PORTABLE_NAME}" "${PACKAGE_DIR}"
|
||||||
|
popd
|
||||||
|
|
||||||
|
# we need reinstall config32.nsh
|
||||||
|
pushd .
|
||||||
|
cd "${BUILD_DIR}"
|
||||||
|
make install
|
||||||
|
popd
|
||||||
|
|
||||||
|
echo "Making installer..."
|
||||||
|
|
||||||
|
pushd .
|
||||||
|
cd "${PACKAGE_DIR}"
|
||||||
|
ln -s "${MINGW}" $MinGW_NAME
|
||||||
|
|
||||||
|
cp "${SOURCE_DIR}/platform/windows/installer-scripts/lang.nsh" .
|
||||||
|
cp "${SOURCE_DIR}/platform/windows/installer-scripts/redpanda-i686.nsi" .
|
||||||
|
|
||||||
|
"${NSIS}" redpanda-i686.nsi
|
||||||
|
rm -f lang.nsh
|
||||||
|
rm -f config32.nsh
|
||||||
|
rm -f config.nsh
|
||||||
|
rm -f redpanda-i686.nsi
|
||||||
|
|
||||||
|
SETUP_NAME=`ls *.Setup.exe`
|
||||||
|
PORTABLE_NAME=`echo $SETUP_NAME | sed 's/Setup.exe/Portable.7z/'`
|
||||||
|
mv "$SETUP_NAME" "${TARGET_DIR}"
|
||||||
|
|
||||||
|
popd
|
||||||
|
|
||||||
|
pushd .
|
||||||
|
cd "${TARGET_DIR}"
|
||||||
|
echo "Making Portable Package..."
|
||||||
|
7z a -mmt8 -mx9 "${PORTABLE_NAME}" "${PACKAGE_DIR}"
|
||||||
|
popd
|
||||||
|
|
||||||
|
echo "Clean up..."
|
||||||
|
rm -rf "${PACKAGE_DIR}"
|
||||||
|
|
Loading…
Reference in New Issue