Android Codabar Generator generate, create barcode Codabar images in Android application

Codabar Generator for Android to Generate Codabar Barcodes in Android Application using Android Barcode Generator Library

  • Android Codabar generation api is provided with the Android barcode generator
  • Developed from Java Codabar barcode generator
  • Compatible with Android 1.5 SDK and later versions
  • Easy to add the Codabar generation feature into Android apps
  • Generate high quality Codabar barcode with the Android Codabar SDK
  • GIF, JPEG, and PNG are supported by the Android Codabar Barcode Generator
  • Reliable and mature Android barcode library for Codabar generation
  • Compatible with the latest Codabar barcode symbology standard
  • Android Codabar source code is available for the purchase of the Source Code license


Index
 

Android Codabar Barcode Generator Introduction

Android Codabar barcode API is a Codabar generator for Android apps, designed for creating Codabar barcode on Android platform.

  • Android Codabar SDK is entirely developed for Android platform
  • Android Codabar generator is completely built in Android 1.5 SDK
  • Developer Licenses for this Android Codabar library are royalty-free and perpetual

Codabar is a linear barcode symbology developed in 1972 by Pitney Bowes Corp. It is also known as Codeabar, Ames Code, NW-7, Monarch, Code 2 of 7, Rationalized Codabar, ANSI/AIM BC3-1995 or USD-4.

We provide multiple Codabar Generator libraries, SDK and applications, including .NET Codabar, Java Codabar, C# Codabar, VB.NET Codabar, ASP.NET Codabar, Codabar Generator.

 

Codabar Valid Data Scope

Android Barcode Codabar supports 16 letters.

  • 0, 1, 2, 3, 4, 5, 6, 7, 8, 9
  • - (Dash), $ (Dollar), : (Colon), / (Slash), . (Point), + (Plus)

 

How to generate Codabar barcodes in your Android application?

Generating barcode Codabar in Java Class example

	Codabar barcode = new Codabar();
	    
	// barcode data to encode
	/*
	               Codabar Valid data char set:
	                    - (Dash), $ (Dollar), : (Colon), / (Slash), . (Point), + (Plus)
	                    0, 1, 2, 3, 4, 5, 6, 7, 8, 9
	            */
	barcode.setData("112233445566");
	    
	// Codabar Start & Stop Char, Valid values are 'A', 'B', 'C', 'D'
	barcode.setStartChar('A');
	barcode.setStopChar('A');
	    
	// Unit of Measure, pixel, cm, or inch
	barcode.setUom(IBarcode.UOM_PIXEL);
	// barcode bar module width (X) in pixel
	barcode.setX(1f);
	// barcode bar module height (Y) in pixel
	barcode.setY(75f);
	    
	// barcode image margins
	barcode.setLeftMargin(10f);
	barcode.setRightMargin(10f);
	barcode.setTopMargin(10f);
	barcode.setBottomMargin(10f);
	    
	// barcode image resolution in dpi
	barcode.setResolution(72);
	    
	// disply barcode encoding data below the barcode
	barcode.setShowText(true);
	// barcode encoding data font style
	barcode.setTextFont(new AndroidFont("Arial", Typeface.NORMAL, 12));
	// space between barcode and barcode encoding data
	barcode.setTextMargin(6);
	barcode.setTextColor(AndroidColor.black);
	    
	// barcode bar color and background color in Android device
	barcode.setForeColor(AndroidColor.black);
	barcode.setBackColor(AndroidColor.white);
	
	/*
	      specify your barcode drawing area
	    */
	RectF bounds = new RectF(30, 30, 0, 0);
	barcode.drawBarcode(canvas, bounds);
 

Android Codabar Barcode Properties

Codabar Barcode Java Class: com.onbarcode.barcode.android.Codabar.

Category Properties Value Comments
Basic Property: data Type: String
Default: ""
Barcode value to encode.

