Coder Social home page Coder Social logo

barcode-java's People

Contributors

barnhill avatar carldea avatar douglasyang avatar redsoft7 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

barcode-java's Issues

Lib can't be pulled from Maven since 2.2

hello,

Thanks for the library, I'm using it from quite a long time and it works nice!

I was using the 1.x branch and wanted to switch to the latest (2.6.1) but I see the artifacts are hosed since 2.2. I get the error:
The following artifacts could not be resolved: com.pnuema.java:barcode:jar:2.6.1 (absent) when using the dependency example shown in the README.

If I check on mvnrepository, it's ok in 2.1:
image
image

But in 2.2, it's not published the same we see a -jar.jar:
image
image

I see a commit mentioning a classifier change which is certainly the -jar is all about.
I did not add the dependency in a fancy way but it does not see to work anymore from 2.2 onwards.

best regards,
--Stef

EAN13 standardized label broken

When creating a EAN13 with standardized label something is broken with the computation of the white boxes and the font heights. Especially is looks like setFont() is never called internally in this code flow and defaults to something

        Barcode b = new Barcode();
        b.setIncludeLabel(true);
        b.setLabelFont(new Font("Monospace", Font.PLAIN, 25));
        // EAN13 "standardized label tries to separate the digits and blank out the lower bounds of two
        // blocks in the EAN, to look like what we find on some products. however it fails to adjust the font
        // size and looks awful
        b.setStandardizeLabel(true); //change to false and it looks ok, but not "standardized"
        BufferedImage img = (BufferedImage) b.encode(Barcode.TYPE.EAN13, val);

Bildschirmfoto 2021-07-07 um 17 44 10
Bildschirmfoto 2021-07-07 um 17 45 06

version: 'com.pnuema.java:barcode:1.10'

Example does not work

This code just produces a solid
barcode with no text, it is not teh same as the sample image.

Barcode barcode = new Barcode(); Image img = barcode.encode(BarcodeLib.TYPE.UPCA, "038000356216");

Maven dependency

Maven dependency is not available.

com.pnuema.java
barcode
1.1

Dependecy com.pnuema.java.barcode:1.1 not found

The LabelPositions.TOP does not work.

The line 914 in barcode.java.

if ((getLabelPosition().ordinal() & Labels.LabelPositions.TOP.ordinal()) > 0)

Labels.LabelPositions.TOP.ordinal() is 0, So it is always 0. Maybe we just check the enum not enum's value.

Pharmacode with values 3,4,5,7,8,9 doesn't encode correctly

When generating a pharmacode barcode with the value 3 or 4 or 5 then I only seem to get a solid black box, i.e. a single barcode line that fills the area I specify.

When generating a pharmacode barcode with the value 6, I correctly get a wide bar, space and wide bar, however, generating with 7 or 8 or 9 also gives the same barcode as when using 6 as the value.

S2of5 encoding is wrong

10101110111010 in position 8 is incorrect and this corresponds to the value for 0. Move this to the front of the list and it should correct this issue

Installation Problem

Hi Brad
I got some error when trying to run the project
Is there some settings to make before using it?

image

Code 128 does not encode correctly

Does not encode
905216900040000000045771410179249000474750

correctly as a standard C128 barcode. Its starting with the CODE_A char which is incorrect as this is all numeric and should detect that and use CODE_C

Get String encoded value

Im trying to use the library for get the encoded value for use with a barcode font type.

If I get the encoded value (for example for Code128):
new Code128(value).getEncodedValue()

Im getting a String with a binary content. For example I have this data:
value - expected - encodedValue
0 - Ì01Î - 1101000010010011101100100111011001100011101011
93 -Í}ÃÎ - 1101001110010100011110101111010001100011101011
95 - ÍÃÅÎ - 1101001110010111101000111101010001100011101011
400000 - ÍHÂÂJÎ - 11010011100110001010001101100110011011001100101101110001100011101011

Any way to convert this binary output to a string for use with a barcode font type?

allow for customizable margin (feature request)

when the barcode is embedded on some background, the scanner gun will need some "peace space" (white border) in order to recognize the barcode regardless of the background. this should be an option to have.
could look like

b.setMargin(10)

or even

b.setMargin(10,10,10,15)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.