From 3be4cf4fa8308aa139cce9b019f15c6436614688 Mon Sep 17 00:00:00 2001 From: fengyuecanzhu <1021300691@qq.com> Date: Thu, 3 Dec 2020 20:37:17 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=B0=E5=A2=9E=E4=B9=A6=E7=B1=8D=E5=88=86?= =?UTF-8?q?=E4=BA=AB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .idea/caches/build_file_checksums.ser | Bin 537 -> 537 bytes .../xyz/fycz/myreader/common/APPCONST.java | 4 +-- .../xyz/fycz/myreader/widget/page/TxtChar.kt | 26 ++++++++++++++++++ .../xyz/fycz/myreader/widget/page/TxtLine.kt | 23 ++++++++++++++++ 4 files changed, 51 insertions(+), 2 deletions(-) create mode 100644 app/src/main/java/xyz/fycz/myreader/widget/page/TxtChar.kt create mode 100644 app/src/main/java/xyz/fycz/myreader/widget/page/TxtLine.kt diff --git a/.idea/caches/build_file_checksums.ser b/.idea/caches/build_file_checksums.ser index ba3975bb40ea40627241aa700b7ca9e0c4165f2e..002ef3ba56da218b1f5014639b45fc26f82fe701 100644 GIT binary patch delta 36 ucmV+<0NekW1epYom;@-7(Acq@J^>I%@Y`*7bwm*@NXP%k4WSQ{>H#kveGiua delta 36 ucmV+<0NekW1epYom;@9|nw_znJ^>JDi<{kSi~{4@9ewbYDeo$i>H#kjcn`|} diff --git a/app/src/main/java/xyz/fycz/myreader/common/APPCONST.java b/app/src/main/java/xyz/fycz/myreader/common/APPCONST.java index db52a95..7b95886 100644 --- a/app/src/main/java/xyz/fycz/myreader/common/APPCONST.java +++ b/app/src/main/java/xyz/fycz/myreader/common/APPCONST.java @@ -10,10 +10,10 @@ import java.io.File; public class APPCONST { - public static String publicKey = "fyds1.0";//服务端公钥 + public static String publicKey = "";//服务端公钥 public static String privateKey;//app私钥 public final static String s = "11940364935628058505"; - public static final String KEY = "readerByFengyue"; + public static final String KEY = ""; public static final String ALARM_SCHEDULE_MSG = "alarm_schedule_msg"; diff --git a/app/src/main/java/xyz/fycz/myreader/widget/page/TxtChar.kt b/app/src/main/java/xyz/fycz/myreader/widget/page/TxtChar.kt new file mode 100644 index 0000000..f1cc31b --- /dev/null +++ b/app/src/main/java/xyz/fycz/myreader/widget/page/TxtChar.kt @@ -0,0 +1,26 @@ +package xyz.fycz.myreader.widget.page2 + +import android.graphics.Point + + +class TxtChar { + var chardata: Char = ' '//字符数据 + + var selected: Boolean? = false//当前字符是否被选中 + + //记录文字的左上右上左下右下四个点坐标 + var topLeftPosition: Point? = null//左上 + var topRightPosition: Point? = null//右上 + var bottomLeftPosition: Point? = null//左下 + var bottomRightPosition: Point? = null//右下 + + var charWidth = 0f//字符宽度 + var Index = 0//当前字符位置 + + override fun toString(): String { + return ("ShowChar [chardata=" + chardata + ", Selected=" + selected + ", TopLeftPosition=" + topLeftPosition + + ", TopRightPosition=" + topRightPosition + ", BottomLeftPosition=" + bottomLeftPosition + + ", BottomRightPosition=" + bottomRightPosition + ", charWidth=" + charWidth + ", Index=" + Index + + "]"); + } +} \ No newline at end of file diff --git a/app/src/main/java/xyz/fycz/myreader/widget/page/TxtLine.kt b/app/src/main/java/xyz/fycz/myreader/widget/page/TxtLine.kt new file mode 100644 index 0000000..15c58c8 --- /dev/null +++ b/app/src/main/java/xyz/fycz/myreader/widget/page/TxtLine.kt @@ -0,0 +1,23 @@ +package xyz.fycz.myreader.widget.page2 + +class TxtLine { + + var charsData: List? = null + + fun getLineData(): String { + var linedata = "" + if (charsData == null) return linedata + charsData?.let { + if (it.isEmpty()) return linedata + for (c in it) { + linedata += c.chardata + } + } + return linedata + } + + override fun toString(): String { + return "ShowLine [Linedata=" + getLineData() + "]" + } + +} \ No newline at end of file