Skip to content

p575 Unify description field#5902

Open
akleshchev wants to merge 2 commits into
developfrom
andreyk/viewer_p575
Open

p575 Unify description field#5902
akleshchev wants to merge 2 commits into
developfrom
andreyk/viewer_p575

Conversation

@akleshchev
Copy link
Copy Markdown
Contributor

Landmarks permit newlines in the description, but also permit pipes (which breaks notecards), other items permit neither. Unified requirements.

P.S. I will create a ticket for CopyInventoryFromNotecard separately and a bit later.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR standardizes the validation rules for inventory/landmark description fields so they can contain newlines while still disallowing the pipe (|) character (which is used as a legacy delimiter and can break notecard-style serialization). It also hardens legacy inventory item stream import/export to better preserve multi-line descriptions by escaping/unescaping newlines.

Changes:

  • Introduces/renames a text validator to allow ASCII + newline while excluding |, and wires it up via XUI prevalidator attributes.
  • Updates the validator error string for the new “newline + ASCII (no pipe)” rule.
  • Updates LLInventoryItem legacy stream import/export to escape/unescape newlines and reassemble multi-line desc fields split across lines.

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
indra/newview/skins/default/xui/en/strings.xml Adds a new validator error string for the no-pipe, newline-allowing validator.
indra/newview/skins/default/xui/en/sidepanel_item_info.xml Switches the description field to a newline-allowing, no-pipe validator.
indra/newview/skins/default/xui/en/panel_landmark_info.xml Switches landmark notes to the newline-allowing, no-pipe validator.
indra/newview/skins/default/xui/en/floater_create_landmark.xml Switches landmark creation notes to the newline-allowing, no-pipe validator.
indra/llui/lltextvalidate.h Renames the exported validator symbol to the new “newline + no pipe” variant.
indra/llui/lltextvalidate.cpp Implements the “newline + ASCII excluding pipe” validator and registers it as ascii_with_newline_no_pipe.
indra/llinventory/llinventory.cpp Escapes newlines on export, reassembles multi-line desc on import, and unescapes back to the original content.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread indra/newview/skins/default/xui/en/strings.xml
Comment thread indra/newview/skins/default/xui/en/sidepanel_item_info.xml
Comment thread indra/newview/skins/default/xui/en/panel_landmark_info.xml
Comment thread indra/newview/skins/default/xui/en/floater_create_landmark.xml
Comment thread indra/llinventory/llinventory.cpp
@akleshchev akleshchev force-pushed the andreyk/viewer_p575 branch from 172bc55 to f052c24 Compare June 5, 2026 22:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants