brailleutils-1.2.1.orig/ 0000755 0001750 0001750 00000000000 12130740502 015701 5 ustar streicher streicher brailleutils-1.2.1.orig/build.debian.properties 0000644 0001750 0001750 00000001002 12071251243 022333 0 ustar streicher streicher # These properties can be edited file.reference.saxon=/usr/share/java/saxonb.jar file.reference.stax-api=/usr/share/java/stax-api.jar file.reference.jing=/usr/share/java/jing.jar file.reference.xercesImpl=/usr/share/java/xercesImpl.jar file.reference.xml-apis=/usr/share/java/xml-apis.jar file.reference.isorelax=/usr/share/java/isorelax.jar file.reference.wstx=/usr/share/java/wstx-lgpl.jar file.reference.junit=/usr/share/java/junit4.jar ui.classpath.attribute=${core-jar.name} ${catalog-jar.name} brailleutils-1.2.1.orig/doc/ 0000755 0001750 0001750 00000000000 12130740476 016460 5 ustar streicher streicher brailleutils-1.2.1.orig/doc/README.txt 0000644 0001750 0001750 00000003770 12004210016 020143 0 ustar streicher streicher === Braille Utils === Contributors: Joel Håkansson, Bert Frees Code license: GNU Lesser GPL Language: Java Platform: Cross platform Code URL: http://brailleutils.googlecode.com == Contents == 1 Description 2 Installation 3 Help Resources == 1 Description == Braille Utils is a cross platform utility package for embossing and converting PEF-files. Braille Utils provides a cross platform API for embossing and converting braille in PEF-format. Conversion to and from commonly used "braille" text formats is also supported. The package is written in Java and contains basic user interfaces for common operations. However, the main purpose of the package is as part of other software, such as the Daisy Pipeline and Odt2braille. = Main Features = * Emboss PEF-files * Convert to or from PEF-files * Split or merge PEF-files = Supported embossers = The package supports the following embosser families: * Braillo * Cidat * Enabling Technologies * Index Braille * Mountbatten * ViewPlus For details, see the complete list of supported embossers: http://code.google.com/p/brailleutils/wiki/SupportedEmbossers == 2 Installation == You can download a ready-to-run binary variant of this library from http://brailleutils.googlecode.com A list of the dependencies is located in the developer documentation (e. g. in the source under doc/). Compilation is done just by % ant in the source directory. The built library can be found under ant-build/output/. NOTE: On Debian systems, you should use 'ant -DuseExternalJarsOnLinux=true' in order to use the Debian-own libraries. == 3 Help Resources == See the latest version of the written documentation on http://brailleutils.googlecode.com There is also a mailing list where development and usage is discussed. For details, see http://groups.google.com/group/brailleutils On Debian systems, documentation can be found at /usr/share/doc/brailleutils/ or at the web site mentioned above. brailleutils-1.2.1.orig/doc/developer-guide.html 0000644 0001750 0001750 00000021356 11632337340 022433 0 ustar streicher streicher
The goal of this project is to provide core functionality needed to interact with PEF-files, to provide implementations for commonly used software/hardware related to PEF-files and to provide an easy way for others to extend the list of implementations.
The project contains code to:
Soon the following features will be included too:
The software should be:
Code written for this project must work under Java SE 5.
Some operations are best handled using XSLT and XPath. Where these technologies have been used, only the versions directly supported by Java has been used, i.e.
Note that care must be taken not to use XSLT 2.0, since it is readily available in the coding environment. Saxon 8 is used for the validation functionality, but should not be used elsewhere.
The goal to avoid using additional libraries if possible has been successful, except in validation and testing. Therefore, in order to use the PEF validator, the following libraries must be included in the class path:
To run unit tests using Ant, "junit-4.4.jar" must be in the class path.
If validation is not needed, no jar-files have to be included in the distribution.
An online version of the Javadoc is available here (release 1.1.0).
Java Services API is used for discovering implementations at runtime. The reason for using this technology instead of, for example, OSGi, is because the Services API is part of the JRE.
All services that an implementation wants to provide as Java services must be published in the META-INF/services folder. That folder should contain one file for each interface having implementations that should be provided as Java services. The file name must equal the interface's canonical name. The contents of each file should be a list of canonical names of classes implementing the interface indicated by the file name.
The following interfaces have been constructed so that they can be discovered as Java services:
All of these may be discovered by the Services API. However, in most cases, one of the following interfaces will provide a starting point for a developer who wishes to add functionality to the software:
The classes in the org.daisy.factory package provides the foundation for the interfaces used elsewhere in the software to discover and create objects. At the top level is the Provider interface. Its sole purpose is to provide a collection of factories. The factories implement the Factory interface.
Note that the objects created using a Factory implementation are not controlled by these interfaces.
Different factories creating the same type of objects can be combined in a FactoryCatalog. The catalog can then be used to extract a list of all factories that can be used to create a specific type of objects.
The trunk, tags, and branches directories live in the root directory of the repository, and the projects are placed in subdirectories beneath those. The main project (Braille Utils) is located in the "braille" subdirectory (https://brailleutils.googlecode.com/svn/trunk/braille). Additional projects may be added to the repository in the future.
The project contains three source folders:
Core functionality should be placed in the src folder. Interface implementations, such as embossers or papers, should generally be placed in the catalog folder.
Unit tests should be placed in the tests folder, mirroring the structure of the other two source folders. The risk for naming conflicts in the tests folder have been minimized by using different naming schemes for src and catalog.
The catalog folder has a relatively flat structure. Each folder in the catalog folder should contain related implementation entities. Each entity should be modelled on the domain of an organization using a two-part underscore separated string where the first part begins with the top level domain name of the organization and then the organization's domain. If possible, use the organization of the provider of the hardware (or software) that the implementations target. If this is not possible, use the organization of the provider of the implementations (your organization).
Note that this does not imply ownership or responsibility for the code in the package, but merely serves as identification and a structuring aid.
The classes in each of these folders should be considered package specific. Implementations may not rely on other packages in the catalog. If a functionality can be regarded as generic, it should be placed in the src folder instead.
Unit tests can performed by running "build.xml" with Ant.
If applicable, add unit tests to verify your changes and make sure that all unit tests pass before committing code to the project. Also, remember to enter a descriptive commit comment, describing the key aspects of your work.
The distribution is built by running "build.xml" with Ant. "build.xml" can also generate Javadoc and run unit tests. All files related to this process should be placed in the "ant-build" folder. Files created as a result of running "build.xml" should be placed in "ant-build/output" and should not be added to the repository.
...
brailleutils-1.2.1.orig/doc/user-guide.html 0000644 0001750 0001750 00000021475 11632337340 021426 0 ustar streicher streicherThis document contains information needed to run the command line user interface contained in the package. Note that this software doesn't target end users directly, but rather developers of user interfaces or braille systems. The functionality in the user interface does not demonstrate the full capability of the package.
To run the user interface, download and extract the latest release. If you do not have Java installed on your machine, you have to download and install that as well.
On the command line, navigate to the extracted folder and type: java -jar brailleUtils-ui-1.1.0.jar. Press enter.
This will bring up a list of applications (or features):
These are explained in detail below. To start one of them, append their name as the first argument, for example: java -jar brailleUtils-ui-1.1.0.jar emboss
Send a PEF-file to an embosser for embossing.
One argument is required, and can be one of the following:
Upon the first run, the application will ask the user for the required setup:
The file will be sent directly to the embosser on subsequent runs. To change settings, use either -setup or -clear.
Setup will ask all the user to verify all settings.
Clear will delete the current settings. The next time the application is started, it runs as on the first run.
The device is the address where the embosser can be contacted. In most cases this should be intuitive. If your device does not show up, make sure that the embosser is turned on.
Note that the same embosser model may communicate differently depending on firmware or hardware version. Make sure that the embosser version is correct.
Some embossers require that a table is chosen by the user for the purpose of communication. Make sure that the table chosen in the user interface matches the value expected by the embosser.
Verify that the paper in the embosser matches the value in the user interface. Some embossers uses rolls of paper. In this case, select a paper size that matches the intended paper size once cut.
Convert a text braille file into a PEF-file.
Two arguments are required path to input file and path to output file.
The input file should be a "braille ready" text file, i.e. broken in rows an pages (using the form feed character), and using one unique character to represent each braille pattern.
Optional arguments include:
The options identifier, date, author, title and language all involve setting the meta data of the resulting file. It will not affect the contents of the file in any way.
Choose a table to use when converting. Note that, if a character is encountered in the file that isn't in the selected table, an error will occur. The default mode is to attempt to detect. If this fail, choose between the tables suggested in the detector failure message.
Set the duplex property of the resulting file.
Convert a PEF-file document into a text braille file.
Two arguments are required path to input file and path to output file.
Optional arguments include:
Output a range of pages.
Set the table (character mapping) to use.
Set the line break style. Most braille applications use DOS line breaks.
Set the action to use if an eight dot pattern is encountered and the current table does not support eight dot:
Set the replacement character to use if an eight dot pattern is encountered and fallback is set to "replace".
Validate a PEF-file.
One argument is required: path to input file
Optional arguments include:
Set the validation mode:
Split a PEF file into several files, one file per volume.
The purpose is to facilitating the use of PEF files with braille editors that do not support multi volume files.
Two arguments are required: path to input file and path to output folder.
Merge several PEF files into one.
The purpose is to facilitating the use of PEF-files with braille editors that do not support multi volume files.
Three arguments are required: path to input folder, path to output file and identifier.
Optional arguments include:
Set the sorting method to use when ordering files in the input folder.
Generate a random PEF-file for testing purposes.
One argument is required: path to output file
Optional arguments include:
Set the number of volumes to generate.
Set the number of pages in each volume.
Set to true to include 8-dot patterns.
Set the maximum numbers of rows on a page.
Set the maximum number of characters on a row.
Set the duplex property.
Plugins can be added by creating a directory called plugins in the software folder and placing the plugin (.jar) in that folder.
brailleutils-1.2.1.orig/tests/ 0000755 0001750 0001750 00000000000 12130740476 017055 5 ustar streicher streicher brailleutils-1.2.1.orig/tests/com_yourdolphin/ 0000755 0001750 0001750 00000000000 12130740476 022267 5 ustar streicher streicher brailleutils-1.2.1.orig/tests/com_yourdolphin/SupernovaTableProviderTest.java 0000644 0001750 0001750 00000003620 11477125056 030444 0 ustar streicher streicher package com_yourdolphin; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertTrue; import java.nio.charset.Charset; import org.daisy.braille.BrailleConstants; import org.daisy.braille.table.BrailleConverter; import org.daisy.braille.table.EmbosserBrailleConverter.EightDotFallbackMethod; import org.junit.Test; public class SupernovaTableProviderTest { private static SupernovaTableProvider bt = new SupernovaTableProvider(); @Test public void testFeatureReplacement() { assertEquals('\u2800', bt.getFeature("replacement")); } @Test public void testFeatureFallback() { assertEquals(EightDotFallbackMethod.MASK, bt.getFeature("fallback")); } @Test (expected=IllegalArgumentException.class) public void testGetUnknownFeature() { bt.getFeature("unknown-feature"); } @Test (expected=IllegalArgumentException.class) public void testSetUnknownFeature() { bt.setFeature("unknown-feature", null); } @Test public void testListLength() { assertEquals("Assert that all tables have tests by counting the list length", 1, bt.list().size()); } @Test public void testTableSV_SE_6DOT() { //BrailloTableProvider bt = new BrailloTableProvider(); String input = BrailleConstants.BRAILLE_PATTERNS_64; SupernovaTableProvider.TableType t = SupernovaTableProvider.TableType.SV_SE_6DOT; BrailleConverter ta = bt.newTable(t); String text = ta.toText(input); String braille = ta.toBraille(text); assertEquals("Assert that conversion is reversible", input, braille); assertEquals("Assert that text has been transformed", " a,b.k;l@cif/msp'e:h*o!rødjgäntq_å?ê-u(v`îöë§xèç\"û+ü)z=àœôwï#yùé", text); assertTrue("Assert that table does not support 8-dot", !ta.supportsEightDot()); assertEquals("Assert that UTF-8 is the preferred charset", Charset.forName("UTF-8"), ta.getPreferredCharset()); } } brailleutils-1.2.1.orig/tests/com_indexbraille/ 0000755 0001750 0001750 00000000000 12130740476 022355 5 ustar streicher streicher brailleutils-1.2.1.orig/tests/com_indexbraille/resource-files/ 0000755 0001750 0001750 00000000000 12130740476 025304 5 ustar streicher streicher brailleutils-1.2.1.orig/tests/com_indexbraille/resource-files/basic_s_v2_single_sided.prn 0000644 0001750 0001750 00000001143 11625421273 032546 0 ustar streicher streicher 0,0,0,0,x,x,x,x,x,18,0,0,0,0,4,0,0,0,x,0,0,x,x,x,x,x,x,0,1,x,x,x,x,x,x,x,x,x,x,x,PCCCCCCCCCCCCCCCCCC? L A1B'K2L@CIF/MSP _ L "E3H9O6R^DJG>NTQ _ L ,*5<-U8V.%[$+X!& _ L ;:4\0Z7(_?W]#Y)= _ V------------------#PCCCCCCCCCCCCCCCCCC? L A1B'K2L@CIF/MSP _ L "E3H9O6R^DJG>NTQ _ L ,*5<-U8V.%[$+X!& _ L ;:4\0Z7(_?W]#Y)= _ V------------------#PCCCCCCCCCCCCCCCCCC? L A1B'K2L@CIF/MSP _ L "E3H9O6R^DJG>NTQ _ L ,*5<-U8V.%[$+X!& _ L ;:4\0Z7(_?W]#Y)= _ V------------------#PCCCCCCCCCCCCCCCCCC? L A1B'K2L@CIF/MSP _ L "E3H9O6R^DJG>NTQ _ L ,*5<-U8V.%[$+X!& _ L ;:4\0Z7(_?W]#Y)= _ V------------------# brailleutils-1.2.1.orig/tests/com_indexbraille/resource-files/double_sided.pef 0000644 0001750 0001750 00000004112 11567434244 030426 0 ustar streicher streicher