Codabar Valid Data Char Set:

  • - (Dash), $ (Dollar), : (Colon), / (Slash), . (Point), + (Plus)

  • 0, 1, 2, 3, 4, 5, 6, 7, 8, 9

Property: addCheckSum Type: boolean
Default: false
addCheckSum property is not applied here. Codabar does not require any checksum.
 
Codabar
Special
Property: startChar Type: char
Default: 'A'
Codabar start char, valid values: 'A', 'B', 'C', 'D'
Property: stopChar Type: char
Default: 'A'
Codabar stop char, valid values: 'A', 'B', 'C', 'D'
Property: N Type: float
Default: 2.0f
Wide/narrow ratio, 2.0 - 3.0 inclusive, default is 2.
 
Barcode
Size
Related
Property: autoResize Type: boolean
Default: false
Auto resize the generated barcode image
Property: barAlignment Type: int
Default: 1 (center)
Barcode horizontal alignment inside the image. 0: left, 1: center, 2: right.
Property: uom Type: int
Default: 0 (pixel)
Unit of meature for all size related settings in the library.
Valid values: 0: pixel; 1: inch; 2: cm.
Property: X Type: float
Default: 1
Width of barcode bar module (narrow bar), default is 1 pixel
Property: Y Type: float
Default: 30
Height of barcode bar module, default is 30 pixel
Property: barcodeWidth Type: float
Default: 0
Barcode image width.

If barcodeWidth setting is smaller than the barcode required minimum width, the library will automatically reset to barcode minimum width.
Property: barcodeHeight Type: float
Default: 0
Barcode image height.

If barcodeHeight setting is smaller than the barcode required minimum height, the library will automatically reset to barcode minimum height.
Property: leftMargin Type: float
Default: 0
Barcode image left margin size.
Property: rightMargin Type: float
Default: 0
Barcode image right margin size.
Property: topMargin Type: float
Default: 0
Barcode image top margin size.
Property: bottomMargin Type: float
Default: 0
Barcode image bottom margin size.
Property: resolution Type: int
Default: 72
Barcode image resolution in DPI (Dots per inch).
Property: rotate Type: int
Default: 0 (IBarcode.ROTATE_0)
Valid values:

  • 0 (IBarcode.ROTATE_0)
  • 1 (IBarcode.ROTATE_90)
  • 2 (IBarcode.ROTATE_180)
  • 3 (IBarcode.ROTATE_270)
 
Barcode
Colors
Property: backColor Type: AndroidColor
Default: AndroidColor.white
Barcode image background color
Property: foreColor Type: AndroidColor
Default: AndroidColor.black
Barcode image foreground color
 
Font
Style
Property: showText Type: boolean
Default: true
If true, display barcode data text under the barcode, otherwise do not display.
Property: textFont Type: AndroidFont
Default:
new AndroidFont("Arial", Typeface.NORMAL, 11)
Barcode text font style.
Property: textMargin Type: float
Default: 6
Space between barcode and barcode data text, default is 6 pixel
Property: textColor Type: AndroidColor
Default: AndroidColor.black
Barcode text color









OnBarcode is a market-leading provider of barcode generator, reader controls and components for ASP.NET, Windows Forms, WPF, as well Java, Android, iOS (iPhone, iPad) across all major enterprise development platforms. We provides high quality tutorials and guides for various linear, 2d barcode information, such as C# Barcode, QR Code C#, QR Code VB.NET, QR Code ASP.NET, QR Code .NET, ASP.NET Barcode. OnBarcode barcode products are supported by RasterEdge .NET HTML5 Document Viewer high quality C# Convert PDF to Tiff, C# Convert PDF to Word, C# Convert PDF to HTML, C# Convert PDF to Jpeg images, and their easy and simple documents, like C# PDF SDK, C# extract text from PDF, C# Compress PDF, Print PDF in C# and C# extract image from PDF.
Terms of Use | Privacy Policy
Copyright © OnBarcode.com . All rights reserved.