diff -urNad '--exclude=CVS' '--exclude=.svn' '--exclude=.git' '--exclude=.arch' '--exclude=.hg' '--exclude=_darcs' '--exclude=.bzr' writer2latex-1.4~/source/java/org/openoffice/da/comp/w2lcommon/filter/FilterDataParser.java writer2latex-1.4/source/java/org/openoffice/da/comp/w2lcommon/filter/FilterDataParser.java
--- writer2latex-1.4~/source/java/org/openoffice/da/comp/w2lcommon/filter/FilterDataParser.java	2011-06-07 11:01:15.000000000 +0200
+++ writer2latex-1.4/source/java/org/openoffice/da/comp/w2lcommon/filter/FilterDataParser.java	2015-12-23 21:35:12.644079492 +0100
@@ -55,8 +55,6 @@
  *  All errors are silently ignored
  */
 public class FilterDataParser {
-	// TODO: Use JSON format
-    
     //private static XComponentContext xComponentContext = null;
     
     private XSimpleFileAccess2 sfa2;
diff -urNad '--exclude=CVS' '--exclude=.svn' '--exclude=.git' '--exclude=.arch' '--exclude=.hg' '--exclude=_darcs' '--exclude=.bzr' writer2latex-1.4~/source/java/writer2latex/latex/FieldConverter.java writer2latex-1.4/source/java/writer2latex/latex/FieldConverter.java
--- writer2latex-1.4~/source/java/writer2latex/latex/FieldConverter.java	2014-09-19 17:26:50.000000000 +0200
+++ writer2latex-1.4/source/java/writer2latex/latex/FieldConverter.java	2015-12-23 21:35:12.644079492 +0100
@@ -32,9 +32,6 @@
 import java.util.Vector;
 import java.util.regex.Pattern;
 
-import org.json.JSONArray;
-import org.json.JSONException;
-import org.json.JSONObject;
 import org.w3c.dom.Element;
 import org.w3c.dom.Node;
 
@@ -444,203 +441,6 @@
     
     // Try to handle this reference name as a Zotero reference, return true on success
     private boolean handleZoteroReferenceName(String sName, LaTeXDocumentPortion ldp, Context oc) {
-    	// First parse the reference name:
-    	// A Zotero reference name has the form ZOTERO_ITEM <json object> <identifier> with a single space separating the items
-    	// The identifier is a unique identifier for the reference and is not used here
-    	if (sName.startsWith(ZOTERO_ITEM)) {
-    		int nObjectStart = sName.indexOf('{');
-    		int nObjectEnd = sName.lastIndexOf('}');
-    		if (nObjectStart>-1 && nObjectEnd>-1 && nObjectStart<nObjectEnd) {
-    			String sJsonObject = sName.substring(nObjectStart, nObjectEnd+1);
-    			JSONObject jo = null;
-    			try {
-    				jo = new JSONObject(sJsonObject);
-    			} catch (JSONException e) {
-    				return false;
-    			}
-    			// Successfully parsed the reference, now generate the code
-    			// (we don't expect any errors and ignore them, if they happen anyway)
-
-    			// Sort key (purpose? currently ignored)
-    			/*boolean bSort = true;
-    			try {
-    				bSort = jo.getBoolean("sort");
-    			}
-    			catch (JSONException e) {
-    			}*/
-
-    			JSONArray citationItemsArray = null;
-    			try { // The value is an array of objects, one for each source in this citation
-    				citationItemsArray = jo.getJSONArray("citationItems");
-    			}
-    			catch (JSONException e) {	
-    			}
-
-    			if (citationItemsArray!=null) {
-    				int nCitationCount = citationItemsArray.length();
-    				
-    				if (bUseNatbib) {
-    					if (nCitationCount>1) {
-    						// For multiple citations, use \citetext, otherwise we cannot add individual prefixes and suffixes
-    						// TODO: If no prefixes or suffixes exist, it's safe to combine the citations
-    						ldp.append("\\citetext{");
-    					}
-
-    					for (int nIndex=0; nIndex<nCitationCount; nIndex++) {
-
-    						JSONObject citationItems = null;
-    						try { // Each citation is represented as an object
-    							citationItems = citationItemsArray.getJSONObject(nIndex);
-    						}
-    						catch (JSONException e) {
-    						}
-
-    						if (citationItems!=null) {
-    							if (nIndex>0) {
-    								ldp.append("; "); // Separate multiple citations in this reference
-    							}
-
-    							// Citation items
-    							String sURI = "";
-    							boolean bSuppressAuthor = false;
-    							String sPrefix = "";
-    							String sSuffix = "";
-    							String sLocator = "";
-    							String sLocatorType = "";
-
-    							try { // The URI seems to be an array with a single string value(?)
-    								sURI = citationItems.getJSONArray("uri").getString(0);
-    							}
-    							catch (JSONException e) {	
-    							}
-
-    							try { // SuppressAuthor is a boolean value
-    								bSuppressAuthor = citationItems.getBoolean("suppressAuthor");
-    							}
-    							catch (JSONException e) {	
-    							}
-
-    							try { // Prefix is a string value
-    								sPrefix = citationItems.getString("prefix");
-    							}
-    							catch (JSONException e) {	
-    							}
-
-    							try { // Suffix is a string value
-    								sSuffix = citationItems.getString("suffix");
-    							}
-    							catch (JSONException e) {	
-    							}
-
-    							try { // Locator is a string value, e.g. a page number
-    								sLocator = citationItems.getString("locator");
-    							}
-    							catch (JSONException e) {	
-    							}
-
-    							try {
-    								// LocatorType is a string value, e.g. book, verse, page (missing locatorType means page)
-    								sLocatorType = citationItems.getString("locatorType");
-    							}
-    							catch (JSONException e) {	
-    							}
-
-    							// Adjust locator type (empty locator type means "page")
-    							// TODO: Handle other locator types (localize and abbreviate): Currently the internal name (e.g. book) is used.
-    							if (sLocator.length()>0 && sLocatorType.length()==0) {
-    								// A locator of the form <number><other characters><number> is interpreted as several pages
-    								if (Pattern.compile("[0-9]+[^0-9]+[0-9]+").matcher(sLocator).find()) {
-    									sLocatorType = "pp.";
-    								}
-    								else {
-    									sLocatorType = "p.";
-    								}
-    							}
-
-    							// Insert command. TODO: Evaluate this
-    							if (nCitationCount>1) { // Use commands without parentheses
-    								if (bSuppressAuthor) { ldp.append("\\citeyear"); }
-    								else { ldp.append("\\citet"); }
-    							}
-    							else {
-    								if (bSuppressAuthor) { ldp.append("\\citeyearpar"); }
-    								else { ldp.append("\\citep"); }
-    							}
-
-    							if (sPrefix.length()>0) {
-    								ldp.append("[").append(palette.getI18n().convert(sPrefix,true,oc.getLang())).append("]");
-    							}
-
-    							if (sPrefix.length()>0 || sSuffix.length()>0 || sLocatorType.length()>0 || sLocator.length()>0) {
-    								// Note that we need to include an empty suffix if there's a prefix!
-    								ldp.append("[")
-    								.append(palette.getI18n().convert(sSuffix,true,oc.getLang()))
-    								.append(palette.getI18n().convert(sLocatorType,true,oc.getLang()));
-    								if (sLocatorType.length()>0 && sLocator.length()>0) {
-    									ldp.append("~");
-    								}
-    								ldp.append(palette.getI18n().convert(sLocator,true,oc.getLang()))
-    								.append("]");
-    							}
-
-    							ldp.append("{");
-    							int nSlash = sURI.lastIndexOf('/');
-    							if (nSlash>0) {
-    								ldp.append(sURI.substring(nSlash+1));
-    							}
-    							else {
-    								ldp.append(sURI);
-    							}
-    							ldp.append("}");
-    						}
-    					}
-
-    					if (nCitationCount>1) { // End the \citetext command
-    						ldp.append("}");
-    					}
-    				}
-    				else { // natbib is not available, use simple \cite command
-    					ldp.append("\\cite{");
-    					for (int nIndex=0; nIndex<nCitationCount; nIndex++) {
-    						JSONObject citationItems = null;
-    						try { // Each citation is represented as an object
-    							citationItems = citationItemsArray.getJSONObject(nIndex);
-    						}
-    						catch (JSONException e) {
-    						}
-
-    						if (citationItems!=null) {
-    							if (nIndex>0) {
-    								ldp.append(","); // Separate multiple citations in this reference
-    							}
-
-    							// Citation items
-    							String sURI = "";
-
-    							try { // The URI seems to be an array with a single string value(?)
-    								sURI = citationItems.getJSONArray("uri").getString(0);
-    							}
-    							catch (JSONException e) {	
-    							}
-
-    							int nSlash = sURI.lastIndexOf('/');
-    							if (nSlash>0) {
-    								ldp.append(sURI.substring(nSlash+1));
-    							}
-    							else {
-    								ldp.append(sURI);
-    							}
-    						}
-    					}
-						ldp.append("}");
-    				}
-    				
-    				oc.setInZoteroJabRefText(true);
-    				
-    				return true;
-    			}
-    		}
-    	}
     	return false;
     }
     
@@ -993,4 +793,4 @@
         return buf.toString();
     }
  
