424 questions
2
votes
1
answer
57
views
Matplotlib LaTeX text not respecting font family
I am trying to display a LaTeX-style equation in a Matplotlib plot using a custom font (Algerian). I want both the equation and the surrounding text to use the same upright (non-italic) font. Using ...
3
votes
1
answer
151
views
Plotly changes font size in 3D plot when updating via Dash
I am trying to create a 3D plot with plotly. In the plotting area, I want a grid of floating text annotations.
This is my MWE:
import plotly.graph_objs as go
import dash
from dash import html, dcc, ...
0
votes
1
answer
96
views
Text-formatting: Replace tabs with spaces in text/config file and keep the pretty formatting / reformat it via script (Python or BASH)
not sure how to categorize the following issue, I thought about relating it to BASH or Python first, but actually it's rather language-independent imo...
Anyway, I was searching but couldn't find any ...
2
votes
2
answers
180
views
PowerShell Output Formatting | Equal Spacing?
I have spent about 2 hours today working on a script to query specific Domain Controllers on the network, then verify if a service account is locked or not. And before anyone asks, I am aware of the ...
3
votes
1
answer
100
views
Proper algorithm for ltr/rtl mixed text in JavaScript?
I am using the OpenAI completions API to write text like how ChatGPT does it in the user/system message back and forth. But this is for Arabic text, and explanation of text comes back in mixture of ...
0
votes
1
answer
106
views
How to preserve text styles (bold/italic) and extract footnotes from a Word document using Python?
I’m working on a Python script to extract content from a Word document (.docx) and insert it into a SQL Server database. The challenge is that I need to preserve text styles like bold and italic, as ...
0
votes
0
answers
37
views
Streaming text from openai in next.js
"Streaming Text Formatting" – Formatting text that arrives in chunks from a stream.
"Real-time Text Structuring"
I am creating a web app using next.js and openai
When I use openai ...
0
votes
0
answers
150
views
Quill.js Resets Text to Normal on Enter Instead of Keeping Selected Size
I’m using Quill.js and need to:
Make "small" the default text size when the editor loads.
Ensure the text size persists when the user types.
Keep the selected size after pressing Enter (...
0
votes
0
answers
132
views
InvalidCastException when using <Span> to format label text in MAUI
Can I make the <Span/> elements inherit styles from parent <Label/> or freely apply styles in some way?
I've been trying to use <Span/> elements to format <Label.FormattedText/>...
0
votes
1
answer
108
views
formating text to a new field in foundry contour
I need to transform text from one field to a new one. Currently the TEXTVALUE is "202411219999".
The NEWVALUE to obtain must be like this: "2024-11-21"
I managed to use substring(&...
1
vote
2
answers
645
views
How to get current time as string in VBA?
I am trying to return the time value as a string, with no ":" or "AM/PM". I do not want the value returned as a decimal.
If it is currently 7:53 PM, I want "195300".
A ...
0
votes
4
answers
79
views
How to use lapply on strings so that they end up grouped together?
The actual issue: I'm trying to rearrange a bunch of names, street addresses, states, etc. into a nice list of addresses without any weird bracketed [row numbers], quotation marks, awkward breaks, etc....
1
vote
0
answers
51
views
How to not show double quotes in ansible run output while displaying contents of a file? [duplicate]
clean.txt file having data without any double quotes below.
[wladmin@linuxhost ~]$ cat clean.txt
REPL session history will not be persisted.
WDA-EMEA-PROD
{
db: 'WDA-EMEA-PROD',
collections: 53,
...
-1
votes
3
answers
45
views
reformat short per-line data into a(n indexed) tabular layout to fill my terminal
I have a text file containing a small piece of data on each line: Maybe it's a word, or a single number. For simplicity let's assume there are no empty lines and no headers within that file. For ...
2
votes
2
answers
149
views
How to prevent text jumping to new line when printing to div?
I've written a function for my little JavaScript project that prints text to a div akin to a dialog in an old-school game. I've included the code for this function in the snippet below, although I ...
0
votes
0
answers
311
views
Automate git commit message formatting regardless of editor
I use vim to write my commit messages, which means they get formatted "the right way" automatically. That is, as I write, my messages are formatted more or less as described in the classic ...
1
vote
1
answer
180
views
Add mail merge field with VBA and set specific font settings
The purpose of this VBA is to find the text "Something" in the document, insert a space after it, add a mail merge field named "address" and then format the inserted field with ...
1
vote
2
answers
64
views
Aligning strings in the terminal with c#
I am looking for a little assistance. I am new to C# and am trying to build a simple addition/ subtraction game for my kid to practice his skills. I have the basics working (more to develop on it) so ...
4
votes
2
answers
6k
views
Adding Line Breaks to Chakra UI <Text> element?
I'm trying to add validator warning messages to the front-end of my signup form. My application is a React.js app that's styled using Chakra UI. My validator hook function looks as follows:
const ...
0
votes
1
answer
370
views
Recognizing tags in the Text property of a TextBlock element in a WinUI 3 application
I know that the text of the TextBlock element can be formatted (italic, bold, underlined, etc.) using both C# code and XAML markup, which is very convenient. Here is an example from the MSDN site.
<...
0
votes
0
answers
90
views
How to render asciidoc tables to text?
I have some asciidoc documentation with tables, and I would like to render them for output to a text console. I'm looking for a rendition something like markdown:
| Item | Price | # In ...
1
vote
1
answer
274
views
Underline the header using forestplot
I'm trying to underline my headers for my columns of my forestplot, which I've created with the forestplot() function from the library(forestplot) package.
this is a excerpt of the settings i already ...
2
votes
1
answer
51
views
I need help on getting a preferred format for the text i pulled out with a webscraper. (Complete Beginner)
from bs4 import BeautifulSoup
import requests
def scraper(url):
url = "https://www.folhape.com.br/economia/preco-da-gasolina-cai-apos-duas-semanas-de-alta-nos-postos-diz-anp/280763/"
...
-3
votes
1
answer
1k
views
Format text as like WhatsApp or stackoverflow (Replace symbols to style as bold, italic, and strikethrough in text)
*this text is bold*,
_this text is italic_,
~this text is strikethrough~.
~_*this text is bold, italic and strike-through*_~
I want these text to be presented as,
<b>this text is bold<...
1
vote
1
answer
1k
views
Pre-wrap styling added a large indent to first paragraph
I am making a book blogging app where a user can fill out a form that includes a textarea field for the book review.
I added a pre-wrap class to the paragraph element meant to display the review text ...
1
vote
0
answers
236
views
Disable automatic text wrapping within custom word pattern in Vim
Vim/neovim's automatic line wrapping feature is great for writing reports in Markdown, but sometimes it kicks in when I don't want it to. Is there a setting somewhere that I can set a regex pattern to ...
1
vote
1
answer
683
views
Format bullet points in dynamically produced AdaptiveCard list to Teams
I have a Watcher action to message a Teams channel.
To create a nested bullet list I added the following TextBlock to my AdaptiveCard body:
"body":[
{
"type": "...
0
votes
2
answers
1k
views
Flutter input formatting in textformfield
I'm trying to format textformfield while typing. I've managed to get it working...well sort of. Currently the textformfield takes in number and works like this:
user types in number for example "...
1
vote
4
answers
3k
views
Putting text in the top left corner of google sheets cell
I'm trying to make a crossword in google sheets, and would like the clue numbers to be as far up in the top left of the cell as possible. Using the normal alignment buttons puts in in the corner, but ...
3
votes
3
answers
3k
views
Restrict leading zero in TextFormField in Flutter
Currently, I'm looking at a TextFormField restriction.
My requirement is
Allow single 0 in TextFormField
If it is 099, I want to remove the leading 0. So, it's 99
Do not allow symbols or special ...
0
votes
0
answers
27
views
Split array into custom format pyspark
I have a dataframe, where certain columns have array type data, this array has elements separated by semicolon(;) ie when i print df'column_name'[0] i.e first element in the array it will print all ...
-2
votes
2
answers
2k
views
How to copy every line in text file containing substring
I have a text file I've been viewing in visual studio code:
here is one line
problem path: path1
another line
value line more info
value
problem path: path2
incredible data line
problem path: path3
...
1
vote
1
answer
547
views
How do I format numeric values in a Panel widget?
Using the Python library Panel, I'm trying to format an IntSliderRange to f"{the_slider_number} kr" but the formatting argument in that class is not doing anything with the python text ...
2
votes
1
answer
353
views
Format raw text (from Google Forms response) into rows and columns in Google Sheets and append sheet
I have a Google Forms where I'm capturing data in the following format.
Name:Karslten [0023]
Level:1
You managed to complete:
Burpies:30
Squats:45
Bench:29
Crunch:43
TotalLoss: 981
Name:Jaeger [0119]
...
0
votes
1
answer
556
views
Format different parts of text that is in a container in android studio [duplicate]
I am using a fragment list, so I have a child .xml to manage the formatting of each bit of text within each drop down. How do I manipulate my code to embold my heading?
ItemClass
override fun ...
0
votes
1
answer
554
views
How is the height of an inline text element calculated when the browser zoom changes?
So the actual height of an inline text element is not simply the font-size value, but is determined by the individual font's metrics, as explained in this answer (see also this article).
So for the ...
0
votes
1
answer
851
views
Empty Space, Text Formatting, Google Sheets
When I use ="""" & TEXT("1468", "# ###") & """", "1 468" is returned. Perfect.
However, once 4 digits become 3 digits, I ...
1
vote
1
answer
53
views
Reformat text with arbitrary newlines into rows of equal length
Sorry that this is probably a really basic question - it seems like it ought to be easy, but I just can't figure it out.
I'm trying to write a function that, given a stream of alphabetical characters ...
1
vote
1
answer
189
views
how to make my horizontal histogram to vertical
this is a part of my program which generates * patterns from 4 user inputs
total= progresscount + trailercount + retrivercount + excludecount
print("..................................................
4
votes
1
answer
3k
views
Change timestamp variable format or do replacement
I am currently working on setting up ci/cd pipeline for pushing nuget packages.
I want to use the built-in CI_COMMIT_TIMESTAMP for version suffix however its ISO 8601 format is not valid for this.
...
1
vote
3
answers
67
views
how to add " to end of specific lines in linux
I have a file as below
"time":"2022-03-01T12:00:25.388Z","duration":0.8255,"error":0
"time":"2022-03-01T12:00:26.809Z","duration":...
3
votes
2
answers
20k
views
How to bold text in c program
How do I Bold my PrintF? .. ( I am new in C)
#include <stdio.h>
int main() {
int i;
for (i=1; i<=5; i++) {
printf("Md.Mehedi hasan");
}
return 0;
}
0
votes
2
answers
963
views
Rendering HTML Tags from Server
I have a webpage containing a text editor(tinymce), which does nice formatting to the text and then stores it in the database. The server retrieves this formatted text from database and sends it to a ...
1
vote
1
answer
954
views
Function to insert a HTML element separator every X lines of text (dynamic pagination, just like in a professional text editor)
Working on a responsive white paper for an open-source project.
Research has proven that this challenge has yet to be taken down clearly by anyone on the internet.
My original intention was to create ...
-3
votes
1
answer
1k
views
Is there any way to reduce the size of a portion of text present as a header in a Markdown file?
So I was formatting the text of a Readme.md file on GitHub. I wanted one portion of the heading [styled as heading1], to reduce in size and come right below that heading in order to just beautify the ...
1
vote
1
answer
2k
views
Style Property of TextSpan Widget in Flutter
I am working on a route that displays information about my flutter app. I've used RichText and TextSpan widgets in order to display inline hyperlinks to my email and github repo. This made it easy to ...
1
vote
1
answer
265
views
Google Sheets Script. getDisplayValues adds Leading Space
Sample File
Users add new values by copying them from an external source.
It creates a visual effect of a small leading space.
Usual formulas can delete this space:
=""&A1"
↑ will ...
0
votes
0
answers
568
views
My paragraph comes in one line instead of multiple lines as input by the user in a HTML text. I want my paragraph in the same format as input by user
This is my html code:
<td>
<pre style="white-space: pre;" id="Comments" class="value">
text here
</pre>
</td>
I have used pre tag to take care of ...
-3
votes
3
answers
638
views
Counting number of zeros in a row, adding count to new column [closed]
I have a tab-delimited table that looks like this:
chr1 100 110 + 2 3 0 8 6
chr1 150 200 + 1 4 0 2 0
chr1 200 220 + 1 4 2 0 0
chr1 250 260 + 4 2 6 1 3
I would like to count how many zeros are in ...
1
vote
3
answers
1k
views
How to decrease the line spacing in this python program?
I was learning nested loops, and ran into this problem with line spacing between each of x's lines.
numbers = [2, 2, 2, 2, 7, 7]
for i in numbers:
for j in range(0, i):
print("x"...