mirror of
				https://github.com/subsurface/subsurface.git
				synced 2025-02-19 22:16:15 +00:00 
			
		
		
		
	Allow comma separated CSV files
The separator selector in the CSV import dialog was unused. This passes the value into the xslt and adds ',' as possible value. I'm sure this could be done much better (pass the actual character instead of the index), but I couldn't get that to work and this does seem to do the trick. Also added a test dive to test this feature. Fixes #321 Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
		
							parent
							
								
									5fc50b2aab
								
							
						
					
					
						commit
						b5d3476b0b
					
				
					 5 changed files with 43 additions and 4 deletions
				
			
		|  | @ -11,11 +11,17 @@ | |||
|   <xsl:param name="stopdepthField" select="stopdepthField"/> | ||||
|   <xsl:param name="date" select="date"/> | ||||
|   <xsl:param name="time" select="time"/> | ||||
|   <xsl:param name="separatorIndex" select="separatorIndex"/> | ||||
|   <xsl:output method="xml" indent="yes"/> | ||||
| 
 | ||||
|   <xsl:variable name="lf"><xsl:text> | ||||
| </xsl:text></xsl:variable> | ||||
|   <xsl:variable name="fs"><xsl:text>	</xsl:text></xsl:variable> | ||||
|   <xsl:variable name="fs"> | ||||
|     <xsl:choose> | ||||
|       <xsl:when test="$separatorIndex = 0"><xsl:text>	</xsl:text></xsl:when> | ||||
|       <xsl:otherwise><xsl:text>,</xsl:text></xsl:otherwise> | ||||
|     </xsl:choose> | ||||
|   </xsl:variable> | ||||
| 
 | ||||
|   <xsl:template match="/"> | ||||
|     <divelog program="subsurface-import" version="2"> | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue