Simple web Online Editor Based on Contentditable Attribute
There are two ways to implement web online editor: one is based on iframe, the other is based on contenteditable.
Setting the contenteditable attribute for the element allows editability within the element's area.
<div class="textareaByDiv" contenteditable></div>
Set the css property of the editable area, which is written in le ...
Added by NYSiRacer on Fri, 21 Jun 2019 05:12:58 +0300
Summary of Android Sequencing Learning
The main functions of serialization are:
1: Permanently save the object, save the byte sequence of the object to the local file;
2: Transfer objects through serialized objects in the network;
3: Transfer objects between processes through serialization.
2. There are two kinds of serialization in Android: Serializable and arcelable.
1: Seria ...
Added by Scorptique on Thu, 20 Jun 2019 04:33:07 +0300
[java source code along the way series] PriorityQueue
Follow the recipe shown below and walk through the source code.Put together Priority Queue to summon the Dragon.Ler's go go go!
structure
/**
* Priority queue represented as a balanced binary heap: the two
* children of queue[n] are queue[2*n+1] and queue[2*(n+1)]. The
* priority queue is ordered by comparator, or by the elements'
* natur ...
Added by guttyguppy on Thu, 20 Jun 2019 03:35:18 +0300
J2SE Introduction String, String Buffer, String Builder
Introduction to J2SE (III) String, String Buffer, String Builder
String can be said to be the most frequently used class in Java, and also the knowledge points that are often asked in interviews.
I. Use of String
1. String's immutability
/**
* The {@code String} class represents character strings. All
* string literals in Java programs, such ...
Added by domainshuffle on Thu, 20 Jun 2019 03:12:45 +0300
HTML5 Picture Compression Rotation Adjustment
Picture upload is needed in recent projects, but at present, photos taken or scanned will be very large. When uploaded directly to the server, there will be too many pictures. Files will affect the upload speed, and if the resolution of the picture is too large, it is also a problem to view. So I think of using HTML 5 Canvas technology to compr ...
Added by d-woo on Thu, 20 Jun 2019 01:36:37 +0300
Unity Shader Introductory Learning Notes - Chapter 13 Using Depth and Normal Texture
Reprinted from Feng Lele's "Unity Shader Essentials"
Getting Depth and Normal Texture
Although the code for obtaining depth and normal textures in Unity is very simple, we need to understand the implementation behind them first.
Depth texture is actually a rendering texture, but the pixel value stored in it is not a color value but ...
Added by abushahin on Wed, 19 Jun 2019 22:57:36 +0300
Use of gulp tools
gulp
Multiple developers work together to develop a project. Each developer is responsible for different modules.
This results in a complete project consisting of many "code sections";
Some pre-processors such as less and sass are used to reduce the maintenance cost of CSS, and these pre-processors need to be parsed eventually.
...
Added by Quicksilver_0 on Wed, 19 Jun 2019 21:51:28 +0300
Fifty lines of code to get the bomb screen effect
Preface
In recent years, the bullet curtain has slowly become popular. We can see the image of the barrage when we watch video or live broadcasting on the internet. Sometimes the content of the barrage is even more wonderful than the content of the video itself. I also like the marble curtain very much. It's common to brush a marble curtain at ...
Added by cgchris99 on Tue, 18 Jun 2019 23:42:54 +0300
Different String, StringBuffer and StringBuilder from the Bytecode Perspective
Oracle official note:
javap
Decomposition one or more class files.
Brief description of use
javap [options] classfile...
options
Command-line options, see Options later in detail
classfile
One or more Class files (separated by multiple spaces) can use file paths or files under classPath or enter URL s
Description
The javap command decom ...
Added by rbudj on Tue, 18 Jun 2019 23:07:50 +0300
java Collection - views and wrappers
View - By using views, you can get other objects that implement the Collection-Map interface.An example of this is the keySet of the mapping class.At first glance, it looks like this method creates a new set, fills in all the keys in the map, and returns to the set.However, this is not the case.Instead, the keySet method returns a class object ...
Added by ILMV on Mon, 17 Jun 2019 19:37:53 +0300