Skip to content

Commit a709709

Browse files
committed
Remove trailing whitespace from lines
Shellscript suggested by @zakkak at #29
1 parent 9d29af5 commit a709709

22 files changed

Lines changed: 198 additions & 198 deletions

‎CMakeLists.txt‎

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
11
# /*
22
# dspdfviewer - Dual Screen PDF Viewer for LaTeX-Beamer
33
# Copyright (C) 2012 Danny Edel <mail@danny-edel.de>
4-
#
4+
#
55
# This program is free software; you can redistribute it and/or modify
66
# it under the terms of the GNU General Public License as published by
77
# the Free Software Foundation; either version 2 of the License, or
88
# (at your option) any later version.
9-
#
9+
#
1010
# This program is distributed in the hope that it will be useful,
1111
# but WITHOUT ANY WARRANTY; without even the implied warranty of
1212
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
1313
# GNU General Public License for more details.
14-
#
14+
#
1515
# You should have received a copy of the GNU General Public License along
1616
# with this program; if not, write to the Free Software Foundation, Inc.,
1717
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
@@ -29,7 +29,7 @@ include_directories(${Boost_INCLUDE_DIR})
2929
add_definitions(-ggdb)
3030

3131
# Use c++11 support.
32-
# found on
32+
# found on
3333
# http://stackoverflow.com/questions/10984442/how-to-detect-c11-support-of-a-compiler-with-cmake
3434
if(CMAKE_COMPILER_IS_GNUCXX)
3535
execute_process(COMMAND ${CMAKE_C_COMPILER} -dumpversion OUTPUT_VARIABLE GCC_VERSION)
@@ -40,7 +40,7 @@ if(CMAKE_COMPILER_IS_GNUCXX)
4040
message(WARNING "C++0x activated. If you get any errors update to a compiler which fully supports C++11")
4141
add_definitions("-std=c++0x")
4242
else ()
43-
message(FATAL_ERROR "C++11 needed. Therefore a gcc compiler with a version higher than 4.3 is needed.")
43+
message(FATAL_ERROR "C++11 needed. Therefore a gcc compiler with a version higher than 4.3 is needed.")
4444
endif()
4545
else()
4646
# No GCC Compiler

‎INSTALL‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ How to install the dspdfviewer
33

44
1. Debian-based distributions
55
=============================
6-
6+
77

88
1.1 Install ready-to-run binaries
99
---------------------------------

‎README.md‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ Q/Esc: Quit
2929
### Debian wheezy/sid
3030
If you are using Debian wheezy or sid, you should be able to
3131
get a binary from my repository:
32-
32+
3333
http://danny-edel.de/deb/
3434

3535
If you open the link with a web browser, there are some copy-and-paste
@@ -38,7 +38,7 @@ instructions on how to add the repository. These packages are built by myself.
3838
### Ubuntu 12.04 LTS (Precise Pangolin) or newer
3939

4040
For Ubuntu, there are two PPAs configured:
41-
A "daily" repository and a "release" repository. Use the daily builds only
41+
A "daily" repository and a "release" repository. Use the daily builds only
4242
if you want to help in development (test bugs in the latest git revision),
4343
otherwise stick to the "release" PPA:
4444

@@ -54,7 +54,7 @@ of the above:
5454
1. Daily
5555
https://launchpad.net/~dannyedel/+archive/dspdfviewer-daily-lucid
5656
2. Release
57-
https://launchpad.net/~dannyedel/+archive/dspdfviewer-lucid
57+
https://launchpad.net/~dannyedel/+archive/dspdfviewer-lucid
5858

