Skip to content

Commit

Permalink
Bug fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
burghoff committed Nov 23, 2024
1 parent 2adf669 commit 9c5a8a4
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
2 changes: 1 addition & 1 deletion scientific_inkscape/autoexporter.py
Original file line number Diff line number Diff line change
Expand Up @@ -546,7 +546,7 @@ def preprocessing(bfn, fin, opts, tempbase):
AutoExporter.subsuper_fix(elem)

# Preserve duplicate of text to be converted to paths
if opts.texttopath and elem.get("display") != "none":
if opts.texttopath and elem.get("display") != "none" and elem.croot is not None:
dup = elem.duplicate()
excludetxtids.append(dup.get_id())
grp = dh.group([dup])
Expand Down
9 changes: 5 additions & 4 deletions scientific_inkscape/gallery_viewer_script.py
Original file line number Diff line number Diff line change
Expand Up @@ -1092,10 +1092,11 @@ def on_folder_button_clicked(self, widget):
if os.path.exists(selected_file):
for fnm in os.listdir(selected_file):
if fnm.endswith('.docx') or fnm.endswith('.pptx') or fnm.endswith('.one'):
file_name = fnm
file_dir = selected_file
self.liststore.append([file_name, file_dir])
process_selection(os.path.join(file_dir,file_name))
if not fnm.startswith('~$'): # temp files
file_name = fnm
file_dir = selected_file
self.liststore.append([file_name, file_dir])
process_selection(os.path.join(file_dir,file_name))
native.destroy()

def gallery_button_clicked(self, widget):
Expand Down
2 changes: 1 addition & 1 deletion scientific_inkscape/gallery_viewer_template.html
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ <h2>Gallery Viewer</h2>
descDiv.innerHTML += `
<div>
<a href="http://localhost:${port}/process?param=${encodeURIComponent(file.embed)}" class="open">Original</a>
<a href="http://localhost:${port}/show_file?param=${encodeURIComponent(file.file_uri)}" class="show-file" style="margin-left:5px;">
<a href="http://localhost:${port}/show_file?param=${encodeURIComponent(file.embed)}" class="show-file" style="margin-left:5px;">
<!-- Folder SVG Icon -->
<svg width="13.938748" height="11.034863" viewBox="0 0 20.908124 16.552295" fill="currentColor" xmlns="http://www.w3.org/2000/svg">
<path
Expand Down

0 comments on commit 9c5a8a4

Please sign in to comment.