Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion ios/Classes/Method/BrotherUtils.m
Original file line number Diff line number Diff line change
Expand Up @@ -1277,6 +1277,7 @@ + (BRLMPTPrintSettings *)ptPrintSettingsFromMapWithValue:(NSDictionary<NSString
bool cutmarkPrint = [[map objectForKey:@"isCutMark"] isEqual:@(YES)];
bool autoCut = [[map objectForKey:@"isAutoCut"] isEqual:@(YES)];
bool halfCut = [[map objectForKey:@"isHalfCut"] isEqual:@(YES)];
bool chainPrint = [[map objectForKey:@"chainPrint"] isEqual:@(YES)];
bool specialTapePrint = [[map objectForKey:@"isSpecialTape"] isEqual:@(YES)];

NSDictionary<NSString *, NSObject *> * dartResolution = (NSDictionary<NSString *, NSObject *> *)[map objectForKey:@"printQuality"];
Expand All @@ -1291,8 +1292,9 @@ + (BRLMPTPrintSettings *)ptPrintSettingsFromMapWithValue:(NSDictionary<NSString
printerSettings.cutmarkPrint = cutmarkPrint;
printerSettings.autoCut = autoCut;
printerSettings.halfCut = halfCut;
printerSettings.chainPrint = chainPrint;
printerSettings.specialTapePrint = specialTapePrint;
printerSettings.resolution = [BrotherUtils printResolutionFromMapWithValue:dartResolution];
printerSettings.printQuality = [BrotherUtils printResolutionFromMapWithValue:dartResolution];
printerSettings.forceVanishingMargin = forceVanishingMargin;
printerSettings.printOrientation = [BrotherUtils orientationFromMapWithValue:dartOrientation];

Expand Down Expand Up @@ -2242,6 +2244,7 @@ + (NSString *) colorTypeToNameWithValue:(ColorType) colorType {
@"isHalfCut": @FALSE, // TODO
@"isSpecialTape": @FALSE, // TODO
@"isCutMark": @FALSE, // TODO
@"chainPrint": @FALSE, // TODO
@"labelColor": [BrotherUtils colorTypeToMapWithValue:[status labelColor]],
@"labelFontColor": [BrotherUtils colorTypeToMapWithValue:[status fontColor]],
@"labelType": [BrotherUtils labelIdTypeToNumberWithValue: [status labelID ]]
Expand Down
5 changes: 5 additions & 0 deletions lib/label_info.dart
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ class LabelInfo {
bool isHalfCut = false;
bool isSpecialTape = false;
bool isCutMark = false;
bool chainPrint = false;
LabelColor labelColor;
LabelColor labelFontColor;
int labelType = -1;
Expand All @@ -18,6 +19,7 @@ class LabelInfo {
this.isHalfCut = false,
this.isSpecialTape = false,
this.isCutMark = false,
this.chainPrint = false,
this.labelColor = LabelColor.UNSUPPORT,
this.labelFontColor = LabelColor.UNSUPPORT,
this.labelType = -1});
Expand All @@ -30,6 +32,7 @@ class LabelInfo {
isHalfCut: map["isHalfCut"],
isSpecialTape: map["isSpecialTape"],
isCutMark: map["isCutMark"],
chainPrint: map["chainPrint"],
labelColor: LabelColor.fromMap(map["labelColor"]),
labelFontColor: LabelColor.fromMap(map["labelFontColor"]),
labelType: map["labelType"],
Expand All @@ -45,6 +48,7 @@ class LabelInfo {
"isHalfCut" : isHalfCut,
"isSpecialTape" : isSpecialTape,
"isCutMark" : isCutMark,
"chainPrint" : chainPrint,
"labelColor" : labelColor.toMap(),
"labelFontColor": labelFontColor.toMap(),
"labelType": labelType
Expand All @@ -59,6 +63,7 @@ class LabelInfo {
"isHalfCut $isHalfCut, "
"isSpecialTape $isSpecialTape, "
"isCutMark $isCutMark, "
"chainPrint $chainPrint, "
"labelColor $labelColor, "
"labelFontColor $labelFontColor, "
"labelType $labelType}";
Expand Down
6 changes: 6 additions & 0 deletions lib/printer_info.dart
Original file line number Diff line number Diff line change
Expand Up @@ -1473,6 +1473,7 @@ class PrinterInfo {
bool isCutAtEnd;
bool isSpecialTape;
bool isHalfCut;
bool chainPrint;
bool mode9;
PrintQuality printQuality;
bool mirrorPrint;
Expand Down Expand Up @@ -1516,6 +1517,7 @@ class PrinterInfo {
this.paperPosition = Align.CENTER,
this.isAutoCut = true,
this.isCutAtEnd = true,
this.chainPrint = false,
this.mode9 = true,
this.skipStatusCheck = false,
this.checkPrintEnd = CheckPrintEnd.CPE_CHECK,
Expand Down Expand Up @@ -1602,6 +1604,7 @@ class PrinterInfo {
paperPosition: Align.fromMap(map["paperPosition"]),
isAutoCut: map["isAutoCut"],
isCutAtEnd: map["isCutAtEnd"],
chainPrint: map["chainPrint"],
mode9: map["mode9"],
skipStatusCheck: map["skipStatusCheck"],
checkPrintEnd: CheckPrintEnd.fromMap(map["checkPrintEnd"]),
Expand Down Expand Up @@ -1665,6 +1668,7 @@ class PrinterInfo {
"paperPosition": paperPosition.toMap(),
"isAutoCut": isAutoCut,
"isCutAtEnd": isCutAtEnd,
"chainPrint": chainPrint,
"mode9": mode9,
"skipStatusCheck": skipStatusCheck,
"checkPrintEnd": checkPrintEnd.toMap(),
Expand Down Expand Up @@ -2089,6 +2093,7 @@ class LabelParam {
bool isHalfCut = false;
bool isSpecialTape = false;
bool isCutMark = false;
bool chainPrint = false;
int tubeHeadPinNum = 0;
String paperName;
String paperNameInch;
Expand Down Expand Up @@ -2177,6 +2182,7 @@ class LabelParam {
"isHalfCut $isHalfCut, "
"isSpecialTape $isSpecialTape,"
"isCutMark $isCutMark,"
"chainPrint $chainPrint,"
"tubeHeadPinNum $tubeHeadPinNum, "
"paperName $paperName, "
"paperNameInch $paperNameInch, "
Expand Down
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: another_brother
description: A flutter plugin for printing with the Brother label and TypeB printers.
version: 2.1.3
version: 2.1.5
repository: https://github.com/CodeMinion/another_brother

environment:
Expand Down