[brailleblaster] Pasting text

  • From: "Vic Beckley" <vic.beckley3@xxxxxxxxx>
  • To: <brailleblaster@xxxxxxxxxxxxx>
  • Date: Fri, 13 Sep 2013 13:57:29 -0400

Isn't it possible to paste text into a new document? I have successfully
pasted one paragraph into an existing element. I tried pasting four
paragraphs into a blank document. I thought all paragraphs would have the
para style. It didn't seem they had any style. I tried applying a heading2
style to one of the paragraphs but my text disappeared and this was in the
console window.

New Node Value:
Value:
Node 1: 0
Node 2:  none
java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
        at java.util.LinkedList.checkElementIndex(Unknown Source)
        at java.util.LinkedList.get(Unknown Source)
        at org.brailleblaster.mapping.MapList.findClosest(MapList.java:87)
        at
org.brailleblaster.wordprocessor.DocumentManager.handleSetCurrent(Doc
umentManager.java:469)
        at
org.brailleblaster.wordprocessor.DocumentManager.dispatch(DocumentMan
ager.java:379)
        at org.brailleblaster.views.TextView.setCurrent(TextView.java:366)
        at org.brailleblaster.views.TextView.access$1200(TextView.java:64)
        at org.brailleblaster.views.TextView$5.caretMoved(TextView.java:279)
        at org.eclipse.swt.custom.StyledTextListener.handleEvent(Unknown
Source)

        at org.eclipse.swt.widgets.EventTable.sendEvent(Unknown Source)
        at org.eclipse.swt.widgets.Widget.sendEvent(Unknown Source)
        at org.eclipse.swt.widgets.Widget.sendEvent(Unknown Source)
        at org.eclipse.swt.widgets.Widget.sendEvent(Unknown Source)
        at org.eclipse.swt.widgets.Widget.notifyListeners(Unknown Source)
        at org.eclipse.swt.custom.StyledText.setCaretOffset(Unknown Source)
        at org.eclipse.swt.custom.StyledText.doLineDown(Unknown Source)
        at org.eclipse.swt.custom.StyledText.invokeAction(Unknown Source)
        at org.eclipse.swt.custom.StyledText.handleKey(Unknown Source)
        at org.eclipse.swt.custom.StyledText.handleKeyDown(Unknown Source)
        at org.eclipse.swt.custom.StyledText$7.handleEvent(Unknown Source)
        at org.eclipse.swt.widgets.EventTable.sendEvent(Unknown Source)
        at org.eclipse.swt.widgets.Widget.sendEvent(Unknown Source)
        at org.eclipse.swt.widgets.Widget.sendEvent(Unknown Source)
        at org.eclipse.swt.widgets.Widget.sendEvent(Unknown Source)
        at org.eclipse.swt.widgets.Widget.sendKeyEvent(Unknown Source)
        at org.eclipse.swt.widgets.Widget.sendKeyEvent(Unknown Source)
        at org.eclipse.swt.widgets.Widget.wmKeyDown(Unknown Source)
        at org.eclipse.swt.widgets.Control.WM_KEYDOWN(Unknown Source)
        at org.eclipse.swt.widgets.Control.windowProc(Unknown Source)
        at org.eclipse.swt.widgets.Canvas.windowProc(Unknown Source)
        at org.eclipse.swt.widgets.Display.windowProc(Unknown Source)
        at org.eclipse.swt.internal.win32.OS.DispatchMessageW(Native Method)
        at org.eclipse.swt.internal.win32.OS.DispatchMessage(Unknown Source)
        at org.eclipse.swt.widgets.Display.readAndDispatch(Unknown Source)
        at
org.brailleblaster.wordprocessor.WPManager.<init>(WPManager.java:132)

        at org.brailleblaster.Main.main(Main.java:55)
java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
        at java.util.LinkedList.checkElementIndex(Unknown Source)
        at java.util.LinkedList.get(Unknown Source)
        at
org.brailleblaster.mapping.MapList.findTextMapElements(MapList.java:5
09)
        at
org.brailleblaster.wordprocessor.DocumentManager.handleUpdateStyle(Do
cumentManager.java:722)
        at
org.brailleblaster.wordprocessor.DocumentManager.dispatch(DocumentMan
ager.java:415)
        at
org.brailleblaster.stylePanel.StyleManager.apply(StyleManager.java:86
)
        at
org.brailleblaster.stylePanel.StyleTable$3.widgetSelected(StyleTable.
java:115)
        at org.eclipse.swt.widgets.TypedListener.handleEvent(Unknown Source)
        at org.eclipse.swt.widgets.EventTable.sendEvent(Unknown Source)
        at org.eclipse.swt.widgets.Widget.sendEvent(Unknown Source)
        at org.eclipse.swt.widgets.Display.runDeferredEvents(Unknown Source)
        at org.eclipse.swt.widgets.Display.readAndDispatch(Unknown Source)
        at
org.brailleblaster.wordprocessor.WPManager.<init>(WPManager.java:132)

        at org.brailleblaster.Main.main(Main.java:55)
Main Shell handling Close event, about to dipose the main Display

If I am pushing ahead too fast, just ignore this. Document creation is
looking so good that I get impatient. Pretty soon I won't even need to use
the DAISY for Word plug-in. I can just create the document in ND to begin
with. I have already been able to modify existing documents by pasting in
text and then applying styles. This was a little tricky, though. If I
created a blank element and pasted the text into that element then things
got messed up. I had to paste the text at the end of an existing element and
then split the element. This worked fine. I could then apply the style I
wanted. This is looking so great!


Best regards from Ohio,

Vic




Other related posts: