From 1ab57def7078ea3226f9147b57745b074f413dfa Mon Sep 17 00:00:00 2001 From: shibakaneki Date: Mon, 4 Jul 2011 08:03:52 +0200 Subject: [PATCH 01/13] Updated for commit --- src/pdf/XPDFRenderer.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/pdf/XPDFRenderer.cpp b/src/pdf/XPDFRenderer.cpp index 86ad687c..799e0549 100644 --- a/src/pdf/XPDFRenderer.cpp +++ b/src/pdf/XPDFRenderer.cpp @@ -180,7 +180,10 @@ void XPDFRenderer::render(QPainter *p, int pageNumber, const QRectF &bounds) QTransform savedTransform = p->worldTransform(); p->resetTransform(); + QTime t; + t.start(); p->drawImage(QPointF(savedTransform.dx() + mSliceX, savedTransform.dy() + mSliceY), pdfImage); + //qDebug() << "XPDFRenderer::render(...) execution time: " << t.elapsed() << "ms"; p->setWorldTransform(savedTransform); } } From 91af774814d6bde2420e3a427bb30f486f135cd6 Mon Sep 17 00:00:00 2001 From: shibakaneki Date: Mon, 4 Jul 2011 14:39:30 +0200 Subject: [PATCH 02/13] Using the preference dialog to store the community username & password + adding arabian translation file --- resources/i18n/sankore_ar.ts | 2627 +++++++++++++++++ .../publishing/UBDocumentPublisher.cpp | 6 +- src/api/UBWidgetUniboardAPI.cpp | 20 + src/api/UBWidgetUniboardAPI.h | 3 + src/core/UBPreferencesController.cpp | 17 + src/core/UBPreferencesController.h | 2 + src/core/UBSettings.cpp | 22 + src/core/UBSettings.h | 8 + src/domain/UBGraphicsWidgetItem.cpp | 2 +- src/domain/UBW3CWidget.cpp | 2 +- src/gui/UBToolWidget.cpp | 2 +- 11 files changed, 2706 insertions(+), 5 deletions(-) create mode 100644 resources/i18n/sankore_ar.ts diff --git a/resources/i18n/sankore_ar.ts b/resources/i18n/sankore_ar.ts new file mode 100644 index 00000000..e9d93b02 --- /dev/null +++ b/resources/i18n/sankore_ar.ts @@ -0,0 +1,2627 @@ + + + BlackoutWidget + + background: url(:/images/bigUniboard.png); border: none; + + + + Click to Return to Application + + + + + DownloadDialog + + Downloads + + + + Clean Up + + + + 0 Items + + + + + DownloadItem + + Form + + + + Ico + + + + Filename + + + + Try Again + + + + Stop + + + + Open + + + + + IntranetPodcastPublishingDialog + + Publish Podcast to YouTube + + + + Title + + + + Description + + + + Author + + + + + MainWindow + + Uniboard + + + + Board + + + + Web + + + + Documents + + + + Tutorial + + + + Stylus + + + + Ctrl+T + + + + Backgrounds + + + + Change Background + + + + Undo + + + + Ctrl+Z + + + + Redo + + + + Ctrl+Y + + + + Previous + + + + Previous Page + + + + PgUp + + + + Next + + + + Next Page + + + + PgDown + + + + Manage Documents + + + + Ctrl+D + + + + Web Browsing + + + + Ctrl+W + + + + Line + + + + Small Line + + + + Medium Line + + + + Large Line + + + + Quit + + + + Quit Uniboard + + + + Eraser + + + + Smalle Eraser + + + + Medium Eraser + + + + Large Eraser + + + + Color + + + + Back + + + + Left + + + + Forward + + + + Right + + + + Reload + + + + Reload Current Page + + + + Home + + + + Load Home Page + + + + Bookmarks + + + + Show Bookmarks + + + + Bookmark + + + + Add Bookmark + + + + Display Board + + + + Ctrl+B + + + + Erase + + + + Erase Content + + + + Preferences + + + + Display Preferences + + + + Library + + + + Show Library + + + + Ctrl+L + + + + Sankoré 3.1 + + + + Sankore 3.1 + + + + Show Desktop + + + + Show Computer Desktop + + + + Ctrl+Shift+H + + + + Bigger + + + + Zoom In + + + + Ctrl++ + + + + Smaller + + + + Zoom Out + + + + Ctrl+- + + + + New Folder + + + + Create a New Folder + + + + New Document + + + + Create a New Document + + + + Import + + + + Import a Document + + + + Export + + + + Export a Document + + + + Open in Board + + + + Open Page in Board + + + + Ctrl+O + + + + Duplicate + + + + Duplicate Selected Content + + + + Delete + + + + Delete Selected Content + + + + Del + + + + Add to Working Document + + + + Add Selected Content to Open Document + + + + Add + + + + Add Content to Document + + + + Rename + + + + Rename Content + + + + Tools + + + + Display Tools + + + + Multi Screen + + + + Wide Size (16/9) + + + + Use Document Wide Size (16/9) + + + + Regular Size (4/3) + + + + Use Document Regular Size (4/3) + + + + Custom Size + + + + Use Custom Document Size + + + + Stop Loading + + + + Stop Loading Web Page + + + + Cut + + + + Copy + + + + Paste + + + + Sleep + + + + Put Presentation to Sleep + + + + Virtual Keyboard + + + + Display Virtual Keyboard + + + + Plain Light Background + + + + Light + + + + Grid Light Background + + + + Plain Dark Background + + + + Dark + + + + Grid Dark Background + + + + Podcast + + + + Record Presentation to Video + + + + Record + + + + Start Screen Recording + + + + Erase Items + + + + Erase All Items + + + + Erase Annotations + + + + Erase All Annotations + + + + Clear Page + + + + Clear All Elements + + + + Pen + + + + Annotate Document + + + + Ctrl+I + + + + Erase Annotation + + + + Ctrl+E + + + + Marker + + + + Highlight + + + + Ctrl+M + + + + Selector + + + + Select And Modify Objects + + + + Ctrl+F + + + + Hand + + + + Scroll Page + + + + Laser Pointer + + + + Virtual Laser Pointer + + + + Ctrl+G + + + + Draw Lines + + + + Ctrl+J + + + + Text + + + + Write Text + + + + Ctrl+K + + + + Capture + + + + Capture Part of the Screen + + + + Add To Current Page + + + + Add Item To Current Page + + + + Add To New Page + + + + Add Item To New Page + + + + Add To Library + + + + Add Item To Library + + + + Pages + + + + Create a New Page + + + + New Page + + + + Duplicate Page + + + + Duplicate the Current Page + + + + Import Page + + + + Import an External Page + + + + Pause + + + + Pause Podcast Recording + + + + Podcast Config + + + + Configure Podcast Recording + + + + Flash Trap + + + + Trap Flash Content + + + + Web Trap + + + + Trap Web Content + + + + Custom Capture + + + + Window Capture + + + + Capture a Window + + + + Embed Web Content + + + + Capture Embeddable Web Content + + + + Show on Display + + + + Show Main Screen on Display Screen + + + + Share Item on the Web + + + + Share Capture on the Web + + + + Define Drawing Options + + + + Erase all Annotations + + + + eduMedia + + + + Import eduMedia simulation + + + + Open the tutorial + + + + Check Update + + + + Sankoré Editor + + + + Show Sankore Widgets Editor + + + + Hide Sankoré + + + + Hide Sankoré Application + + + + Ctrl+H + + + + + PasswordDialog + + Authentication Required + + + + DUMMY ICON + + + + INTRO TEXT DUMMY + + + + Username: + + + + Password: + + + + + ProxyDialog + + Proxy Authentication + + + + ICON + + + + Connect to Proxy + + + + Username: + + + + Password: + + + + Save username and password for future use + + + + + QObject + + /Home + Category list label on navigation tool bar + + + + Trash + Pictures category element + + + + + UBAbstractPublisher + + Contacting %1 + + + + Found %1 + + + + Cannot Authenticate with %1 + + + + + UBAbstractWidget + + Cannot load content + + + + Loading ... + + + + + UBApplication + + Page Size + + + + Podcast + + + + + UBApplicationController + + Web + + + + New update available, would you go to the web page ? + + + + No update available + + + + + UBBoardController + + Downloading content from %1 + + + + Downloading content %1 failed + + + + Download finished + + + + Flash is not supported on Sankore Linux + + + + Unknown tool type %1 + + + + Unknown content type %1 + + + + Add Item + + + + All Supported (%1) + + + + + UBBoardPaletteManager + + Error Adding Image to Library + + + + Error Publishing Image to the Web + + + + + UBCapturePublisher + + Preparing capture for upload... + + + + Publication canceled ... + + + + Capture Published to the Web. + + + + Error Publishing Capture to the Web: %1 + + + + + UBCapturePublishingDialog + + Publish + + + + + UBDesktopPalette + + Show Uniboard + + + + Capture Part of the Screen + + + + Capture the Screen + + + + Show the stylus palette + + + + Show Board on Secondary Screen + + + + Show Desktop on Secondary Screen + + + + + UBDocumentController + + New Folder + + + + Page %1 + + + + Add Folder of Images + + + + Add Images + + + + Add Pages from File + + + + Duplicating Document %1 + + + + Document %1 copied + + + + Remove Page + + + + Remove Document + + + + Are you sure you want to remove the document '%1'? + + + + Empty Trash + + + + Are you sure you want to empty trash? + + + + Emptying trash + + + + Emptied trash + + + + Remove Folder + + + + Are you sure you want to remove the folder '%1' and all its content? + + + + No document selected! + + + + Open Supported File + + + + Importing file %1... + + + + Failed to import file ... + + + + Import all Images from Folder + + + + Folder does not contain any image files! + + + + Delete + + + + Empty + + + + Trash + + + + Open Document + + + + The document '%1' has been generated with a newer version of Sankore (%2). By opening it, you may lose some information. Do you want to proceed? + + + + Add all Images to Document + + + + All Images (%1) + + + + Selection does not contain any image files! + + + + + UBDocumentManager + + images + + + + videos + + + + objects + + + + widgets + + + + All supported files (*.%1) + + + + File %1 saved + + + + Importing page %1 of %2 + + + + Erronous image data, skipping file %1 + + + + + UBDocumentNavigator + + Page %0 + + + + + UBDocumentPublisher + + Sankore Uploading Page + + + + Uploading Sankore File on Web. + + + + Export failed. + + + + Export canceled ... + + + + Converting page %1/%2 ... + + + + + UBDocumentTreeWidget + + %1 (copy) + + + + Copying page %1/%2 + + + + + UBDropMeWidget + + Drop here + + + + + UBExportDocument + + Page + + + + Export as UBZ File + + + + Exporting document... + + + + Export successful. + + + + Exporting %1 %2 of %3 + + + + Export to Sankore Format + + + + + UBExportFullPDF + + Export as PDF File + + + + Exporting document... + + + + Export successful. + + + + Export to PDF + + + + + UBExportPDF + + Export as PDF File + + + + Exporting document... + + + + Export successful. + + + + Exporting page %1 of %2 + + + + Export to PDF + + + + + UBExportWeb + + Page + + + + Export as Web data + + + + Exporting document... + + + + Export successful. + + + + Export failed. + + + + Export to Web Browser + + + + + UBGraphicsItemDelegate + + Locked + + + + Visible on Extended Screen + + + + Go to Content Source + + + + + UBGraphicsTextItem + + <Type Text Here> + + + + + UBGraphicsTextItemDelegate + + Text Color + + + + + UBGraphicsWidgetItemDelegate + + Frozen + + + + Transform as Tool + + + + + UBImportDocument + + Sankore 3.1 (*.ubz) + + + + Importing file %1... + + + + Import successful. + + + + + UBImportImage + + Image Format ( + + + + Image import failed. + + + + Image import successful. + + + + + UBImportPDF + + Portable Document Format (*.pdf) + + + + PDF import failed. + + + + Importing page %1 of %2 + + + + PDF import successful. + + + + + UBIntranetPodcastPublisher + + Error while publishing video to intranet (%1) + + + + Publishing to Intranet in progress %1 % + + + + + UBIntranetPodcastPublishingDialog + + Publish + + + + + UBLibActionBar + + Add to favorites + + + + Share + + + + Search + + + + Delete + + + + Back to folder + + + + Remove from favorites + + + + Create new folder + + + + + UBLibItemProperties + + Back + + + + Add to page + + + + Set as background + + + + Add to library + + + + Object informations + + + + + UBLibraryController + + Added 1 Image to Library + + + + Audios + Audio category element + + + + Movies + Movies category element + + + + Pictures + Pictures category element + + + + Shapes + Shapes category element + + + + Applications + Applications category element + + + + Favorite + Favorite category element + + + + Interactivities + Interactives category element + + + + Creating image thumbnail for %1. + + + + Adding to page failed for item %1. + + + + + UBNetworkAccessManager + + <qt>Enter username and password for "%1" at %2</qt> + + + + Failed to log to Proxy + + + + SSL Errors: + +%1 + +%2 + +Do you want to ignore these errors for this host? + + + + + UBNewFolderDlg + + Add new folder + + + + New Folder name: + + + + + UBPersistenceManager + + (copy) + + + + Document Repository Loss + + + + Sankore has lost access to the document repository '%1'. Unfortunately the application must shut down to avoid data corruption. Latest changes may be lost as well. + + + + + UBPodcastController + + Sankore Cast + + + + Failed to start encoder ... + + + + No Podcast encoder available ... + + + + Part %1 + + + + on your desktop ... + + + + in folder %1 + + + + Podcast created %1 + + + + Podcast recording error (%1) + + + + Default Audio Input + + + + No Audio Recording + + + + Small + + + + Medium + + + + Full + + + + Publish to Intranet + + + + Publish to Youtube + + + + + UBPreferencesController + + version: + + + + Marker is pressure sensitive + + + + + UBSettings + + Untitled Documents + + + + Trash + + + + Images + + + + My Movies + + + + + UBThumbnailAdaptor + + Generating preview thumbnails ... + + + + %1 thumbnails generated ... + + + + + UBToolsManager + + Mask + + + + Ruler + + + + Compass + + + + Protractor + + + + Triangle + + + + + UBTrapFlashController + + Whole page + + + + Web + + + + + UBUpdateDlg + + Document updater + + + + files require an update. + + + + Backup path: + + + + Browse + + + + Update + + + + Select a backup folder + + + + Files update successful! +Please reboot the application to access the updated documents. + + + + An error occured during the update. The files have not been affected. + + + + Files update results + + + + + UBW3CWidget + + Web + + + + + UBWebPluginWidget + + Loading... + + + + + UBWebPublisher + + Publish Document on Sankore Web + + + + + UBWidgetUniboardAPI + + %0 called (method=%1, status=%2) + + + + + UBYouTubePublisher + + YouTube authentication failed. + + + + Error while uploading video to YouTube (%1) + + + + Upload to YouTube in progress %1 % + + + + + UBYouTubePublishingDialog + + Upload + + + + Autos & Vehicles + + + + Music + + + + Pets & Animals + + + + Sports + + + + Travel & Events + + + + Gaming + + + + Comedy + + + + People & Blogs + + + + News & Politics + + + + Entertainment + + + + Education + + + + Howto & Style + + + + Nonprofits & Activism + + + + Science & Technology + + + + + UBZoomPalette + + %1 x + + + + + WBClearButton + + Clear + + + + + WBDownloadItem + + Save File + + + + Download canceled: %1 + + + + Error opening saved file: %1 + + + + Error saving: %1 + + + + Network Error: %1 + + + + seconds + + + + minutes + + + + - %4 %5 remaining + + + + %1 of %2 (%3/sec) %4 + + + + ? + unknown file size + + + + %1 of %2 - Stopped + + + + bytes + + + + KB + + + + MB + + + + + WBDownloadManager + + 1 Download + + + + %1 Downloads + always >= 2 + + + + + WBHistoryModel + + Title + + + + Address + + + + + WBHistoryTreeModel + + Earlier Today + + + + %1 items + + + + + WBSearchLineEdit + + Search + + + + + WBTabBar + + New &Tab + + + + Clone Tab + + + + &Close Tab + + + + Close &Other Tabs + + + + Reload Tab + + + + Reload All Tabs + + + + + WBTabWidget + + Recently Closed Tabs + + + + (Untitled) + + + + + WBToolbarSearch + + Search + + + + No Recent Searches + + + + Recent Searches + + + + Clear Recent Searches + + + + + WBWebPage + + Download PDF Document: would you prefer to download the PDF file or add it to the current Sankore document? + + + + Download + + + + Add to Current Document + + + + PDF + + + + Error loading page: %1 + + + + + WBWebView + + Open in New Tab + + + + + YouTubePublishingDialog + + Publish Podcast to YouTube + + + + Title + + + + Description + + + + Keywords + + + + Uniboard + + + + Category + + + + YouTube Username + + + + YouTube Password + + + + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Lucida Grande'; font-size:10pt;">By clicking 'Upload,' you certify that you own all rights to the content or that you are authorized by the owner to make the content publicly available on YouTube, and that it otherwise complies with the YouTube Terms of Service located at </span><a href="http://www.youtube.com/t/terms"><span style=" font-family:'Lucida Grande'; font-size:10pt; text-decoration: underline; color:#0000ff;">http://www.youtube.com/t/terms</span></a></p></body></html> + + + + + brushProperties + + On Light Background + + + + On Dark Background + + + + Opacity + + + + Line Width + + + + Medium + + + + Strong + + + + Fine + + + + Pen is Pressure Sensitive + + + + + capturePublishingDialog + + Dialog + + + + Title + + + + E-mail + + + + Author + + + + Description + + + + + documentPublishingDialog + + Dialog + + + + Title + + + + E-mail + + + + Author + + + + Description + + + + Attach Downloadable PDF Version + + + + Attach Downloadable Uniboard File (UBZ) + + + + Warning: This documents contains video, which will not be displayed properly on the Web + + + + + documents + + Uniboard Documents + + + + 1 + + + + + preferencesDialog + + Preferences + + + + version : … + + + + Default Settings + + + + Close + + + + Display + + + + Internet + + + + Show Page with External Browser + + + + Home Page: + + + + Proxy User/Pass: + + + + Mirroring + + + + Show main display immediately on secondary screen or projector + + + + Virtual Keyboard + + + + Minimize keyboard when not active + + + + Keyboard button size: + + + + Toolbar + + + + Positioned at the Top (recommended for tablets) + + + + Positioned at the Bottom (recommended for white boards) + + + + Display Text Under Button + + + + Stylus Palette + + + + Horizontal + + + + Vertical + + + + Pen + + + + Marker + + + + Licences + + + + OpenSSl + + + + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Ubuntu'; font-size:11pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt; color:#1a1a1a;">The OpenSSL toolkit stays under a dual license, i.e. both the conditions of the OpenSSL License and the original SSLeay license apply to the toolkit.</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt; color:#1a1a1a;">See below for the actual license texts. Actually both licenses are BSD-style Open Source licenses. In case of any license issues related to OpenSSL please contact </span><a href="mailto:openssl-core@openssl.org"><span style=" font-size:9pt; text-decoration: underline; color:#0000ff;">openssl-core@openssl.org</span></a><span style=" font-size:9pt; color:#1a1a1a;">.</span><span style=" font-size:9pt;"> </span></p></body></html> + + + + zlib + + + + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Ubuntu'; font-size:11pt; font-weight:400; font-style:normal;"> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt; color:#1a1a1a;">Copyright (C) 1995-1998 Jean-loup Gailly and Mark Adler</span><span style=" font-size:12pt;"><br /><br /></span><span style=" font-size:9pt; color:#1a1a1a;"> This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software.</span><span style=" font-size:9pt;"><br /><br /></span><span style=" font-size:9pt; color:#1a1a1a;"> Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions:</span><span style=" font-size:9pt;"><br /><br /></span><span style=" font-size:9pt; color:#1a1a1a;"> 1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required.</span><span style=" font-size:9pt;"><br /></span><span style=" font-size:9pt; color:#1a1a1a;"> 2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software.</span><span style=" font-size:9pt;"><br /></span><span style=" font-size:9pt; color:#1a1a1a;"> 3. This notice may not be removed or altered from any source distribution.</span><span style=" font-size:9pt;"> </span></p></body></html> + + + + xpdf + + + + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Ubuntu'; font-size:11pt; font-weight:400; font-style:normal;"> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt; color:#000000;">Xpdf is licensed under the GNU General Public License (GPL), version 2.</span></p></body></html> + + + + Quazip + + + + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Ubuntu'; font-size:11pt; font-weight:400; font-style:normal;"> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">GNU Library or Lesser General Public License (LGPL), zlib/libpng License</span></p></body></html> + + + + Sankoré 3.1 + + + + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Ubuntu'; font-size:11pt; font-weight:400; font-style:normal;"> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">SANKORE3.1 is free software: you can redistribute it and/or modify it under the terms of the Lesser GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or any later version. You can find the source code of this software at &lt;https://adullact.net/projects/sankore/&gt;</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">SANKORE3.1 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 Lesser GNU General Public License below for more details.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> GNU LESSER GENERAL PUBLIC LICENSE</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> Version 3, 29 June 2007</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> Copyright (C) 2007 Free Software Foundation, Inc. &lt;http://fsf.org/&gt;</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> Everyone is permitted to copy and distribute verbatim copies</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> of this license document, but changing it is not allowed.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> This version of the GNU Lesser General Public License incorporates</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">the terms and conditions of version 3 of the GNU General Public</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">License, supplemented by the additional permissions listed below.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> 0. Additional Definitions.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> As used herein, &quot;this License&quot; refers to version 3 of the GNU Lesser</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">General Public License, and the &quot;GNU GPL&quot; refers to version 3 of the GNU</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">General Public License.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> &quot;The Library&quot; refers to a covered work governed by this License,</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">other than an Application or a Combined Work as defined below.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> An &quot;Application&quot; is any work that makes use of an interface provided</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">by the Library, but which is not otherwise based on the Library.</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">Defining a subclass of a class defined by the Library is deemed a mode</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">of using an interface provided by the Library.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> A &quot;Combined Work&quot; is a work produced by combining or linking an</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">Application with the Library. The particular version of the Library</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">with which the Combined Work was made is also called the &quot;Linked</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">Version&quot;.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> The &quot;Minimal Corresponding Source&quot; for a Combined Work means the</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">Corresponding Source for the Combined Work, excluding any source code</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">for portions of the Combined Work that, considered in isolation, are</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">based on the Application, and not on the Linked Version.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> The &quot;Corresponding Application Code&quot; for a Combined Work means the</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">object code and/or source code for the Application, including any data</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">and utility programs needed for reproducing the Combined Work from the</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">Application, but excluding the System Libraries of the Combined Work.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> 1. Exception to Section 3 of the GNU GPL.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> You may convey a covered work under sections 3 and 4 of this License</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">without being bound by section 3 of the GNU GPL.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> 2. Conveying Modified Versions.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> If you modify a copy of the Library, and, in your modifications, a</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">facility refers to a function or data to be supplied by an Application</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">that uses the facility (other than as an argument passed when the</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">facility is invoked), then you may convey a copy of the modified</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">version:</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> a) under this License, provided that you make a good faith effort to</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> ensure that, in the event an Application does not supply the</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> function or data, the facility still operates, and performs</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> whatever part of its purpose remains meaningful, or</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> b) under the GNU GPL, with none of the additional permissions of</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> this License applicable to that copy.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> 3. Object Code Incorporating Material from Library Header Files.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> The object code form of an Application may incorporate material from</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">a header file that is part of the Library. You may convey such object</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">code under terms of your choice, provided that, if the incorporated</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">material is not limited to numerical parameters, data structure</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">layouts and accessors, or small macros, inline functions and templates</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">(ten or fewer lines in length), you do both of the following:</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> a) Give prominent notice with each copy of the object code that the</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> Library is used in it and that the Library and its use are</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> covered by this License.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> b) Accompany the object code with a copy of the GNU GPL and this license</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> document.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> 4. Combined Works.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> You may convey a Combined Work under terms of your choice that,</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">taken together, effectively do not restrict modification of the</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">portions of the Library contained in the Combined Work and reverse</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">engineering for debugging such modifications, if you also do each of</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">the following:</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> a) Give prominent notice with each copy of the Combined Work that</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> the Library is used in it and that the Library and its use are</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> covered by this License.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> b) Accompany the Combined Work with a copy of the GNU GPL and this license</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> document.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> c) For a Combined Work that displays copyright notices during</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> execution, include the copyright notice for the Library among</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> these notices, as well as a reference directing the user to the</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> copies of the GNU GPL and this license document.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> d) Do one of the following:</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> 0) Convey the Minimal Corresponding Source under the terms of this</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> License, and the Corresponding Application Code in a form</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> suitable for, and under terms that permit, the user to</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> recombine or relink the Application with a modified version of</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> the Linked Version to produce a modified Combined Work, in the</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> manner specified by section 6 of the GNU GPL for conveying</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> Corresponding Source.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> 1) Use a suitable shared library mechanism for linking with the</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> Library. A suitable mechanism is one that (a) uses at run time</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> a copy of the Library already present on the user's computer</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> system, and (b) will operate properly with a modified version</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> of the Library that is interface-compatible with the Linked</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> Version.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> e) Provide Installation Information, but only if you would otherwise</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> be required to provide such information under section 6 of the</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> GNU GPL, and only to the extent that such information is</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> necessary to install and execute a modified version of the</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> Combined Work produced by recombining or relinking the</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> Application with a modified version of the Linked Version. (If</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> you use option 4d0, the Installation Information must accompany</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> the Minimal Corresponding Source and Corresponding Application</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> Code. If you use option 4d1, you must provide the Installation</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> Information in the manner specified by section 6 of the GNU GPL</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> for conveying Corresponding Source.)</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> 5. Combined Libraries.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> You may place library facilities that are a work based on the</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">Library side by side in a single library together with other library</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">facilities that are not Applications and are not covered by this</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">License, and convey such a combined library under terms of your</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">choice, if you do both of the following:</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> a) Accompany the combined library with a copy of the same work based</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> on the Library, uncombined with any other library facilities,</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> conveyed under the terms of this License.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> b) Give prominent notice with the combined library that part of it</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> is a work based on the Library, and explaining where to find the</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> accompanying uncombined form of the same work.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> 6. Revised Versions of the GNU Lesser General Public License.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> The Free Software Foundation may publish revised and/or new versions</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">of the GNU Lesser General Public License from time to time. Such new</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">versions will be similar in spirit to the present version, but may</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">differ in detail to address new problems or concerns.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> Each version is given a distinguishing version number. If the</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">Library as you received it specifies that a certain numbered version</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">of the GNU Lesser General Public License &quot;or any later version&quot;</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">applies to it, you have the option of following the terms and</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">conditions either of that published version or of any later version</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">published by the Free Software Foundation. If the Library as you</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">received it does not specify a version number of the GNU Lesser</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">General Public License, you may choose any version of the GNU Lesser</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">General Public License ever published by the Free Software Foundation.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;"> If the Library as you received it specifies that a proxy can decide</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">whether future versions of the GNU Lesser General Public License shall</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">apply, that proxy's public statement of acceptance of any version is</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">permanent authorization for you to choose that version for the</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">Library.</span></p></body></html> + + + + About + + + + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Ubuntu'; font-size:11pt; font-weight:400; font-style:normal;"> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt; color:#1a1a1a;">Sankoré 3.1 version , Copyright (C) 2010 Sankoré 3.1 comes with ABSOLUTELY NO WARRANTY.</span><span style=" font-size:9pt;"><br /></span><span style=" font-size:9pt; color:#35382a;"> </span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt; color:#35382a;">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 3 of the License, or (at your option) any later version.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt; color:#35382a;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt; color:#35382a;">This program 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.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt; color:#35382a;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt; color:#35382a;">You should have received a copy of the GNU General Public License along with this program. If not, see &lt;http://www.gnu.org/licenses/&gt;.</span></p></body></html> + + + + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Ubuntu'; font-size:11pt; font-weight:400; font-style:normal;"> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:10pt;"></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt; color:#3c3c3c;">GIPENA</span><span style=" font-size:9pt;"><br /></span><span style=" font-size:9pt; color:#3c3c3c;">Délégation Interministérielle à l'Education Numérique en Afrique</span><span style=" font-size:9pt;"><br /></span><span style=" font-size:9pt; color:#3c3c3c;">20 Avenue Ségur Paris 75007</span><span style=" font-size:9pt;"><br /><br /></span><span style=" font-size:9pt; color:#3c3c3c;">Téléphone : 01 43 17 68 08</span><span style=" font-size:9pt;"><br /><br /></span><span style=" font-size:9pt; color:#3c3c3c;">email: </span><a href="mailto:contact@sankore.org"><span style=" font-size:9pt; text-decoration: underline; color:#0000ff;">contact@sankore.org</span></a><span style=" font-size:9pt;"> </span></p></body></html> + + + + Software Update + + + + Check software update at launch + + + + Network + + + + Community + + + + User/Pass: + + + + + trapFlashDialog + + Trap flash + + + + Select a flash to trap + + + + about:blank + + + + Application name + + + + Create Application + + + + diff --git a/src/adaptors/publishing/UBDocumentPublisher.cpp b/src/adaptors/publishing/UBDocumentPublisher.cpp index e2201f05..00ad33d6 100644 --- a/src/adaptors/publishing/UBDocumentPublisher.cpp +++ b/src/adaptors/publishing/UBDocumentPublisher.cpp @@ -60,8 +60,10 @@ UBDocumentPublisher::~UBDocumentPublisher() void UBDocumentPublisher::publish() { //check that the username and password are stored on preferences - mUsername = "Admin"; - mPassword = "admin"; + UBSettings* settings = UBSettings::settings(); + + mUsername = settings->communityUsername(); + mPassword = settings->communityPassword(); buildUbwFile(); UBApplication::showMessage(tr("Uploading Sankore File on Web.")); sendUbw(); diff --git a/src/api/UBWidgetUniboardAPI.cpp b/src/api/UBWidgetUniboardAPI.cpp index 19555866..bda9d64b 100644 --- a/src/api/UBWidgetUniboardAPI.cpp +++ b/src/api/UBWidgetUniboardAPI.cpp @@ -375,6 +375,26 @@ QString UBWidgetUniboardAPI::lang() return lang; } +void UBWidgetUniboardAPI::returnStatus(const QString& method, const QString& status) +{ + QString msg = QString(tr("%0 called (method=%1, status=%2)")).arg("returnStatus").arg(method).arg(status); + UBApplication::showMessage(msg); +} + +void UBWidgetUniboardAPI::usedMethods(QStringList methods) +{ + // TODO: Implement this method + foreach(QString method, methods) + { + + } +} + +void UBWidgetUniboardAPI::response(bool correct) +{ + Q_UNUSED(correct); + // TODO: Implement this method +} UBDocumentDatastoreAPI::UBDocumentDatastoreAPI(UBGraphicsW3CWidgetItem *graphicsWidget) diff --git a/src/api/UBWidgetUniboardAPI.h b/src/api/UBWidgetUniboardAPI.h index 839b0bee..0310a84b 100644 --- a/src/api/UBWidgetUniboardAPI.h +++ b/src/api/UBWidgetUniboardAPI.h @@ -207,6 +207,9 @@ class UBWidgetUniboardAPI : public QObject void addText(const QString& text, const qreal x, const qreal y, const int height = -1, const QString& font = "" , bool bold = false, bool italic = false); + void returnStatus(const QString& method, const QString& status); + void usedMethods(QStringList methods); + void response(bool correct); private: QString uuid(); diff --git a/src/core/UBPreferencesController.cpp b/src/core/UBPreferencesController.cpp index a8759889..2bf93f5b 100644 --- a/src/core/UBPreferencesController.cpp +++ b/src/core/UBPreferencesController.cpp @@ -38,6 +38,8 @@ UBPreferencesController::UBPreferencesController(QWidget *parent) mPreferencesWindow = new QDialog(parent, Qt::Dialog); mPreferencesUI = new Ui::preferencesDialog(); // deleted in UBPreferencesController::destructor mPreferencesUI->setupUi(mPreferencesWindow); + connect(mPreferencesUI->Username_textBox, SIGNAL(editingFinished()), this, SLOT(onCommunityUsernameChanged())); + connect(mPreferencesUI->Password_textEdit, SIGNAL(editingFinished()), this, SLOT(onCommunityPasswordChanged())); wire(); } @@ -160,6 +162,9 @@ void UBPreferencesController::init() mPreferencesUI->verticalChoice->setChecked(settings->appToolBarOrientationVertical->get().toBool()); mPreferencesUI->horizontalChoice->setChecked(!settings->appToolBarOrientationVertical->get().toBool()); + mPreferencesUI->Username_textBox->setText(settings->communityUsername()); + mPreferencesUI->Password_textEdit->setText(settings->communityPassword()); + // pen tab mPenProperties->fineSlider->setValue(settings->boardPenFineWidth->get().toDouble() * sSliderRatio); mPenProperties->mediumSlider->setValue(settings->boardPenMediumWidth->get().toDouble() * sSliderRatio); @@ -176,6 +181,18 @@ void UBPreferencesController::init() } +void UBPreferencesController::onCommunityUsernameChanged() +{ + UBSettings* settings = UBSettings::settings(); + settings->setCommunityUsername(mPreferencesUI->Username_textBox->text()); +} + +void UBPreferencesController::onCommunityPasswordChanged() +{ + UBSettings* settings = UBSettings::settings(); + settings->setCommunityPassword(mPreferencesUI->Password_textEdit->text()); +} + void UBPreferencesController::close() { //web diff --git a/src/core/UBPreferencesController.h b/src/core/UBPreferencesController.h index 9911539d..39c9cb51 100644 --- a/src/core/UBPreferencesController.h +++ b/src/core/UBPreferencesController.h @@ -55,6 +55,8 @@ class UBPreferencesController : public QObject void toolbarPositionChanged(bool checked); void toolbarOrientationVertical(bool checked); void toolbarOrientationHorizontal(bool checked); + void onCommunityUsernameChanged(); + void onCommunityPasswordChanged(); private: diff --git a/src/core/UBSettings.cpp b/src/core/UBSettings.cpp index ec8a59e9..3707e997 100644 --- a/src/core/UBSettings.cpp +++ b/src/core/UBSettings.cpp @@ -313,6 +313,9 @@ void UBSettings::init() uniboardWebAuthor = new UBSetting(this, "UniboardWeb", "Author", ""); uniboardWebGoogleMapApiKey = new UBSetting(this, "UniboardWeb", "GoogleMapAPIKey", "ABQIAAAAsWU4bIbaeCLinpZ30N_erRQEk562OPinwQkG9J-ZXUNAqYhJ5RT_z2EmpfVXiUg8c41BcsD_XM6P5g"); + communityUser = new UBSetting(this, "Community", "Username", ""); + communityPsw = new UBSetting(this, "Community", "Password", ""); + QStringList uris = UBToolsManager::manager()->allToolIDs(); favoritesNativeToolUris = new UBSetting(this, "App", "FavoriteToolURIs", uris); @@ -1292,3 +1295,22 @@ void UBSettings::setProxyPassword(const QString& password) } +QString UBSettings::communityUsername() +{ + return communityUser->get().toString(); +} + +void UBSettings::setCommunityUsername(const QString &username) +{ + communityUser->set(QVariant(username)); +} + +QString UBSettings::communityPassword() +{ + return communityPsw->get().toString(); +} + +void UBSettings::setCommunityPassword(const QString &password) +{ + communityPsw->set(QVariant(password)); +} diff --git a/src/core/UBSettings.h b/src/core/UBSettings.h index d4720e66..08748383 100644 --- a/src/core/UBSettings.h +++ b/src/core/UBSettings.h @@ -89,6 +89,11 @@ class UBSettings : public QObject QString proxyPassword(); void setProxyPassword(const QString& password); + QString communityUsername(); + void setCommunityUsername(const QString& username); + QString communityPassword(); + void setCommunityPassword(const QString& password); + void init(); static QString uniboardDataDirectory(); @@ -315,6 +320,9 @@ class UBSettings : public QObject UBSetting* navigPaletteWidth; UBSetting* libPaletteWidth; + UBSetting* communityUser; + UBSetting* communityPsw; + /* static int navigPaletteWidth; static int libPaletteWidth; diff --git a/src/domain/UBGraphicsWidgetItem.cpp b/src/domain/UBGraphicsWidgetItem.cpp index e7fbcc8e..7ec7cb98 100644 --- a/src/domain/UBGraphicsWidgetItem.cpp +++ b/src/domain/UBGraphicsWidgetItem.cpp @@ -36,7 +36,7 @@ void UBGraphicsWidgetItem::javaScriptWindowObjectCleared() if(!mUniboardAPI) mUniboardAPI = new UBWidgetUniboardAPI(scene(), this); - mWebKitWidget->page()->mainFrame()->addToJavaScriptWindowObject("uniboard", mUniboardAPI); + mWebKitWidget->page()->mainFrame()->addToJavaScriptWindowObject("sankore", mUniboardAPI); } diff --git a/src/domain/UBW3CWidget.cpp b/src/domain/UBW3CWidget.cpp index 4ca26cfb..81ec3201 100644 --- a/src/domain/UBW3CWidget.cpp +++ b/src/domain/UBW3CWidget.cpp @@ -169,7 +169,7 @@ void UBW3CWidget::javaScriptWindowObjectCleared() { UBWidgetUniboardAPI *uniboardAPI = new UBWidgetUniboardAPI(UBApplication::boardController->activeScene(), 0); - page()->mainFrame()->addToJavaScriptWindowObject("uniboard", uniboardAPI); + page()->mainFrame()->addToJavaScriptWindowObject("sankore", uniboardAPI); UBWidgetVotingSystemAPI *votingSystem = new UBWidgetVotingSystemAPI(this); page()->mainFrame()->addToJavaScriptWindowObject("voting", votingSystem); diff --git a/src/gui/UBToolWidget.cpp b/src/gui/UBToolWidget.cpp index 539d8b66..60a15b9c 100644 --- a/src/gui/UBToolWidget.cpp +++ b/src/gui/UBToolWidget.cpp @@ -120,7 +120,7 @@ void UBToolWidget::javaScriptWindowObjectCleared() { UBWidgetUniboardAPI* uniboardAPI = new UBWidgetUniboardAPI(UBApplication::boardController->activeScene()); - mToolWidget->page()->mainFrame()->addToJavaScriptWindowObject("uniboard", uniboardAPI); + mToolWidget->page()->mainFrame()->addToJavaScriptWindowObject("sankore", uniboardAPI); UBW3CWidget* w3c = dynamic_cast(mToolWidget); if (w3c) From e99a2eed3c79944a73f69276c31bd9ffd558e6bc Mon Sep 17 00:00:00 2001 From: Anatoly Mihalchenko Date: Mon, 4 Jul 2011 18:20:12 +0300 Subject: [PATCH 03/13] Graphics Triangle Tool --- Sankore 3.1.iss | 89 ------------------ resources/images/toolPalette/triangleTool.png | Bin 11360 -> 9618 bytes src/tools/UBGraphicsTriangle.cpp | 71 ++++++++------ src/tools/UBGraphicsTriangle.h | 4 +- 4 files changed, 42 insertions(+), 122 deletions(-) delete mode 100644 Sankore 3.1.iss diff --git a/Sankore 3.1.iss b/Sankore 3.1.iss deleted file mode 100644 index 158894c7..00000000 --- a/Sankore 3.1.iss +++ /dev/null @@ -1,89 +0,0 @@ -; Script generated by the Inno Setup Script Wizard. -; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES! - -[Setup] -; NOTE: The value of AppId uniquely identifies this application. -; Do not use the same AppId value in installers for other applications. -; (To generate a new GUID, click Tools | Generate GUID inside the IDE.) -AppId={{E63D17F8-D9DA-479D-B9B5-0D101A03703B} -AppName=Sankore 3.1 -AppVerName=Sankore 3.1 -AppPublisher=Mnemis - -AppPublisherURL=http://www.getuniboard.com -AppSupportURL=http://support.getuniboard.com -AppUpdatesURL=http://www.getuniboard.com - -DefaultDirName={pf}\Sankore 3.1 -DefaultGroupName=Sankore 3.1 - -OutputDir=.\install\win32\ -OutputBaseFilename=Sankore 3.1 setup -SetupIconFile=.\resources\win\uniboard.ico -Compression=lzma -SolidCompression=yes - -[Languages] -Name: "english"; MessagesFile: "compiler:Default.isl" - -[Tasks] -Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked -Name: "quicklaunchicon"; Description: "{cm:CreateQuickLaunchIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked - -[InstallDelete] - -Type: files ; Name: "{app}\Sankore 3.1.pdb" -Type: filesandordirs ; Name: "{app}\library" -Type: filesandordirs ; Name: "{app}\Microsoft.VC90.CRT" -Type: filesandordirs ; Name: "{app}\plugins" -Type: filesandordirs ; Name: "{app}\i18n" -Type: files ; Name: "{app}\*.dll" - -[Files] -Source: ".\build\win32\release\product\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs createallsubdirs -Source: ".\runtime\windows\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs createallsubdirs; -Source: ".\resources\win\plugins\*"; DestDir: "{app}"; Flags: recursesubdirs createallsubdirs -; NOTE: Don't use "Flags: ignoreversion" on any shared system files - -[Icons] -Name: "{group}\Sankore 3.1"; Filename: "{app}\Sankore 3.1.exe" -;Name: "{group}\{cm:ProgramOnTheWeb,Sankore 3.1}"; Filename: "http://www.getuniboard.com/" -Name: "{group}\{cm:UninstallProgram,Sankore 3.1}"; Filename: "{uninstallexe}" -Name: "{commondesktop}\Sankore 3.1"; Filename: "{app}\Sankore 3.1.exe"; Tasks: desktopicon -Name: "{userappdata}\Microsoft\Internet Explorer\Quick Launch\Sankore 3.1"; Filename: "{app}\Sankore 3.1.exe"; Tasks: quicklaunchicon -Name: "{group}\Printing Preferences"; Filename: "{app}\properties.exe"; WorkingDir: {app} - -[Registry] -Root: HKCR; Subkey: ".ubz"; ValueType: string; ValueName: ""; ValueData: "SankoreFile"; Flags: uninsdeletevalue -Root: HKCR; Subkey: "SankoreFile"; ValueType: string; ValueName: ""; ValueData: "Sankore 3.1 document"; Flags: uninsdeletekey -Root: HKCR; Subkey: "SankoreFile\DefaultIcon"; ValueType: string; ValueName: ""; ValueData: "{app}\Sankore 3.1.exe,1" -Root: HKCR; Subkey: "SankoreFile\shell\open\command"; ValueType: string; ValueName: ""; ValueData: """{app}\Sankore 3.1.exe"" ""%1""" - -Root: HKLM; Subkey: "SOFTWARE\Sankore 3.1"; ValueType: string; ValueName: "Client application"; ValueData: "{app}\Sankore 3.1.exe"; Flags: uninsdeletevalue; Check: isProcessorNotX64 -Root: HKLM; Subkey: "SOFTWARE\Sankore 3.1"; ValueType: dword; ValueName: "Transfer mode"; ValueData: "0"; Flags: uninsdeletevalue; Check: isProcessorNotX64 -Root: HKLM; Subkey: "SOFTWARE\Sankore 3.1"; ValueType: dword; ValueName: "EMF: Hide page"; ValueData: "1"; Flags: uninsdeletevalue; Check: isProcessorNotX64 -Root: HKLM; Subkey: "SOFTWARE\Sankore 3.1\Defaults"; ValueType: dword; ValueName: "PDF: Enabled"; ValueData: "1"; Flags: uninsdeletevalue; Check: isProcessorNotX64 - -Root: HKLM64; Subkey: "SOFTWARE\Sankore 3.1"; ValueType: string; ValueName: "Client application"; ValueData: "{app}\Sankore 3.1.exe"; Flags: uninsdeletevalue; Check: isProcessorX64 -Root: HKLM64; Subkey: "SOFTWARE\Sankore 3.1"; ValueType: dword; ValueName: "Transfer mode"; ValueData: "0"; Flags: uninsdeletevalue; Check: isProcessorX64 -Root: HKLM64; Subkey: "SOFTWARE\Sankore 3.1"; ValueType: dword; ValueName: "EMF: Hide page"; ValueData: "1"; Flags: uninsdeletevalue; Check: isProcessorX64 -Root: HKLM64; Subkey: "SOFTWARE\Sankore 3.1\Defaults"; ValueType: dword; ValueName: "PDF: Enabled"; ValueData: "1"; Flags: uninsdeletevalue; Check: isProcessorX64 - -[Run] -Filename: "{app}\Sankore 3.1.exe"; Description: "{cm:LaunchProgram,Sankore 3.1}"; Flags: nowait postinstall - -[UninstallDelete] -; cleanup and delete whole installation directory -Name: {app}; Type: filesandordirs - -[Code] -function isProcessorX64: Boolean; -begin - Result := (ProcessorArchitecture = paX64); -end; - -function isProcessorNotX64: Boolean; -begin - Result := not isProcessorX64; -end; - diff --git a/resources/images/toolPalette/triangleTool.png b/resources/images/toolPalette/triangleTool.png index 0421bcea69995c0cc0247009ea0855bee5d20920..a9c876cd34451fc7ec64e66fb1ed00f660df0acd 100644 GIT binary patch literal 9618 zcmV;DC2iV?P)>-`q#IGLTK1 zoow3re#W-G`fva7C*Qd7-TLPL{NXp>I1+`yyHVhMEe!lu{2)XaMlzlpcc21I4a3l2 z8b;nSj4#@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?3Y68Y_9_Ts%oz1s(3+I{+v9EPr>z_4|qCW%(Z z`H5TRgRcX#00_#M?LsX|O%hTPCiQ{_RB{!qt4znzRLNNCLQgH41kXEB6G}@UG{>w+Vdxqf zQ~VXet^saLL?P9dLtYs9+Ic}Km?P3`K+^V#QcC(Z)66@iDjAK7E&a0+_BNe;Ry(=l zb%xI5d;t~3ku@0_%+(@dU9VeDHpCr&##(6^qvr#2AFQ9&@+!;kTVsV*z;+l8%Nyg$ zxBGRRTDM#&DX$lpd$Ro&>|#2mZRQMA1%!orCzcT7e55JI`}5Uo?@p0tW+prch54fp zon#M--5Xz@0ZM%cCA{;WIkb@SFS*ti2~jo?6`4U)g;2*0L)ZXdcbdILA8a?4v=Snd zckg0Eym^Kq&?lj)`{41l({FL{SB60b zwTzW06&{lfWx!bmga1_@MP*VCzJ7gkLS_j&K5!Dhflk>hupmSK6IO$9OJkH9&{G0x z&qms{6z0?ba@A=YiqIa5JpP=K4imR{9%fL9&Bxjo$raQg&~lG<@a1_YmbLbmp+@Uo z@SnHcdvMl?StsjDlMAExt#9voDObzNmzEGGknk5T;F9c=O>j7TY=|okHnGicUVpA) zwuCtqhgVK;8i3;v_~uX?{S8`7SMRNh(#7xneJWekbr!bf+ZXOH2wxOr#KaDIx0vwU zqPMDK^lsVMsJvE>yXj+1*$lbX*Spo$yme6FQ|6!Z#@_(bKNMQT9jeQzokPP(xNQ1I zi{!8sgXYftl+?vLDnz5ljfSC9+Fl2h}g>=r5E#9ukboitfN9i;kQdSLrj_-4`mo zl^P|c-lWr=SB^i(1O^7Of(V*O9yfUC^=&jFH^jum=0hll=;UsHvdEhY;ysq=Q#Bww zI)amk3yL2e$%%;_3dUDfMlb7xeg#PT)$B*EwGV_Gw_FK{AgJyltD~{LLgLrNT8hDy$DKDK??lDo4!6!mKi;MHk0D$UvLLGVdmHSg k->paangle = -this->angle; + rotateAroundCenter(t, rotationCenter()); + setTransform(t); + } } UBGraphicsScene* UBGraphicsTriangle::scene() const @@ -236,17 +240,19 @@ void UBGraphicsTriangle::paintGraduations(QPainter *painter) void UBGraphicsTriangle::rotateAroundCenter(qreal angle) { + qreal oldAngle = this->angle; this->angle = angle; QTransform transform; - rotateAroundCenter(transform); + rotateAroundCenter(transform, rotationCenter()); setTransform(transform, true); + this->angle = oldAngle + angle; // We have to store absolute value for FLIP case } -void UBGraphicsTriangle::rotateAroundCenter(QTransform& transform) +void UBGraphicsTriangle::rotateAroundCenter(QTransform& transform, QPointF center) { - transform.translate(rotationCenter().x(), rotationCenter().y()); + transform.translate(center.x(), center.y()); transform.rotate(angle); - transform.translate(- rotationCenter().x(), - rotationCenter().y()); + transform.translate(- center.x(), - center.y()); } @@ -388,11 +394,11 @@ void UBGraphicsTriangle::mouseMoveEvent(QGraphicsSceneMouseEvent *event) } else { - setRect( + setRect(QRectF( rect().left() - delta.x(), rect().top(), rect().width() + delta.x(), - rect().height(), + rect().height()), mOrientation ); } @@ -400,15 +406,18 @@ void UBGraphicsTriangle::mouseMoveEvent(QGraphicsSceneMouseEvent *event) if (mResizing2) { QPointF delta = event->pos() - event->lastPos(); - if (rect().height() + delta.y() < sMinHeight) + if (rect().height() - delta.y() < sMinHeight) delta.setY(sMinHeight - rect().height()); - qDebug() << delta; - setRect(QRect( + qDebug() << event->pos() << event->lastPos() << delta; + QRectF r( rect().left(), rect().top() + delta.y(), rect().width(), - rect().height() - delta.y()), - mOrientation); + rect().height() - delta.y()); + qDebug() << r; + setRect(r, mOrientation); + + } if (mRotating) { diff --git a/src/tools/UBGraphicsTriangle.h b/src/tools/UBGraphicsTriangle.h index 69e9f436..756a1fc6 100644 --- a/src/tools/UBGraphicsTriangle.h +++ b/src/tools/UBGraphicsTriangle.h @@ -94,7 +94,7 @@ class UBGraphicsTriangle : public UBAbstractDrawRuler, public QGraphicsPolygonIt QTransform calculateRotationTransform(); qreal angle; - void rotateAroundCenter(QTransform& transform); + void rotateAroundCenter(QTransform& transform, QPointF center); bool mResizing1; bool mResizing2; @@ -115,7 +115,7 @@ class UBGraphicsTriangle : public UBAbstractDrawRuler, public QGraphicsPolygonIt static const int d = 70; // width of triangle border static const int sArrowLength = 30; static const int sMinWidth = 200; - static const int sMinHeight = 150; + static const int sMinHeight = 200; }; #endif /* UBGRAPHICSTRIANGLE_H_ */ From 7d08495143441378997d7825fa159aa4394a8ff6 Mon Sep 17 00:00:00 2001 From: Anatoly Mihalchenko Date: Mon, 4 Jul 2011 18:25:59 +0300 Subject: [PATCH 04/13] Comp. errors in UBPreferencesControler - marked by ??? --- src/core/UBPreferencesController.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/core/UBPreferencesController.cpp b/src/core/UBPreferencesController.cpp index 2bf93f5b..6297f407 100644 --- a/src/core/UBPreferencesController.cpp +++ b/src/core/UBPreferencesController.cpp @@ -38,8 +38,8 @@ UBPreferencesController::UBPreferencesController(QWidget *parent) mPreferencesWindow = new QDialog(parent, Qt::Dialog); mPreferencesUI = new Ui::preferencesDialog(); // deleted in UBPreferencesController::destructor mPreferencesUI->setupUi(mPreferencesWindow); - connect(mPreferencesUI->Username_textBox, SIGNAL(editingFinished()), this, SLOT(onCommunityUsernameChanged())); - connect(mPreferencesUI->Password_textEdit, SIGNAL(editingFinished()), this, SLOT(onCommunityPasswordChanged())); + // ??? connect(mPreferencesUI->Username_textBox, SIGNAL(editingFinished()), this, SLOT(onCommunityUsernameChanged())); + // ??? connect(mPreferencesUI->Password_textEdit, SIGNAL(editingFinished()), this, SLOT(onCommunityPasswordChanged())); wire(); } @@ -162,8 +162,8 @@ void UBPreferencesController::init() mPreferencesUI->verticalChoice->setChecked(settings->appToolBarOrientationVertical->get().toBool()); mPreferencesUI->horizontalChoice->setChecked(!settings->appToolBarOrientationVertical->get().toBool()); - mPreferencesUI->Username_textBox->setText(settings->communityUsername()); - mPreferencesUI->Password_textEdit->setText(settings->communityPassword()); + // ??? mPreferencesUI->Username_textBox->setText(settings->communityUsername()); + // ??? mPreferencesUI->Password_textEdit->setText(settings->communityPassword()); // pen tab mPenProperties->fineSlider->setValue(settings->boardPenFineWidth->get().toDouble() * sSliderRatio); @@ -184,13 +184,13 @@ void UBPreferencesController::init() void UBPreferencesController::onCommunityUsernameChanged() { UBSettings* settings = UBSettings::settings(); - settings->setCommunityUsername(mPreferencesUI->Username_textBox->text()); + // ??? settings->setCommunityUsername(mPreferencesUI->Username_textBox->text()); } void UBPreferencesController::onCommunityPasswordChanged() { UBSettings* settings = UBSettings::settings(); - settings->setCommunityPassword(mPreferencesUI->Password_textEdit->text()); + // ??? settings->setCommunityPassword(mPreferencesUI->Password_textEdit->text()); } void UBPreferencesController::close() From b2f2de0e79dcfd3900af5d46ce2a06aee017af09 Mon Sep 17 00:00:00 2001 From: shibakaneki Date: Tue, 5 Jul 2011 08:31:38 +0200 Subject: [PATCH 05/13] forgot to update the form on the repository, my mistake... --- resources/forms/preferences.ui | 190 +++++++++++++++++++++++---------- 1 file changed, 131 insertions(+), 59 deletions(-) diff --git a/resources/forms/preferences.ui b/resources/forms/preferences.ui index d55a6287..2d694d52 100644 --- a/resources/forms/preferences.ui +++ b/resources/forms/preferences.ui @@ -21,10 +21,59 @@ + + + + QFrame::NoFrame + + + QFrame::Raised + + + + 0 + + + + + Default Settings + + + + + + + Qt::Horizontal + + + + 40 + 20 + + + + + + + + + + Close + + + true + + + + + + + + - 4 + 0 @@ -564,7 +613,7 @@ - 4 + 3 @@ -577,7 +626,7 @@ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> <html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'Ubuntu'; font-size:10pt; font-weight:400; font-style:normal;"> +</style></head><body style=" font-family:'Ubuntu'; font-size:11pt; font-weight:400; font-style:normal;"> <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt; color:#1a1a1a;">The OpenSSL toolkit stays under a dual license, i.e. both the conditions of the OpenSSL License and the original SSLeay license apply to the toolkit.</span></p> <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt; color:#1a1a1a;">See below for the actual license texts. Actually both licenses are BSD-style Open Source licenses. In case of any license issues related to OpenSSL please contact </span><a href="mailto:openssl-core@openssl.org"><span style=" font-size:9pt; text-decoration: underline; color:#0000ff;">openssl-core@openssl.org</span></a><span style=" font-size:9pt; color:#1a1a1a;">.</span><span style=" font-size:9pt;"> </span></p></body></html> @@ -596,7 +645,7 @@ p, li { white-space: pre-wrap; } <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> <html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'Ubuntu'; font-size:10pt; font-weight:400; font-style:normal;"> +</style></head><body style=" font-family:'Ubuntu'; font-size:11pt; font-weight:400; font-style:normal;"> <p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt; color:#1a1a1a;">Copyright (C) 1995-1998 Jean-loup Gailly and Mark Adler</span><span style=" font-size:12pt;"><br /><br /></span><span style=" font-size:9pt; color:#1a1a1a;"> This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software.</span><span style=" font-size:9pt;"><br /><br /></span><span style=" font-size:9pt; color:#1a1a1a;"> Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions:</span><span style=" font-size:9pt;"><br /><br /></span><span style=" font-size:9pt; color:#1a1a1a;"> 1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required.</span><span style=" font-size:9pt;"><br /></span><span style=" font-size:9pt; color:#1a1a1a;"> 2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software.</span><span style=" font-size:9pt;"><br /></span><span style=" font-size:9pt; color:#1a1a1a;"> 3. This notice may not be removed or altered from any source distribution.</span><span style=" font-size:9pt;"> </span></p></body></html> @@ -614,7 +663,7 @@ p, li { white-space: pre-wrap; } <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> <html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'Ubuntu'; font-size:10pt; font-weight:400; font-style:normal;"> +</style></head><body style=" font-family:'Ubuntu'; font-size:11pt; font-weight:400; font-style:normal;"> <p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt; color:#000000;">Xpdf is licensed under the GNU General Public License (GPL), version 2.</span></p></body></html> @@ -632,7 +681,7 @@ p, li { white-space: pre-wrap; } <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> <html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'Ubuntu'; font-size:10pt; font-weight:400; font-style:normal;"> +</style></head><body style=" font-family:'Ubuntu'; font-size:11pt; font-weight:400; font-style:normal;"> <p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">GNU Library or Lesser General Public License (LGPL), zlib/libpng License</span></p></body></html> @@ -650,7 +699,7 @@ p, li { white-space: pre-wrap; } <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> <html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'Ubuntu'; font-size:10pt; font-weight:400; font-style:normal;"> +</style></head><body style=" font-family:'Ubuntu'; font-size:11pt; font-weight:400; font-style:normal;"> <p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt;">SANKORE3.1 is free software: you can redistribute it and/or modify it under the terms of the Lesser GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or any later version. You can find the source code of this software at &lt;https://adullact.net/projects/sankore/&gt;</span></p> <p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> <p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt;"></p> @@ -845,7 +894,7 @@ p, li { white-space: pre-wrap; } <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> <html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'Ubuntu'; font-size:10pt; font-weight:400; font-style:normal;"> +</style></head><body style=" font-family:'Ubuntu'; font-size:11pt; font-weight:400; font-style:normal;"> <p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt; color:#1a1a1a;">Sankoré 3.1 version , Copyright (C) 2010 Sankoré 3.1 comes with ABSOLUTELY NO WARRANTY.</span><span style=" font-size:9pt;"><br /></span><span style=" font-size:9pt; color:#35382a;"> </span></p> <p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt; color:#35382a;">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 3 of the License, or (at your option) any later version.</span></p> <p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:9pt; color:#35382a;"></p> @@ -861,8 +910,8 @@ p, li { white-space: pre-wrap; } <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> <html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'Ubuntu'; font-size:10pt; font-weight:400; font-style:normal;"> -<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"></p> +</style></head><body style=" font-family:'Ubuntu'; font-size:11pt; font-weight:400; font-style:normal;"> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:10pt;"></p> <p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:9pt; color:#3c3c3c;">GIPENA</span><span style=" font-size:9pt;"><br /></span><span style=" font-size:9pt; color:#3c3c3c;">Délégation Interministérielle à l'Education Numérique en Afrique</span><span style=" font-size:9pt;"><br /></span><span style=" font-size:9pt; color:#3c3c3c;">20 Avenue Ségur Paris 75007</span><span style=" font-size:9pt;"><br /><br /></span><span style=" font-size:9pt; color:#3c3c3c;">Téléphone : 01 43 17 68 08</span><span style=" font-size:9pt;"><br /><br /></span><span style=" font-size:9pt; color:#3c3c3c;">email: </span><a href="mailto:contact@sankore.org"><span style=" font-size:9pt; text-decoration: underline; color:#0000ff;">contact@sankore.org</span></a><span style=" font-size:9pt;"> </span></p></body></html> @@ -907,55 +956,78 @@ p, li { white-space: pre-wrap; } - - - - - - QFrame::NoFrame - - - QFrame::Raised - - - - 0 - - - - - Default Settings - - - - - - - Qt::Horizontal - - - - 40 - 20 - - - - - - - - - - Close - - - true - - - - - - + + + Network + + + + + + + 0 + 0 + + + + Community + + + + + + + + User/Pass: + + + + + + + + 5 + + + 0 + + + + + QLineEdit::Normal + + + + + + + QLineEdit::Password + + + + + + + + + + + + Qt::Vertical + + + + 20 + 40 + + + + + + + + + From 331a82ff16c9ef560f8c069b6053b5e13ca9282c Mon Sep 17 00:00:00 2001 From: shibakaneki Date: Tue, 5 Jul 2011 08:37:38 +0200 Subject: [PATCH 06/13] re-enabled some preferences --- src/core/UBPreferencesController.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/core/UBPreferencesController.cpp b/src/core/UBPreferencesController.cpp index 6297f407..2bf93f5b 100644 --- a/src/core/UBPreferencesController.cpp +++ b/src/core/UBPreferencesController.cpp @@ -38,8 +38,8 @@ UBPreferencesController::UBPreferencesController(QWidget *parent) mPreferencesWindow = new QDialog(parent, Qt::Dialog); mPreferencesUI = new Ui::preferencesDialog(); // deleted in UBPreferencesController::destructor mPreferencesUI->setupUi(mPreferencesWindow); - // ??? connect(mPreferencesUI->Username_textBox, SIGNAL(editingFinished()), this, SLOT(onCommunityUsernameChanged())); - // ??? connect(mPreferencesUI->Password_textEdit, SIGNAL(editingFinished()), this, SLOT(onCommunityPasswordChanged())); + connect(mPreferencesUI->Username_textBox, SIGNAL(editingFinished()), this, SLOT(onCommunityUsernameChanged())); + connect(mPreferencesUI->Password_textEdit, SIGNAL(editingFinished()), this, SLOT(onCommunityPasswordChanged())); wire(); } @@ -162,8 +162,8 @@ void UBPreferencesController::init() mPreferencesUI->verticalChoice->setChecked(settings->appToolBarOrientationVertical->get().toBool()); mPreferencesUI->horizontalChoice->setChecked(!settings->appToolBarOrientationVertical->get().toBool()); - // ??? mPreferencesUI->Username_textBox->setText(settings->communityUsername()); - // ??? mPreferencesUI->Password_textEdit->setText(settings->communityPassword()); + mPreferencesUI->Username_textBox->setText(settings->communityUsername()); + mPreferencesUI->Password_textEdit->setText(settings->communityPassword()); // pen tab mPenProperties->fineSlider->setValue(settings->boardPenFineWidth->get().toDouble() * sSliderRatio); @@ -184,13 +184,13 @@ void UBPreferencesController::init() void UBPreferencesController::onCommunityUsernameChanged() { UBSettings* settings = UBSettings::settings(); - // ??? settings->setCommunityUsername(mPreferencesUI->Username_textBox->text()); + settings->setCommunityUsername(mPreferencesUI->Username_textBox->text()); } void UBPreferencesController::onCommunityPasswordChanged() { UBSettings* settings = UBSettings::settings(); - // ??? settings->setCommunityPassword(mPreferencesUI->Password_textEdit->text()); + settings->setCommunityPassword(mPreferencesUI->Password_textEdit->text()); } void UBPreferencesController::close() From 2491e7e33d3ab52db34ce9917ac96c179ec676ad Mon Sep 17 00:00:00 2001 From: Anatoly Mihalchenko Date: Tue, 5 Jul 2011 16:49:46 +0300 Subject: [PATCH 07/13] Graphics Triangle Tool --- src/tools/UBGraphicsTriangle.cpp | 463 +++++++++++++++++++++++-------- src/tools/UBGraphicsTriangle.h | 17 +- 2 files changed, 363 insertions(+), 117 deletions(-) diff --git a/src/tools/UBGraphicsTriangle.cpp b/src/tools/UBGraphicsTriangle.cpp index 3be1140b..7c9e4605 100644 --- a/src/tools/UBGraphicsTriangle.cpp +++ b/src/tools/UBGraphicsTriangle.cpp @@ -40,9 +40,35 @@ UBGraphicsTriangle::UBGraphicsTriangle() mRotateSvgItem->setVisible(false); mRotateSvgItem->setData(UBGraphicsItemData::ItemLayerType, QVariant(UBItemLayerType::Control)); - //updateResizeCursor(); + updateResizeCursor(); } + +void UBGraphicsTriangle::updateResizeCursor() +{ + QPixmap pix(":/images/cursors/resize.png"); + QTransform itemTransform = sceneTransform(); + QRectF itemRect = boundingRect(); + + QPointF topLeft = itemTransform.map(itemRect.topLeft()); + QPointF topRight = itemTransform.map(itemRect.topRight()); + QPointF bottomLeft = itemTransform.map(itemRect.bottomLeft()); + + QLineF topLine(topLeft, topRight); + QLineF leftLine(topLeft, bottomLeft); + + qreal angle = topLine.angle(); + QTransform tr1; + tr1.rotate(- angle); + mResizeCursor1 = QCursor(pix.transformed(tr1, Qt::SmoothTransformation), pix.width() / 2, pix.height() / 2); + + angle = leftLine.angle(); + QTransform tr2; + tr2.rotate(- angle); + mResizeCursor2 = QCursor(pix.transformed(tr2, Qt::SmoothTransformation), pix.width() / 2, pix.height() / 2); +} + + UBGraphicsTriangle::~UBGraphicsTriangle() { } @@ -65,7 +91,7 @@ UBItem* UBGraphicsTriangle::deepCopy(void) const void UBGraphicsTriangle::setRect(qreal x, qreal y, qreal w, qreal h, UBGraphicsTriangleOrientation orientation) { QPolygonF polygon; - polygon << QPointF(x, y) << QPoint(x, y + h) << QPoint(x+w, y + h) << QPoint(x, y); + polygon << QPointF(x, y) << QPoint(x, y + h) << QPoint(x+w, y + h); setPolygon(polygon); setOrientation(orientation); @@ -73,30 +99,12 @@ void UBGraphicsTriangle::setRect(qreal x, qreal y, qreal w, qreal h, UBGraphicsT void UBGraphicsTriangle::setOrientation(UBGraphicsTriangleOrientation orientation) { - if (mOrientation != orientation) - { - mOrientation = orientation; - QTransform t; - switch(orientation) - { - case BottomLeft: - t.setMatrix(1, 0, 0, 0, 1, 0, 0, 0, 1); - break; - case BottomRight: - t.setMatrix(-1, 0, 0, 0, 1, 0, boundingRect().right(), 0, 1); - break; - case TopLeft: - t.setMatrix(1, 0, 0, 0, -1, 0, 0, boundingRect().bottom(), 1); - break; - case TopRight: - t.setMatrix(-1, 0, 0, 0, -1, 0, boundingRect().right(), boundingRect().bottom(), 1); - break; - } - - this->angle = -this->angle; - rotateAroundCenter(t, rotationCenter()); - setTransform(t); - } + mOrientation = orientation; + calculatePoints(boundingRect()); + + QPolygonF polygon; + polygon << A1 << B1 << C1; + setPolygon(polygon); } UBGraphicsScene* UBGraphicsTriangle::scene() const @@ -104,25 +112,81 @@ UBGraphicsScene* UBGraphicsTriangle::scene() const return static_cast(QGraphicsPolygonItem::scene()); } -void UBGraphicsTriangle::paint(QPainter *painter, const QStyleOptionGraphicsItem *, QWidget *) +void UBGraphicsTriangle::calculatePoints(const QRectF& r) { - QPointF A1(rect().x(), rect().y()); - QPointF B1(rect().x(), rect().y() + rect().height()); - QPointF C1(rect().x() + rect().width(), rect().y() + rect().height()); + switch(mOrientation) + { + case BottomLeft: + A1.setX(r.left()); A1.setY(r.top()); + B1.setX(r.left()); B1.setY(r.bottom()); + C1.setX(r.right()); C1.setY(r.bottom()); + break; + case TopLeft: + A1.setX(r.left()); A1.setY(r.bottom()); + B1.setX(r.left()); B1.setY(r.top()); + C1.setX(r.right()); C1.setY(r.top()); + break; + case TopRight: + A1.setX(r.right()); A1.setY(r.bottom()); + B1.setX(r.right()); B1.setY(r.top()); + C1.setX(r.left()); C1.setY(r.top()); + break; + case BottomRight: + A1.setX(r.right()); A1.setY(r.top()); + B1.setX(r.right()); B1.setY(r.bottom()); + C1.setX(r.left()); C1.setY(r.bottom()); + break; + } - qreal C = sqrt(rect().width() * rect().width() + rect().height() * rect().height()); + C = sqrt(rect().width() * rect().width() + rect().height() * rect().height()); qreal L = (C * d + rect().width() * d)/ rect().height(); qreal K = (C * d + rect().height() * d)/ rect().width(); - qreal W1 = rect().height() * d / C; - qreal H1 = rect().width() * d / C; + switch(mOrientation) + { + case BottomLeft: + A2.setX(r.left() + d); A2.setY(r.top() + K); + B2.setX(r.left() + d); B2.setY(r.bottom() - d); + C2.setX(r.right() - L); C2.setY(r.bottom() - d); + break; + case TopLeft: + A2.setX(r.left() + d); A2.setY(r.bottom() - K); + B2.setX(r.left() + d); B2.setY(r.top() + d); + C2.setX(r.right() - L); C2.setY(r.top() + d); + break; + case TopRight: + A2.setX(r.right() - d); A2.setY(r.bottom() - K); + B2.setX(r.right() - d); B2.setY(r.top() + d); + C2.setX(r.left() + L); C2.setY(r.top() + d); + break; + case BottomRight: + A2.setX(r.right() - d); A2.setY(r.top() + K); + B2.setX(r.right() - d); B2.setY(r.bottom() - d); + C2.setX(r.left() + L); C2.setY(r.bottom() - d); + break; + } + W1 = rect().height() * d / C; + H1 = rect().width() * d / C; - QPointF A2(rect().x() + d, rect().y() + K); - QPointF B2(rect().x() + d, rect().y() + rect().height() - d); - QPointF C2(rect().x() + rect().width() - L, rect().y() + rect().height() - d); + switch(mOrientation) + { + case BottomLeft: + CC.setX(r.right() - L + W1); CC.setY(r.bottom() - d - H1); + break; + case TopLeft: + CC.setX(r.right() - L + W1); CC.setY(r.top() + d + H1); + break; + case TopRight: + CC.setX(r.left() + L - W1); CC.setY(r.top() + d + H1); + break; + case BottomRight: + CC.setX(r.left() + L - W1); CC.setY(r.top() - d - H1); + break; + } +} - QPoint CC(rect().x() + rect().width() - L + W1, - rect().y() + rect().height() - d - H1); +void UBGraphicsTriangle::paint(QPainter *painter, const QStyleOptionGraphicsItem *, QWidget *) +{ painter->setPen(Qt::NoPen); @@ -197,41 +261,76 @@ void UBGraphicsTriangle::paintGraduations(QPainter *painter) const int millimetersPerCentimeter = 10; const int millimetersPerHalfCentimeter = 5; + qreal kx = (mOrientation == TopLeft || mOrientation == BottomLeft) ? 1 : -1; + qreal ky = (mOrientation == BottomLeft || mOrientation == BottomRight) ? 1 : -1; + painter->save(); painter->setFont(font()); QFontMetricsF fontMetrics(painter->font()); for (int millimeters = 0; millimeters < (rect().width() - sLeftEdgeMargin - sRoundingRadius) / sPixelsPerMillimeter; millimeters++) { - int graduationX = rotationCenter().x() + sPixelsPerMillimeter * millimeters; + int graduationX = rotationCenter().x() + kx * sPixelsPerMillimeter * millimeters; int graduationHeight = (0 == millimeters % millimetersPerCentimeter) ? centimeterGraduationHeight : ((0 == millimeters % millimetersPerHalfCentimeter) ? halfCentimeterGraduationHeight : millimeterGraduationHeight); // Check that grad. line inside triangle - qreal lineY = rect().bottom() - rect().height()/rect().width()*(rect().width() - graduationX); - if (lineY >= rotationCenter().y() - graduationHeight) - break; + qreal dx = (kx > 0) ? rect().width() - graduationX : graduationX - rect().x(); + qreal lineY = rotationCenter().y() - ky * rect().height()/rect().width() * dx; + if (mOrientation == BottomLeft || mOrientation == BottomRight) + { + if (lineY >= rotationCenter().y() - ky * graduationHeight) + break; + } + else + { + if (lineY <= rotationCenter().y() - ky * graduationHeight) + break; + } - painter->drawLine(QLine(graduationX, rotationCenter().y(), graduationX, rotationCenter().y() - graduationHeight)); + painter->drawLine(QLine(graduationX, rotationCenter().y(), graduationX, rotationCenter().y() - ky * graduationHeight)); if (0 == millimeters % millimetersPerCentimeter) { QString text = QString("%1").arg((int)(millimeters / millimetersPerCentimeter)); int textXRight = graduationX + fontMetrics.width(text) / 2; qreal textWidth = fontMetrics.width(text); qreal textHeight = fontMetrics.tightBoundingRect(text).height() + 5; - int textY = rect().bottom() - 5 - centimeterGraduationHeight - textHeight; - lineY = rect().bottom() - rect().height()/rect().width()*(rect().width() - textXRight); + int textY = (ky > 0) ? rotationCenter().y() - 5 - centimeterGraduationHeight - textHeight + : rotationCenter().y() + 5 + centimeterGraduationHeight; - if (textXRight < rect().right() - && lineY < textY) + bool bText = false; + switch(mOrientation) { + case BottomLeft: + dx = rect().width() - textXRight; + lineY = rotationCenter().y() - rect().height()/rect().width() * dx; + bText = lineY <= textY; + break; + case TopLeft: + dx = rect().width() - textXRight; + lineY = rotationCenter().y() + rect().height()/rect().width() * dx; + bText = lineY >= textY + textHeight; + break; + case TopRight: + dx = textXRight - textWidth - rect().left(); + lineY = rotationCenter().y() + rect().height()/rect().width() * dx; + bText = lineY >= textY + textHeight; + break; + case BottomRight: + dx = textXRight - textWidth - rect().left(); + lineY = rotationCenter().y() - rect().height()/rect().width() * dx; + bText = lineY <= textY; + break; + } + + if (bText) painter->drawText( QRectF(graduationX - textWidth / 2, - textY, textWidth, textHeight), + textY, textWidth, textHeight), Qt::AlignVCenter, text); - } + } } painter->restore(); @@ -258,82 +357,192 @@ void UBGraphicsTriangle::rotateAroundCenter(QTransform& transform, QPointF cente QPointF UBGraphicsTriangle::rotationCenter() const { - return QPointF(rect().x() + sLeftEdgeMargin , rect().bottom()); + switch(mOrientation) + { + case BottomLeft: + case TopLeft: + return B1 + QPointF(sLeftEdgeMargin, 0); + case TopRight: + case BottomRight: + return B1 - QPointF(sLeftEdgeMargin, 0); + } + return QPointF(0, 0); } QRectF UBGraphicsTriangle::closeButtonRect() const { - return QRectF(rect().x() + d - mCloseSvgItem->boundingRect().width() - 5, - rect().bottom() - d - mCloseSvgItem->boundingRect().height() - 5, - mCloseSvgItem->boundingRect().width(), - mCloseSvgItem->boundingRect().height()); + switch(mOrientation) + { + case BottomLeft: + return QRectF(B2.x() - mCloseSvgItem->boundingRect().width() - 5, + B2.y() - mCloseSvgItem->boundingRect().height() - 5, + mCloseSvgItem->boundingRect().width(), + mCloseSvgItem->boundingRect().height()); + case TopLeft: + return QRectF(B2.x() - mCloseSvgItem->boundingRect().width() - 5, + B2.y() + 5, + mCloseSvgItem->boundingRect().width(), + mCloseSvgItem->boundingRect().height()); + case TopRight: + return QRectF(B2.x() + 5, + B2.y() + 5, + mCloseSvgItem->boundingRect().width(), + mCloseSvgItem->boundingRect().height()); + case BottomRight: + return QRectF(B2.x() + 5, + B2.y() - mCloseSvgItem->boundingRect().height() - 5, + mCloseSvgItem->boundingRect().width(), + mCloseSvgItem->boundingRect().height()); + } + return QRectF(0,0,0,0); } QPolygonF UBGraphicsTriangle::resize1Polygon() const { - qreal C = sqrt(rect().width() * rect().width() + rect().height() * rect().height()); - + qreal x1, y1; + switch(mOrientation) + { + case BottomLeft: + x1 = -1; + y1 = -1; + break; + case TopLeft: + x1 = -1; + y1 = 1; + break; + case TopRight: + x1 = 1; + y1 = 1; + break; + case BottomRight: + x1 = 1; + y1 = -1; + break; + } + QPointF P1(C1.x() + x1 * sArrowLength, C1.y()); + QPointF P2(C1.x() + x1 * sArrowLength * rect().width()/C, C1.y() + y1 * sArrowLength * rect().height() / C); QPolygonF p; - - QPointF P1(rect().right() - sArrowLength, rect().bottom()); - QPointF P2(rect().right() - sArrowLength * rect().width() / C, - rect().bottom() - sArrowLength * rect().height() / C ); - - p << QPointF(rect().right(), rect().bottom()) << P1 << P2; - + p << C1 << P1 << P2; return p; } QPolygonF UBGraphicsTriangle::resize2Polygon() const { - qreal C = sqrt(rect().width() * rect().width() + rect().height() * rect().height()); - + qreal x1, y1; + switch(mOrientation) + { + case BottomLeft: + x1 = 1; + y1 = 1; + break; + case TopLeft: + x1 = 1; + y1 = -1; + break; + case TopRight: + x1 = -1; + y1 = -1; + break; + case BottomRight: + x1 = -1; + y1 = 1; + break; + } + QPointF P1(A1.x(), A1.y() + y1 * sArrowLength); + QPointF P2(A1.x() + x1 * sArrowLength * rect().width()/C, + A1.y() + y1 * sArrowLength * rect().height() / C); QPolygonF p; - - QPointF P1(rect().left(), rect().top() + sArrowLength); - QPointF P2(rect().left() + sArrowLength * rect().width() / C, - rect().top() + sArrowLength * rect().height() / C ); - - p << QPointF(rect().left(), rect().top()) << P1 << P2; - + p << A1 << P1 << P2; return p; } QRectF UBGraphicsTriangle::hFlipRect() const { - return QRectF(rect().x() + d - mHFlipSvgItem->boundingRect().width() - 5, - rect().bottom() - d - mCloseSvgItem->boundingRect().height() - mVFlipSvgItem->boundingRect().height() - - mVFlipSvgItem->boundingRect().height() - 15, - mHFlipSvgItem->boundingRect().width(), - mHFlipSvgItem->boundingRect().height()); + qreal dy = mVFlipSvgItem->boundingRect().height() + mCloseSvgItem->boundingRect().height() + 10; + switch(mOrientation) + { + case BottomLeft: + return QRectF(B2.x() - mHFlipSvgItem->boundingRect().width() - 5, + B2.y() - mHFlipSvgItem->boundingRect().height() - 5 - dy, + mHFlipSvgItem->boundingRect().width(), + mHFlipSvgItem->boundingRect().height()); + case TopLeft: + return QRectF(B2.x() - mHFlipSvgItem->boundingRect().width() - 5, + B2.y() + 5 + dy, + mHFlipSvgItem->boundingRect().width(), + mHFlipSvgItem->boundingRect().height()); + case TopRight: + return QRectF(B2.x() + 5, + B2.y() + 5 + dy, + mHFlipSvgItem->boundingRect().width(), + mHFlipSvgItem->boundingRect().height()); + case BottomRight: + return QRectF(B2.x() + 5, + B2.y() - mHFlipSvgItem->boundingRect().height() - 5 - dy, + mHFlipSvgItem->boundingRect().width(), + mHFlipSvgItem->boundingRect().height()); + } + return QRectF(0,0,0,0); } QRectF UBGraphicsTriangle::vFlipRect() const { - return QRectF(rect().x() + d - mVFlipSvgItem->boundingRect().width() - 5, - rect().bottom() - d - mCloseSvgItem->boundingRect().height() - mVFlipSvgItem->boundingRect().height() - 10, - mVFlipSvgItem->boundingRect().width(), - mVFlipSvgItem->boundingRect().height()); + qreal dy = mCloseSvgItem->boundingRect().height() + 5; + switch(mOrientation) + { + case BottomLeft: + return QRectF(B2.x() - mVFlipSvgItem->boundingRect().width() - 5, + B2.y() - mVFlipSvgItem->boundingRect().height() - 5 - dy, + mVFlipSvgItem->boundingRect().width(), + mVFlipSvgItem->boundingRect().height()); + case TopLeft: + return QRectF(B2.x() - mVFlipSvgItem->boundingRect().width() - 5, + B2.y() + 5 + dy, + mVFlipSvgItem->boundingRect().width(), + mVFlipSvgItem->boundingRect().height()); + case TopRight: + return QRectF(B2.x() + 5, + B2.y() + 5 + dy, + mVFlipSvgItem->boundingRect().width(), + mVFlipSvgItem->boundingRect().height()); + case BottomRight: + return QRectF(B2.x() + 5, + B2.y() - mVFlipSvgItem->boundingRect().height() - 5 - dy, + mVFlipSvgItem->boundingRect().width(), + mVFlipSvgItem->boundingRect().height()); + } + return QRectF(0,0,0,0); } QRectF UBGraphicsTriangle::rotateRect() const { - QPointF A1(rect().x(), rect().y()); - QPointF B1(rect().x(), rect().y() + rect().height()); - QPointF C1(rect().x() + rect().width(), rect().y() + rect().height()); - - qreal C = sqrt(rect().width() * rect().width() + rect().height() * rect().height()); - qreal L = (C * d + rect().width() * d)/ rect().height(); - - QPointF C2(rect().x() + rect().width() - L, rect().y() + rect().height() - d); - - return QRectF(C2 + QPointF(20, 5), QSizeF(mRotateSvgItem->boundingRect().size())); + QPointF p(C2); + switch(mOrientation) + { + case BottomLeft: + p += QPointF(20, 5); + break; + case TopLeft: + p += QPointF(20, -5 - mRotateSvgItem->boundingRect().height()); + break; + case TopRight: + p += QPointF(-20 - mRotateSvgItem->boundingRect().width(), -5 - mRotateSvgItem->boundingRect().height()); + break; + case BottomRight: + p += QPointF(-20 - mRotateSvgItem->boundingRect().width(), 5); + break; + } + return QRectF(p, QSizeF(mRotateSvgItem->boundingRect().size())); +} +QCursor UBGraphicsTriangle::resizeCursor1() const +{ + return mResizeCursor1; } -QCursor UBGraphicsTriangle::moveResizeCursor() const +QCursor UBGraphicsTriangle::resizeCursor2() const { - return Qt::OpenHandCursor; + return mResizeCursor2; } QCursor UBGraphicsTriangle::flipCursor() const @@ -382,8 +591,16 @@ void UBGraphicsTriangle::mouseMoveEvent(QGraphicsSceneMouseEvent *event) if (mResizing1) { QPointF delta = event->pos() - event->lastPos(); - if (rect().width() + delta.x() < sMinWidth) - delta.setX(sMinWidth - rect().width()); + if (mOrientation == TopLeft || mOrientation == BottomLeft) + { + if (rect().width() + delta.x() < sMinWidth) + delta.setX(sMinWidth - rect().width()); + } + else + { + if (rect().width() - delta.x() < sMinWidth) + delta.setX(sMinWidth - rect().width()); + } if (mOrientation == TopLeft || mOrientation == BottomLeft) { setRect(QRectF( @@ -395,9 +612,9 @@ void UBGraphicsTriangle::mouseMoveEvent(QGraphicsSceneMouseEvent *event) else { setRect(QRectF( - rect().left() - delta.x(), + rect().left() + delta.x(), rect().top(), - rect().width() + delta.x(), + rect().width() - delta.x(), rect().height()), mOrientation ); @@ -406,18 +623,30 @@ void UBGraphicsTriangle::mouseMoveEvent(QGraphicsSceneMouseEvent *event) if (mResizing2) { QPointF delta = event->pos() - event->lastPos(); - if (rect().height() - delta.y() < sMinHeight) - delta.setY(sMinHeight - rect().height()); - qDebug() << event->pos() << event->lastPos() << delta; - QRectF r( - rect().left(), - rect().top() + delta.y(), - rect().width(), - rect().height() - delta.y()); - qDebug() << r; - setRect(r, mOrientation); - - + if (mOrientation == BottomRight || mOrientation == BottomLeft) + { + if (rect().height() - delta.y() < sMinHeight) + delta.setY(sMinHeight - rect().height()); + } + else + { + if (rect().height() + delta.y() < sMinHeight) + delta.setY(sMinHeight - rect().height()); + } + if (mOrientation == BottomRight || mOrientation == BottomLeft) + setRect(QRectF( + rect().left(), + rect().top() + delta.y(), + rect().width(), + rect().height() - delta.y()), + mOrientation); + else + setRect(QRectF( + rect().left(), + rect().top(), + rect().width(), + rect().height() + delta.y()), + mOrientation); } if (mRotating) { @@ -434,6 +663,8 @@ void UBGraphicsTriangle::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { if (mResizing1 || mResizing2 || mRotating) { + if (mRotating) + updateResizeCursor(); mResizing1 = false; mResizing2 = false; mRotating = false; @@ -505,9 +736,10 @@ void UBGraphicsTriangle::hoverEnterEvent(QGraphicsSceneHoverEvent *event) mVFlipSvgItem->setVisible(true); mRotateSvgItem->setVisible(true); - if (resize1Polygon().containsPoint(event->pos().toPoint(), Qt::OddEvenFill) || - resize2Polygon().containsPoint(event->pos().toPoint(), Qt::OddEvenFill)) - setCursor(moveResizeCursor()); + if (resize1Polygon().containsPoint(event->pos().toPoint(), Qt::OddEvenFill)) + setCursor(resizeCursor1()); + else if(resize2Polygon().containsPoint(event->pos().toPoint(), Qt::OddEvenFill)) + setCursor(resizeCursor2()); else if (closeButtonRect().contains(event->pos())) setCursor(closeCursor()); else if (hFlipRect().contains(event->pos()) @@ -546,9 +778,10 @@ void UBGraphicsTriangle::hoverMoveEvent(QGraphicsSceneHoverEvent *event) mHFlipSvgItem->setVisible(mShowButtons); mRotateSvgItem->setVisible(mShowButtons); - if (resize1Polygon().containsPoint(event->pos().toPoint(), Qt::OddEvenFill) || - resize2Polygon().containsPoint(event->pos().toPoint(), Qt::OddEvenFill)) - setCursor(moveResizeCursor()); + if (resize1Polygon().containsPoint(event->pos().toPoint(), Qt::OddEvenFill)) + setCursor(resizeCursor1()); + else if (resize2Polygon().containsPoint(event->pos().toPoint(), Qt::OddEvenFill)) + setCursor(resizeCursor2()); else if (closeButtonRect().contains(event->pos())) setCursor(closeCursor()); else if (hFlipRect().contains(event->pos()) diff --git a/src/tools/UBGraphicsTriangle.h b/src/tools/UBGraphicsTriangle.h index 756a1fc6..1ff52999 100644 --- a/src/tools/UBGraphicsTriangle.h +++ b/src/tools/UBGraphicsTriangle.h @@ -67,6 +67,8 @@ class UBGraphicsTriangle : public UBAbstractDrawRuler, public QGraphicsPolygonIt protected: + void updateResizeCursor(); + virtual void paint (QPainter *painter, const QStyleOptionGraphicsItem *styleOption, QWidget *widget); virtual void rotateAroundCenter(qreal angle); @@ -80,7 +82,9 @@ class UBGraphicsTriangle : public UBAbstractDrawRuler, public QGraphicsPolygonIt QRectF vFlipRect() const; QRectF rotateRect() const; - QCursor moveResizeCursor() const; + QCursor resizeCursor1() const; + QCursor resizeCursor2() const; + QCursor flipCursor() const; virtual void mousePressEvent(QGraphicsSceneMouseEvent *event); @@ -92,6 +96,9 @@ class UBGraphicsTriangle : public UBAbstractDrawRuler, public QGraphicsPolygonIt private: + QCursor mResizeCursor1; + QCursor mResizeCursor2; + QTransform calculateRotationTransform(); qreal angle; void rotateAroundCenter(QTransform& transform, QPointF center); @@ -112,9 +119,15 @@ class UBGraphicsTriangle : public UBAbstractDrawRuler, public QGraphicsPolygonIt UBGraphicsTriangleOrientation mOrientation; + QPointF A1, B1, C1, A2, B2, C2; // coordinates of points in ext and int triangles + qreal C; + qreal W1, H1; // Neccessary for filling + QPointF CC; // Hyp. fillining gradient - top point + void calculatePoints(const QRectF& rect); + static const int d = 70; // width of triangle border static const int sArrowLength = 30; - static const int sMinWidth = 200; + static const int sMinWidth = 380; static const int sMinHeight = 200; }; From 497288d4d719419e28f96f331e4d613aef1af688 Mon Sep 17 00:00:00 2001 From: shibakaneki Date: Wed, 6 Jul 2011 08:23:35 +0200 Subject: [PATCH 08/13] First version of the publication on the web --- .../publishing/UBDocumentPublisher.cpp | 141 ++++++++++++++---- src/adaptors/publishing/UBDocumentPublisher.h | 7 +- 2 files changed, 119 insertions(+), 29 deletions(-) diff --git a/src/adaptors/publishing/UBDocumentPublisher.cpp b/src/adaptors/publishing/UBDocumentPublisher.cpp index 00ad33d6..d3bfafe3 100644 --- a/src/adaptors/publishing/UBDocumentPublisher.cpp +++ b/src/adaptors/publishing/UBDocumentPublisher.cpp @@ -1,4 +1,6 @@ - #include "UBDocumentPublisher.h" +#include + +#include "UBDocumentPublisher.h" #include "frameworks/UBPlatformUtils.h" #include "frameworks/UBFileSystemUtils.h" @@ -44,6 +46,7 @@ UBDocumentPublisher::UBDocumentPublisher(UBDocumentProxy* pDocument, QObject *pa connect(mpWebView, SIGNAL(loadFinished(bool)), this, SLOT(onLoadFinished(bool))); connect(mpWebView, SIGNAL(linkClicked(QUrl)), this, SLOT(onLinkClicked(QUrl))); + connect(this, SIGNAL(loginDone()), this, SLOT(onLoginDone())); init(); @@ -52,7 +55,7 @@ UBDocumentPublisher::UBDocumentPublisher(UBDocumentProxy* pDocument, QObject *pa UBDocumentPublisher::~UBDocumentPublisher() { - delete mpWebView; + //delete mpWebView; delete mPublishingDocument; } @@ -66,11 +69,54 @@ void UBDocumentPublisher::publish() mPassword = settings->communityPassword(); buildUbwFile(); UBApplication::showMessage(tr("Uploading Sankore File on Web.")); + + login(mUsername, mPassword); + //sendUbw(); + +} + +void UBDocumentPublisher::onLoginDone() +{ sendUbw(); +} +void UBDocumentPublisher::login(QString username, QString password) +{ + QString data,crlf; + QByteArray datatoSend; + + // Create the request body + data="srid=&j_username=" +username +"&j_password=" +password +crlf+crlf; + datatoSend=data.toAscii(); // convert data string to byte array for request + + // Create the request header + QString qsLoginURL = QString("http://sankore.devxwiki.com/xwiki/bin/loginsubmit/XWiki/XWikiLogin?xredirect=%0").arg(DOCPUBLICATION_URL); + QNetworkRequest request(QUrl(qsLoginURL.toAscii().constData())); + request.setRawHeader("Origin", "http://sankore.devxwiki.com"); + request.setHeader(QNetworkRequest::ContentTypeHeader, "application/x-www-form-urlencoded"); + request.setRawHeader("Accept", "application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5"); + request.setRawHeader("Referer", DOCPUBLICATION_URL); + request.setHeader(QNetworkRequest::ContentLengthHeader,datatoSend.size()); + request.setRawHeader("Accept-Language", "en-US,*"); + + // Generate a session id + //mSessionID = getSessionID(); + + // Create the cookie + //QList cookiesList; + //QString qsCookieValue; + //qsCookieValue = mSessionID; + //qsCookieValue += "; language=en"; + //QNetworkCookie cookie("JSESSIONID", qsCookieValue.toAscii().constData()); + //cookiesList << cookie; + //request.setHeader(QNetworkRequest::CookieHeader, QVariant::fromValue(cookiesList)); + + // Send the request + mpNetworkMgr->post(request,datatoSend); } + void UBDocumentPublisher::buildUbwFile() { QDir d; @@ -537,18 +583,17 @@ void UBDocumentPublisher::onFinished(QNetworkReply *reply) { QByteArray response = reply->readAll(); - if (!bCookieSet) + if (!bLoginCookieSet) { QList cookiesList; QVariant cookieHeader = reply->rawHeader("Set-Cookie"); - qDebug() << cookieHeader.toString(); // First we concatenate all the Set-Cookie values (the packet can contains many of them) QStringList qslCookie = cookieHeader.toString().split("\n"); QString qsCookieValue = qslCookie.at(0); for (int i = 1; i < qslCookie.size(); i++) { qsCookieValue += "; " +qslCookie.at(i); } - qDebug() << "qsCookieValue " << qsCookieValue; + // Now we isolate every cookie value QStringList qslCookieVals = qsCookieValue.split("; "); @@ -556,31 +601,69 @@ void UBDocumentPublisher::onFinished(QNetworkReply *reply) for (int i = 0; i < qslCookieVals.size(); i++) { QString cookieString = qslCookieVals.at(i); - qDebug() << "qslCookieVals.at(i): " << cookieString.replace("\"", ""); + //qDebug() << "qslCookieVals.at(i): " << cookieString.replace("\"", ""); QStringList qslCrntCookie = cookieString.split("="); QNetworkCookie crntCookie; if (qslCrntCookie.length() == 2) - crntCookie = QNetworkCookie(qslCrntCookie.at(0).toAscii().constData(), qslCrntCookie.at(1).toAscii().constData()); + { + QString qsValue = qslCrntCookie.at(1); + qsValue.remove("\""); + crntCookie = QNetworkCookie(qslCrntCookie.at(0).toAscii().constData(), qsValue.toAscii().constData()); + } else + { crntCookie = QNetworkCookie(qslCrntCookie.at(0).toAscii().constData()); - cookiesList << crntCookie; + } + // HACK : keep only the same cookies as the XWiki website does. + if(crntCookie.name() == "JSESSIONID" || + crntCookie.name() == "username" || + crntCookie.name() == "password" || + crntCookie.name() == "rememberme" || + crntCookie.name() == "validation") + { + cookiesList << crntCookie; + } + } + QNetworkCookie langCookie("language", "en"); + cookiesList << langCookie; + // DEBUG : Verify + for(int i = 0; i < cookiesList.size(); i++) + { + qDebug() << cookiesList.at(i).name() << "=" << cookiesList.at(i).value(); } // Set the cookiejar : it set the cookies that will be sent with every packet. - qDebug() << reply->url().toString(); - mpCookieJar->setCookiesFromUrl(cookiesList, reply->url()); - mpNetworkMgr->setCookieJar(mpCookieJar); - bCookieSet = true; - } + mpCookieJar->setCookiesFromUrl(cookiesList, QUrl(DOCPUBLICATION_URL)/*reply->url()*/); - if (response.isEmpty()){ + mpNetworkMgr->setCookieJar(mpCookieJar); + bLoginCookieSet = true; emit loginDone(); } - else{ - // Display the iframe - mpWebView->setHtml(response, QUrl("http://sankore.devxwiki.com/xwiki/bin/view/Test/FileUpload")); - UBApplication::applicationController->showSankoreWebDocument(); + else + { + if (!response.isEmpty()){ + // Display the iframe + mpWebView->setHtml(response, QUrl(DOCPUBLICATION_URL)); + UBApplication::applicationController->showSankoreWebDocument(); + + } + else + { + // Redirect + QVariant locationHeader = reply->rawHeader("Location"); + + + qDebug() << "---------------------------"; + QList clist = mpCookieJar->cookiesForUrl(QUrl(locationHeader.toString())); + for(int i = 0; i < clist.size(); i++) + { + qDebug() << clist.at(i).name() << "=" << clist.at(i).value(); + } + + QNetworkRequest req(QUrl(locationHeader.toString())); + mpNetworkMgr->get(req); + } } } @@ -591,6 +674,7 @@ void UBDocumentPublisher::sendUbw() QFile f(mTmpZipFile); if (f.open(QIODevice::ReadOnly)) { + QFileInfo fi(f); QByteArray ba = f.readAll(); QString boundary,data, multipartHeader; QByteArray datatoSend; @@ -599,23 +683,24 @@ void UBDocumentPublisher::sendUbw() multipartHeader = "multipart/form-data; boundary="+boundary; data="--"+boundary+mCrlf; - data+="Content-Disposition: form-data; name=\"file\"; filename=\""+ f.fileName() +"\""+mCrlf; + data+="Content-Disposition: form-data; name=\"file\"; filename=\""+ fi.fileName() +"\""+mCrlf; data+="Content-Type: application/octet-stream"+mCrlf+mCrlf; datatoSend=data.toAscii(); // convert data string to byte array for request datatoSend += ba; - datatoSend += mCrlf.toAscii(); - datatoSend += QString("--%0--%1").arg(boundary).arg(mCrlf).toAscii(); - - QNetworkRequest request(QUrl("http://sankore.devxwiki.com/xwiki/bin/view/Test/FileUpload")); + datatoSend += mCrlf; + datatoSend += QString("--%0--%1").arg(boundary).arg(mCrlf); + //datatoSend += QString("%0").arg("Content-Disposition: form-data; name=\"submit\""); + //datatoSend += "Submit Query"; + //datatoSend += mCrlf; + //datatoSend += QString("--%0--%1").arg(boundary).arg(mCrlf); + + // ?xpage=plain&outputSyntax=plain + QNetworkRequest request(QUrl(DOCPUBLICATION_URL)); request.setHeader(QNetworkRequest::ContentTypeHeader, multipartHeader); request.setHeader(QNetworkRequest::ContentLengthHeader,datatoSend.size()); request.setRawHeader("Accept", "application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5"); request.setRawHeader("Accept-Language", "en-US,*"); - request.setRawHeader("Referer", "http://sankore.devxwiki.com/xwiki/bin/view/Test/FileUpload"); - request.setRawHeader("Origin", "http://sankore.devxwiki.com"); - - QString b64Auth = getBase64Of(QString("%0:%1").arg(mUsername).arg(mPassword)); - request.setRawHeader("Authorization", QString("Basic %0").arg(b64Auth).toAscii().constData()); + request.setRawHeader("Referer", DOCPUBLICATION_URL); // Send the file mpNetworkMgr->post(request,datatoSend); diff --git a/src/adaptors/publishing/UBDocumentPublisher.h b/src/adaptors/publishing/UBDocumentPublisher.h index 6c6cde80..0c4bcd6b 100644 --- a/src/adaptors/publishing/UBDocumentPublisher.h +++ b/src/adaptors/publishing/UBDocumentPublisher.h @@ -7,6 +7,9 @@ #include "ui_webPublishing.h" #include "UBAbstractPublisher.h" +#define DOCPUBLICATION_URL "http://sankore.devxwiki.com/xwiki/bin/view/CreateResources/UniboardUpload" +#define XWIKI_ORIGIN_HEADER "http://sankore.devxwiki.com" + class UBDocumentProxy; class UBServerXMLHttpRequest; class UBGraphicsW3CWidgetItem; @@ -38,6 +41,7 @@ private slots: void onFinished(QNetworkReply* reply); void onLinkClicked(const QUrl& url); void onLoadFinished(bool result); + void onLoginDone(); private: @@ -55,9 +59,10 @@ private: QString mUsername; QString mPassword; QString mCrlf; - bool bCookieSet; + bool bLoginCookieSet; void buildUbwFile(); + void login(QString username, QString password); QString mTmpZipFile; }; From 5c6effbab9ed2214bcc217e295c96ebe0cf7ebd0 Mon Sep 17 00:00:00 2001 From: shibakaneki Date: Wed, 6 Jul 2011 08:57:37 +0200 Subject: [PATCH 09/13] Updated version number --- Sankore_3.1.pro | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/Sankore_3.1.pro b/Sankore_3.1.pro index ef05e726..6fb035ce 100644 --- a/Sankore_3.1.pro +++ b/Sankore_3.1.pro @@ -7,8 +7,8 @@ CONFIG += debug_and_release \ no_include_pwd VERSION_MAJ = 1 -VERSION_MIN = 00 -VERSION_TYPE = r # a = alpha, b = beta, r = release, other => error +VERSION_MIN = 10 +VERSION_TYPE = b # a = alpha, b = beta, r = release, other => error VERSION_PATCH = 00 VERSION = "$${VERSION_MAJ}.$${VERSION_MIN}.$${VERSION_TYPE}.$${VERSION_PATCH}" @@ -269,6 +269,12 @@ macx { TRANSLATION_ro.path = "$$RESOURCES_DIR/ro.lproj" QMAKE_BUNDLE_DATA += TRANSLATION_ro } + exists(resources/i18n/sankore_ar.qm) { + TRANSLATION_ar.files = resources/i18n/sankore_ar.qm \ + resources/i18n/Localizable.strings + TRANSLATION_ar.path = "$$RESOURCES_DIR/ar.lproj" + QMAKE_BUNDLE_DATA += TRANSLATION_ar + } QMAKE_BUNDLE_DATA += UB_ETC \ UB_LIBRARY \ @@ -338,7 +344,8 @@ TRANSLATIONS = resources/i18n/sankore_en.ts \ resources/i18n/sankore_ja.ts \ resources/i18n/sankore_ko.ts \ resources/i18n/sankore_zh.ts \ - resources/i18n/sankore_ro.ts + resources/i18n/sankore_ro.ts \ + resources/i18n/sankore_ar.ts INSTALLS = UB_ETC \ UB_I18N \ From f9da65c04482a12b6e3c12cdd89572813cf860ae Mon Sep 17 00:00:00 2001 From: Claudio Valerio Date: Wed, 6 Jul 2011 09:45:14 +0200 Subject: [PATCH 10/13] added windows setup script --- Sankore 3.1.iss | 88 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 88 insertions(+) create mode 100644 Sankore 3.1.iss diff --git a/Sankore 3.1.iss b/Sankore 3.1.iss new file mode 100644 index 00000000..1e968088 --- /dev/null +++ b/Sankore 3.1.iss @@ -0,0 +1,88 @@ +; Script generated by the Inno Setup Script Wizard. +; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES! + +[Setup] +; NOTE: The value of AppId uniquely identifies this application. +; Do not use the same AppId value in installers for other applications. +; (To generate a new GUID, click Tools | Generate GUID inside the IDE.) +AppId={{E63D17F8-D9DA-479D-B9B5-0D101A03703B} +AppName=Sankore 3.1 +AppVerName=Sankore 3.1 +AppPublisher=Mnemis + +AppPublisherURL=http://www.getuniboard.com +AppSupportURL=http://support.getuniboard.com +AppUpdatesURL=http://www.getuniboard.com + +DefaultDirName={pf}\Sankore 3.1 +DefaultGroupName=Sankore 3.1 + +OutputDir=.\install\win32\ +OutputBaseFilename=Sankore 3.1 setup +SetupIconFile=.\resources\win\uniboard.ico +Compression=lzma +SolidCompression=yes + +[Languages] +Name: "english"; MessagesFile: "compiler:Default.isl" + +[Tasks] +Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked +Name: "quicklaunchicon"; Description: "{cm:CreateQuickLaunchIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked + +[InstallDelete] + +Type: files ; Name: "{app}\Sankore 3.1.pdb" +Type: filesandordirs ; Name: "{app}\library" +Type: filesandordirs ; Name: "{app}\Microsoft.VC90.CRT" +Type: filesandordirs ; Name: "{app}\plugins" +Type: filesandordirs ; Name: "{app}\i18n" +Type: files ; Name: "{app}\*.dll" + +[Files] +Source: ".\build\win32\release\product\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs createallsubdirs +Source: ".\runtime\windows\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs createallsubdirs; +Source: ".\resources\win\plugins\*"; DestDir: "{app}"; Flags: recursesubdirs createallsubdirs +; NOTE: Don't use "Flags: ignoreversion" on any shared system files + +[Icons] +Name: "{group}\Sankore 3.1"; Filename: "{app}\Sankore 3.1.exe" +;Name: "{group}\{cm:ProgramOnTheWeb,Sankore 3.1}"; Filename: "http://www.getuniboard.com/" +Name: "{group}\{cm:UninstallProgram,Sankore 3.1}"; Filename: "{uninstallexe}" +Name: "{commondesktop}\Sankore 3.1"; Filename: "{app}\Sankore 3.1.exe"; Tasks: desktopicon +Name: "{userappdata}\Microsoft\Internet Explorer\Quick Launch\Sankore 3.1"; Filename: "{app}\Sankore 3.1.exe"; Tasks: quicklaunchicon +Name: "{group}\Printing Preferences"; Filename: "{app}\properties.exe"; WorkingDir: {app} + +[Registry] +Root: HKCR; Subkey: ".ubz"; ValueType: string; ValueName: ""; ValueData: "SankoreFile"; Flags: uninsdeletevalue +Root: HKCR; Subkey: "SankoreFile"; ValueType: string; ValueName: ""; ValueData: "Sankore 3.1 document"; Flags: uninsdeletekey +Root: HKCR; Subkey: "SankoreFile\DefaultIcon"; ValueType: string; ValueName: ""; ValueData: "{app}\Sankore 3.1.exe,1" +Root: HKCR; Subkey: "SankoreFile\shell\open\command"; ValueType: string; ValueName: ""; ValueData: """{app}\Sankore 3.1.exe"" ""%1""" + +Root: HKLM; Subkey: "SOFTWARE\Sankore 3.1"; ValueType: string; ValueName: "Client application"; ValueData: "{app}\Sankore 3.1.exe"; Flags: uninsdeletevalue; Check: isProcessorNotX64 +Root: HKLM; Subkey: "SOFTWARE\Sankore 3.1"; ValueType: dword; ValueName: "Transfer mode"; ValueData: "0"; Flags: uninsdeletevalue; Check: isProcessorNotX64 +Root: HKLM; Subkey: "SOFTWARE\Sankore 3.1"; ValueType: dword; ValueName: "EMF: Hide page"; ValueData: "1"; Flags: uninsdeletevalue; Check: isProcessorNotX64 +Root: HKLM; Subkey: "SOFTWARE\Sankore 3.1\Defaults"; ValueType: dword; ValueName: "PDF: Enabled"; ValueData: "1"; Flags: uninsdeletevalue; Check: isProcessorNotX64 + +Root: HKLM64; Subkey: "SOFTWARE\Sankore 3.1"; ValueType: string; ValueName: "Client application"; ValueData: "{app}\Sankore 3.1.exe"; Flags: uninsdeletevalue; Check: isProcessorX64 +Root: HKLM64; Subkey: "SOFTWARE\Sankore 3.1"; ValueType: dword; ValueName: "Transfer mode"; ValueData: "0"; Flags: uninsdeletevalue; Check: isProcessorX64 +Root: HKLM64; Subkey: "SOFTWARE\Sankore 3.1"; ValueType: dword; ValueName: "EMF: Hide page"; ValueData: "1"; Flags: uninsdeletevalue; Check: isProcessorX64 +Root: HKLM64; Subkey: "SOFTWARE\Sankore 3.1\Defaults"; ValueType: dword; ValueName: "PDF: Enabled"; ValueData: "1"; Flags: uninsdeletevalue; Check: isProcessorX64 + +[Run] +Filename: "{app}\Sankore 3.1.exe"; Description: "{cm:LaunchProgram,Sankore 3.1}"; Flags: nowait postinstall + +[UninstallDelete] +; cleanup and delete whole installation directory +Name: {app}; Type: filesandordirs + +[Code] +function isProcessorX64: Boolean; +begin + Result := (ProcessorArchitecture = paX64); +end; + +function isProcessorNotX64: Boolean; +begin + Result := not isProcessorX64; +end; \ No newline at end of file From 2ebd21ceb8d57d713394a346476b3bfaa7146008 Mon Sep 17 00:00:00 2001 From: shibakaneki Date: Wed, 6 Jul 2011 14:42:29 +0200 Subject: [PATCH 11/13] First working version of the Web publication --- .../publishing/UBDocumentPublisher.cpp | 39 +++++++------------ src/adaptors/publishing/UBDocumentPublisher.h | 1 + 2 files changed, 16 insertions(+), 24 deletions(-) diff --git a/src/adaptors/publishing/UBDocumentPublisher.cpp b/src/adaptors/publishing/UBDocumentPublisher.cpp index d3bfafe3..412289c0 100644 --- a/src/adaptors/publishing/UBDocumentPublisher.cpp +++ b/src/adaptors/publishing/UBDocumentPublisher.cpp @@ -56,7 +56,7 @@ UBDocumentPublisher::UBDocumentPublisher(UBDocumentProxy* pDocument, QObject *pa UBDocumentPublisher::~UBDocumentPublisher() { //delete mpWebView; - delete mPublishingDocument; + //delete mPublishingDocument; } @@ -574,6 +574,9 @@ void UBDocumentPublisher::init() mCrlf+=0x0a; mpNetworkMgr = new QNetworkAccessManager(this); + //mpCache = new QNetworkDiskCache(this); + //mpCache->setCacheDirectory("cache"); + //mpNetworkMgr->setCache(mpCache); mpCookieJar = new QNetworkCookieJar(); connect(mpNetworkMgr, SIGNAL(finished(QNetworkReply*)), this, SLOT(onFinished(QNetworkReply*))); @@ -581,11 +584,11 @@ void UBDocumentPublisher::init() void UBDocumentPublisher::onFinished(QNetworkReply *reply) { + qDebug() << "[-[ Request finished! ]-]"; QByteArray response = reply->readAll(); if (!bLoginCookieSet) { - QList cookiesList; QVariant cookieHeader = reply->rawHeader("Set-Cookie"); // First we concatenate all the Set-Cookie values (the packet can contains many of them) QStringList qslCookie = cookieHeader.toString().split("\n"); @@ -621,19 +624,19 @@ void UBDocumentPublisher::onFinished(QNetworkReply *reply) crntCookie.name() == "rememberme" || crntCookie.name() == "validation") { - cookiesList << crntCookie; + mCookies << crntCookie; } } QNetworkCookie langCookie("language", "en"); - cookiesList << langCookie; + mCookies << langCookie; // DEBUG : Verify - for(int i = 0; i < cookiesList.size(); i++) + for(int i = 0; i < mCookies.size(); i++) { - qDebug() << cookiesList.at(i).name() << "=" << cookiesList.at(i).value(); + qDebug() << mCookies.at(i).name() << "=" << mCookies.at(i).value(); } // Set the cookiejar : it set the cookies that will be sent with every packet. - mpCookieJar->setCookiesFromUrl(cookiesList, QUrl(DOCPUBLICATION_URL)/*reply->url()*/); + mpCookieJar->setCookiesFromUrl(mCookies, QUrl(DOCPUBLICATION_URL)/*reply->url()*/); mpNetworkMgr->setCookieJar(mpCookieJar); bLoginCookieSet = true; @@ -643,28 +646,20 @@ void UBDocumentPublisher::onFinished(QNetworkReply *reply) { if (!response.isEmpty()){ // Display the iframe - mpWebView->setHtml(response, QUrl(DOCPUBLICATION_URL)); + mpWebView->setHtml(response, reply->url()); UBApplication::applicationController->showSankoreWebDocument(); - } else { // Redirect QVariant locationHeader = reply->rawHeader("Location"); - - qDebug() << "---------------------------"; - QList clist = mpCookieJar->cookiesForUrl(QUrl(locationHeader.toString())); - for(int i = 0; i < clist.size(); i++) - { - qDebug() << clist.at(i).name() << "=" << clist.at(i).value(); - } - - QNetworkRequest req(QUrl(locationHeader.toString())); mpNetworkMgr->get(req); + qDebug() << mpWebView->url().toString(); } } + reply->deleteLater(); } void UBDocumentPublisher::sendUbw() @@ -689,12 +684,7 @@ void UBDocumentPublisher::sendUbw() datatoSend += ba; datatoSend += mCrlf; datatoSend += QString("--%0--%1").arg(boundary).arg(mCrlf); - //datatoSend += QString("%0").arg("Content-Disposition: form-data; name=\"submit\""); - //datatoSend += "Submit Query"; - //datatoSend += mCrlf; - //datatoSend += QString("--%0--%1").arg(boundary).arg(mCrlf); - // ?xpage=plain&outputSyntax=plain QNetworkRequest request(QUrl(DOCPUBLICATION_URL)); request.setHeader(QNetworkRequest::ContentTypeHeader, multipartHeader); request.setHeader(QNetworkRequest::ContentLengthHeader,datatoSend.size()); @@ -727,7 +717,8 @@ void UBDocumentPublisher::onLoadFinished(bool result) { Q_UNUSED(result); // [Basic Auth] This line says: if the user click on a link, do not interpret it. - mpWebView->page()->setLinkDelegationPolicy(QWebPage::DelegateAllLinks); + //mpWebView->page()->setLinkDelegationPolicy(QWebPage::DelegateAllLinks); + mpWebView->page()->setNetworkAccessManager(mpNetworkMgr); } diff --git a/src/adaptors/publishing/UBDocumentPublisher.h b/src/adaptors/publishing/UBDocumentPublisher.h index 0c4bcd6b..8b4c289c 100644 --- a/src/adaptors/publishing/UBDocumentPublisher.h +++ b/src/adaptors/publishing/UBDocumentPublisher.h @@ -64,6 +64,7 @@ private: void buildUbwFile(); void login(QString username, QString password); QString mTmpZipFile; + QList mCookies; }; #endif // UBDOCUMENTPUBLISHER_H From 21e42370fd15610e1d14c6016fbe35bfadb13b33 Mon Sep 17 00:00:00 2001 From: shibakaneki Date: Wed, 6 Jul 2011 14:43:35 +0200 Subject: [PATCH 12/13] Updated version number --- Sankore_3.1.pro | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Sankore_3.1.pro b/Sankore_3.1.pro index 6fb035ce..c6cb40b8 100644 --- a/Sankore_3.1.pro +++ b/Sankore_3.1.pro @@ -9,7 +9,7 @@ CONFIG += debug_and_release \ VERSION_MAJ = 1 VERSION_MIN = 10 VERSION_TYPE = b # a = alpha, b = beta, r = release, other => error -VERSION_PATCH = 00 +VERSION_PATCH = 01 VERSION = "$${VERSION_MAJ}.$${VERSION_MIN}.$${VERSION_TYPE}.$${VERSION_PATCH}" VERSION = $$replace(VERSION, "\\.r", "") From 705c2cc4c67e9d7add8aafb25de085ea035bfc31 Mon Sep 17 00:00:00 2001 From: Claudio Valerio Date: Wed, 6 Jul 2011 16:07:31 +0200 Subject: [PATCH 13/13] Initializing a variable --- src/adaptors/publishing/UBDocumentPublisher.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/adaptors/publishing/UBDocumentPublisher.cpp b/src/adaptors/publishing/UBDocumentPublisher.cpp index 412289c0..b9d191c1 100644 --- a/src/adaptors/publishing/UBDocumentPublisher.cpp +++ b/src/adaptors/publishing/UBDocumentPublisher.cpp @@ -38,6 +38,7 @@ UBDocumentPublisher::UBDocumentPublisher(UBDocumentProxy* pDocument, QObject *pa , mPublishingDocument(0) , mUsername("") , mPassword("") + , bLoginCookieSet(false) { mpWebView = new QWebView(0); UBApplication::mainWindow->addSankoreWebDocumentWidget(mpWebView);