Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
O
OpenBoard
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lifo
Nicolas Ollinger
OpenBoard
Commits
c220bf47
Commit
c220bf47
authored
Dec 10, 2015
by
Craig Watson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix bad URL encoding in .svg
parent
82e5f92c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
6 deletions
+7
-6
UBSvgSubsetAdaptor.cpp
src/adaptors/UBSvgSubsetAdaptor.cpp
+7
-6
No files found.
src/adaptors/UBSvgSubsetAdaptor.cpp
View file @
c220bf47
...
@@ -1983,10 +1983,7 @@ void UBSvgSubsetAdaptor::UBSvgSubsetWriter::audioItemToLinkedAudio(UBGraphicsMed
...
@@ -1983,10 +1983,7 @@ void UBSvgSubsetAdaptor::UBSvgSubsetWriter::audioItemToLinkedAudio(UBGraphicsMed
mXmlWriter
.
writeAttribute
(
UBSettings
::
uniboardDocumentNamespaceUri
,
"position"
,
QString
(
"%1"
).
arg
(
pos
));
mXmlWriter
.
writeAttribute
(
UBSettings
::
uniboardDocumentNamespaceUri
,
"position"
,
QString
(
"%1"
).
arg
(
pos
));
}
}
QString
audioFileHref
=
audioItem
->
mediaFileUrl
().
toString
();
QString
audioFileHref
=
"audios/"
+
audioItem
->
mediaFileUrl
().
fileName
();
audioFileHref
=
UBFileSystemUtils
::
removeLocalFilePrefix
(
audioFileHref
);
if
(
audioFileHref
.
startsWith
(
mDocumentPath
))
audioFileHref
=
audioFileHref
.
replace
(
mDocumentPath
+
"/"
,
""
);
mXmlWriter
.
writeAttribute
(
nsXLink
,
"href"
,
audioFileHref
);
mXmlWriter
.
writeAttribute
(
nsXLink
,
"href"
,
audioFileHref
);
mXmlWriter
.
writeEndElement
();
mXmlWriter
.
writeEndElement
();
...
@@ -2225,7 +2222,7 @@ void UBSvgSubsetAdaptor::UBSvgSubsetWriter::graphicsItemToSvg(QGraphicsItem* ite
...
@@ -2225,7 +2222,7 @@ void UBSvgSubsetAdaptor::UBSvgSubsetWriter::graphicsItemToSvg(QGraphicsItem* ite
QUrl
sourceUrl
=
ubItem
->
sourceUrl
();
QUrl
sourceUrl
=
ubItem
->
sourceUrl
();
if
(
!
sourceUrl
.
isEmpty
())
if
(
!
sourceUrl
.
isEmpty
())
mXmlWriter
.
writeAttribute
(
UBSettings
::
uniboardDocumentNamespaceUri
,
"source"
,
sourceUrl
.
toString
());
mXmlWriter
.
writeAttribute
(
UBSettings
::
uniboardDocumentNamespaceUri
,
"source"
,
sourceUrl
.
path
());
}
}
...
@@ -2285,8 +2282,10 @@ void UBSvgSubsetAdaptor::UBSvgSubsetWriter::graphicsWidgetToSvg(UBGraphicsWidget
...
@@ -2285,8 +2282,10 @@ void UBSvgSubsetAdaptor::UBSvgSubsetWriter::graphicsWidgetToSvg(UBGraphicsWidget
widgetRootUrl
=
widgetTargetDir
;
widgetRootUrl
=
widgetTargetDir
;
}
}
QString
widgetPath
=
"widgets/"
+
widgetRootUrl
.
fileName
();
mXmlWriter
.
writeStartElement
(
"foreignObject"
);
mXmlWriter
.
writeStartElement
(
"foreignObject"
);
mXmlWriter
.
writeAttribute
(
UBSettings
::
uniboardDocumentNamespaceUri
,
"src"
,
widget
RootUrl
.
toString
()
);
mXmlWriter
.
writeAttribute
(
UBSettings
::
uniboardDocumentNamespaceUri
,
"src"
,
widget
Path
);
graphicsItemToSvg
(
item
);
graphicsItemToSvg
(
item
);
...
@@ -2307,6 +2306,8 @@ void UBSvgSubsetAdaptor::UBSvgSubsetWriter::graphicsWidgetToSvg(UBGraphicsWidget
...
@@ -2307,6 +2306,8 @@ void UBSvgSubsetAdaptor::UBSvgSubsetWriter::graphicsWidgetToSvg(UBGraphicsWidget
else
else
startFileUrl
=
widgetRootUrl
.
toString
()
+
"/"
+
item
->
mainHtmlFileName
();
startFileUrl
=
widgetRootUrl
.
toString
()
+
"/"
+
item
->
mainHtmlFileName
();
startFileUrl
=
QUrl
::
fromPercentEncoding
(
startFileUrl
.
toUtf8
());
mXmlWriter
.
writeAttribute
(
"src"
,
startFileUrl
);
mXmlWriter
.
writeAttribute
(
"src"
,
startFileUrl
);
mXmlWriter
.
writeEndElement
();
//iFrame
mXmlWriter
.
writeEndElement
();
//iFrame
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment