CN111508039B - Word processing method of ink screen and communication terminal - Google Patents

Word processing method of ink screen and communication terminal Download PDF

Info

Publication number
CN111508039B
CN111508039B CN202010312055.1A CN202010312055A CN111508039B CN 111508039 B CN111508039 B CN 111508039B CN 202010312055 A CN202010312055 A CN 202010312055A CN 111508039 B CN111508039 B CN 111508039B
Authority
CN
China
Prior art keywords
gray level
gray
text
ink screen
display page
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202010312055.1A
Other languages
Chinese (zh)
Other versions
CN111508039A (en
Inventor
修平
步晨
梅正怡
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Hisense Mobile Communications Technology Co Ltd
Original Assignee
Hisense Mobile Communications Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hisense Mobile Communications Technology Co Ltd filed Critical Hisense Mobile Communications Technology Co Ltd
Priority to CN202010312055.1A priority Critical patent/CN111508039B/en
Publication of CN111508039A publication Critical patent/CN111508039A/en
Application granted granted Critical
Publication of CN111508039B publication Critical patent/CN111508039B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/90Determination of colour characteristics
    • GPHYSICS
    • G09EDUCATION; CRYPTOGRAPHY; DISPLAY; ADVERTISING; SEALS
    • G09FDISPLAYING; ADVERTISING; SIGNS; LABELS OR NAME-PLATES; SEALS
    • G09F9/00Indicating arrangements for variable information in which the information is built-up on a support by selection or combination of individual elements
    • G09F9/30Indicating arrangements for variable information in which the information is built-up on a support by selection or combination of individual elements in which the desired character or characters are formed by combining individual elements
    • G09F9/37Indicating arrangements for variable information in which the information is built-up on a support by selection or combination of individual elements in which the desired character or characters are formed by combining individual elements being movable elements
    • G09F9/372Indicating arrangements for variable information in which the information is built-up on a support by selection or combination of individual elements in which the desired character or characters are formed by combining individual elements being movable elements the positions of the elements being controlled by the application of an electric field

Abstract

The application discloses a word processing method of an ink screen and a communication terminal, which are used for improving the accuracy of word gray level conversion. According to the embodiment of the application, the communication terminal responds to the instruction triggered by the user to reduce the gray level of the ink screen display page, and obtains the original gray value corresponding to each character in the current ink screen display page; and drawing a preview text with the gray level of the first gray level according to the original gray value corresponding to the obtained text for each text, converting the preview text into a target text with the gray level of the second gray level, and displaying the target text on the ink screen display page. According to the embodiment of the application, the preview text with the gray level of the first gray level is redrawn according to the original gray value corresponding to each text, so that the preview text can be accurately converted into the target text with the gray level of the second gray level, the influence of transition colors around the text displayed on the current ink screen display page on the gray level conversion is eliminated, and the accuracy of the gray level conversion of the text is improved.

Description

Word processing method of ink screen and communication terminal
Technical Field
The present application relates to the field of terminal display technologies, and in particular, to a word processing method for an ink screen and a communication terminal.
Background
With the development of communication terminals, services provided by the communication terminals to users are more and more comprehensive, and the demands of users for reading articles by using the communication terminals are also increasing.
The communication terminal with the ink screen meets the requirements of the electronic reading market, is widely applied, and can only display gray images or characters due to the physical characteristics of the ink screen. The gray scales of the images or the characters displayed on the ink screen are different, the displayed effects are different, the images with higher gray scales are displayed more clearly on the ink screen, and the images with lower gray scales are displayed more smoothly on the ink screen. When converting a higher gray level text into a lower gray level text, a saw-tooth shape may be displayed in error in the converted text.
Disclosure of Invention
The invention provides a word processing method of an ink screen and a communication terminal, which are used for improving the accuracy of word gray level conversion of the ink screen.
According to a first aspect in an exemplary embodiment, there is provided a communication terminal comprising:
a touch screen configured to receive a touch operation from a user;
a display screen configured to display a user interface;
A processor coupled to the touch screen and the display screen, respectively, the processor configured to:
responding to an instruction triggered by a user to reduce the gray level of the ink screen display page, and acquiring an original gray value corresponding to each character in the current ink screen display page;
drawing a preview text with a gray level of a first gray level according to the acquired original gray value corresponding to each text, converting the preview text into a target text with a gray level of a second gray level, and displaying the target text on an ink screen display page;
the preview text of the first gray level is text which is not subjected to antialiasing treatment, and the first gray level is larger than the second gray level.
In the embodiment, the terminal responds to the command triggered by the user to reduce the gray level of the ink screen display page, acquires the original gray level value corresponding to each character in the current ink screen display page, draws the preview character with the gray level of the first gray level according to the original gray level value corresponding to each character, and converts the preview character into the target character with the gray level of the second gray level.
In some exemplary embodiments, the processor is further configured to:
after receiving an instruction of lowering the gray level of the ink screen display page triggered by a user, setting drawing parameters corresponding to the current ink screen display page as parameters for representing closing anti-aliasing processing before the original gray level corresponding to each word in the current ink screen display page is obtained.
In the above embodiment, after receiving the instruction triggered by the user to reduce the gray level of the display page of the ink screen, the drawing parameter is set to the parameter indicating that the antialiasing process is turned off, so that when the preview text is drawn, by reading the parameter, it is determined that the antialiasing process is not required to be performed for drawing the preview text in the text gray level conversion process, and the influence of the antialiasing process on the text gray level conversion is eliminated.
In some exemplary embodiments, the processor is specifically configured to:
and calling a drawing function to execute non-anti-aliasing drawing processing according to the acquired original gray value corresponding to the text, so as to obtain the preview text with the gray level of the first gray level.
In the above embodiment, the step of adding the transition color to the text after the antialiasing processing is deleted by directly drawing according to the original gray value corresponding to the text, thereby avoiding the influence of the transition color around the text on the text gray level conversion process and improving the accuracy of text gray level conversion.
In some exemplary embodiments, the processor is specifically configured to:
and converting the gray value of the first gray level of each pixel point in the preview text into the gray value of the second gray level according to the corresponding relation between the gray value of the first gray level and the gray value of the second gray level, so as to obtain the target text with the gray level of the second gray level.
In the above embodiment, each pixel point in the preview text is converted through the corresponding relationship between the gray value of the first gray level and the gray value of the second gray level, so that a more accurate target text of the second gray level can be obtained, and since no transition color exists around the preview text, the font of the converted target text of the second gray level is smoother, and the user experience is improved.
In some exemplary embodiments, the instruction triggered by the user to reduce the gray level of the ink screen display page is an instruction triggered by the user through a system setting interface of the communication terminal; or (b)
The instruction triggered by the user to reduce the gray level of the ink screen display page is an instruction triggered by the user through the suspension ball on the ink screen display page.
In the embodiment, the user can trigger the instruction for switching the display mode of the ink screen display page through the setting interface or the suspension ball, so that the method is more convenient and quick, and the user experience is improved.
According to a second aspect in an exemplary embodiment, there is provided a word processing method of an ink screen, including:
at a communication terminal having a processor, a memory, a touch screen, and a display screen:
responding to an instruction triggered by a user to reduce the gray level of the ink screen display page, and acquiring an original gray value corresponding to each character in the current ink screen display page;
drawing a preview text with a gray level of a first gray level according to the acquired original gray value corresponding to each text, converting the preview text into a target text with a gray level of a second gray level, and displaying the target text on an ink screen display page;
the preview text of the first gray level is text which is not subjected to antialiasing treatment, and the first gray level is larger than the second gray level.
In some exemplary embodiments, after receiving the instruction triggered by the user to reduce the gray level of the ink screen display page, before the obtaining the original gray level value corresponding to each text in the current ink screen display page, the method further includes:
and setting the drawing parameters corresponding to the current ink screen display page as parameters for representing the closing of the antialiasing treatment.
In some exemplary embodiments, the drawing the preview text with the gray level of the first gray level according to the obtained original gray value corresponding to the text includes:
and calling a drawing function to execute non-anti-aliasing drawing processing according to the acquired original gray value corresponding to the text, so as to obtain the preview text with the gray level of the first gray level.
In some exemplary embodiments, the converting the preview text into the target text with the gray level of the second gray level includes:
and converting the gray value of the first gray level of each pixel point in the preview text into the gray value of the second gray level according to the corresponding relation between the gray value of the first gray level and the gray value of the second gray level, so as to obtain the target text with the gray level of the second gray level.
In some exemplary embodiments, the instruction triggered by the user to reduce the gray level of the ink screen display page is an instruction triggered by the user through a system setting interface of the communication terminal; or (b)
The instruction triggered by the user to reduce the gray level of the ink screen display page is an instruction triggered by the user through the suspension ball on the ink screen display page.
According to a third aspect in an exemplary embodiment, there is provided a computer storage medium having stored therein computer program instructions which, when run on a computer, cause the computer to perform a word processing method of an ink screen as described above.
On the basis of conforming to the common knowledge in the field, the above preferred conditions can be arbitrarily combined to obtain the preferred embodiments of the present application.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings that are needed in the description of the embodiments will be briefly described below, it will be apparent that the drawings in the following description are only some embodiments of the present application, and that other drawings can be obtained according to these drawings without inventive effort for a person skilled in the art.
Fig. 1 is a schematic structural diagram of a communication terminal according to an embodiment of the present application;
fig. 2 is a schematic diagram schematically illustrating a software architecture of a communication terminal according to an embodiment of the present application;
fig. 3 schematically illustrates a user interface of a communication terminal according to an embodiment of the present application;
FIG. 4 is a schematic diagram illustrating antialiasing of text to add a transition color according to an embodiment of the application;
FIG. 5 is a schematic diagram illustrating a saw-tooth shape with error display in a font after gray-scale conversion according to an embodiment of the present application;
FIG. 6 is a flow chart illustrating a word processing method of an ink screen according to an embodiment of the present application;
FIG. 7a is a schematic diagram illustrating an instruction for a user to trigger a decrease in gray level of an ink screen display page through a setup interface according to an embodiment of the present application;
FIG. 7b is a schematic diagram illustrating an instruction for a user to reduce the gray level of an ink screen display page by a hover ball trigger according to an embodiment of the present application;
FIG. 8 is a schematic diagram illustrating a target text of a second gray level after conversion obtained by the text processing method of an ink screen according to an embodiment of the present application;
FIG. 9 is a flow chart illustrating a word processing method for a complete ink screen according to an embodiment of the present application;
fig. 10 is a flowchart illustrating an implementation manner of a word processing method of an ink screen based on an Android system according to an embodiment of the present application.
Detailed Description
The following description will be given in detail of the technical solutions in the embodiments of the present application with reference to the accompanying drawings. Wherein, in the description of the embodiments of the present application, unless otherwise indicated, "/" means or, for example, a/B may represent a or B; the text "and/or" is merely an association relation describing the associated object, and indicates that three relations may exist, for example, a and/or B may indicate: the three cases where a exists alone, a and B exist together, and B exists alone, and furthermore, in the description of the embodiments of the present application, "plural" means two or more than two.
The terms "first," "second," and the like, are used below for descriptive purposes only and are not to be construed as implying or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defining "a first" or "a second" may explicitly or implicitly include one or more such feature, and in the description of embodiments of the application, unless otherwise indicated, the meaning of "a plurality" is two or more.
Some terms appearing hereinafter are explained:
1. in the embodiment of the application, the term "and/or" describes the association relation of the association objects, which means that three relations can exist, for example, a and/or B can be expressed as follows: a exists alone, A and B exist together, and B exists alone. The character "/" generally indicates that the context-dependent object is an "or" relationship.
2. In the embodiment of the application, the term "gray scale", namely the gray scale, is to divide the brightness change between the brightest and darkest into a plurality of parts so as to control the brightness of the screen. Each digital image is composed of a number of dots, also known as pixels (pixels), which typically each display a number of different colors, consisting of three sub-pixels, red, green, and blue (RGB). The light source behind each sub-pixel may exhibit a different brightness level. While gray scale represents the hierarchical level of different brightness from darkest to brightest. The more such intermediate levels, the finer the picture effect that can be presented.
3. The term "antialiasing" in embodiments of the invention is also referred to as "antialiasing". Because the image is restricted by resolution, the edge of the object always presents more or less triangular saw teeth, and anti-saw teeth refer to a method for softening the edge of the image to make the edge of the image look smoother and more approximate to the object of a real object, and the method is used for improving the image quality to be soft.
4. The term "gradation" in the embodiments of the present invention means that an object is represented by a black tone, that is, an image is displayed by black having a reference color, using black of different saturation, each gradation object having one luminance value in the range of 0% (white) to 100% (black); the pixel value is quantized and then represented by one byte. If the gray scale value with continuous black-gray-white change is quantized into 256 gray scales, the gray scale value ranges from 0 to 255, the brightness is represented from deep to light, the corresponding colors in the image are from black to white, all gray scales between black and white are included, and each pixel value is one of 256 gray scales between black and white.
5. The term "image dithering algorithm" in the embodiments of the present invention refers to that for a system with fewer available colors, the number of available colors can be increased by dithering the color values at the expense of resolution; the image dithering algorithm obtains the pixel of the current point and the pixel of the adjacent point to be compared and carries out corresponding processing, so that the light quantity of one area is kept consistent. In a gray image, an visual impression of a change in hue is given by generating a binary image of black on a white background, i.e. by adjusting the density and arrangement of black and white, whereby different gray scales are visually presented.
6. The term "error diffusion algorithm" in the embodiment of the present invention refers to that when the color depth is reduced, the error of the pixel change is diffused, so that the error of the whole adjacent pixel point set becomes smaller when the naked eye observes the picture.
Fig. 1 shows a schematic configuration diagram of a communication terminal 100.
The embodiment will be specifically described below taking the communication terminal 100 as an example. It should be understood that the communication terminal 100 shown in fig. 1 is only one example, and that the communication terminal 100 may have more or fewer components than shown in fig. 1, may combine two or more components, or may have a different configuration of components. The various components shown in the figures may be implemented in hardware, software, or a combination of hardware and software, including one or more signal processing and/or application specific integrated circuits.
A hardware configuration block diagram of the communication terminal 100 in accordance with an exemplary embodiment is exemplarily shown in fig. 1. As shown in fig. 1, the communication terminal 100 includes: radio Frequency (RF) circuitry 110, memory 120, display unit 130, display unit 131, camera 140, sensor 150, audio circuitry 160, wireless fidelity (Wireless Fidelity, wi-Fi) module 170, processor 180, bluetooth module 181, and power supply 190.
The RF circuit 110 may be used for receiving and transmitting signals during the process of receiving and transmitting information or communication, and may receive downlink data of the base station and then transmit the downlink data to the processor 180 for processing; uplink data may be sent to the base station. Typically, RF circuitry includes, but is not limited to, antennas, at least one amplifier, transceivers, couplers, low noise amplifiers, diplexers, and the like.
Memory 120 may be used to store software programs and data. The processor 180 performs various functions of the communication terminal 100 and data processing by running software programs or data stored in the memory 120. Memory 120 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid-state storage device. The memory 120 stores an operating system that enables the communication terminal 100 to operate. The memory 120 of the present application may store an operating system and various application programs, and may also store code for performing the methods of the embodiments of the present application.
The display unit 130 may be used to receive input digital or character information, generate signal inputs related to user settings and function control of the communication terminal 100, and in particular, the display unit 130 may include a touch screen 1301 provided at the front of the communication terminal 100, and may collect touch operations on or near the user, such as clicking buttons, dragging scroll boxes, and the like.
The display unit 130 may also be used to display information input by a user or information provided to the user and a graphical user interface (graphical user interface, GUI) of various menus of the terminal 100. Specifically, the display unit 130 may include a display screen 1302 provided on the front surface of the communication terminal 100. The display screen 1302 may be a color liquid crystal screen, and may be configured in the form of a liquid crystal display, a light emitting diode, or the like. The display unit 130 may be used to display various graphical user interfaces described in the present application.
The touch screen 1301 may cover the display screen 1302, or the touch screen 1301 may be integrated with the display screen 1302 to implement input and output functions of the communication terminal 100, and after integration, the touch screen may be simply referred to as a touch screen. The display unit 130 may display the application program and the corresponding operation steps in the present application.
The display unit 131 may be used to receive input digital or character information, generate signal inputs related to user settings and function control of the communication terminal 100, and in particular, the display unit 131 may include a touch screen 1311 provided at the back of the communication terminal 100, and may collect touch operations on or near the user, such as clicking buttons, dragging scroll boxes, and the like.
The display unit 131 may also be used to display information input by a user or information provided to the user and GUIs of various menus of the terminal 100. Specifically, the display unit 131 may include a display screen 1312 provided on the back surface of the communication terminal 100. The display screen 1312 may be an ink screen, and may be configured in the form of electronic ink or the like. The display unit 131 may be used to display text, images or various graphic user interfaces of the first gray scale and the second gray scale described in the present application.
The touch screen 1311 may cover the display screen 1312, or the touch screen 1311 may be integrated with the display screen 1312 to implement input and output functions of the communication terminal 100, and after integration, the touch screen may be simply referred to as a touch screen.
The camera 140 may be used to capture still images or video. The object generates an optical image through the lens and projects the optical image onto the photosensitive element. The photosensitive element may be a charge coupled device (charge coupled device, CCD) or a Complementary Metal Oxide Semiconductor (CMOS) phototransistor. The photosensitive element converts the optical signal into an electrical signal, which is then transferred to the processor 180 for conversion into a digital image signal.
The communication terminal 100 may further include at least one sensor 150 such as an acceleration sensor 151, a distance sensor 152, a fingerprint sensor 153, a temperature sensor 154. The communication terminal 100 may be further configured with other sensors such as gyroscopes, barometers, hygrometers, thermometers, infrared sensors, light sensors, motion sensors, and the like.
The audio circuit 160, speaker 161, microphone 162 can provide an audio interface between a user and the communication terminal 100. The audio circuit 160 may transmit the received electrical signal converted from audio data to the speaker 161, and the speaker 161 converts the electrical signal into a sound signal and outputs the sound signal. The communication terminal 100 may also be configured with a volume button for adjusting the volume of the sound signal. On the other hand, the microphone 162 converts the collected sound signal into an electrical signal, which is received by the audio circuit 160 and converted into audio data, which is output to the RF circuit 110 for transmission to, for example, another terminal, or to the memory 120 for further processing. The microphone 162 of the present application may acquire the voice of the user.
Wi-Fi belongs to a short-range wireless transmission technology, and the communication terminal 100 can help a user to send and receive e-mail, browse web pages, access streaming media and the like through the Wi-Fi module 170, so that wireless broadband internet access is provided for the user.
The processor 180 is a control center of the communication terminal 100, connects various parts of the entire terminal using various interfaces and lines, and performs various functions of the communication terminal 100 and processes data by running or executing software programs stored in the memory 120 and calling data stored in the memory 120. In some embodiments, the processor 180 may include one or more processing units; the processor 180 may also integrate an application processor that primarily handles operating systems, user interfaces, applications, etc., and a baseband processor that primarily handles wireless communications. It will be appreciated that the baseband processor described above may not be integrated into the processor 180. The processor 180 of the present application may run an operating system, an application program, a user interface display and a touch response, and a processing method according to the embodiments of the present application. In addition, the processor 180 is coupled with the display unit 130.
The bluetooth module 181 is configured to perform information interaction with other bluetooth devices having a bluetooth module through a bluetooth protocol. For example, the communication terminal 100 may establish a bluetooth connection with a wearable electronic device (e.g., a smart watch) also provided with a bluetooth module through the bluetooth module 181, thereby performing data interaction.
The communication terminal 100 also includes a power supply 190 (e.g., a battery) that provides power to the various components. The power supply may be logically connected to the processor 180 through a power management system, so that functions of managing charge, discharge, power consumption, etc. are implemented through the power management system. The communication terminal 100 may also be configured with a power button for power on and off, screen locking, etc. functions of the terminal.
Fig. 2 is a software configuration block diagram of the communication terminal 100 according to the embodiment of the present invention.
The layered architecture divides the software into several layers, each with distinct roles and branches. The layers communicate with each other through a software interface. In some embodiments, the Android system is divided into four layers, from top to bottom, an application layer, an application framework layer, an Zhuoyun row (Android run) and system libraries, and a kernel layer, respectively.
The application layer may include a series of application packages.
As shown in fig. 2, the application package may include applications for cameras, gallery, calendar, phone calls, maps, navigation, WLAN, bluetooth, music, video, short messages, etc.
The application framework layer provides an application programming interface (application programming interface, API) and programming framework for application programs of the application layer. The application framework layer includes a number of predefined functions.
As shown in FIG. 2, the application framework layer may include a window manager, a content provider, a view system, a telephony manager, a resource manager, a notification manager, and the like.
The window manager is used for managing window programs. The window manager can acquire the size of the display screen, judge whether a status bar exists, lock the screen, intercept the screen and the like.
The content provider is used to store and retrieve data and make such data accessible to applications. The data may include video, images, audio, calls made and received, browsing history and bookmarks, phonebooks, etc.
The view system includes visual controls, such as controls to display text, controls to display pictures, and the like. The view system may be used to build applications. The display interface may be composed of one or more views. For example, a display interface including a text message notification icon may include a view displaying text and a view displaying a picture.
The telephony manager is used to provide communication functions of the communication terminal 100. Such as the management of call status (including on, hung-up, etc.).
The resource manager provides various resources for the application program, such as localization strings, icons, pictures, layout files, video files, and the like.
The notification manager allows the application to display notification information in a status bar, can be used to communicate notification type messages, can automatically disappear after a short dwell, and does not require user interaction. Such as notification manager is used to inform that the download is complete, message alerts, etc. The notification manager may also be a notification in the form of a chart or scroll bar text that appears on the system top status bar, such as a notification of a background running application, or a notification that appears on the screen in the form of a dialog window. For example, a text message is presented in a status bar, a presentation sound is emitted, the communication terminal vibrates, and an indicator light blinks.
Android run time includes a core library and virtual machines. Android run time is responsible for scheduling and management of the Android system.
The core library consists of two parts: one part is a function which needs to be called by java language, and the other part is a core library of android.
The application layer and the application framework layer run in a virtual machine. The virtual machine executes java files of the application program layer and the application program framework layer as binary files. The virtual machine is used for executing the functions of object life cycle management, stack management, thread management, security and exception management, garbage collection and the like.
The system library may include a plurality of functional modules. For example: surface manager (surface manager), media Libraries (Media Libraries), three-dimensional graphics processing Libraries (e.g., openGL ES), 2D graphics engines (e.g., SGL), etc.
The surface manager is used to manage the display subsystem and provides a fusion of 2D and 3D layers for multiple applications.
Media libraries support a variety of commonly used audio, video format playback and recording, still image files, and the like. The media library may support a variety of audio and video encoding formats, such as MPEG4, h.264, MP3, AAC, AMR, JPG, PNG, etc.
The three-dimensional graphic processing library is used for realizing three-dimensional graphic drawing, image rendering, synthesis, layer processing and the like.
The 2D graphics engine is a drawing engine for 2D drawing.
The kernel layer is a layer between hardware and software. The inner core layer at least comprises a display driver, a camera driver, an audio driver and a sensor driver.
The workflow of the communication terminal 100 software and hardware is exemplified in connection with capturing a photo scene.
When the touch screen 131 receives a touch operation, a corresponding hardware interrupt is issued to the kernel layer. The kernel layer processes the touch operation into the original input event (including information such as touch coordinates, time stamp of touch operation, etc.). The original input event is stored at the kernel layer. The application framework layer acquires an original input event from the kernel layer, and identifies a control corresponding to the input event. Taking the touch operation as a touch click operation, taking a control corresponding to the click operation as an example of a control of a camera application icon, the camera application calls an interface of an application framework layer, starts the camera application, further starts a camera driver by calling a kernel layer, and captures a still image or video through the camera 140.
The communication terminal 100 in the embodiment of the application can be a mobile phone, a tablet computer, a wearable device, a notebook computer, a television and the like.
Fig. 3 is a schematic diagram for illustrating a user interface on a communication terminal, such as communication terminal 100 of fig. 1. In some implementations, a user may open a corresponding application by touching an application icon on the user interface, or may open a corresponding folder by touching a folder icon on the user interface.
The ink screen adopts a printing type electronic paper technology, can provide a user with experience similar to paper reading, displays gray images, and can only display images with 16 gray scales and 2 gray scales at present due to the physical characteristics of the ink screen. The 16 gray-scale images are displayed on the ink screen more clearly, and the characters are finer; and the 2 gray-scale images are displayed on the ink screen more smoothly, and the characters are clearer.
When 16 gray-scale characters are displayed on the ink screen, anti-aliasing is performed on the characters to make the visual effect of the characters finer, transition colors are added around the characters, and then the characters are displayed, as shown in fig. 4, a schematic diagram for adding the transition colors to the characters in the anti-aliasing process is shown;
When the ink screen displays the characters with 16 gray scales, in order to make the page loading speed faster, when the user triggers an instruction for reducing the gray scale of the display page of the ink screen, the characters with 16 gray scales are converted to 2 gray scales through an error diffusion algorithm, the transition color around the characters caused by antialiasing treatment can influence the black-white conversion of the characters, the communication terminal can misjudge the transition color around the characters as the characters, and the converted characters have the saw-tooth shape displayed in error, as shown in fig. 5.
Based on the above problems, an embodiment of the present invention provides a word processing method for an ink screen, as shown in fig. 6, including the following steps:
step S601, a terminal responds to an instruction triggered by a user to reduce the gray level of an ink screen display page, and an original gray value corresponding to each character in the current ink screen display page is obtained;
step S602, drawing preview characters with gray levels of a first gray level according to the original gray values corresponding to the acquired characters for each character, converting the preview characters into target characters with gray levels of a second gray level, and displaying the target characters on an ink screen display page; the preview text of the first gray level is text which is not subjected to antialiasing treatment, and the first gray level is larger than the second gray level.
According to the embodiment of the invention, the terminal responds to the command triggered by the user to reduce the gray level of the ink screen display page, acquires the original gray level corresponding to each character in the current ink screen display page, draws the preview character with the gray level of the first gray level according to the original gray level corresponding to each character, and converts the preview character into the target character with the gray level of the second gray level.
It should be noted that, the first gray level and the second gray level are gray levels of the ink screen for supporting display, wherein the first gray level is greater than the second gray level; the embodiment of the invention does not limit the gray level of the first gray level and the second gray level, and any gray level supported by the ink screen is applicable.
In implementation, the user of the embodiment of the invention can trigger the instruction for reducing the gray level of the display page of the ink screen by the following modes:
mode 1, user triggers an instruction through a system setup interface
The display modes of the ink screen display page comprise a clear mode and a very fast mode; for example, when the display mode is a clear mode, the ink screen displays characters with 16 gray levels, the displayed characters have finer edges, and the ink screen is suitable for reading scenes; when the display mode is a smooth mode or a very fast mode, the ink screen displays characters with gray level of 2 gray levels on the page, and the displayed characters are clear and suitable for fast browsing articles or displaying two-dimensional codes.
When the display mode of the current ink screen display page is a clear mode, a user can select to switch the display mode to a high-speed mode on a system setting interface of the communication terminal, and an instruction for reducing the gray level of the ink screen display page is triggered;
for example, as shown in fig. 7a, the user may set the display mode to the extreme speed mode by selecting the display mode of the ink screen display page on the setting interface, triggering an instruction to lower the gray scale of the ink screen display page.
Mode 2, user triggering an instruction via a hover ball
When the display mode of the current ink screen display page is a clear mode, a user can select to switch the display mode to a high-speed mode in a window expanded by the suspension ball by clicking the suspension ball on the ink screen display page, and an instruction for reducing the gray level of the ink screen display page is triggered;
for example, as shown in fig. 7b, the user may trigger an instruction to decrease the gray level of the ink screen display page by selecting the display mode of the ink screen display page in the window where the hover ball is spread, and setting the display mode to the extreme speed mode.
It should be noted that, the above manner in which the user triggers the instruction for reducing the gray level of the ink screen display page is merely an example of the embodiment of the present invention, and the manner in which the embodiment of the present invention intends to protect the user from triggering the instruction for reducing the gray level of the ink screen display page is not limited to the above example.
In order to clear the characters displayed in the current display page, the communication terminal responds to an instruction triggered by a user to reduce the gray level of the ink screen display page and then clear the cache parameters in the cache space corresponding to the current ink screen display page; the cache parameters in the cache space corresponding to the current ink screen display page are cache parameters corresponding to characters displayed in the current ink screen display page;
Specifically, in the clear mode, the characters displayed on the display page of the ink screen are characters with first gray scale, wherein transition colors are added around the characters through antialiasing, so that the buffer parameters in the buffer space corresponding to the current display page of the ink screen are gray scale values corresponding to each character after antialiasing.
In the embodiment of the application, after responding to an instruction triggered by a user to reduce the gray level of an ink screen display page, a communication terminal sets a drawing parameter corresponding to the current ink screen display page as a parameter for representing the closing anti-aliasing processing;
in a specific implementation, parameters related to the realization of the paint class, the canvas class and the native layer are synchronously set as parameters for representing the shutdown of the antialiasing treatment.
After clearing the buffer parameters in the buffer space corresponding to the current ink screen display page, the communication terminal acquires the original gray value corresponding to each character in the current ink screen display page;
in a specific implementation, a page layout file corresponding to a current ink screen display page is read, and an original gray value corresponding to each text in the current ink screen display page is obtained, wherein the original gray value corresponding to each text can be a gray value matrix corresponding to all pixel points forming the text.
After the original gray value corresponding to each word in the current ink screen display page is obtained, drawing a preview word with the gray level of the first gray level according to the obtained original gray value corresponding to each word, in specific implementation, calling a drawing function, reading whether the parameter for starting antialiasing treatment in the drawing parameters is "off", and executing non-antialiasing drawing treatment to obtain the preview word with the gray level of the first gray level.
It should be noted that, the drawing function may be a paint-like paint-java function, and the non-antialiasing drawing is performed by directly drawing the text according to the original gray value corresponding to each text, without adding a transition color to the antialiasing process for the text.
After drawing to obtain a preview text with a first gray level, converting the preview text into a target text with a second gray level;
in one possible implementation manner, according to a corresponding relationship between the gray value of the first gray level and the gray value of the second gray level, the gray value of the first gray level of each pixel point in the preview text is converted into the gray value of the second gray level, so as to obtain the target text with the gray level of the second gray level.
For example, when the first gray level is 16 gray levels and the second gray level is 2 gray levels, the corresponding relation between the gray level values of the first gray level and the gray level values of the second gray level is that 0-7 gray levels in the 16 gray levels correspond to 0 gray level in the 2 gray levels; the 8-15 gray values in the 16 gray scales correspond to the 1 gray value in the 2 gray scales; converting 0-7 gray scale values of 16 gray scales of pixel points in the preview text into 0 gray scale values of 2 gray scales, converting 8-15 gray scale values of 16 gray scales of pixel points in the preview text into 1 gray scale values of 2 gray scales, and obtaining target text with 2 gray scales;
or when the first gray level is 8 gray levels and the second gray level is 4 gray levels, the corresponding relation between the gray level values of the first gray level and the gray level values of the second gray level is that the 0 gray level and the 1 gray level value in the 8 gray levels correspond to the 0 gray level value in the 4 gray levels; the 2, 3 gray values in the 8 gray scale correspond to the 1 gray value in the 4 gray scale; the 4, 5 gray values in the 8 gray scale correspond to the 2 gray values in the 4 gray scale; the 6, 7 gray values in the 8 gray scale correspond to the 3 gray values in the 4 gray scale; converting the 0, 1 gray scale value of 8 gray scales of the pixel points in the preview text into the 0 gray scale value of 4 gray scales; converting 2 and 3 gray values in 8 gray scales of pixel points in the preview text into 1 gray value in 4 gray scales; converting the 4, 5 gray values in the 8 gray levels of the pixel points in the preview text into 2 gray values in the 4 gray levels; and converting the 6 and 7 gray values in the 8 gray scales of the pixel points in the preview text into the 3 gray values in the 4 gray scales to obtain the target text with the gray scale of 4 gray scales.
After the gray value conversion is carried out on the preview text to obtain the target text, gray processing is carried out on the target text according to an image dithering algorithm, the gray value of the second gray level of each pixel point is adjusted according to the gray level relation between each pixel in each text and the surrounding pixels, the target text which is finally used for displaying is obtained, and the target text is displayed on a display page of the ink screen.
As shown in fig. 8, the converted target text with the second gray level obtained by the text processing method of the ink screen according to the embodiment of the present invention no longer has a saw-tooth shape that is displayed in error.
As shown in fig. 9, a flowchart of a word processing method for a complete ink screen according to an embodiment of the present invention includes the following steps:
step S901, a terminal responds to an instruction triggered by a user to reduce the gray level of an ink screen display page, and clears a buffer parameter in a buffer space corresponding to the current ink screen display page;
step S902, setting drawing parameters corresponding to a current ink screen display page as parameters for representing the closing of anti-aliasing processing;
step 903, obtaining an original gray value corresponding to each text in a current ink screen display page;
step S904, drawing preview characters with gray levels of first gray levels according to the original gray values corresponding to the acquired characters for each character;
Step S905, converting the gray value of the first gray level of each pixel point in the preview text into the gray value of the second gray level according to the corresponding relation between the gray value of the first gray level and the gray value of the second gray level, so as to obtain a target text with the gray level of the second gray level;
step S906, carrying out gray processing on the target characters according to an image dithering algorithm to obtain target characters which are finally used for displaying, and displaying the target characters on a display page of the ink screen.
The embodiment of the invention also provides an implementation mode of the word processing method of the ink screen based on the Android system, as shown in fig. 10, comprising the following steps:
step S1001, a frame layer receives an instruction triggered by a user to reduce the gray level of a display page of an ink screen, sets an antialiasing treatment flag bit to be 'closed', and synchronously sets antialiasing treatment flag bits of parameters related to the realization of the paint class, the canvas class and the active layer thereof to be 'closed';
step S1002, a frame layer transmits an instruction to an Activity, the Activity calls an index function, a ViewGroup corresponding to a current ink screen display page is extracted, the ChildView is traversed circularly, an original gray value corresponding to each character is obtained, and cache parameters in a cache space corresponding to the current ink screen display page are cleared;
Step S1003, calling a paint function, and drawing a preview text with a gray level of a first gray level according to an original gray value corresponding to the obtained text;
step S1004, converting the gray value of the first gray level of each pixel point in the preview text into the gray value of the second gray level by the layer according to the corresponding relation between the gray value of the first gray level and the gray value of the second gray level;
step S1005, adjusting the gray level value of the second gray level of each pixel point according to the gray level relation between the pixel and the surrounding pixels by an image dithering algorithm to obtain target characters with the gray level of the second gray level;
step S1006, displaying the target text on the display page of the ink screen.
The embodiments of the present application also provide a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of any of the methods described above.
Since the communication terminal and the computer storage medium in the embodiments of the present application may be applied to the above-mentioned processing method, the technical effects that can be obtained by the communication terminal and the computer storage medium may also refer to the above-mentioned method embodiments, and the embodiments of the present application are not described herein again.
Those of ordinary skill in the art will appreciate that: all or part of the steps for implementing the method embodiments described above may be performed by hardware associated with program instructions. The foregoing program may be stored in a computer readable storage medium. The program, when executed, performs steps including the method embodiments described above; and the aforementioned storage medium includes: various media that can store program code, such as ROM, RAM, magnetic or optical disks.
While specific embodiments of the invention have been described above, it will be appreciated by those skilled in the art that these are by way of example only, and the scope of the invention is defined by the appended claims. Various changes and modifications to these embodiments may be made by those skilled in the art without departing from the principles and spirit of the invention, but such changes and modifications fall within the scope of the invention.

Claims (10)

1. A communication terminal, comprising:
a touch screen configured to receive a touch operation from a user;
a display screen configured to display a user interface;
a processor coupled to the touch screen and the display screen, respectively, the processor configured to:
responding to an instruction triggered by a user to reduce the gray level of an ink screen display page, and clearing cache parameters in a cache space corresponding to the ink screen display page, wherein the cache parameters are cache parameters corresponding to characters displayed in a current ink screen display page, and the characters displayed in the current ink screen display page are characters subjected to antialiasing treatment; acquiring an original gray value corresponding to each character in a current ink screen display page;
The following operations are respectively executed for each text:
according to the acquired original gray value corresponding to the characters, performing non-anti-aliasing drawing processing to obtain preview characters with gray levels of first gray levels, wherein the preview characters with the first gray levels are characters without anti-aliasing processing, and the preview characters with the first gray levels do not comprise transition colors;
converting the preview text into target text with a gray level of second gray level, wherein the first gray level is larger than the second gray level;
and carrying out gray level processing on the target characters, and adjusting the gray level value of the second gray level of each pixel point according to the gray level relation between each pixel in each character and the surrounding pixels to obtain the target characters which are finally used for displaying, and displaying the target characters on an ink screen display page, wherein the displayed target characters do not comprise the saw-tooth shapes which are displayed in error.
2. The communication terminal of claim 1, wherein the processor is further configured to:
after receiving an instruction of lowering the gray level of the ink screen display page triggered by a user, setting drawing parameters corresponding to the current ink screen display page as parameters for representing closing anti-aliasing processing before the original gray level corresponding to each word in the current ink screen display page is obtained.
3. The communication terminal of claim 2, wherein the processor is specifically configured to:
and calling a drawing function to execute non-anti-aliasing drawing processing according to the acquired original gray value corresponding to the text, so as to obtain the preview text with the gray level of the first gray level.
4. The communication terminal of claim 1, wherein the processor is specifically configured to:
and converting the gray value of the first gray level of each pixel point in the preview text into the gray value of the second gray level according to the corresponding relation between the gray value of the first gray level and the gray value of the second gray level, so as to obtain the target text with the gray level of the second gray level.
5. The communication terminal according to claim 1, wherein the user-triggered instruction to decrease the gray level of the ink screen display page is an instruction triggered by the user through a system setup interface of the communication terminal; or (b)
The instruction triggered by the user to reduce the gray level of the ink screen display page is an instruction triggered by the user through the suspension ball on the ink screen display page.
6. A method of word processing an ink screen, the method comprising:
At a communication terminal having a processor, a memory, a touch screen, and a display screen:
responding to an instruction triggered by a user to reduce the gray level of an ink screen display page, and clearing cache parameters in a cache space corresponding to the ink screen display page, wherein the cache parameters are cache parameters corresponding to characters displayed in a current ink screen display page, and the characters displayed in the current ink screen display page are characters subjected to antialiasing treatment; acquiring an original gray value corresponding to each character in a current ink screen display page;
the following operations are respectively executed for each text:
according to the acquired original gray value corresponding to the characters, performing non-anti-aliasing drawing processing to obtain preview characters with gray levels of first gray levels, wherein the preview characters with the first gray levels are characters without anti-aliasing processing, and the preview characters with the first gray levels do not comprise transition colors;
converting the preview text into target text with a gray level of second gray level, wherein the first gray level is larger than the second gray level;
and carrying out gray level processing on the target characters, and adjusting the gray level value of the second gray level of each pixel point according to the gray level relation between each pixel in each character and the surrounding pixels to obtain the target characters which are finally used for displaying, and displaying the target characters on an ink screen display page, wherein the displayed target characters do not comprise the saw-tooth shapes which are displayed in error.
7. The method of claim 6, wherein after receiving the user-triggered instruction for reducing the gray level of the ink screen display page, the method further comprises, before obtaining the original gray level value corresponding to each text in the current ink screen display page:
and setting the drawing parameters corresponding to the current ink screen display page as parameters for representing the closing of the antialiasing treatment.
8. The method of claim 7, wherein the performing the non-antialiasing rendering process according to the obtained original gray value corresponding to the text, rendering the preview text with the gray level of the first gray level, includes:
and calling a drawing function to execute non-anti-aliasing drawing processing according to the acquired original gray value corresponding to the text, so as to obtain the preview text with the gray level of the first gray level.
9. The method of claim 6, wherein converting the preview text to a target text having a grayscale level of a second grayscale level comprises:
and converting the gray value of the first gray level of each pixel point in the preview text into the gray value of the second gray level according to the corresponding relation between the gray value of the first gray level and the gray value of the second gray level, so as to obtain the target text with the gray level of the second gray level.
10. A computer storage medium having stored therein computer program instructions which, when run on a computer, cause the computer to perform the method of any of claims 6 to 9.
CN202010312055.1A 2020-04-20 2020-04-20 Word processing method of ink screen and communication terminal Active CN111508039B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010312055.1A CN111508039B (en) 2020-04-20 2020-04-20 Word processing method of ink screen and communication terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010312055.1A CN111508039B (en) 2020-04-20 2020-04-20 Word processing method of ink screen and communication terminal

Publications (2)

Publication Number Publication Date
CN111508039A CN111508039A (en) 2020-08-07
CN111508039B true CN111508039B (en) 2023-11-28

Family

ID=71877793

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010312055.1A Active CN111508039B (en) 2020-04-20 2020-04-20 Word processing method of ink screen and communication terminal

Country Status (1)

Country Link
CN (1) CN111508039B (en)

Families Citing this family (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112184595B (en) * 2020-10-23 2023-03-14 青岛海信移动通信技术股份有限公司 Mobile terminal and image display method thereof
CN112667134A (en) * 2021-01-06 2021-04-16 青岛海信移动通信技术股份有限公司 Mobile terminal and updating method of display interface thereof
CN112799557B (en) * 2021-01-28 2022-03-22 青岛海信移动通信技术股份有限公司 Ink screen display control method, terminal and computer readable storage medium
CN112925596B (en) * 2021-02-25 2022-11-15 青岛海信移动通信技术股份有限公司 Mobile terminal and display method of display object thereof
CN113053322B (en) * 2021-03-12 2022-08-02 广州文石信息科技有限公司 Display optimization method of electronic ink screen and related device
CN113596425B (en) * 2021-06-21 2023-02-07 深圳市沃特沃德信息有限公司 Image processing method and device for ink screen terminal, storage medium and intelligent device
CN113934340B (en) * 2021-09-22 2024-04-19 青岛海信移动通信技术有限公司 Terminal equipment and progress bar display method
CN115424588B (en) * 2022-10-11 2023-06-20 广州文石信息科技有限公司 Text display edge processing method and device, terminal equipment and storage medium
CN115909980B (en) * 2022-11-08 2023-10-17 广州文石信息科技有限公司 Text display optimization method, device, equipment and storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011204144A (en) * 2010-03-26 2011-10-13 Toshiba Corp Multi-gradation font drawing method and device
CN103137073A (en) * 2011-11-25 2013-06-05 上海盛轩网络科技有限公司 Residual image eliminating method and system of electronic ink screen
CN106023904A (en) * 2016-05-16 2016-10-12 深圳市博阅科技股份有限公司 Display control method and device based on electronic ink screen
CN106128369A (en) * 2016-08-31 2016-11-16 长沙丰灼通讯科技有限公司 A kind of interface processing method reducing electronic ink screen ghost
CN108847187A (en) * 2018-06-05 2018-11-20 掌阅科技股份有限公司 Screensaver displaying method, ink screen equipment and the storage medium of ink screen equipment
CN109410849A (en) * 2018-12-21 2019-03-01 上海墨案智能科技有限公司 Refresh control method, device and storage medium

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011204144A (en) * 2010-03-26 2011-10-13 Toshiba Corp Multi-gradation font drawing method and device
CN103137073A (en) * 2011-11-25 2013-06-05 上海盛轩网络科技有限公司 Residual image eliminating method and system of electronic ink screen
CN106023904A (en) * 2016-05-16 2016-10-12 深圳市博阅科技股份有限公司 Display control method and device based on electronic ink screen
CN106128369A (en) * 2016-08-31 2016-11-16 长沙丰灼通讯科技有限公司 A kind of interface processing method reducing electronic ink screen ghost
CN108847187A (en) * 2018-06-05 2018-11-20 掌阅科技股份有限公司 Screensaver displaying method, ink screen equipment and the storage medium of ink screen equipment
CN109410849A (en) * 2018-12-21 2019-03-01 上海墨案智能科技有限公司 Refresh control method, device and storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
章新友 等.《全国中医药行业高等教育"十三五"规划教材 医学图形图像处理 新世纪第3版》.中国中医药出版社,2018,第135-136页. *

Also Published As

Publication number Publication date
CN111508039A (en) 2020-08-07

Similar Documents

Publication Publication Date Title
CN111508039B (en) Word processing method of ink screen and communication terminal
CN111343339B (en) Mobile terminal and image display method thereof
CN111597000B (en) Small window management method and terminal
CN112114929B (en) Display device and image display method thereof
CN112184595B (en) Mobile terminal and image display method thereof
CN111526232B (en) Camera control method based on double-screen terminal and double-screen terminal
CN112925596B (en) Mobile terminal and display method of display object thereof
CN113038141B (en) Video frame processing method and electronic equipment
CN111193874B (en) Image display parameter adjusting method and mobile terminal
CN111031377B (en) Mobile terminal and video production method
CN114639358B (en) Ink screen refreshing method, terminal device, storage medium and program product
CN113518243A (en) Image processing method and device
CN114063945B (en) Mobile terminal and image display method thereof
CN113934340B (en) Terminal equipment and progress bar display method
CN112799557B (en) Ink screen display control method, terminal and computer readable storage medium
CN114449171B (en) Method for controlling camera, terminal device, storage medium and program product
CN113360122B (en) Mobile terminal and text display method thereof
CN114863432A (en) Terminal device, contrast adjusting method, device and medium
CN114067758B (en) Mobile terminal and image display method thereof
CN115033199A (en) Mobile terminal and image display method thereof
CN113542711A (en) Image display method and terminal
CN115334239B (en) Front camera and rear camera photographing fusion method, terminal equipment and storage medium
CN111479075B (en) Photographing terminal and image processing method thereof
CN117055779B (en) Application interface display method, terminal equipment and storage medium
CN111414142B (en) Mobile terminal and display method of application interface thereof

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
CB02 Change of applicant information
CB02 Change of applicant information

Address after: 266071 Shandong city of Qingdao province Jiangxi City Road No. 11

Applicant after: Qingdao Hisense Mobile Communication Technology Co.,Ltd.

Address before: 266071 Shandong city of Qingdao province Jiangxi City Road No. 11

Applicant before: HISENSE MOBILE COMMUNICATIONS TECHNOLOGY Co.,Ltd.

GR01 Patent grant
GR01 Patent grant