Coder Social home page Coder Social logo

farling42 / rwoutput Goto Github PK

View Code? Open in Web Editor NEW
14.0 3.0 0.0 2.3 MB

Tool to convert a Realm Works Output file into other formats.

License: GNU General Public License v3.0

QMake 0.85% C++ 96.40% NSIS 0.94% JavaScript 0.40% CSS 1.24% C 0.16%
qt5 realmworks

rwoutput's Introduction

ko-fi patreon paypal Latest Release Download Count GitHub License

RWoutput

Tool to convert a Realm Works Output or Export file into other formats.

** NOTE: This tool will NEVER be able to export "protected" content, such as material sold on the Content Market. **

Instructions for Use

  1. Within Realm Works, from the "Share" tab of the ribbon select "Manage Exports" and enter some data, then do one of the following depending upon which output you want:

    • For Markdown, select "Full Export". This will generate a file in your "Realm Works\Export" folder whose name ends with ".rwexport".

    • For other formats, select "Compact Output". This will generate a file in your "Realm Works\Output" folder whose name ends with ".rwoutput".

  2. Launch the RWoutput tool, press the "LOAD rwoutput FILE" button and select the file created in step 1.

  3. If a separate web page is desired for each topic, then ensure that the "Separate Topic Files" option is selected.

  4. If you want to restrict the width of images to something more suitable for web pages, then choose the width in the "Max. Width (pixels)" menu. Optionally choose the "apply reveal mask" if your export should hide unrevealed parts of maps.

  5. Choose one of the output options:

    • Create HTML file(s) will create XHTML files containing lots of formatting. (Word does not support importing XHTML files, see HTML4 below).

    • Create PDF file - experimental, and might not always work.

    • Print - print the output to a printer, you could choose the "print to PDF" printer on windows 10 for a more reliable PDF output.

    • Create HTML4 file - this is the intermediate file for printing and PDF generation; so why not have it available. This format can also be imported into Word (and possibly other editors).

    • Create Markdown - which will prompt you for a directory into which the markdown files will be placed.

rwoutput's People

Contributors

farling42 avatar

Stargazers

Tim Newton avatar Taylor Hiatt avatar David J Brockley avatar  avatar  avatar  avatar Daplunk avatar  avatar Jimmy Briggs avatar Aaron Bopp avatar Ben Stern avatar  avatar Vesala avatar  avatar

Watchers

 avatar  avatar  avatar

rwoutput's Issues

Request: Preffix Suffix Tag Option

An option to enable either a Preffix/Suffix as a tag would be fantastic. Perhaps as a on/off choice?
LWD required all Mechanics to have a suffix code to match the content. So this would be a great place to pull a tag from.

Request: Ability to resize images on import

I'm not sure I completely understand the format you are using for linking images yet however there is capability to set image sizes using something like:

![[Image.png|200]]

Where 200 could be a variable fed in via the Output Formatter?

Feedback - Text Formatting

Morning,
Starting to really slow down and look at the output in detail. Not sure if there's anything that can be done about this. I've noticed over the years that the way text works in RW is rather odd (it cold also just be me, who knows) and it tends to add spaces in where they don't belong. This seems to be having an impacted on the output.

Between paragraphs theres usually an empty line. If that line is clean, then the output format is fantastic.
However in some situations there's spaces on the empty lines. Where that occurs the output format has a large gap between the paragraphs.

Here's an example:
image

And as you can see. The reason for the gap is there a spaces on the empty line.
image

So yeah. Not sure if anything can be done. I see this as an issue with the source realm but FYI.

Create mermaid tree for each relationship.

A mermaid relationship tree needs to go into its own note, which can then be linked to by each referenced topic note.

Each type of relationship should build a tree of all connected nodes.

Some connection types don't really work for building a tree - such as arbitrary.

```mermaid
graph TD
topic_1(Eye of Abendego)
topic_2(Onokin)
topic_42(Ungoro Tedar)

topic_1 -- Master to Minion --> topic_2
topic_42 --> topic_1
```

Feedback - Heading Formatting

I suspect this could be because the raw text is a whole paragraph of BOLD.
image

Looks like the heading got confused about where it should start/end.
image

Pattern seems to be where there is a line of BOLD is does weird things.
image

image

Interestingly... that link does not exist in RW. I do wonder if it was linked once upon a time and I removed it though.

Request - MetaData For Tags

Is it possible to get the tags added to the Meta Data?

Example: A spell is used by a Bard and it's an Transmutation Spell.

---
ImportedOn: Sunday, 12 December 2021 9:55:01 PM
Tags: Category/Spell
Class: Bard
School: Transmutation 
parent:
  - 9. - Spell Descriptions
up:
  - 9. - Spell Descriptions
prev:
  - Zone of Truth
RWtopicId: Topic_425
---

This will enable the use of Dataview. For example:

```dataview
table ImportedOn, Class, School
where (School = "Transmutation")

This then updates automatically to: 

![image](https://user-images.githubusercontent.com/8046697/145711048-06a3072b-5bb9-49d1-849e-f51d98c6448b.png)

This could be really powerful. 

Support additional snippet types

The following are complete (but might need extra CSS styles)
Labeled_Text = done
Multi_Line = done
Numeric = done
Date_Game = done
Date_Range = done
Tag_Standard = done
Tag_Multi_Domain = done
Picture = done
Smart_Image = done (including reveal mask and map pins)

The following are saved as external files are linked inside topic page
Statblock = done
Portfolio = done
Rich_Text = done
PDF = done
Audio = done
Video = done
Foreign = done
HTML = done

The following are not done:
Hybrid_Tag = not done

Generate a long list of CSS dynamically

While loading each topic, look for individual "style" attributes on any element.
Store those "style" attributes in a lookup table - and replace the "style" attribute with a "class" attribute indicating the name added to the lookup table.

Lots of styles in the RWoutput file are the same across many elements, so this should further reduce the overall file sizes.

PDF and Printing

Qt provides the QPDFWriter and QPrinter devices which provide a paint device on which QTextDocument can be drawn, assuming that the XML has been converted into the Qt subset of HTML4.

Better linking between pages.

There should be a "HOME" button on each topic page.

There should be a list of "child" topics on each topic page: Maybe in a new section at the end of each file.

Add a footnote to each page containing the generation time of the page.

MD: Add connections to markdown

Process the connection elements in each topic.

Create explicit line at end of each page showing links out to other pages.

Add tag of some sort to allow connection to be shown by other diagrams/graphs.

Smart Map support

Add map pin data to the exported data.
The simple (?) thing is to create the link map.
The difficult thing is to create the overlay of map pins.

Parse embedded HTML properly

The current HTML parsing doesn't work properly, since HTML isn't well-formed XML.

Some tables start each row with but don't have the ending token.

Handle MASSIVE files

When reading in a 900 MB file, the program runs out of memory (being a 32-bit app).

It needs to read one topic (hierarchy) at a time, and then output that one topic.

HTML: Allow formatted tooltips in generated HTML

Using jquery-ui, the tooltip's "title" attributes are still used.
Only need to add an "include" of the script in the head of each page.

See https://jqueryui.com/tooltip/

Presumably have a single output configuration option to put the extra line(s) in the header, and to generate full HTML inside the 'title' instead of just basic text.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.