我正在开发一个小应用程序,我可以生成一个条形码列表.我的计算机上安装了正确的字体.现在我将它们直接打印到网页上,它可以在Chrome和IE 7中正常运行,但不适用于Firefox.有谁知道Firefox与IE和Chrome有什么不同?
这是我的代码:
<html>
<head>
<title>Barcode Font Test</title>
<style type="text/css" media="screen">
.barcode { font-family: "wasp 39 m", verdana, calibri; font-size: 36pt; }
</style>
</head>
<body>
<div class="barcode">*574656*</div>
</body>
</html>
Run Code Online (Sandbox Code Playgroud)
编辑: 我可能应该提到,这更像是一个个人项目,并不打算发布到世界各地.虽然我会采取一个有效的解决方案,但我想要一些不涉及Javascript/Flash /等的东西.
我有条形码扫描仪和笔记本电脑(当然:)),我正在寻找简单的事件管理应用程序,可以处理条形码扫描仪的输入,并保持我们频繁的私人会议的出勤记录.
我想知道是否有可用的开源软件允许我使用代码128条形码ID卡管理事件?
非常感谢您的帮助.
在阅读维基百科关于条形码的文章后,我了解到有大量的2D和线性条形码.我熟悉的一种格式是QR码.
线性和二维条码的最大存储容量是多少?
我有条形码图像.我必须让它变小.
这会损坏条形码吗?
比例缩放
不成比例缩放(仅高度变化)
条形码是:输入UPC-A/EAN-13"垂直线".对不起条形码的专家,认为条形码的类型不重要.缩放适中,图像不会丢失相关数据.
Font f = new Font("Free 3 of 9", 80);
this.Font = f;
Label l = new Label();
l.Text = "*STACKOVERFLOW*";
l.Size = new System.Drawing.Size(800, 600);
this.Controls.Add(l);
this.Size = new Size(800, 600);
Run Code Online (Sandbox Code Playgroud)
它的工作.我看到条形码,我能够扫描它.现在我想使用其他东西,比如Code 128因为我需要安装Font(完成)并且只是改变
Font f = new Font("Free 3 of 9", 80); 至 Font f = new Font("Code 128", 80);
之后我在窗口看到条形码.问题是我无法扫描它.我认为那是因为我没有使用正确的开始和停止标签的条形码.据我所知,必须始终有一个开始/停止char或其他什么.对于Code 128的*中的3个我不确定.在维基上有开始代码A所以我试过
Font f = new Font("<Start Code A>test<Stop>", 80);,Font f = new Font("<Start Code …
我有一个关于打印条形码附加信息的问题.我正在使用http://barbecue.sourceforge.net/来创建我的条形码.
在我创建条形码后,我想添加一些额外的信息.目前我用以下方式做到这一点!例如:
Graphics2D g2d5 = container4Barcode.createGraphics();
g2d5.setBackground(Color.WHITE);
g2d5.clearRect(0, 33, 200, 200);
g2d5.setColor(Color.BLACK);
g2d5.setRenderingHint(RenderingHints.KEY_TEXT_ANTIALIASING,
RenderingHints.VALUE_TEXT_ANTIALIAS_ON);
g2d5.setRenderingHint(RenderingHints.KEY_TEXT_ANTIALIASING,
RenderingHints.VALUE_TEXT_ANTIALIAS_GASP);
g2d5.setFont(new Font("Arial", Font.PLAIN, 8));
g2d5.drawString(barcode, 8, 40);
g2d5.drawString(generateRandomNumber(ekPreis), 57, 40);
String datumResult = datum;
g2d5.drawString(location, 98, 40);
g2d5.drawString(datum.substring(2), 114, 40);
g2d5.dispose();
Run Code Online (Sandbox Code Playgroud)
输出结果如下:

正如你所看到的那样,我的文本质量(条形码上方和下方)非常糟糕......我怎样才能提高文本质量,使文本更加流畅而不是像素化?!
(当我打印我的条形码时,条形码看起来非常像素化......)
有小费吗?
更新:
所以,我在这里添加了我最新结果的图片......当我打印出这些条形码时,它们看起来很可怕!以下是我所做的代码:
Graphics2D g2d6 = container4Barcode.createGraphics();
g2d6.setColor(Color.black);
g2d6.setRenderingHint(RenderingHints.KEY_TEXT_ANTIALIASING,
RenderingHints.VALUE_TEXT_ANTIALIAS_ON);
g2d6.setFont(new Font("Verdana", Font.BOLD, 7));
g2d6.drawString("FLORETT", 9, 20);
g2d6.drawString("50-521-60", 57, 20);
Graphics2D g2d4 = container4Barcode.createGraphics();
g2d4.setColor(Color.black);
g2d4.setRenderingHint(RenderingHints.KEY_TEXT_ANTIALIASING,
RenderingHints.VALUE_TEXT_ANTIALIAS_ON);
g2d4.setRenderingHint(RenderingHints.KEY_FRACTIONALMETRICS,
RenderingHints.VALUE_FRACTIONALMETRICS_ON);
g2d4.setFont(new Font("Verdana", Font.BOLD, 11));
g2d4.drawString("SSYYS", 105, 19);
g2d4.dispose();
Run Code Online (Sandbox Code Playgroud)
有了该代码,我获得了最好的结果!当然我玩"Metrics,AA_GASP,LCS_HRGB,不同的字体(Verdana在我看来是最好的)......"还有更多,但其中一些我无法使用,因为那时我的条形码变得模糊了!因此,我正在强迫我无法从graphics2d提高我的文本质量的束带的问题! …
我想在我的应用程序中实现QR Code/Barcode阅读器.我想知道什么是最轻量级的解决方案(无视zxing的意图集成商).
我一直在开发一个Android应用程序来扫描条形码和QR码并将结果发送到其他应用程序(HTTP).我已经通过互联网阅读了大部分文档,并且在堆栈中通过流程阅读并使其正常工作.我能够在我的设备上运行独立的zxing android应用程序,我也可以运行我自己的独立Android应用程序来使用Zxing意图扫描条形码.但即使在这里阅读了这么多问题以及互联网上的一些博客之后,我也无法满足我的严格要求.
我想实现以下目标.1.我不想在我的设备中安装单独的条形码扫描仪应用程序以使我自己的应用程序工作(扫描条形码).我使用了以下代码
Intent intent = new Intent("com.google.zxing.client.android.SCAN");
startActivityForResult(intent, 0);
Run Code Online (Sandbox Code Playgroud)
当我在我的设备中运行应用程序时,它会询问"选择应用程序以完成此操作"并显示"Google"和"Google Goggles"并打开Google页面默认摄像头并扫描条形码.我希望CaptureActivtiy默认捕获页面(不是Google的)来扫描条形码.3.我尝试在我自己的应用程序中使用ZXing作为库,但它没有用.
你能告诉我到底哪里出错吗?
我正在研究构建一个13位数的EAN条形码扫描器,该扫描器可在移动设备上的网络上运行,并将使用设备相机拍摄条形码图像进行扫描和解码.我不是想通过原生应用程序来做这件事,因为我更愿意将这部分作为我的原生网站搜索体验.例如,移动设备上的网站访问者将被提示扫描条形码而无需打开应用程序.
此脚本在桌面https://github.com/EddieLa/JOB上运行良好,并使用Navigator.getUserMedia属性在JavaScript中完成所有这些操作,但Android中的支持才刚刚开始,并且IOS上的支持不存在http:// caniuse.com/#feat=stream
所以我想知道我是否可以改为支持移动设备,这是我想要做的事情的全部内容,而不是在浏览器中读取条形码,拍下条形码的照片,通过以下方式将其发送到服务器Ajax,让服务器解码图像并将响应发送回网页.
通过这种方法,我知道有些python脚本可以读取条形码,例如https://pypi.python.org/pypi/zbar,但是它有PHP等价吗?
我一直在实施Apple在WWDC2017中引入的新Vision框架的测试.我特别关注条形码检测 - 我从相机/图库扫描图像后得知这是条形码图像.但是,在查看barcodeDescriptor时,我无法看到实际的条形码值或有效负载数据.https://developer.apple.com/documentation/coreimage/cibarcodedescriptor页面上似乎没有任何内容可以识别任何属性.
我收到这些错误:
- 无法连接到远程服务:错误域= NSCocoaErrorDomain代码= 4097"连接到名为
com.apple.BarcodeSupport.BarcodeNotificationService的服务"- libMobileGestalt MobileGestalt.c:555:无法访问InverseDeviceID(请参阅问题/ 11744455>)
- 连接到名为com.apple.BarcodeSupport.BarcodeNotificationService的服务错误
域= NSCocoaErrorDomain代码= 4097
有没有办法从VNBarcodeObservation访问条形码值?任何帮助将不胜感激.谢谢!这是我正在使用的代码:
@IBAction func chooseImage(_ sender: Any) {
imagePicker.allowsEditing = true
imagePicker.sourceType = .photoLibrary
present(imagePicker, animated: true, completion: nil)
}
@IBAction func takePicture(_ sender: Any) {
if(UIImagePickerController .isSourceTypeAvailable(UIImagePickerControllerSourceType.camera)){
imagePicker.sourceType = UIImagePickerControllerSourceType.camera
self .present(imagePicker, animated: true, completion: nil)
}
else{
let alert = UIAlertController(title: "Warning", message: "Camera not available", preferredStyle: UIAlertControllerStyle.alert)
alert.addAction(UIAlertAction(title: "Dismiss", style: UIAlertActionStyle.default, handler: nil))
self.present(alert, animated: true, completion: nil)
}
}
//PickerView …Run Code Online (Sandbox Code Playgroud) barcode ×10
android ×2
php ×2
qr-code ×2
.net ×1
apple-vision ×1
c# ×1
css ×1
fonts ×1
graphics2d ×1
html ×1
image ×1
ios11 ×1
java ×1
javascript ×1
open-source ×1
rendering ×1
scaling ×1
storage ×1
swift4 ×1
windows ×1
xcode9-beta ×1
xhtml ×1
zxing ×1