5959
### Arch Linux
6060
In the [AUR](https://wiki.archlinux.org/index.php/Arch_User_Repository) there is

‎debian/changelog‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -113,20 +113,20 @@ dspdfviewer (1.0) testing; urgency=low
113113

114114
dspdfviewer (0.4) testing; urgency=low
115115

116-
* Changed compat to 0.7 so it can compile with ubuntu
116+
* Changed compat to 0.7 so it can compile with ubuntu
117117

118118
-- Danny Edel <mail@danny-edel.de> Wed, 14 Nov 2012 14:43:52 +0100
119119

120120
dspdfviewer (0.3) testing; urgency=low
121121

122-
* Added GitHub links in the package file
123-
* Small INSTALL and README files
122+
* Added GitHub links in the package file
123+
* Small INSTALL and README files
124124

125125
-- Danny Edel <mail@danny-edel.de> Wed, 14 Nov 2012 13:53:39 +0100
126126

127127
dspdfviewer (0.2c) testing; urgency=low
128128

129-
* Changed release to testing
129+
* Changed release to testing
130130

131131
-- Danny Edel <mail@danny-edel.de> Wed, 14 Nov 2012 12:14:26 +0100
132132

‎debian/rules‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,4 +35,4 @@ export LDFLAGS:=$(LDFLAGS) -static-libstdc++
3535
endif
3636

3737
%:
38-
dh $@
38+
dh $@

‎dspdfviewer.cpp‎

Lines changed: 30 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
#include <QDebug>
3434
#include <stdexcept>
3535

36-
DSPDFViewer::DSPDFViewer(const RuntimeConfiguration& r):
36+
DSPDFViewer::DSPDFViewer(const RuntimeConfiguration& r):
3737
runtimeConfiguration(r),
3838
presentationClockRunning(false),
3939
renderFactory(r.filePathQString(), r.cachePDFToMemory()?PDFCacheOption::keepPDFinMemory:PDFCacheOption::rereadFromDisk ),
@@ -42,12 +42,12 @@ DSPDFViewer::DSPDFViewer(const RuntimeConfiguration& r):
4242
secondaryWindow(0, r.useFullPage()? PagePart::FullPage : PagePart::RightHalf, true, r, "Secondary_Window", r.useSecondScreen() )
4343
{
4444
qDebug() << "Starting constructor" ;
45-
45+
4646
if ( ! r.useSecondScreen() ) {
4747
secondaryWindow.hide();
4848
}
49-
50-
49+
50+
5151
audienceWindow.showLoadingScreen(0);
5252
secondaryWindow.showLoadingScreen(0);
5353

@@ -59,58 +59,58 @@ DSPDFViewer::DSPDFViewer(const RuntimeConfiguration& r):
5959
}
6060
#endif
6161
qDebug() << "Connecting audience window";
62-
62+
6363
audienceWindow.setPageNumberLimits(0, numberOfPages()-1);
64-
64+
6565
connect( &renderFactory, SIGNAL(pageRendered(QSharedPointer<RenderedPage>)), &audienceWindow, SLOT(renderedPageIncoming(QSharedPointer<RenderedPage>)));
6666
connect( &renderFactory, SIGNAL(thumbnailRendered(QSharedPointer<RenderedPage>)), &audienceWindow, SLOT(renderedThumbnailIncoming(QSharedPointer<RenderedPage>)));
6767
connect( &renderFactory, SIGNAL(pdfFileRereadSuccesfully()), this, SLOT(renderPage()));
68-
68+
6969
connect( &audienceWindow, SIGNAL(nextPageRequested()), this, SLOT(goForward()));
7070
connect( &audienceWindow, SIGNAL(previousPageRequested()), this, SLOT(goBackward()));
7171
connect( &audienceWindow, SIGNAL(pageRequested(uint)), this, SLOT(gotoPage(uint)));
72-
72+
7373
connect( &audienceWindow, SIGNAL(quitRequested()), this, SLOT(exit()));
7474
connect( &audienceWindow, SIGNAL(rerenderRequested()), this, SLOT(renderPage()));
7575
connect( &audienceWindow, SIGNAL(restartRequested()), this, SLOT(goToStartAndResetClocks()));
76-
76+
7777
connect( &audienceWindow, SIGNAL(screenSwapRequested()), this, SLOT(swapScreens()) );
78-
78+
7979
connect( &audienceWindow, SIGNAL(blankToggleRequested()), this, SLOT(toggleAudienceScreenBlank()));
8080
connect( &audienceWindow, SIGNAL(secondScreenFunctionToggleRequested()), this, SLOT(toggleSecondaryScreenFunction()));
81-
81+
8282
if ( r.useSecondScreen() )
8383
{
8484
qDebug() << "Connecting secondary window";
85-
85+
8686
secondaryWindow.setPageNumberLimits(0, numberOfPages()-1);
87-
87+
8888
connect( &renderFactory, SIGNAL(pageRendered(QSharedPointer<RenderedPage>)), &secondaryWindow, SLOT(renderedPageIncoming(QSharedPointer<RenderedPage>)));
8989
connect( &renderFactory, SIGNAL(thumbnailRendered(QSharedPointer<RenderedPage>)), &secondaryWindow, SLOT(renderedThumbnailIncoming(QSharedPointer<RenderedPage>)));
9090

9191
connect( &secondaryWindow, SIGNAL(nextPageRequested()), this, SLOT(goForward()));
9292
connect( &secondaryWindow, SIGNAL(previousPageRequested()), this, SLOT(goBackward()));
9393
connect( &secondaryWindow, SIGNAL(pageRequested(uint)), this, SLOT(gotoPage(uint)));
94-
94+
9595
connect( &secondaryWindow, SIGNAL(quitRequested()), this, SLOT(exit()));
9696
connect( &secondaryWindow, SIGNAL(rerenderRequested()), this, SLOT(renderPage()));
9797
connect( &secondaryWindow, SIGNAL(restartRequested()), this, SLOT(goToStartAndResetClocks()));
98-
98+
9999
connect( &secondaryWindow, SIGNAL(screenSwapRequested()), this, SLOT(swapScreens()) );
100100

101101
connect( &secondaryWindow, SIGNAL(blankToggleRequested()), this, SLOT(toggleAudienceScreenBlank()));
102102
connect( &secondaryWindow, SIGNAL(secondScreenFunctionToggleRequested()), this, SLOT(toggleSecondaryScreenFunction()));
103103

104-
104+
105105
connect( this, SIGNAL(presentationClockUpdate(QTime)), &secondaryWindow, SLOT(updatePresentationClock(QTime)));
106106
connect( this, SIGNAL(slideClockUpdate(QTime)), &secondaryWindow, SLOT(updateSlideClock(QTime)));
107107
connect( this, SIGNAL(wallClockUpdate(QTime)), &secondaryWindow, SLOT(updateWallClock(QTime)));
108-
108+
109109

110110
}
111-
111+
112112
renderPage();
113-
113+
114114
clockDisplayTimer.setInterval(TIMER_UPDATE_INTERVAL);
115115
clockDisplayTimer.start();
116116
connect( &clockDisplayTimer, SIGNAL(timeout()), this, SLOT(sendAllClockSignals()));
@@ -143,7 +143,7 @@ unsigned int DSPDFViewer::pageNumber() const
143143

144144
QImage DSPDFViewer::renderForTarget(QSharedPointer< Poppler::Page > page, QSize targetSize, bool onlyHalf, bool rightHalf)
145145
{
146-
PagePart part(
146+
PagePart part(
147147
onlyHalf?
148148
( rightHalf? PagePart::RightHalf : PagePart::LeftHalf )
149149
: PagePart::FullPage );
@@ -165,11 +165,11 @@ void DSPDFViewer::renderPage()
165165
theFactory()->requestThumbnailRendering(m_pagenumber);
166166
}
167167
theFactory()->requestPageRendering( toRenderIdent(m_pagenumber, audienceWindow), QThread::HighestPriority);
168-
168+
169169
if ( runtimeConfiguration.useSecondScreen() ) {
170170
theFactory()->requestPageRendering( toRenderIdent(m_pagenumber, secondaryWindow), QThread::HighPriority);
171171
}
172-
172+
173173
/** Pre-Render next pages **/
174174
for ( unsigned i=m_pagenumber; i<m_pagenumber+runtimeConfiguration.prerenderNextPages() && i < numberOfPages() ; i++) {
175175
if ( runtimeConfiguration.showThumbnails() ) {
@@ -180,9 +180,9 @@ void DSPDFViewer::renderPage()
180180
theFactory()->requestPageRendering( toRenderIdent(i, secondaryWindow));
181181
}
182182
}
183-
183+
184184
/** Pre-Render previous pages **/
185-
185+
186186
for ( unsigned i= std::max(m_pagenumber,runtimeConfiguration.prerenderPreviousPages())-runtimeConfiguration.prerenderPreviousPages();
187187
i<m_pagenumber; i++) {
188188
if ( runtimeConfiguration.showThumbnails() ) {
@@ -193,13 +193,13 @@ void DSPDFViewer::renderPage()
193193
theFactory()->requestPageRendering(toRenderIdent(i, secondaryWindow));
194194
}
195195
}
196-
196+
197197
}
198198

199199

200200
void DSPDFViewer::gotoPage(unsigned int pageNumber)
201201
{
202-
if ( m_pagenumber != pageNumber
202+
if ( m_pagenumber != pageNumber
203203
&& numberOfPages() > pageNumber )
204204
{
205205
m_pagenumber = pageNumber;
@@ -244,7 +244,7 @@ unsigned int DSPDFViewer::numberOfPages() const {
244244
int pages = renderFactory.numberOfPages();
245245
if ( pages < 0 )
246246
{
247-
/* What the... ?!
247+
/* What the... ?!
248248
*
249249
* I return zero, so that any kind of loop that counts "for
250250
* all pages" will terminate immediately.
@@ -291,9 +291,9 @@ void DSPDFViewer::resetSlideClock()
291291
}
292292
/* and make sure they'll get refreshed a second later aswell. */
293293
slideStart.start();
294-
294+
295295
presentationClockRunning=true;
296-
296+
297297
/* Refresh display times immediately */
298298
sendAllClockSignals();
299299
}
@@ -316,7 +316,7 @@ RenderingIdentifier DSPDFViewer::toRenderIdent(unsigned int pageNumber, const PD
316316
{
317317
return
318318
RenderingIdentifier ( pageNumber, window.getMyPagePart(), window.getTargetImageSize());
319-
319+
320320
}
321321

322322
bool DSPDFViewer::isAudienceScreenBlank() const

‎dspdfviewer.h‎

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -52,49 +52,49 @@ class DSPDFViewer: public QObject
5252
unsigned int m_pagenumber;
5353
PDFViewerWindow audienceWindow;
5454
PDFViewerWindow secondaryWindow;
55-
55+
5656

5757

5858
public:
5959
static const QSize thumbnailSize;
60-
60+
6161
private:
6262
QImage renderForTarget( QSharedPointer<Poppler::Page> page, QSize targetSize, bool onlyHalf, bool rightHalf=false);
63-
63+
6464
QString timeToString(QTime time) const;
6565
QString timeToString(int milliseconds) const;
6666
void resetSlideClock();
67-
67+
6868
RenderingIdentifier toRenderIdent(unsigned int pageNumber, const PDFViewerWindow& window);
69-
69+
7070
private slots:
7171
void sendAllClockSignals() const;
72-
72+
7373
public:
7474
DSPDFViewer(const RuntimeConfiguration& r);
7575
virtual ~DSPDFViewer();
76-
77-
76+
77+
7878
/** get current page number
7979
*/
8080
unsigned int pageNumber() const;
81-
81+
8282
/** get page count
8383
*/
8484
unsigned int numberOfPages() const;
85-
85+
8686
void setHighQuality(bool hq);
87-
87+
8888
bool isReadyToRender() const;
89-
89+
9090
PdfRenderFactory* theFactory();
91-
91+
9292
QTime wallClock() const;
9393
QTime slideClock() const;
9494
QTime presentationClock() const;
95-
95+
9696
QTime timeSince( const QTime& startPoint) const;
97-
97+
9898
bool isAudienceScreenBlank() const;
9999

100100
signals:
@@ -106,26 +106,26 @@ public slots:
106106
/** (re-)Renders the current page on both monitors
107107
*/
108108
void renderPage();
109-
109+
110110
/** goes to the specified page. Pages start at zero.
111111
*/
112112
void gotoPage(unsigned int pageNumber);
113113
/** go Forward one page
114114
*/
115115
void goForward();
116-
116+
117117
/** go backward one page
118118
*/
119119
void goBackward();
120-
120+
121121
void goToStartAndResetClocks();
122-
122+
123123
void swapScreens();
124-
124+
125125
void toggleAudienceScreenBlank();
126126
void setAudienceScreenBlank();
127127
void setAudienceScreenVisible();
128-
128+
129129
void toggleSecondaryScreenFunction();
130130

131131
void exit();

‎pagepart.h‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
enum class PagePart
2525
{
26-
26+
2727
FullPage,
2828
LeftHalf,
2929
RightHalf

0 commit comments

Comments
 (0)