-}
\ No newline at end of file
+}
diff -urNad '--exclude=CVS' '--exclude=.svn' '--exclude=.git' '--exclude=.arch' '--exclude=.hg' '--exclude=_darcs' '--exclude=.bzr' writer2latex-1.4~/source/java/writer2latex/latex/SectionConverter.java writer2latex-1.4/source/java/writer2latex/latex/SectionConverter.java
--- writer2latex-1.4~/source/java/writer2latex/latex/SectionConverter.java	2014-09-09 20:18:24.000000000 +0200
+++ writer2latex-1.4/source/java/writer2latex/latex/SectionConverter.java	2015-12-23 21:35:12.644079492 +0100
@@ -26,9 +26,6 @@
 
 package writer2latex.latex;
 
-import org.json.JSONArray;
-import org.json.JSONException;
-import org.json.JSONObject;
 import org.w3c.dom.Element;
 import org.w3c.dom.Node;
 
@@ -65,64 +62,7 @@
     
     // Handle a section as a Zotero bibliography
     private boolean handleZoteroBibliography(Element node, LaTeXDocumentPortion ldp, Context oc) {
-    	String sName = node.getAttribute(XMLString.TEXT_NAME);
-    	if (config.useBibtex() && config.zoteroBibtexFiles().length()>0	&& sName.startsWith("ZOTERO_BIBL")) {
-    		// This section is a Zotero bibliography, and the user wishes to handle it as such
-        	// A Zotero bibliography name has the form ZOTERO_BIBL <json object> <identifier> with a single space separating the items
-        	// The identifier is a unique identifier for the bibliography and is not used here
-    		if (!config.noIndex()) {
-    			// Parse the name (errors are ignored) and add \nocite commands as appropriate
-        		int nObjectStart = sName.indexOf('{');
-        		int nObjectEnd = sName.lastIndexOf('}');
-        		if (nObjectStart>-1 && nObjectEnd>-1 && nObjectStart<nObjectEnd) {
-        			String sJsonObject = sName.substring(nObjectStart, nObjectEnd+1);
-        			JSONObject jo = null;
-        			try {
-        				jo = new JSONObject(sJsonObject);
-        			} catch (JSONException e) {
-        			}
-        			if (jo!=null) {
-        				JSONArray uncited = null;
-        				try {
-        					uncited = jo.getJSONArray("uncited");
-        				}
-        				catch (JSONException e) {
-        				}
-        				if (uncited!=null) {
-        					int nCount = uncited.length();
-        					if (nCount>0) {
-        						ldp.append("\\nocite{");
-        						for (int nIndex=0; nIndex<nCount; nIndex++) {
-        							if (nIndex>0) {
-        								ldp.append(",");
-        							}
-        							String sURI = null;
-        							try { // Each item is an array containing a single string
-        								sURI = uncited.getJSONArray(nIndex).getString(0);
-        							}
-        							catch (JSONException e) {
-        							}
-        							if (sURI!=null) {
-        								int nSlash = sURI.lastIndexOf('/');
-        								if (nSlash>0) { ldp.append(sURI.substring(nSlash+1)); }
-        								else { ldp.append(sURI); }
-        							}
-        						}
-        						ldp.append("}").nl();
-        					}
-        				}
-        			}
-        		}
-
-    			// Use the BibTeX style and files given in the configuration
-    			ldp.append("\\bibliographystyle{").append(config.bibtexStyle()).append("}").nl()
-    			.append("\\bibliography{").append(config.zoteroBibtexFiles()).append("}").nl();
-    		}
-    		return true;
-    	}
-    	else {
-    		return false;
-    	}
+	return false;
     }
     
     // Handle a section as a JabRef bibliography
diff -urNad '--exclude=CVS' '--exclude=.svn' '--exclude=.git' '--exclude=.arch' '--exclude=.hg' '--exclude=_darcs' '--exclude=.bzr' writer2latex-1.4~/source/readme-source.txt writer2latex-1.4/source/readme-source.txt
--- writer2latex-1.4~/source/readme-source.txt	2015-02-16 16:32:08.000000000 +0100
+++ writer2latex-1.4/source/readme-source.txt	2015-12-23 21:35:12.644079492 +0100
@@ -27,24 +27,6 @@
 Third-party software
 --------------------
 
-From JSON.org:
-
-The classes org.json.* are copyright (c) 2002 JSON.org and is used subject to the following notice
-
-Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files
-(the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge,
-publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do
-so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
-
-The Software shall be used for Good, not Evil.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
-OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
-CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 
-
 From iharder.sourceforge.net:
 
 The class writer2latex.util.Base64 is Robert Harders public domain Base64 class
