五月天青色头像情侣网名,国产亚洲av片在线观看18女人,黑人巨茎大战俄罗斯美女,扒下她的小内裤打屁股

歡迎光臨散文網(wǎng) 會(huì)員登陸 & 注冊(cè)

Android QPython3 可視化-輸出窗體:Output.py

2020-10-04 07:58 作者:乘著船  | 我要投稿

#需要BaseWindow.py? https://www.bilibili.com/read/cv8680125


from BaseWindow import *

XML="""<?xml version="1.0" encoding="utf-8"?>

<LinearLayout

android:layout_width="fill_parent"

android:layout_height="fill_parent"

android:background="#9f5f00"

android:orientation="vertical"

xmlns:android="http://schemas.android.com/apk/res/android">

<LinearLayout

android:layout_width="fill_parent"

android:layout_height="fill_parent"

android:orientation="vertical"

android:layout_weight="20">

<ScrollView? ?

? ? ? ? android:layout_width="fill_parent"? ?

? ? ? ? android:layout_height="fill_parent" >?

<LinearLayout

android:layout_width="fill_parent"

android:layout_height="fill_parent"

android:orientation="vertical"

android:layout_weight="20">

? ? <EditText

android:id="@+id/editNew"

android:layout_width="fill_parent"

android:layout_height="wrap_content"

android:textSize="8dp"

android:text=""

android:textColor="#0000ff"

android:layout_weight="1"

/>

<EditText

android:id="@+id/editOld"

android:layout_width="fill_parent"

android:layout_height="wrap_content"

android:textSize="8dp"

android:text=""

android:textColor="#ff0000"

android:layout_weight="1"

/>

</LinearLayout>

</ScrollView>

? ? </LinearLayout>

<LinearLayout

android:layout_width="fill_parent"

android:layout_height="100dp"

android:orientation="horizontal"

android:layout_weight="8">

<Button

android:layout_width="fill_parent"

android:layout_height="fill_parent"

android:text="繼續(xù)(保留)"

android:id="@+id/but_conf"

android:textSize="8dp"

android:background="#2f3f8f"

android:textColor="#ffffffff"

android:layout_weight="1"

android:gravity="center"/>

<Button

android:layout_width="fill_parent"

android:layout_height="fill_parent"

android:text="復(fù)制"

android:id="@+id/but_copy"

android:textSize="8dp"

android:background="#7f7f00"

android:textColor="#ffffffff"

android:layout_weight="1"

android:gravity="center"/>

<Button

android:layout_width="fill_parent"

android:layout_height="fill_parent"

android:text="繼續(xù)(清除)"

android:id="@+id/but_canc"

android:textSize="8dp"

android:background="#6f1f6f"

android:textColor="#ffffffff"

android:layout_weight="1"

android:gravity="center"/>

</LinearLayout>

</LinearLayout>"""

class MainScreen(Layout):

? ? def on_show(self):

? ? ? ? self.views.but_conf.add_event(click_EventHandler(self.views.but_conf,self.conf))

? ? ? ? self.views.but_copy.add_event(click_EventHandler(self.views.but_copy,self.copy))

? ? ? ? self.views.but_canc.add_event(click_EventHandler(self.views.but_canc,self.canc))

? ? ? ? self.views.editNew.text=clbr(self.New)

? ? ? ? global First

? ? ? ? if First:

? ? ? ? ? ? self.views.editOld.text=First

? ? ? ? ? ? First=None

? ? ? ? else:

? ? ? ? ? ? self.views.editOld.text=clbr(self.Old)

? ? ? ? MainScreen.Old=self.Old+self.New

? ? ? ? MainScreen.New=''

? ? def on_close(self):

? ? ? ? pass

? ? def copy(self,view,dummy):

? ? ? ? droid.setClipboard(self.Old)

? ? ? ? droid.makeToast("文本已復(fù)制")

? ? def conf(self,view,dummy):

? ? ? ? FullScreenWrapper2App.close_layout()

? ? def canc(self,view,dummy):

? ? ? ? MainScreen.Old=''

? ? ? ? FullScreenWrapper2App.close_layout()

? ? Old='';New=''

def clbr(x):

#去掉頭尾空行

? ? t=True

? ? while t:

? ? ? ? t=False

? ? ? ? if x and x[0]=='\n':

? ? ? ? ? ? x=x[1:]

? ? ? ? ? ? t=True

? ? ? ? if x and x[-1]=='\n':

? ? ? ? ? ? x=x[:-1]

? ? ? ? ? ? t=True

? ? return x

First='上/藍(lán):最新輸出\n下/紅:歷史輸出\n這是標(biāo)準(zhǔn)輸出窗口\n此提示只顯示一次'

def Output(Content=''):#主函數(shù)

#輸出窗體(內(nèi)容str)

#不會(huì)自動(dòng)換行

#輸出:None

? ? MainScreen.New=Content

? ? FullScreenWrapper2App.show_layout(MainScreen(XML,'Output'))

? ? FullScreenWrapper2App.eventloop()

__all__=('Output','droid')


Output('測(cè)試\n內(nèi)容')


作者:乘著船@Bilibili

更多文章+下載鏈接:https://www.bilibili.com/read/readlist/rl321663


Android QPython3 可視化-輸出窗體:Output.py的評(píng)論 (共 條)

分享到微博請(qǐng)遵守國家法律
邓州市| 临颍县| 禄劝| 博野县| 海丰县| 榕江县| 墨竹工卡县| 梁山县| 静宁县| 乌拉特前旗| 始兴县| 耒阳市| 富源县| 万荣县| 任丘市| 怀安县| 海口市| 拉萨市| 丹东市| 新绛县| 深泽县| 石柱| 大化| 碌曲县| 特克斯县| 岢岚县| 临洮县| 平罗县| 陵川县| 陈巴尔虎旗| 宜兰市| 镇雄县| 南丹县| 泰安市| 荔波县| 海安县| 澄迈县| 宜君县| 禄劝| 旅游| 文成县|