# The chat window, laid out as the 2002 applet (net.spray.chat.normal.b): the tabs Salons, Connecté(e)s, Options, # Ami(e)s, the room, one per private talk; one page each. Code behind: src/Form/ChatForm.php. Texts in English # (keys of config/lang.yaml): the applet's French words are the French translation. form: title: CaraChat theme: light layout: column padding: 0 gap: 0 scroll: false background: '#c0c0c0' children: - {class: App\Gui\TabBar, id: tabs, events: {change: onTabsChange}} # ---- the room --------------------------------------------------------------------------------------------- - type: row id: roomPane height: fill gap: 8 padding: 6 items: stretch visible: false children: # a phone: the talk, the members and the smileys one at a time, chosen here (ChatForm::adapt) - {class: App\Gui\TabBar, id: roomSwitch, strip: '#c0c0c0', visible: false, events: {change: onRoomSwitchChange}} - type: column id: roomMain grow: 1 height: fill gap: 4 children: - {class: App\Gui\Etched, id: talkBox, title: Dialogue, height: fill, children: [{class: App\Gui\ChatList, id: talk, max: 2000, follow: true, tooltips: true, events: {click: onTalkClick, activate: onTalkActivate}}]} - {type: label, id: topic, text: '', size: 12, wrap: false} - type: row id: lineRow gap: 8 children: - {class: App\Gui\AwtCheck, id: privateMsg, text: 'Private message', minWidth: 160, background: '#d4d4d4', events: {change: onPrivateMsgChange}} - {class: App\Gui\AwtText, id: line, maxLength: 192, grow: 1, events: {submit: onSendClick}} - type: row id: optsRow gap: 8 wrap: true children: - {class: App\Gui\AwtCheck, id: noPrivate, text: 'No new private talks', minWidth: 160, background: '#d4d4d4', events: {change: onFlagsChange}} - {class: App\Gui\AwtChoice, id: color, size: 10, width: 96, items: [Black, Blue, Red, Pink, Orange, Grey, 'Navy blue', Maroon, Green, Mauve, Gold, Rainbow], selected: 0} - {class: App\Gui\AwtChoice, id: size, size: 10, width: 96, items: [Speak, Whisper, Shout, Wave], selected: 0} - {type: spacer, id: optsSpacer} - {class: App\Gui\AwtButton, id: send, text: Send, events: {click: onSendClick}} - type: column id: roomSide width: 236 height: fill gap: 4 children: - {class: App\Gui\TabBar, id: sideTabs, strip: '#c0c0c0', events: {change: onSideTabsChange}} - {class: App\Gui\Etched, id: membersBox, title: 'Members of the room', height: fill, children: [{class: App\Gui\ChatList, id: members, max: 100, follow: false, selectable: true, tooltips: true, events: {activate: onMembersActivate, change: onMembersChange}}]} - {class: App\Gui\Etched, id: smileysBox, title: 'Special smileys', height: fill, visible: false, children: [{class: App\Gui\SmileyGrid, id: roomSmileys, events: {change: onSmileyPicked}}]} - {type: label, id: membersCount, text: '', size: 12} - type: row gap: 6 wrap: true children: - {type: label, text: 'Sort by:', size: 12} - {class: App\Gui\AwtRadio, id: sortNick, text: Nickname, group: sort, events: {change: onSortChange}} - {class: App\Gui\AwtRadio, id: sortSex, text: Sex, group: sort, checked: true, events: {change: onSortChange}} - type: row gap: 6 children: - {class: App\Gui\AwtButton, id: ignoreBtn, text: Ignore, grow: 1, enabled: false, events: {click: onIgnoreClick}} - {class: App\Gui\AwtButton, id: privateBtn, text: Talk, grow: 1, enabled: false, events: {click: onPrivateClick}} - {class: App\Gui\AwtButton, id: ejectBtn, text: Expel, background: '#ff6060', visible: false, enabled: false, events: {click: onEjectClick}} - {class: App\Gui\AwtButton, id: callModo, text: 'Behaviour problem', background: '#ffc800', width: fill, events: {click: onCallModoClick}} # ---- a private talk --------------------------------------------------------------------------------------- - type: row id: privatePane height: fill gap: 8 padding: 6 items: stretch visible: false children: - type: column grow: 1 height: fill gap: 4 children: - {class: App\Gui\Etched, id: pvBox, title: Dialogue, height: fill, children: [{class: App\Gui\ChatList, id: pvTalk, max: 60, follow: true, tooltips: true}]} - {type: label, id: pvTopic, text: '', size: 12, wrap: false} - type: row id: pvLineRow gap: 8 children: - {class: App\Gui\AwtText, id: pvLine, maxLength: 192, grow: 1, events: {submit: onPvSendClick}} - type: row id: pvOptsRow gap: 8 wrap: true children: - {class: App\Gui\AwtChoice, id: pvColor, size: 10, width: 96, items: [Black, Blue, Red, Pink, Orange, Grey, 'Navy blue', Maroon, Green, Mauve, Gold, Rainbow], selected: 0} - {class: App\Gui\AwtChoice, id: pvSize, size: 10, width: 96, items: [Speak, Whisper, Shout, Wave], selected: 0} - {type: spacer, id: pvSpacer} - {class: App\Gui\AwtButton, id: closeIgnore, text: 'Ignore', events: {click: onCloseIgnoreClick}} - {class: App\Gui\AwtButton, id: closePrivate, text: End, events: {click: onClosePrivateClick}} - {class: App\Gui\AwtButton, id: pvSend, text: Send, events: {click: onPvSendClick}} - type: column width: 236 height: fill gap: 4 children: - type: column class: App\Gui\Etched title: Options gap: 2 children: - {type: label, id: pvWho, text: '', size: 12, bold: true} - {type: label, id: pvAge, text: '', size: 12} - {type: label, id: pvSex, text: '', size: 12} - {type: label, id: pvCity, text: '', size: 12} - {class: App\Gui\AwtCheck, id: pvTime, text: 'Show the time', events: {change: onPvTimeChange}} - {class: App\Gui\AwtButton, id: pvFriend, text: 'Add to my friends', events: {click: onPvFriendClick}} - {class: App\Gui\Etched, title: 'Special smileys', height: fill, children: [{class: App\Gui\SmileyGrid, id: pvSmileys, events: {change: onSmileyPicked}}]} # ---- the rooms ---------------------------------------------------------------------------------------------- - type: row id: roomsPane height: fill gap: 8 padding: 6 items: stretch visible: false children: - type: column class: App\Gui\Etched title: 'Lists of the rooms' grow: 1 height: fill children: - type: row gap: 6 children: - {class: App\Gui\AwtButton, id: permanentRooms, text: 'Permanent rooms', events: {click: onPermanentRoomsClick}} - {class: App\Gui\AwtButton, id: publicRooms, text: 'Public rooms', events: {click: onPublicRoomsClick}} - {class: App\Gui\ChatList, id: rooms, max: 500, follow: false, selectable: true, tooltips: true, events: {activate: onRoomsActivate, change: onRoomsChange}} - type: row children: - {type: label, id: roomsStatus, text: '', size: 12, grow: 1} - {class: App\Gui\AwtButton, id: joinRoom, text: Join, enabled: false, events: {click: onJoinRoomClick}} - type: column width: 236 height: fill gap: 8 children: - type: column class: App\Gui\Etched title: 'Creating a room' children: - {type: label, text: 'Type of the room', size: 12} - type: row gap: 12 children: - {class: App\Gui\AwtRadio, id: newPublic, text: Public, group: kind, checked: true} - {class: App\Gui\AwtRadio, id: newPrivate, text: Private, group: kind} - {type: label, text: 'Name of the room', size: 12} - type: row gap: 6 children: - {class: App\Gui\AwtText, id: newRoom, maxLength: 30, grow: 1, events: {submit: onCreateRoomClick}} - {class: App\Gui\AwtButton, id: createRoom, text: Create, events: {click: onCreateRoomClick}} - type: column class: App\Gui\Etched title: 'Joining a private room' children: - {type: label, text: 'Name of the room', size: 12} - type: row gap: 6 children: - {class: App\Gui\AwtText, id: privateRoom, maxLength: 30, grow: 1, events: {submit: onJoinPrivateClick}} - {class: App\Gui\AwtButton, id: joinPrivate, text: Join, events: {click: onJoinPrivateClick}} # ---- the connected people (search) -------------------------------------------------------------------------- - type: row id: searchPane height: fill gap: 8 padding: 6 items: stretch visible: false children: - type: column class: App\Gui\Etched title: 'Lists of the connected people' grow: 1 height: fill children: - {class: App\Gui\ChatList, id: found, max: 500, follow: false, selectable: true, tooltips: true, events: {activate: onFoundActivate, change: onFoundChange}} - type: row gap: 6 wrap: true children: - {type: label, id: searchStatus, text: '', size: 12, grow: 1} - {class: App\Gui\AwtButton, id: foundPrivate, text: 'Talk in private', enabled: false, events: {click: onFoundPrivateClick}} - {class: App\Gui\AwtButton, id: foundIgnore, text: Ignore, enabled: false, events: {click: onFoundIgnoreClick}} - {class: App\Gui\AwtButton, id: foundJoin, text: Join, enabled: false, events: {click: onFoundJoinClick}} - type: column id: searchSide width: 236 height: fill gap: 8 children: - type: column class: App\Gui\Etched title: Search gap: 6 children: - {type: label, id: connected, text: '', size: 12} - {class: App\Gui\AwtChoice, id: searchBy, size: 12, items: ['with a nickname beginning with', 'with a city beginning with'], selected: 0} - {class: App\Gui\AwtText, id: searchText, maxLength: 20, events: {submit: onSearchClick}} - {type: label, text: '(2 letters at least)', size: 12} - type: row gap: 6 children: - {type: label, text: 'Age:', size: 12, width: 44} - {class: App\Gui\AwtChoice, id: searchAge, size: 12, grow: 1, items: [any, '5-10 y.o.', '10-15 y.o.', '15-20 y.o.', '20-25 y.o.', '25-30 y.o.', '30-40 y.o.', '40-50 y.o.', '50-60 y.o.', '60-70 y.o.', '70 and over', 'Others...'], selected: 0} - type: row gap: 6 children: - {type: label, text: 'Sex:', size: 12, width: 44} - {class: App\Gui\AwtChoice, id: searchSex, size: 12, grow: 1, items: [any, Woman, Man, "Don't know"], selected: 0} - type: row children: - {type: spacer} - {class: App\Gui\AwtButton, id: searchGo, text: Find, events: {click: onSearchClick}} # ---- options: the messages of the server, the settings ------------------------------------------------------ - type: row id: optionsPane height: fill gap: 8 padding: 6 items: stretch visible: false children: - {class: App\Gui\Etched, title: 'Lists of the information messages', grow: 1, height: fill, children: [{class: App\Gui\ChatList, id: info, max: 200, follow: true}]} - type: column width: 236 height: fill gap: 8 children: - type: column class: App\Gui\Etched title: 'Interface settings' gap: 6 children: - {class: App\Gui\HsbPicker, id: picker} - {class: App\Gui\AwtCheck, id: times, text: 'Always show the time in private talks', events: {change: onTimesChange}} - {type: label, text: Language, size: 12} - {class: App\Gui\AwtChoice, id: language, size: 12, items: [Français], selected: 0, events: {change: onLanguageChange}} - type: row gap: 6 wrap: true children: - {class: App\Gui\AwtButton, id: apply, text: Validate, events: {click: onApplyClick}} - {class: App\Gui\AwtButton, id: defaults, text: 'Default settings', events: {click: onDefaultsClick}} - {class: App\Gui\AwtButton, id: help, text: Help, events: {click: onHelpClick}} - type: column class: App\Gui\Etched title: Connection gap: 6 children: - {type: label, id: status, text: '', size: 12, wrap: true} - {class: App\Gui\AwtButton, id: quit, text: 'Leave the chat', events: {click: onQuitClick}} # ---- friends ------------------------------------------------------------------------------------------------ - type: row id: friendsPane height: fill gap: 8 padding: 6 items: stretch visible: false children: - type: column class: App\Gui\Etched title: 'List of my friends' grow: 1 height: fill children: - {class: App\Gui\ChatList, id: friends, max: 200, follow: false, selectable: true, tooltips: true, events: {activate: onFriendsActivate, change: onFriendsChange}} - type: row gap: 6 children: - {type: spacer} - {class: App\Gui\AwtButton, id: friendTalk, text: Talk, enabled: false, events: {click: onFriendTalkClick}} - {class: App\Gui\AwtButton, id: friendRemove, text: Remove, enabled: false, events: {click: onFriendRemoveClick}} - type: column width: 236 height: fill gap: 8 children: - type: column class: App\Gui\Etched title: 'My state:' gap: 6 children: - {type: label, id: mottoNow, text: '', size: 12, wrap: true} - {class: App\Gui\AwtCheck, id: busy, text: 'I am busy', events: {change: onFlagsChange}} - {type: label, text: 'Catch phrase', size: 12} - type: row gap: 6 children: - {class: App\Gui\AwtText, id: motto, maxLength: 80, grow: 1, events: {submit: onMottoClick}} - {class: App\Gui\AwtButton, id: mottoBtn, text: Broadcast, events: {click: onMottoClick}}